Trait http_sig::HttpSignatureVerify
source · pub trait HttpSignatureVerify: Debug + Send + Sync + 'static {
// Required method
fn http_verify(&self, bytes_to_verify: &[u8], signature: &str) -> bool;
}
Expand description
Implements the verification half of an HTTP signature algorithm. For symmetric algorithms the same type implements both signing and verification.
Required Methods§
sourcefn http_verify(&self, bytes_to_verify: &[u8], signature: &str) -> bool
fn http_verify(&self, bytes_to_verify: &[u8], signature: &str) -> bool
Returns true if the signature is valid for the provided content. The implementation should be sure to perform any comparisons in constant time.