[][src]Struct solana_libra_crypto::bls12381::BLS12381Signature

pub struct BLS12381Signature(_);

A BLS12-381 signature.

Methods

impl BLS12381Signature[src]

pub fn to_bytes(&self) -> [u8; 96][src]

Serializes a BLS12381Signature.

Methods from Deref<Target = Signature>

pub fn parity(&self) -> bool[src]

Returns true if the signature contains an odd number of ones.

pub fn to_bytes(&self) -> [u8; 96][src]

Returns a byte string representation of the signature.

Trait Implementations

impl Clone for BLS12381Signature[src]

impl Debug for BLS12381Signature[src]

impl Deref for BLS12381Signature[src]

type Target = Signature

The resulting type after dereferencing.

impl<'de> Deserialize<'de> for BLS12381Signature[src]

impl Eq for BLS12381Signature[src]

impl Hash for BLS12381Signature[src]

impl PartialEq<BLS12381Signature> for BLS12381Signature[src]

impl Serialize for BLS12381Signature[src]

impl Signature for BLS12381Signature[src]

type VerifyingKeyMaterial = BLS12381PublicKey

The associated verifying key type for this signature.

type SigningKeyMaterial = BLS12381PrivateKey

The associated signing key type for this signature

fn verify(
    &self,
    message: &HashValue,
    public_key: &BLS12381PublicKey
) -> Result<()>
[src]

Checks that signature is valid for message using public_key.

fn verify_arbitrary_msg(
    &self,
    message: &[u8],
    public_key: &BLS12381PublicKey
) -> Result<()>
[src]

Checks that signature is valid for an arbitrary &u8 message using public_key.

impl StructuralEq for BLS12381Signature[src]

impl StructuralPartialEq for BLS12381Signature[src]

impl<'_> TryFrom<&'_ [u8]> for BLS12381Signature[src]

type Error = CryptoMaterialError

The type returned in the event of a conversion error.

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> TestOnlyHash for T where
    T: Serialize + ?Sized
[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<V, T> VZip<V> for T where
    V: MultiLane<T>,