pub struct MachineKey(/* private fields */);Expand description
A machine’s key pair (Ed25519): it authenticates the machine to the
relay. Its Debug hides the private half.
Implementations§
Source§impl MachineKey
impl MachineKey
Sourcepub fn generate() -> Result<MachineKey, Error>
pub fn generate() -> Result<MachineKey, Error>
Sourcepub fn from_seed(seed: &[u8]) -> Option<MachineKey>
pub fn from_seed(seed: &[u8]) -> Option<MachineKey>
The key pair from its 32-byte private seed, if seed holds 32 bytes.
Sourcepub fn public_key(&self) -> Vec<u8> ⓘ
pub fn public_key(&self) -> Vec<u8> ⓘ
The public key, 32 bytes.
Trait Implementations§
Auto Trait Implementations§
impl Forget for MachineKey
impl Freeze for MachineKey
impl Move for MachineKey
impl RefUnwindSafe for MachineKey
impl Send for MachineKey
impl Sync for MachineKey
impl Unpin for MachineKey
impl UnsafeUnpin for MachineKey
impl UnwindSafe for MachineKey
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