Class: HmacSHA256Provider

HmacSHA256Provider()

Provides HMAC SHA-256 hashing.

Constructor

new HmacSHA256Provider()

Source:

Methods

(async) calc(hashKey, buffer, offset, count) → {Promise.<Uint8Array>}

Calculate HMAC SHA256 hash for a byte buffer.
Parameters:
Name Type Description
hashKey Uint8Array The HMAC SHA256 key to use for hashing (32 bytes).
buffer Uint8Array The buffer to read the data from.
offset number The position reading will start from.
count number The count of bytes to be read.
Source:
Throws:
IntegrityException thrown if hash cannot be calculated
Returns:
The HMAC SHA256 hash.
Type
Promise.<Uint8Array>