pub struct DecodedCoseSign1<T = ()> {
pub signing_bytes: UnsignedCoseSign1<T>,
pub signature: CoseSignatureBytes,
}Expand description
Decoded COSE_Sign1 object.
Fields§
§signing_bytes: UnsignedCoseSign1<T>Signing bytes.
signature: CoseSignatureBytesSignature.
Implementations§
Source§impl<T> DecodedCoseSign1<T>
impl<T> DecodedCoseSign1<T>
Sourcepub async fn verify<P>(
&self,
params: P,
) -> Result<Verification, ProofValidationError>where
T: ValidateCoseHeader<P> + ValidateClaims<P, CoseSignatureBytes>,
P: ResolverProvider<Resolver: CoseKeyResolver>,
pub async fn verify<P>(
&self,
params: P,
) -> Result<Verification, ProofValidationError>where
T: ValidateCoseHeader<P> + ValidateClaims<P, CoseSignatureBytes>,
P: ResolverProvider<Resolver: CoseKeyResolver>,
Verify.
Source§impl<T> DecodedCoseSign1<T>
impl<T> DecodedCoseSign1<T>
Sourcepub fn map<U>(self, f: impl FnOnce(T, &[u8]) -> U) -> DecodedCoseSign1<U>
pub fn map<U>(self, f: impl FnOnce(T, &[u8]) -> U) -> DecodedCoseSign1<U>
Maps the payload interpretation.
This function can be used to decode the raw payload bytes into a proper typed value the application can work with.
Trait Implementations§
Source§impl From<CoseSign1> for DecodedCoseSign1
impl From<CoseSign1> for DecodedCoseSign1
Source§impl<T> From<DecodedCoseSign1<T>> for CoseSign1
impl<T> From<DecodedCoseSign1<T>> for CoseSign1
Source§fn from(value: DecodedCoseSign1<T>) -> Self
fn from(value: DecodedCoseSign1<T>) -> Self
Converts to this type from the input type.
Source§impl<T> VerifiableClaims for DecodedCoseSign1<T>
impl<T> VerifiableClaims for DecodedCoseSign1<T>
Auto Trait Implementations§
impl<T> Freeze for DecodedCoseSign1<T>where
T: Freeze,
impl<T> RefUnwindSafe for DecodedCoseSign1<T>where
T: RefUnwindSafe,
impl<T> Send for DecodedCoseSign1<T>where
T: Send,
impl<T> Sync for DecodedCoseSign1<T>where
T: Sync,
impl<T> Unpin for DecodedCoseSign1<T>where
T: Unpin,
impl<T> UnwindSafe for DecodedCoseSign1<T>where
T: UnwindSafe,
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
Source§impl<T> BorrowUnordered for T
impl<T> BorrowUnordered for T
fn as_unordered(&self) -> &Unordered<T>
Source§impl<T, U, C> IntoWithContext<U, C> for Twhere
U: FromWithContext<T, C>,
impl<T, U, C> IntoWithContext<U, C> for Twhere
U: FromWithContext<T, C>,
Source§impl<T> ResourceProvider<()> for T
impl<T> ResourceProvider<()> for T
Source§fn get_resource(&self) -> &()
fn get_resource(&self) -> &()
Returns a reference to the resource of type
T.