pub type EphemeralKeyPair = KeyPair<Ephemeral>;
Aliased Type§
struct EphemeralKeyPair { /* private fields */ }
Implementations
Source§impl<U: Lifetime> KeyPair<U>
impl<U: Lifetime> KeyPair<U>
Sourcepub fn generate(alg: &'static Algorithm) -> Result<Self>
pub fn generate(alg: &'static Algorithm) -> Result<Self>
Generate a new key pair for the given algorithm.
pub fn from_private_key(private_key: PrivateKey<U>) -> Result<Self>
Sourcepub fn private_key(&self) -> &PrivateKey<U>
pub fn private_key(&self) -> &PrivateKey<U>
The private key.
Sourcepub fn public_key(&self) -> &PublicKey
pub fn public_key(&self) -> &PublicKey
The public key.
Sourcepub fn split(self) -> (PrivateKey<U>, PublicKey)
pub fn split(self) -> (PrivateKey<U>, PublicKey)
Split the key pair apart.