Skip to main content

seal_to

Function seal_to 

Source
pub fn seal_to(
    recipient_public: &[u8; 32],
    plaintext: &[u8],
    aad: &[u8],
) -> Result<Vec<u8>, SanctuaryAuditError>
Expand description

Seal plaintext so that only the holder of the secret matching recipient_public can open it. Anonymous: the sealer needs no identity, only the recipient’s public key. Output layout: ephemeral_public(32) ‖ ciphertext ‖ tag(16). Non-deterministic (fresh ephemeral key per call).