note 113451 deleted from function.hash-pbkdf2 by nikic
| From: | nikic@php.net | Date: | Wed, 12 Mar 2014 13:22:32 +0000 |
| Subject: | note 113451 deleted from function.hash-pbkdf2 by nikic | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-198872@lists.php.net to get a copy of this message | ||
Note Submitter: comrade-gnarnav
----
Note: length is not an optional parameter:
<?php
hash_pbkdf2('sha256',$pass,$salt,100);
//returns: Warning: hash_pbkdf2(): Length must be greater than or equal to 0: -1273231880
?>
Use this instead:
<?php
hash_pbkdf2('sha256',$pass,$salt,100,0);
//Works as expected.
?>