std1.0.0-beta-7 SafeC docs

std :: crypto::chacha20

Function std::chacha20_poly1305_seal

#include <std/crypto/chacha20.h> source · definition

void chacha20_poly1305_seal(
    []const unsigned char key,
    []const unsigned char nonce,
    []const unsigned char aad,
    []unsigned char data,
    []unsigned char tag,
)

AEAD_CHACHA20_POLY1305 (RFC 8439 §2.8): encrypts data[0..len) in place and writes the 16-byte tag over aad[0..aad_len) (aad may be null when aad_len is 0) and the ciphertext.