pub struct IdentityTransition {
pub old_peer: PeerId,
pub new_public: PublicIdentity,
pub created_at: u64,
pub signature: [u8; 64],
}Expand description
Old identity attests a replacement. Reachability is not silently destroyed.
Fields§
§old_peer: PeerId§new_public: PublicIdentity§created_at: u64§signature: [u8; 64]Implementations§
Source§impl IdentityTransition
impl IdentityTransition
pub fn issue( old: &PrivateIdentity, new_public: PublicIdentity, now: u64, ) -> Result<Self>
pub fn verify(&self, old_public: &PublicIdentity) -> Result<PeerId>
Trait Implementations§
Source§impl Clone for IdentityTransition
impl Clone for IdentityTransition
Source§fn clone(&self) -> IdentityTransition
fn clone(&self) -> IdentityTransition
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for IdentityTransition
impl Debug for IdentityTransition
Source§impl<'de> Deserialize<'de> for IdentityTransition
impl<'de> Deserialize<'de> for IdentityTransition
Source§fn 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
Auto Trait Implementations§
impl Freeze for IdentityTransition
impl RefUnwindSafe for IdentityTransition
impl Send for IdentityTransition
impl Sync for IdentityTransition
impl Unpin for IdentityTransition
impl UnsafeUnpin for IdentityTransition
impl UnwindSafe for IdentityTransition
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