verifyMac(data,key,algorithm,mac)¶
Definition¶
Boolean verifyMac(Binary data, Binary key, String algorithm, Binary mac)
Description¶
Verifies the Message Authentication Code (MAC) of the specified binary data with the specified key and algorithm and returns true if the MAC generated from the data using the algorithm is the same as the given MAC, false otherwise.
Parameter Definition¶
Name | Type | Description |
---|---|---|
data | Binary | Binary data to be signed |
key | Binary | Binary value of key to be used for signing |
algorithm | String | Algorithm to be used for signing, e.g. HMAC-SHA256 |
mac | Binary | Binary mac to be verified |