Enum keri_controller::BasicPrefix
source · pub enum BasicPrefix {
ECDSAsecp256k1NT(PublicKey),
ECDSAsecp256k1(PublicKey),
Ed25519NT(PublicKey),
Ed25519(PublicKey),
Ed448NT(PublicKey),
Ed448(PublicKey),
X25519(PublicKey),
X448(PublicKey),
}Variants§
ECDSAsecp256k1NT(PublicKey)
ECDSAsecp256k1(PublicKey)
Ed25519NT(PublicKey)
Ed25519(PublicKey)
Ed448NT(PublicKey)
Ed448(PublicKey)
X25519(PublicKey)
X448(PublicKey)
Implementations§
source§impl BasicPrefix
impl BasicPrefix
pub fn new(code: Basic, public_key: PublicKey) -> BasicPrefix
pub fn verify( &self, data: &[u8], signature: &SelfSigningPrefix, ) -> Result<bool, SignatureError>
sourcepub fn is_transferable(&self) -> bool
pub fn is_transferable(&self) -> bool
Non transferable means that the public key is always the current public key. Transferable means that the public key might have changed and you need to request KEL to obtain the newest one.
pub fn get_code(&self) -> Basic
Trait Implementations§
source§impl CesrPrimitive for BasicPrefix
impl CesrPrimitive for BasicPrefix
fn derivative(&self) -> Vec<u8>
fn derivation_code(&self) -> PrimitiveCode
fn to_str(&self) -> String
source§impl Clone for BasicPrefix
impl Clone for BasicPrefix
source§fn clone(&self) -> BasicPrefix
fn clone(&self) -> BasicPrefix
Returns a copy of the value. Read more
1.0.0 · 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 BasicPrefix
impl Debug for BasicPrefix
source§impl<'de> Deserialize<'de> for BasicPrefix
impl<'de> Deserialize<'de> for BasicPrefix
Serde compatible Deserialize
source§fn deserialize<D>(
deserializer: D,
) -> Result<BasicPrefix, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<BasicPrefix, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl FromStr for BasicPrefix
impl FromStr for BasicPrefix
source§impl Hash for BasicPrefix
impl Hash for BasicPrefix
source§impl PartialEq for BasicPrefix
impl PartialEq for BasicPrefix
source§impl Serialize for BasicPrefix
impl Serialize for BasicPrefix
Serde compatible Serialize
source§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Eq for BasicPrefix
impl StructuralPartialEq for BasicPrefix
Auto Trait Implementations§
impl Freeze for BasicPrefix
impl RefUnwindSafe for BasicPrefix
impl Send for BasicPrefix
impl Sync for BasicPrefix
impl Unpin for BasicPrefix
impl UnwindSafe for BasicPrefix
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more