Trait SignedMessage

Source
pub trait SignedMessage {
    // Required methods
    fn fetch_signature_header(&self) -> Option<String>;
    fn fetch_signature_input(&self) -> Option<String>;
    fn lookup_component(&self, name: &CoveredComponent) -> Option<String>;
}
Expand description

Trait that messages seeking verification should implement to facilitate looking up raw values from the underlying message.

Required Methods§

Source

fn fetch_signature_header(&self) -> Option<String>

Obtain the parsed version of Signature HTTP header

Source

fn fetch_signature_input(&self) -> Option<String>

Obtain the parsed version of Signature-Input HTTP header

Source

fn lookup_component(&self, name: &CoveredComponent) -> Option<String>

Obtain the serialized value of a covered component. Implementations should respect any parameter values set on the covered component per the message signature spec. Component values that cannot be found must return None. CoveredComponent::HTTP fields are guaranteed to have lowercase ASCII names, so care should be taken to ensure HTTP field names in the message are checked in a case-insensitive way.

Implementors§