Function tpfs_krypt::typed::decrypt

source ·
pub fn decrypt<T, E>(
    encryption: &E,
    key_id: &KeyIdentifier,
    decryption_strategy: DecryptionStrategy
) -> Result<T, Error>where
    E: SharedEncryption + ?Sized,
    T: DeserializeOwned,
Expand description

Decrypts a value

key_id is the sender’s key identifier if the decryption strategy is Sender, otherwise it is the receiver’s key identifier.

See SharedEncryption::shared_decrypt