hmac
hmac(hash-based message authentication code) is an algorithm to generate hmac from hash, the decoded secret key and the message.example
Uint8Array.toHMAC.js
1. if k(the decoded secret key) length is less 64, append zeros.2. apply 0x36^ to 1(repeated 64 times).
3. concat 2 and the message.
4. apply hash to 3.
5. apply 0x5c^ to 1(repeated 64 times).
6. concat 5 and 4.
7. apply hash to 6.