pub unsafe extern "C" fn ocrypto_chacha20_poly1305_init(
    ctx: *mut ocrypto_chacha20_poly1305_ctx,
    n: *const u8,
    n_len: usize,
    k: *const u8
)
Expand description

ChaCha20-Poly1305 initialization.

The generator state * ctx - is initialized by this function.

  • ctx - Generator state.
  • n - Nonce.
  • n_len - Length of * n - . 0 <= * n_len - <= * ocrypto_chacha20_poly1305_NONCE_BYTES_MAX - .
  • k - Encryption key.