you have switched the place of
key
and msg
positional arguments for python example.>>> import hashlib >>> import hmac >>> hmac.new(b'skey', b'abc', hashlib.sha256).hexdigest() 'ee6177854ca54cfcc49f1bf44256eefc0f9f3fb197c9af9ddf821fa4282b5906' >>> hmac.new(key=b'skey', msg=b'abc', digestmod=hashlib.sha256).hexdigest() 'ee6177854ca54cfcc49f1bf44256eefc0f9f3fb197c9af9ddf821fa4282b5906' >>>
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs