
Originally Posted by
james438
Code:
$salt='$2y$07$111111111111111111111y';
$salt='$2y$07$1111111111111111111111';
both produce the same results.
Considering how new I am to crypt() I am going to assume the discrepancies between traq and myself has to do with errors on my part. I'm still trying to get some of the basic syntax down.
Where php.net says blowfish uses a 22-character salt, I think the docs are either a) counting that last $ as one of the characters, or b) wrong. Consider:
PHP Code:
print crypt( 'hello','$2y$07$111111111111111111111y' );
# output # $2y$07$111111111111111111111uQeYcdC8/9Fn5yLUy.9ykXnYTaG3Dyhu
The output hash is prefixed with the salt - but the 'y' is omitted. One way or the other, I'm sure it's being dropped.
Bookmarks