Expand description
Core types and primitives for the Agent Identity & Trust Protocol (AITP).
This crate is pure — no I/O, no crypto, no transport. It defines:
- The
Aidnewtype: a validated AITP Agent Identifier. - The
AitpEnvelopemessage wrapper. - JSON canonicalization per RFC 8785 (
jcs). - Strict unpadded base64url codec (
base64url). - The
Timestampnewtype for Unix-second timestamps. - The
ExtensionsMaptype for forward-compatible extensions. - The
AitpErrorandErrorCodetaxonomy from RFC-AITP-0001.
Higher-level protocol crates (aitp-manifest, aitp-tct, aitp-handshake,
aitp-delegation) build on these primitives.
Re-exports§
pub use aid::Aid;pub use aid::AidAlgorithm;pub use aid::AidParseError;pub use envelope::envelope_signing_digest;pub use envelope::envelope_signing_input;pub use envelope::AitpEnvelope;pub use envelope::MessageType;pub use envelope::Sender;pub use error::AitpError;pub use error::ErrorCode;pub use extensions::ExtensionsMap;pub use raw_url::RawUrl;pub use time::Timestamp;
Modules§
- aid
- AITP Agent Identifier (AID).
- base64url
- Strict unpadded base64url codec (RFC 4648 §5).
- envelope
- AITP message envelope (RFC-AITP-0001 §5).
- error
- AITP error codes from the registry.
- extensions
- Forward-compatible extension fields.
- jcs
- RFC 8785 JSON Canonicalization Scheme (JCS).
- raw_url
RawUrl— a URL that preserves its on-the-wire byte form.- time
- Unix-second timestamps with freshness checks.
Constants§
- AID_
PUBKEY_ IDENTIFIER_ LEN - Length of an AID identifier component when method =
pubkey(Ed25519 raw public key encoded as unpadded base64url). - DEFAULT_
TIMESTAMP_ TOLERANCE_ SECS - Default timestamp tolerance for replay protection (300 seconds, ±).
- ED25519_
SIGNATURE_ BASE64URL_ LEN - Length of an Ed25519 signature encoded as unpadded base64url.
- PROTOCOL_
VERSION - Protocol version this crate implements. Carried as the
versionfield on JCS-profile artifacts and as theverprivate claim on compact-JWS portable trust artifacts (RFC-AITP-0001 §5.4.5).