pub struct AgentCardSignature {
pub protected: String,
pub signature: String,
pub header: Option<JsonObject>,
}Expand description
Signature over an agent card payload.
Fields§
§protected: StringProtected JOSE header segment.
signature: StringSignature bytes encoded as a string.
header: Option<JsonObject>Optional unprotected JOSE header values.
Implementations§
Source§impl AgentCardSignature
impl AgentCardSignature
Sourcepub fn protected_header(
&self,
) -> Result<JwsProtectedHeader, AgentCardSignatureError>
pub fn protected_header( &self, ) -> Result<JwsProtectedHeader, AgentCardSignatureError>
Decode the protected JOSE header from its base64url segment.
Sourcepub fn signature_bytes(&self) -> Result<Vec<u8>, AgentCardSignatureError>
pub fn signature_bytes(&self) -> Result<Vec<u8>, AgentCardSignatureError>
Decode the raw signature bytes from their base64url representation.
Sourcepub fn verification_input(
&self,
card: &AgentCard,
) -> Result<AgentCardSignatureVerificationInput, AgentCardSignatureError>
pub fn verification_input( &self, card: &AgentCard, ) -> Result<AgentCardSignatureVerificationInput, AgentCardSignatureError>
Build the detached-JWS verification input for this signature.
Trait Implementations§
Source§impl Clone for AgentCardSignature
impl Clone for AgentCardSignature
Source§fn clone(&self) -> AgentCardSignature
fn clone(&self) -> AgentCardSignature
Returns a duplicate of the value. Read more
1.0.0 · 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 AgentCardSignature
impl Debug for AgentCardSignature
Source§impl<'de> Deserialize<'de> for AgentCardSignature
impl<'de> Deserialize<'de> for AgentCardSignature
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
Auto Trait Implementations§
impl Freeze for AgentCardSignature
impl RefUnwindSafe for AgentCardSignature
impl Send for AgentCardSignature
impl Sync for AgentCardSignature
impl Unpin for AgentCardSignature
impl UnsafeUnpin for AgentCardSignature
impl UnwindSafe for AgentCardSignature
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