Enum thrussh_keys::key::KeyPair
source · pub enum KeyPair {
Ed25519(SecretKey),
}
Expand description
Public key exchange algorithms.
Variants§
Implementations§
source§impl KeyPair
impl KeyPair
sourcepub fn clone_public_key(&self) -> PublicKey
pub fn clone_public_key(&self) -> PublicKey
Copy the public key of this algorithm.
sourcepub fn generate_ed25519() -> Option<Self>
pub fn generate_ed25519() -> Option<Self>
Generate a key pair.
Trait Implementations§
source§impl PublicKeyBase64 for KeyPair
impl PublicKeyBase64 for KeyPair
source§fn public_key_bytes(&self) -> Vec<u8>
fn public_key_bytes(&self) -> Vec<u8>
Create the base64 part of the public key blob.
fn public_key_base64(&self) -> String
Auto Trait Implementations§
impl RefUnwindSafe for KeyPair
impl Send for KeyPair
impl Sync for KeyPair
impl Unpin for KeyPair
impl UnwindSafe for KeyPair
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