diff options
author | mh <mh@immerda.ch> | 2011-11-26 16:46:10 +0100 |
---|---|---|
committer | mh <mh@immerda.ch> | 2011-11-26 16:46:10 +0100 |
commit | 328b73bc759c3b8a1acd6923410911dfaef23822 (patch) | |
tree | 86891fa48afada448ffc29030b538b977a11b677 /lib/trocla/formats/md5crypt.rb | |
parent | 372cddd123b8840d19e1651d770275ae190839b6 (diff) |
rather use salt than random string to avoid not allowed characters
Diffstat (limited to 'lib/trocla/formats/md5crypt.rb')
-rw-r--r-- | lib/trocla/formats/md5crypt.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/trocla/formats/md5crypt.rb b/lib/trocla/formats/md5crypt.rb index f52e2a1..36e3a3c 100644 --- a/lib/trocla/formats/md5crypt.rb +++ b/lib/trocla/formats/md5crypt.rb @@ -1,6 +1,6 @@ # salted crypt class Trocla::Formats::Md5crypt def format(plain_password,options={}) - plain_password.crypt('$1$' << Trocla::Util.random_str(8) << '$') + plain_password.crypt('$1$' << Trocla::Util.salt << '$') end -end
\ No newline at end of file +end |