1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00

Explain why we don't use certain characters in the generated pw

This commit is contained in:
Andrew Bartlett 2010-03-11 15:34:01 +11:00
parent a6253a45c0
commit 6441a5b0b9

View File

@ -368,6 +368,12 @@ again:
_PUBLIC_ char *generate_random_password(TALLOC_CTX *mem_ctx, size_t min, size_t max) _PUBLIC_ char *generate_random_password(TALLOC_CTX *mem_ctx, size_t min, size_t max)
{ {
char *retstr; char *retstr;
/* This list does not include { or } because they cause
* problems for our provision (it can create a substring
* ${...}, and for Fedora DS (which treats {...} at the start
* of a stored password as special
* -- Andrew Bartlett 2010-03-11
*/
const char *c_list = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+_-#.,@$%&!?:;<=>()[]~"; const char *c_list = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+_-#.,@$%&!?:;<=>()[]~";
size_t len = max; size_t len = max;
size_t diff; size_t diff;