I am getting a warning from the pack function without any information. The string I am passing seems to be fine. Can anyone tell me what might be causing the issue?
$s = trim(hash_hmac('sha1', trim($stringToSign), $key));
$binary_hmac = pack(“H40”, $s);
$binary_hmac returns false.
Probably the quotes:
$binary_hmac = pack(“H40”, $s);
^---^---
those are typographical quotes (e.g. microsoft smart-but-really-moronic quotes). Try switching to the normal "
standard quotes.