rsa::traits

Trait RandomizedEncryptor

source
pub trait RandomizedEncryptor {
    // Required method
    fn encrypt_with_rng<R: CryptoRngCore + ?Sized>(
        &self,
        rng: &mut R,
        msg: &[u8],
    ) -> Result<Vec<u8>>;
}
Expand description

Encrypt the message using provided random source

Required Methods§

source

fn encrypt_with_rng<R: CryptoRngCore + ?Sized>( &self, rng: &mut R, msg: &[u8], ) -> Result<Vec<u8>>

Encrypt the given message.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl RandomizedEncryptor for rsa::pkcs1v15::EncryptingKey

source§

impl<D, MGD> RandomizedEncryptor for rsa::oaep::EncryptingKey<D, MGD>
where D: Digest, MGD: Digest + FixedOutputReset,