Struct ed25519_zebra::Signature
source · #[repr(C)]pub struct Signature { /* private fields */ }
Expand description
Ed25519 signature.
This type represents a container for the byte serialization of an Ed25519 signature, and does not necessarily represent well-formed field or curve elements.
Signature verification libraries are expected to reject invalid field elements at the time a signature is verified.
Implementations§
source§impl Signature
impl Signature
sourcepub fn from_bytes(bytes: &[u8; 64]) -> Signature
pub fn from_bytes(bytes: &[u8; 64]) -> Signature
Parse an Ed25519 signature from a byte slice.
sourcepub fn from_components(R: [u8; 32], s: [u8; 32]) -> Signature
pub fn from_components(R: [u8; 32], s: [u8; 32]) -> Signature
Parse an Ed25519 signature from its R
and s
components.
Trait Implementations§
source§impl<'de> Deserialize<'de> for Signature
impl<'de> Deserialize<'de> for Signature
source§fn deserialize<D>(
deserializer: D
) -> Result<Signature, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>( deserializer: D ) -> Result<Signature, <D as Deserializer<'de>>::Error>where D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl FromStr for Signature
impl FromStr for Signature
Decode a signature from hexadecimal.
Upper and lower case hexadecimal are both accepted, however mixed case is rejected.
source§impl PartialEq<Signature> for Signature
impl PartialEq<Signature> for Signature
source§impl Serialize for Signature
impl Serialize for Signature
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
source§impl Signer<Signature> for SigningKey
impl Signer<Signature> for SigningKey
source§impl Verifier<Signature> for VerificationKey
impl Verifier<Signature> for VerificationKey
impl Copy for Signature
impl Eq for Signature
impl StructuralEq for Signature
impl StructuralPartialEq for Signature
Auto Trait Implementations§
impl RefUnwindSafe for Signature
impl Send for Signature
impl Sync for Signature
impl Unpin for Signature
impl UnwindSafe for Signature
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