Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $pass = "password123";
- $activationToken = bin2hex(random_bytes(16));
- $salt = bin2hex(random_bytes(16));
- $hash = hash_pbkdf2("sha512", $pass, $salt, 262144);
- echo "The following values are good for SALT and ACTIVATION that are CHAR(32) data, and HASH that is CHAR(128) data.";
- echo "password: " . $pass . "\n\n";
- echo "activation token" . $activationToken . "\n\n";
- echo "salt: " . $salt . "\n\n";
- echo "password hash: " . $hash . "\n\n";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement