[−][src]Struct openssl::crypto::rsa::RSA
Methods
impl RSA
[src]
impl RSA
pub fn from_public_components(n: BigNum, e: BigNum) -> Result<RSA, SslError>
[src]
pub fn from_public_components(n: BigNum, e: BigNum) -> Result<RSA, SslError>
only useful for associating the key material directly with the key, it's safer to use the supplied load and save methods for DER formatted keys.
pub fn from_private_components(
n: BigNum,
e: BigNum,
d: BigNum,
p: BigNum,
q: BigNum,
dp: BigNum,
dq: BigNum,
qi: BigNum
) -> Result<RSA, SslError>
[src]
pub fn from_private_components(
n: BigNum,
e: BigNum,
d: BigNum,
p: BigNum,
q: BigNum,
dp: BigNum,
dq: BigNum,
qi: BigNum
) -> Result<RSA, SslError>
pub unsafe fn from_raw(rsa: *mut RSA) -> RSA
[src]
pub unsafe fn from_raw(rsa: *mut RSA) -> RSA
the caller should assert that the rsa pointer is valid.
pub fn private_key_from_pem<R>(reader: &mut R) -> Result<RSA, SslError> where
R: Read,
[src]
pub fn private_key_from_pem<R>(reader: &mut R) -> Result<RSA, SslError> where
R: Read,
Reads an RSA private key from PEM formatted data.
pub fn private_key_to_pem<W>(&self, writer: &mut W) -> Result<(), SslError> where
W: Write,
[src]
pub fn private_key_to_pem<W>(&self, writer: &mut W) -> Result<(), SslError> where
W: Write,
Writes an RSA private key as unencrypted PEM formatted data
pub fn public_key_from_pem<R>(reader: &mut R) -> Result<RSA, SslError> where
R: Read,
[src]
pub fn public_key_from_pem<R>(reader: &mut R) -> Result<RSA, SslError> where
R: Read,
Reads an RSA public key from PEM formatted data.
pub fn public_key_to_pem<W>(&self, writer: &mut W) -> Result<(), SslError> where
W: Write,
[src]
pub fn public_key_to_pem<W>(&self, writer: &mut W) -> Result<(), SslError> where
W: Write,
Writes an RSA public key as PEM formatted data
pub fn size(&self) -> Result<u32, SslError>
[src]
pub fn size(&self) -> Result<u32, SslError>
pub fn sign(&self, hash: Type, message: &[u8]) -> Result<Vec<u8>, SslError>
[src]
pub fn sign(&self, hash: Type, message: &[u8]) -> Result<Vec<u8>, SslError>
pub fn verify(
&self,
hash: Type,
message: &[u8],
sig: &[u8]
) -> Result<bool, SslError>
[src]
pub fn verify(
&self,
hash: Type,
message: &[u8],
sig: &[u8]
) -> Result<bool, SslError>
pub fn as_ptr(&self) -> *mut RSA
[src]
pub fn as_ptr(&self) -> *mut RSA
pub fn n(&self) -> Result<BigNum, SslError>
[src]
pub fn n(&self) -> Result<BigNum, SslError>
pub fn has_n(&self) -> bool
[src]
pub fn has_n(&self) -> bool
pub fn d(&self) -> Result<BigNum, SslError>
[src]
pub fn d(&self) -> Result<BigNum, SslError>
pub fn e(&self) -> Result<BigNum, SslError>
[src]
pub fn e(&self) -> Result<BigNum, SslError>
pub fn has_e(&self) -> bool
[src]
pub fn has_e(&self) -> bool
pub fn p(&self) -> Result<BigNum, SslError>
[src]
pub fn p(&self) -> Result<BigNum, SslError>
pub fn q(&self) -> Result<BigNum, SslError>
[src]
pub fn q(&self) -> Result<BigNum, SslError>
Trait Implementations
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
🔬 This is a nightly-only experimental API. (
try_from
)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
🔬 This is a nightly-only experimental API. (
try_from
)Performs the conversion.
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more