[][src]Struct bls_like::single::KeypairVT

pub struct KeypairVT<E: EngineBLS> {
    pub secret: SecretKeyVT<E>,
    pub public: PublicKey<E>,
}

BLS Keypair

We create Signed messages with a Keypair to avoid recomputing the public key, which usually takes longer than signing when the public key group is G2.

We provide constant-time signing using key splitting.

Fields

secret: SecretKeyVT<E>public: PublicKey<E>

Methods

impl<E: EngineBLS> KeypairVT<E>[src]

pub fn generate<R: Rng>(rng: R) -> Self[src]

Generate a Keypair

pub fn into_split<R: Rng>(&self, rng: R) -> Keypair<E>[src]

Convert into a SecretKey applying side channel protections.

pub fn sign(&self, message: Message) -> SignedMessage<E>[src]

Sign a message creating a SignedMessage using a user supplied CSPRNG for the key splitting.

Trait Implementations

impl<E: EngineBLS> Clone for KeypairVT<E>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl<E> Sync for KeypairVT<E> where
    <E as EngineBLS>::PublicKeyGroup: Sync,
    <E as EngineBLS>::Scalar: Sync

impl<E> Send for KeypairVT<E> where
    <E as EngineBLS>::PublicKeyGroup: Send,
    <E as EngineBLS>::Scalar: Send

impl<E> Unpin for KeypairVT<E> where
    <E as EngineBLS>::PublicKeyGroup: Unpin,
    <E as EngineBLS>::Scalar: Unpin

impl<E> RefUnwindSafe for KeypairVT<E> where
    <E as EngineBLS>::PublicKeyGroup: RefUnwindSafe,
    <E as EngineBLS>::Scalar: RefUnwindSafe

impl<E> UnwindSafe for KeypairVT<E> where
    <E as EngineBLS>::PublicKeyGroup: UnwindSafe,
    <E as EngineBLS>::Scalar: UnwindSafe

Blanket Implementations

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

type Owned = T

The resulting type after obtaining ownership.

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

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

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> BorrowMut<T> for T where
    T: ?Sized
[src]

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self