Struct x25519_dalek::PublicKey
source · [−]pub struct PublicKey(_);
Expand description
A Diffie-Hellman public key, corresponding to an EphemeralSecret
or
StaticSecret
key.
We implement Zeroize
so that downstream consumers may derive it for Drop
should they wish to erase public keys from memory. Note that this erasure
(in this crate) does not automatically happen, but either must be derived
for Drop or explicitly called.
Implementations
Trait Implementations
sourceimpl<'de> Deserialize<'de> for PublicKey
impl<'de> Deserialize<'de> for PublicKey
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<'a> From<&'a EphemeralSecret> for PublicKey
impl<'a> From<&'a EphemeralSecret> for PublicKey
sourcefn from(secret: &'a EphemeralSecret) -> PublicKey
fn from(secret: &'a EphemeralSecret) -> PublicKey
Given an x25519 EphemeralSecret
key, compute its corresponding PublicKey
.
sourceimpl<'a> From<&'a ReusableSecret> for PublicKey
impl<'a> From<&'a ReusableSecret> for PublicKey
sourcefn from(secret: &'a ReusableSecret) -> PublicKey
fn from(secret: &'a ReusableSecret) -> PublicKey
Given an x25519 ReusableSecret
key, compute its corresponding PublicKey
.
sourceimpl<'a> From<&'a StaticSecret> for PublicKey
impl<'a> From<&'a StaticSecret> for PublicKey
sourcefn from(secret: &'a StaticSecret) -> PublicKey
fn from(secret: &'a StaticSecret) -> PublicKey
Given an x25519 StaticSecret
key, compute its corresponding PublicKey
.
impl Copy for PublicKey
impl Eq for PublicKey
impl StructuralEq for PublicKey
impl StructuralPartialEq for PublicKey
Auto Trait Implementations
impl RefUnwindSafe for PublicKey
impl Send for PublicKey
impl Sync for PublicKey
impl Unpin for PublicKey
impl UnwindSafe for PublicKey
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more