Function encrypt_xchacha20_poly1305

Source
pub(crate) fn encrypt_xchacha20_poly1305(
    plaintext: &[u8],
    key: &XChaCha20Poly1305Key,
) -> Result<Vec<u8>, CryptoError>
Expand description

Encrypts a plaintext message using XChaCha20Poly1305 and returns a COSE Encrypt0 message