Skip to main content

Crate acdp_verify

Crate acdp_verify 

Source
Expand description

High-level body / publish-request verification — RFC-ACDP-0001 §5.11 (7-step algorithm).

This layer sits above validation, types, crypto, and did: it recomputes the content_hash, runs structural validation, resolves the producer DID, and verifies the signature envelope. The byte-level primitives (acdp_crypto::verify_ed25519 / acdp_crypto::verify_ecdsa_p256) live in crypto.

Structs§

Verifier
Stateless verifier. Requires a DID resolver to fetch producer keys.

Functions§

verify_body_offline
Full offline body verification for did:key producers — works with --no-default-features (no HTTP stack, no resolver, no async).
verify_body_signature_historical
Historical-key body-signature verification (ACDP 0.2, WS-B).
verify_ctx_id_binding
Verify that a served body’s ctx_id is the one the caller actually requested — RFC-ACDP-0006 §4.1 step 7 (NORMATIVE, “Bind the resolved identity”).
verify_did_key_envelope
Verify a signature envelope whose key is a did:key — a pure function available without the client feature (no resolver, no network, no async).
verify_lifecycle_event
Verify a lifecycle event per RFC-ACDP-0013 §5 — the helper both registries (at /retract//republish submission time, §6 step 3) and consumers (before treating an event as attributable evidence) use.
verify_lifecycle_event_offline
Offline counterpart of verify_lifecycle_event for did:key actors — no resolver, no network, works with --no-default-features. A did:web actor is refused with AcdpError::KeyResolution; use the resolver-backed helper.
verify_publish_request_signature
Verify the producer signature on a PublishRequest per RFC-ACDP-0003 §2.1 steps 7–8.
verify_publish_request_signature_offline
Offline counterpart of verify_publish_request_signature for did:key producers — used by registries (and the bindings) to verify a publish request without the client feature. Assumes structural validation and content_hash recomputation have already run (e.g. via PublishValidator::validate_post_schema).