Struct lamport_sigs::PrivateKey
[−]
[src]
pub struct PrivateKey { /* fields omitted */ }
A one-time signing private key
Methods
impl PrivateKey
[src]
fn new(algorithm: &'static Algorithm) -> PrivateKey
[src]
Generates a new random one-time signing key. This method can panic if OS RNG fails
fn public_key(&self) -> PublicKey
[src]
Returns the public key associated with this private key
fn sign(&mut self, data: &[u8]) -> Result<LamportSignatureData, &'static str>
[src]
Signs the data with the private key and returns the result if successful. If unsuccesful, an explanation string is returned
Trait Implementations
impl Clone for PrivateKey
[src]
fn clone(&self) -> PrivateKey
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for PrivateKey
[src]
impl Drop for PrivateKey
[src]
impl PartialEq for PrivateKey
[src]
fn eq(&self, other: &PrivateKey) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl Eq for PrivateKey
[src]
impl PartialOrd for PrivateKey
[src]
fn partial_cmp(&self, other: &PrivateKey) -> Option<Ordering>
[src]
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Ord for PrivateKey
[src]
fn cmp(&self, other: &PrivateKey) -> Ordering
[src]
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.22.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.22.0[src]
Compares and returns the minimum of two values. Read more