Struct openssl::rsa::Rsa [] [src]

pub struct Rsa(_);

Methods

impl Rsa
[src]

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.

Generates a public/private key pair with the specified size.

The public exponent will be 65537.

Reads an RSA private key from PEM formatted data.

Reads an RSA private key from PEM formatted data and supplies a password callback.

Reads an RSA public key from PEM formatted data.

Methods from Deref<Target=RsaRef>

Writes an RSA private key as unencrypted PEM formatted data

Writes an RSA public key as PEM formatted data

Decrypts data using the private key, returning the number of decrypted bytes.

Panics

Panics if self has no private components, or if to is smaller than self.size().

Encrypts data using the private key, returning the number of encrypted bytes.

Panics

Panics if self has no private components, or if to is smaller than self.size().

Decrypts data using the public key, returning the number of decrypted bytes.

Panics

Panics if to is smaller than self.size().

Encrypts data using the private key, returning the number of encrypted bytes.

Panics

Panics if to is smaller than self.size().

Trait Implementations

impl OpenSslType for Rsa
[src]

The raw C type.

The type representing a reference to this type.

Constructs an instance of this type from its raw type.

impl Drop for Rsa
[src]

A method called when the value goes out of scope. Read more

impl Deref for Rsa
[src]

The resulting type after dereferencing

The method called to dereference a value

impl DerefMut for Rsa
[src]

The method called to mutably dereference a value

impl Debug for Rsa
[src]

Formats the value using the given formatter.