Auth
Authentication is a process of generating authentication data (tag) for a certain message. Its purpose is to assure that the data hasn't been corrupted or tampered with during the transport.
We support 3 variants:
without suffix - HMAC-SHA512-256 (HMAC SHA512 with just the first 256 bits used)
*HmacSha256 - HMAC-SHA256
*HmacSha512 - HMAC-SHA512
Each variant supports three operations:
keygen - generate appropriate key for MAC function
auth - generate the authentication data (tag/mac)
verify - verify that the authenticatoin data (tag/mac) is correct
Functions
Generate a HMAC-SHA512-256 authentication data - Message Authentication Code - tag
Generate a HMAC-SHA256 authentication data - Message Authentication Code - tag
Generate a secret key, meant to be used with auth function.
Verify that given message, secret key and tag, a newly calculated tag matches the received HMAC-SHA256 tag.
Generate a HMAC-SHA512 authentication data - Message Authentication Code - tag
Generate a secret key, meant to be used with auth function.
Verify that given message, secret key and tag, a newly calculated tag matches the received HMAC-SHA512 tag.
Generate a secret key, meant to be used with auth function.
Verify that given message, secret key and tag, a newly calculated tag matches the received HMAC-SHA512-256 tag.