pub struct DecryptingKey<D, MGD = D>{ /* private fields */ }
Expand description
Decryption key for PKCS#1 v1.5 decryption as described in RFC8017 § 7.1.
Implementations§
source§impl<D, MGD> DecryptingKey<D, MGD>
impl<D, MGD> DecryptingKey<D, MGD>
sourcepub fn new(key: RsaPrivateKey) -> Self
pub fn new(key: RsaPrivateKey) -> Self
Create a new verifying key from an RSA public key.
sourcepub fn new_with_label<S: AsRef<str>>(key: RsaPrivateKey, label: S) -> Self
pub fn new_with_label<S: AsRef<str>>(key: RsaPrivateKey, label: S) -> Self
Create a new verifying key from an RSA public key using provided label
Trait Implementations§
source§impl<D, MGD> Clone for DecryptingKey<D, MGD>
impl<D, MGD> Clone for DecryptingKey<D, MGD>
source§fn clone(&self) -> DecryptingKey<D, MGD>
fn clone(&self) -> DecryptingKey<D, MGD>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<D, MGD> Debug for DecryptingKey<D, MGD>
impl<D, MGD> Debug for DecryptingKey<D, MGD>
source§impl<D, MGD> Decryptor for DecryptingKey<D, MGD>
impl<D, MGD> Decryptor for DecryptingKey<D, MGD>
source§impl<D, MGD> RandomizedDecryptor for DecryptingKey<D, MGD>
impl<D, MGD> RandomizedDecryptor for DecryptingKey<D, MGD>
source§fn decrypt_with_rng<R: CryptoRngCore + ?Sized>(
&self,
rng: &mut R,
ciphertext: &[u8],
) -> Result<Vec<u8>>
fn decrypt_with_rng<R: CryptoRngCore + ?Sized>( &self, rng: &mut R, ciphertext: &[u8], ) -> Result<Vec<u8>>
Decrypt the given message.
impl<D, MGD> ZeroizeOnDrop for DecryptingKey<D, MGD>
Auto Trait Implementations§
impl<D, MGD> Freeze for DecryptingKey<D, MGD>
impl<D, MGD> RefUnwindSafe for DecryptingKey<D, MGD>where
D: RefUnwindSafe,
MGD: RefUnwindSafe,
impl<D, MGD> Send for DecryptingKey<D, MGD>
impl<D, MGD> Sync for DecryptingKey<D, MGD>
impl<D, MGD> Unpin for DecryptingKey<D, MGD>
impl<D, MGD> UnwindSafe for DecryptingKey<D, MGD>where
D: UnwindSafe,
MGD: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)