7 releases

0.0.24 Feb 15, 2026
0.0.20 Nov 25, 2025
0.0.18 Feb 20, 2025
0.0.16 Aug 30, 2024
0.0.14 Mar 14, 2024

#1666 in Cryptography

Download history 46/week @ 2025-11-06 10/week @ 2025-11-13 279/week @ 2025-11-20 29/week @ 2025-11-27 2/week @ 2025-12-04 29/week @ 2025-12-11 8/week @ 2025-12-18 7/week @ 2025-12-25 10/week @ 2026-01-01 237/week @ 2026-01-15 190/week @ 2026-01-22 4/week @ 2026-01-29 8/week @ 2026-02-05 105/week @ 2026-02-12 51/week @ 2026-02-19

172 downloads per month
Used in gateryx

MIT license

200KB
4K SLoC

httpsig-hyper

httpsig-hyper httpsig-hyper

Examples

You can run a basic example in ./examples as follows.

Sign and Verify a Request

% cargo run --example hyper-request

Sign and Verify a Response

% cargo run --example hyper-response

Caveats

Note that even if content-digest header is specified as one of covered component for signature, the verification process of httpsig-hyper doesn't validate the message body automatically. Namely, it only check the consistency between the signature and message components.

If you need to verify the body of a given message when content-digest is covered in signature-input header, you need to invoke verify_content_digest() function as follows.

// first verifies the signature according to `signature-input` header
let alg = AlgorithmName::Ed25519;
let public_key = PublicKey::from_pem(&alg, EDDSA_PUBLIC_KEY).unwrap();
let signature_verification = req.verify_message_signature(&public_key, None).await;
assert!(verification_res.is_ok());

// if needed, content-digest can be verified separately (only if content-digest header is included in the header)
let verified_request = request_from_sender.verify_content_digest().await;
assert!(verified_request.is_ok())

In the context of cryptography, the content-digest of covered components in signature-input is verified in the process of signature verification. So, hash value of content-digest is verified. To check if the content-digest is correctly bound with the message body, we need to run the hashing process separately.

Dependencies

~11–16MB
~219K SLoC