diff options
author | natrak <> | 2001-07-25 11:34:53 +0000 |
---|---|---|
committer | natrak <> | 2001-07-25 11:34:53 +0000 |
commit | 0bddb5231d414139aebe9e95ab9f5e36c515260d (patch) | |
tree | a2a46310eb036be406f8307b5a867be10c2027fc | |
parent | 1e5afb398e3cdd53c221ff0c94ab6d79ceeaae75 (diff) | |
download | brdo-0bddb5231d414139aebe9e95ab9f5e36c515260d.tar.gz brdo-0bddb5231d414139aebe9e95ab9f5e36c515260d.tar.bz2 |
user.inc
system.module
- made the words used in passwords configurable thru the admin interface.
-rw-r--r-- | includes/user.inc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/user.inc b/includes/user.inc index 9e1370f6b..721ccfd25 100644 --- a/includes/user.inc +++ b/includes/user.inc @@ -73,8 +73,8 @@ function user_ban($mask, $type) { function user_password($min_length=6) { mt_srand((double)microtime() * 1000000); - $words = array("foo","bar","guy","neo","tux","moo","sun","asm","dot","god","axe","geek","nerd","fish","hack","star","mice","warp","moon","hero","cola","girl","fish","java","perl","boss","dark","sith","jedi","drop","mojo"); - while (strlen($password) < $min_length) $password .= $words[mt_rand(0, count($words))]; + $words = explode(",", variable_get("account_words", "foo,bar,guy,neo,tux,moo,sun,asm,dot,god,axe,geek,nerd,fish,hack,star,mice,warp,moon,hero,cola,girl,fish,java,perl,boss,dark,sith,jedi,drop,mojo")); + while (strlen($password) < $min_length) $password .= trim($words[mt_rand(0, count($words))]); return $password; } |