Struct openssl::crypto::rsa::RSA [−][src]
pub struct RSA(_);
Methods
impl RSA[src]
impl RSApub 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) -> RSAthe 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 RSApub 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) -> boolpub 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) -> boolpub 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>