Interface for AEAD modes
Interface for AEAD (Authenticated Encryption with Associated Data) modes. These modes provide both encryption and message authentication, and can authenticate additional per-message data which is not included in the ciphertext (for instance a sequence number).
Set associated data that is not included in the ciphertext but that should be authenticated. Must be called after setKey and before finish.
Unless reset by another call, the associated data is kept between messages. Thus, if the AD does not change, calling once (after setKey) is the optimum.
const(ubyte)* ad | the associated data |
size_t ad_len | length of add in bytes |
Default AEAD nonce size (a commonly supported value among AEAD modes, and large enough that random collisions are unlikely).
Return the size of the authentication tag used (in bytes)
Get an AEAD mode by name (eg "AES-128/GCM" or "Serpent/EAX")