Struct sm9::UserPrivateKey
source · pub struct UserPrivateKey(/* private fields */);Trait Implementations§
source§impl Clone for UserPrivateKey
impl Clone for UserPrivateKey
source§fn clone(&self) -> UserPrivateKey
fn clone(&self) -> UserPrivateKey
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for UserPrivateKey
impl Debug for UserPrivateKey
source§impl Decapsulator<Sm9EncappedKey> for UserPrivateKey
impl Decapsulator<Sm9EncappedKey> for UserPrivateKey
source§fn try_decap(
&self,
encapped_key: &Sm9EncappedKey
) -> Result<SharedSecret<Sm9EncappedKey>, Error>
fn try_decap( &self, encapped_key: &Sm9EncappedKey ) -> Result<SharedSecret<Sm9EncappedKey>, Error>
Attempt to decapsulate the given encapsulated key. Returns the shared secret on success, or
an error if something went wrong.
source§impl Default for UserPrivateKey
impl Default for UserPrivateKey
source§fn default() -> UserPrivateKey
fn default() -> UserPrivateKey
Returns the “default value” for a type. Read more
source§impl EncodeKey for UserPrivateKey
impl EncodeKey for UserPrivateKey
source§fn to_key_der(&self) -> Result<Document>
fn to_key_der(&self) -> Result<Document>
Serialize a [
Document] containing a ASN.1 DER-encoded key.source§fn read_pem_file(path: impl AsRef<Path>) -> Result<Self>
fn read_pem_file(path: impl AsRef<Path>) -> Result<Self>
Read key from given path
source§impl PartialEq for UserPrivateKey
impl PartialEq for UserPrivateKey
source§fn eq(&self, other: &UserPrivateKey) -> bool
fn eq(&self, other: &UserPrivateKey) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl PemLabel for UserPrivateKey
impl PemLabel for UserPrivateKey
impl Eq for UserPrivateKey
impl StructuralEq for UserPrivateKey
impl StructuralPartialEq for UserPrivateKey
Auto Trait Implementations§
impl RefUnwindSafe for UserPrivateKey
impl Send for UserPrivateKey
impl Sync for UserPrivateKey
impl Unpin for UserPrivateKey
impl UnwindSafe for UserPrivateKey
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