sk_encrypt2

Function sk_encrypt2 

Source
pub fn sk_encrypt2<T>(
    secret_key: &SecretKey,
    buff: T,
    data_len: usize,
) -> Result<usize, ()>
where T: AsRef<[u8]> + AsMut<[u8]>,
Expand description

sk_encrypt2 encrypts data_len bytes of the data in-place in the provided buffer, appends NONCE and TAG information to the buffer, and returns the complete length (encrypted data + overheads)