[−][src]Struct secp256k1zkp::aggsig::AggSigContext
Manages an instance of an aggsig multisig context, and provides all methods to act on that context
Methods
impl AggSigContext
[src]
pub fn new(secp: &Secp256k1, pubkeys: &Vec<PublicKey>) -> AggSigContext
[src]
Creates new aggsig context with a new random seed
pub fn generate_nonce(&self, index: usize) -> bool
[src]
Generate a nonce pair for a single signature part in an aggregated signature Returns: true on success false if a nonce has already been generated for this index In: index: which signature to generate a nonce for
pub fn partial_sign(
&self,
msg: Message,
seckey: SecretKey,
index: usize
) -> Result<AggSigPartialSignature, Error>
[src]
&self,
msg: Message,
seckey: SecretKey,
index: usize
) -> Result<AggSigPartialSignature, Error>
Generate a single signature part in an aggregated signature Returns: Ok(AggSigPartialSignature) on success In: msg: the message to sign seckey: the secret key index: which index to generate a partial sig for
pub fn combine_signatures(
&self,
partial_sigs: &Vec<AggSigPartialSignature>
) -> Result<Signature, Error>
[src]
&self,
partial_sigs: &Vec<AggSigPartialSignature>
) -> Result<Signature, Error>
Aggregate multiple signature parts into a single aggregated signature Returns: Ok(Signature) on success In: partial_sigs: vector of partial signatures
pub fn verify(&self, sig: Signature, msg: Message, pks: &Vec<PublicKey>) -> bool
[src]
Verifies aggregate sig Returns: true if valid, okay if not In: msg: message to verify sig: combined signature pks: public keys
Trait Implementations
impl Clone for AggSigContext
[src]
fn clone(&self) -> AggSigContext
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for AggSigContext
[src]
impl Drop for AggSigContext
[src]
Auto Trait Implementations
impl RefUnwindSafe for AggSigContext
impl !Send for AggSigContext
impl !Sync for AggSigContext
impl Unpin for AggSigContext
impl UnwindSafe for AggSigContext
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,