- hash_hmac: documentation ( source)
- md5: documentation ( source)
<?php
$password = "thisismypassword";
$salt = "SaltyMotherFucker";
// Our hashing method:
$hash = md5($salt . ":" . $password);
echo "Our's: $hash\n";
// Hmac - sha1
$hash = hash_hmac('sha256',$password,$salt);
echo "Hmac-sha1: $hash";