Struct schannel::crypt_prov::ImportOptions
source · pub struct ImportOptions<'a> { /* private fields */ }
Expand description
A builder for key imports.
Implementations§
source§impl<'a> ImportOptions<'a>
impl<'a> ImportOptions<'a>
sourcepub fn import(&mut self, der: &[u8]) -> Result<CryptKey>
pub fn import(&mut self, der: &[u8]) -> Result<CryptKey>
Imports a DER-encoded PKCS1 private key.
sourcepub fn import_pkcs8(&mut self, der: &[u8]) -> Result<CryptKey>
pub fn import_pkcs8(&mut self, der: &[u8]) -> Result<CryptKey>
Imports a DER-encoded PKCS8 private key.
sourcepub fn import_pkcs8_pem(&mut self, pem: &[u8]) -> Result<CryptKey>
pub fn import_pkcs8_pem(&mut self, pem: &[u8]) -> Result<CryptKey>
Imports a PEM-encoded PKCS8 private key. This functions decodes PEM blocks with or without “—–BEGIN PRIVATE KEY—–” and “—–END PRIVATE KEY—–” headers, but if PEM guards are present they must be exactly these.
Auto Trait Implementations§
impl<'a> RefUnwindSafe for ImportOptions<'a>
impl<'a> Send for ImportOptions<'a>
impl<'a> Sync for ImportOptions<'a>
impl<'a> Unpin for ImportOptions<'a>
impl<'a> !UnwindSafe for ImportOptions<'a>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more