pub struct AuthorizedMessageV1 {
pub message: MessageV1,
pub signature: Signature,
}Fields§
§message: MessageV1§signature: SignatureImplementations§
Source§impl AuthorizedMessageV1
impl AuthorizedMessageV1
pub fn new(message: MessageV1, signing_key: &SigningKey) -> Self
Sourcepub fn with_signature(message: MessageV1, signature: Signature) -> Self
pub fn with_signature(message: MessageV1, signature: Signature) -> Self
Create an AuthorizedMessageV1 with a pre-computed signature. Use this when signing is done externally (e.g., via delegate).
pub fn validate( &self, verifying_key: &VerifyingKey, ) -> Result<(), SignatureError>
pub fn id(&self) -> MessageId
Trait Implementations§
Source§impl Clone for AuthorizedMessageV1
impl Clone for AuthorizedMessageV1
Source§fn clone(&self) -> AuthorizedMessageV1
fn clone(&self) -> AuthorizedMessageV1
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 AuthorizedMessageV1
impl Debug for AuthorizedMessageV1
Source§impl<'de> Deserialize<'de> for AuthorizedMessageV1
impl<'de> Deserialize<'de> for AuthorizedMessageV1
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
Source§impl PartialEq for AuthorizedMessageV1
impl PartialEq for AuthorizedMessageV1
Source§fn eq(&self, other: &AuthorizedMessageV1) -> bool
fn eq(&self, other: &AuthorizedMessageV1) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for AuthorizedMessageV1
impl Serialize for AuthorizedMessageV1
impl StructuralPartialEq for AuthorizedMessageV1
Auto Trait Implementations§
impl Freeze for AuthorizedMessageV1
impl RefUnwindSafe for AuthorizedMessageV1
impl Send for AuthorizedMessageV1
impl Sync for AuthorizedMessageV1
impl Unpin for AuthorizedMessageV1
impl UnsafeUnpin for AuthorizedMessageV1
impl UnwindSafe for AuthorizedMessageV1
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