[][src]Trait rsa_export::PemEncode

pub trait PemEncode: Sealed + Encode {
    pub fn as_pkcs1_pem(&self) -> Result<String, Error>;
pub fn as_pkcs8_pem(&self) -> Result<String, Error>;
pub fn as_pkcs1_pem_custom_ending(
        &self,
        line_ending: LineEnding
    ) -> Result<String, Error>;
pub fn as_pkcs8_pem_custom_ending(
        &self,
        line_ending: LineEnding
    ) -> Result<String, Error>; }

Trait for encoding the keys and wrapping them in the PEM format

Required methods

pub fn as_pkcs1_pem(&self) -> Result<String, Error>[src]

Encode in the PKCS#1 format, PEM encoded

pub fn as_pkcs8_pem(&self) -> Result<String, Error>[src]

Encode in the PKCS#8 format, PEM encoded

pub fn as_pkcs1_pem_custom_ending(
    &self,
    line_ending: LineEnding
) -> Result<String, Error>
[src]

Encode in the PKCS#1 format, PEM encoded with a custom line ending

pub fn as_pkcs8_pem_custom_ending(
    &self,
    line_ending: LineEnding
) -> Result<String, Error>
[src]

Encode in the PKCS#8 format, PEM encoded with a custom line ending

Loading content...

Implementations on Foreign Types

impl PemEncode for RSAPrivateKey[src]

pub fn as_pkcs1_pem(&self) -> Result<String, Error>[src]

Line endings default to Unix-style LF

pub fn as_pkcs8_pem(&self) -> Result<String, Error>[src]

Line endings default to Unix-style LF

pub fn as_pkcs1_pem_custom_ending(
    &self,
    line_ending: LineEnding
) -> Result<String, Error>
[src]

Encode with a different line ending

pub fn as_pkcs8_pem_custom_ending(
    &self,
    line_ending: LineEnding
) -> Result<String, Error>
[src]

Encode with a different line ending

impl PemEncode for RSAPublicKey[src]

pub fn as_pkcs1_pem(&self) -> Result<String, Error>[src]

Line endings default to Unix-style LF

pub fn as_pkcs8_pem(&self) -> Result<String, Error>[src]

Line endings default to Unix-style LF

pub fn as_pkcs1_pem_custom_ending(
    &self,
    line_ending: LineEnding
) -> Result<String, Error>
[src]

Encode with a different line ending

pub fn as_pkcs8_pem_custom_ending(
    &self,
    line_ending: LineEnding
) -> Result<String, Error>
[src]

Encode with a different line ending

Loading content...

Implementors

Loading content...