pub struct AppSignature {
pub public_key: B32,
pub signature: [u8; 64],
}Expand description
Signature on a Wasm binary hash, together with the x-only public key it was produced with.
The signature scheme is BIP-340 Schnorr over secp256k1. public_key is the 32-byte x-only
verifying key (BIP-340); signature is the 64-byte Schnorr signature over the SHA256 hash
of the Wasm binary (i.e. over the corresponding VersionedApp::wasm_hash). Both fields
are typed as fixed-size byte arrays so that bad lengths are rejected at the
(de)serialization boundary rather than deep inside signature verification.
Fields§
§public_key: B32BIP-340 x-only public key (32 bytes).
signature: [u8; 64]BIP-340 Schnorr signature over the Wasm binary’s SHA256 hash (64 bytes).
Trait Implementations§
Source§impl Clone for AppSignature
impl Clone for AppSignature
Source§fn clone(&self) -> AppSignature
fn clone(&self) -> AppSignature
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AppSignature
impl Debug for AppSignature
Source§impl<'de> Deserialize<'de> for AppSignature
impl<'de> Deserialize<'de> for AppSignature
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for AppSignature
Source§impl PartialEq for AppSignature
impl PartialEq for AppSignature
Source§fn eq(&self, other: &AppSignature) -> bool
fn eq(&self, other: &AppSignature) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for AppSignature
impl Serialize for AppSignature
impl StructuralPartialEq for AppSignature
Auto Trait Implementations§
impl Freeze for AppSignature
impl RefUnwindSafe for AppSignature
impl Send for AppSignature
impl Sync for AppSignature
impl Unpin for AppSignature
impl UnsafeUnpin for AppSignature
impl UnwindSafe for AppSignature
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more