Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var AuthtagMismatch = fmt.Errorf("Authtag mismatch")
AuthtagMismatch is returned by AuthDec if authentication of the ciphertext failed.
Functions ¶
func AuthDec ¶
AuthDec performs authenticated decryption of the provided input using the provided key. See AuthEnc for more details.
On success the plaintext is returned together with a nil error.
func AuthEnc ¶
AuthEnc performs authenticated encryption of the provided input using the provided key. AES-128 is used in CBC mode with HMAC-SHA256 in encrypt-then-authenticate mode. The output is IV || ciphertext || auth-tag, where "||" is concatenation of byte slices.
On success the ciphertext is returned together with a nil error.
See also AuthDec.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.