ece

Function encrypt

Source
pub fn encrypt(
    remote_pub: &[u8],
    remote_auth: &[u8],
    data: &[u8],
) -> Result<Vec<u8>>
Expand description

Encrypt a block using the AES128GCM encryption scheme.

  • remote_pub : The public key of the remote message recipient
  • remote_auth : The authentication secret of the remote message recipient
  • data : The data to encrypt

For the equivalent function using legacy AESGCM encryption scheme use legacy::encrypt_aesgcm.