Function deltachat::decrypt::try_decrypt

source ·
pub fn try_decrypt(
    mail: &ParsedMail<'_>,
    private_keyring: &[SignedSecretKey],
    public_keyring_for_validate: &[SignedPublicKey]
) -> Result<Option<(Vec<u8>, HashSet<Fingerprint>)>>
Expand description

Tries to decrypt a message, but only if it is structured as an Autocrypt message.

If successful and the message is encrypted, returns decrypted body and a set of valid signature fingerprints.

If the message is wrongly signed, HashSet will be empty.