hmac_sha256
Generates an SHA-256 hash from a string using HMAC (Hash-based Message Authentication Code).
The filter accepts the secret key for the message as an input parameter.
Parameters
str{String}: The input string. This parameter is required.secret{String}: The secret key. This parameter is required. If not provided, an empty string is returned.returns{String}: The resulting HMAC-SHA256 hash.
Usage
{{ hmac_sha256 str secret }}
Example
{{ hmac_sha256 'hello' 'sk' }}
Was this article helpful to you?