What's secret
parameter in the hash_hmac
function and how to add a secret key ?
for example :
$mac = hash_hmac('sha256', $cookie, SECRET_KEY);
The string. This is so called salt. It will be combined with data you want to hash and makes cracking your hash more complicated (but not impossible).
$mac = hash_hmac('sha256', $cookie, 'sdKJ7_dghsJ5dj');