[−][src]Enum mundane::public::rsa::RsaPrivKeyAnyBits
An RSA private key whose bit length is unknown at compile time.
An RsaPrivKeyAnyBits
is an enum of RsaPrivKey
s over all supported bit
lengths. It is returned from RsaPrivKeyAnyBits::parse_from_der
.
Variants
B2048(RsaPrivKey<B2048>)
B3072(RsaPrivKey<B3072>)
B4096(RsaPrivKey<B4096>)
B6144(RsaPrivKey<B6144>)
B8192(RsaPrivKey<B8192>)
Methods
impl RsaPrivKeyAnyBits
[src]
#[must_use]
pub fn public(&self) -> RsaPubKeyAnyBits
[src]
Gets the public key corresponding to this private key.
#[must_use]
pub fn parse_from_der(bytes: &[u8]) -> Result<RsaPrivKeyAnyBits, Error>
[src]
Parses a private key in DER format with any bit length.
parse_from_der
is like DerPrivateKey::parse_from_der
, but it
accepts any bit length rather that a particular bit length.
Since RsaPrivKey
requires a static RsaKeyBits
type parameter,
the parse_from_der
function on RsaPrivKey
's DerPrivateKey
implementation can only be called when the bit length is known ahead of
time. This function, on the other hand, accepts any bit length.
Trait Implementations
Auto Trait Implementations
impl !Send for RsaPrivKeyAnyBits
impl Unpin for RsaPrivKeyAnyBits
impl !Sync for RsaPrivKeyAnyBits
impl RefUnwindSafe for RsaPrivKeyAnyBits
impl UnwindSafe for RsaPrivKeyAnyBits
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,