Struct secp256k1_zkp::WhitelistSignature
source · [−]#[repr(transparent)]pub struct WhitelistSignature(_);
Expand description
A whitelist ring signature.
Implementations
sourceimpl WhitelistSignature
impl WhitelistSignature
sourcepub fn serialize(&self) -> Vec<u8>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A> where
A: Allocator,
pub fn serialize(&self) -> Vec<u8>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A> where
A: Allocator,
A: Allocator,
Serialize to bytes.
sourcepub fn from_slice(bytes: &[u8]) -> Result<Self, Error>
pub fn from_slice(bytes: &[u8]) -> Result<Self, Error>
Parse a whitelist ring signature from a byte slice.
sourcepub fn new<C: Signing>(
secp: &Secp256k1<C>,
online_keys: &[PublicKey],
offline_keys: &[PublicKey],
whitelist_key: &PublicKey,
online_secret_key: &SecretKey,
summed_secret_key: &SecretKey,
key_index: usize
) -> Result<WhitelistSignature, Error>
pub fn new<C: Signing>(
secp: &Secp256k1<C>,
online_keys: &[PublicKey],
offline_keys: &[PublicKey],
whitelist_key: &PublicKey,
online_secret_key: &SecretKey,
summed_secret_key: &SecretKey,
key_index: usize
) -> Result<WhitelistSignature, Error>
Create a new whitelist ring signature for the given PAK list and whitelist key.
sourcepub fn verify<C: Verification>(
&self,
secp: &Secp256k1<C>,
online_keys: &[PublicKey],
offline_keys: &[PublicKey],
whitelist_key: &PublicKey
) -> Result<(), Error>
pub fn verify<C: Verification>(
&self,
secp: &Secp256k1<C>,
online_keys: &[PublicKey],
offline_keys: &[PublicKey],
whitelist_key: &PublicKey
) -> Result<(), Error>
Verify the given whitelist signature against the PAK list and whitelist key.
sourcepub fn as_ptr(&self) -> *const WhitelistSignature
pub fn as_ptr(&self) -> *const WhitelistSignature
Obtains a raw const pointer suitable for use with FFI functions
sourcepub fn as_mut_ptr(&mut self) -> *mut WhitelistSignature
pub fn as_mut_ptr(&mut self) -> *mut WhitelistSignature
Obtains a raw mutable pointer suitable for use with FFI functions
Trait Implementations
sourceimpl CPtr for WhitelistSignature
impl CPtr for WhitelistSignature
type Target = WhitelistSignature
fn as_c_ptr(&self) -> *const Self::Target
fn as_mut_c_ptr(&mut self) -> *mut Self::Target
sourceimpl Clone for WhitelistSignature
impl Clone for WhitelistSignature
sourcefn clone(&self) -> WhitelistSignature
fn clone(&self) -> WhitelistSignature
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for WhitelistSignature
impl Debug for WhitelistSignature
sourceimpl<'de> Deserialize<'de> for WhitelistSignature
impl<'de> Deserialize<'de> for WhitelistSignature
sourcefn deserialize<D: Deserializer<'de>>(d: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(d: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Display for WhitelistSignature
impl Display for WhitelistSignature
sourceimpl FromStr for WhitelistSignature
impl FromStr for WhitelistSignature
sourceimpl Hash for WhitelistSignature
impl Hash for WhitelistSignature
sourceimpl LowerHex for WhitelistSignature
impl LowerHex for WhitelistSignature
sourceimpl PartialEq<WhitelistSignature> for WhitelistSignature
impl PartialEq<WhitelistSignature> for WhitelistSignature
sourcefn eq(&self, other: &WhitelistSignature) -> bool
fn eq(&self, other: &WhitelistSignature) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &WhitelistSignature) -> bool
fn ne(&self, other: &WhitelistSignature) -> bool
This method tests for !=
.
sourceimpl Serialize for WhitelistSignature
impl Serialize for WhitelistSignature
impl Eq for WhitelistSignature
impl StructuralEq for WhitelistSignature
impl StructuralPartialEq for WhitelistSignature
Auto Trait Implementations
impl RefUnwindSafe for WhitelistSignature
impl Send for WhitelistSignature
impl Sync for WhitelistSignature
impl Unpin for WhitelistSignature
impl UnwindSafe for WhitelistSignature
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more