Created
November 5, 2017 17:33
-
-
Save YurePereira/ee8178b0905ed17b52c07e6c1916b986 to your computer and use it in GitHub Desktop.
Creating a password hash with the password_hash function changing the default cost in PHP
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| $password = 'myPassword'; | |
| $options = [ | |
| 'cost' => 13, | |
| ]; | |
| echo password_hash($password, PASSWORD_DEFAULT, $options); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment