klyn.cryptography.Mac.init
method
public init(key as String, keyEncoding as String = "utf8") as Void:
Description

Loads the secret key used to compute the MAC.

Parameters
ParameterDescription
keySecret key material.
keyEncodingKey encoding: utf8, hex, base64 or base64url.
Example
import klyn.cryptography

mac = Hmac(SHA256())
mac.init("secret")