[][src]Struct tapyrus::util::signature::Signature

pub struct Signature {
    pub r_x: [u8; 32],
    pub sigma: [u8; 32],
}

Schnorr signature struct

Fields

r_x: [u8; 32]

R.x

sigma: [u8; 32]

sigma

Implementations

impl Signature[src]

pub fn sign(privkey: &PrivateKey, message: &[u8; 32]) -> Result<Self, Error>[src]

signing to message

pub fn verify(&self, message: &[u8; 32], pk: &PublicKey) -> Result<(), Error>[src]

Verify signature

Trait Implementations

impl Clone for Signature[src]

impl Copy for Signature[src]

impl Debug for Signature[src]

impl Decodable for Signature[src]

impl Default for Signature[src]

impl Encodable for Signature[src]

impl Eq for Signature[src]

impl PartialEq<Signature> for Signature[src]

impl StructuralEq for Signature[src]

impl StructuralPartialEq for Signature[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Az for T[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> CheckedAs for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> OverflowingAs for T[src]

impl<T> SaturatingAs for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> WrappingAs for T[src]