pub fn box_open(
nonce: &[u8; 15],
ciphertext: Vec<u8>,
additional_data: Vec<u8>,
peers_public_key: &PublicKey,
private_key: &StaticSecret,
) -> Result<Vec<u8>>
Expand description
Unboxes (“opens”) the provided additional data and ciphertext via
Deoxys-II-256-128 using a symmetric key derived from the provided
X25519 public and private keys.
The nonce should be NONCE_SIZE
bytes long and both it and the additional
data must match the value passed to box_seal
.