Expand description
Agent Delegation Protocol 1.0 types and validation helpers.
Delegation events are ordinary Agent Identity envelopes whose actor is a controller key for an HTTPS principal document.
Structs§
- Controller
- Same type for active and retired bindings. Missing delegation means signing-only.
- Delegation
Credential - Delegation
Grant Payload - Delegation
Policy - Delegation
Query Request - Delegation
Revoke Payload - Delegation
Service Discovery - Delegation
Service Endpoints - Delegation
Verdict - Result of
verify_delegation_credential. - Principal
Descriptor - Display descriptor of a principal, used by Agent Profile delegation hints.
The descriptor is open: other members are display metadata, kept in
extraso a signed hint re-serializes to the bytes that were signed. - Principal
Document - Principal
Link
Enums§
Constants§
- DELEGATION_
ERROR_ CODES - Delegation-specific error codes (Agent Delegation Section 9.7).
- DELEGATION_
GRANT - DELEGATION_
REVOKE - PROTOCOL
Functions§
- audit_
delegation_ history - Auditor check (Section 8): replays every accepted record of a credential
against the authoritative principal document — signatures, controller
intervals, and ceilings — and confirms that the replay
matches the credential. Relying parties use
verify_delegation_credentialinstead. - controller_
covers_ credential - The Section 5 management rule: a restricted controller may replace, revoke, or enumerate a credential only when every scope and audience of its latest grant is within the controller’s ceiling; an unrestricted controller covers every credential of the principal.
- delegation_
grant_ event - delegation_
revoke_ event - is_
principal_ alias - Reports whether
urlis an alias the principal itself acknowledges. Any origin can redirect to any principal, so an alias must not be shown as a name for the principal unless it is listed here. - materialize_
delegation_ credential - Materializes an already accepted event with trusted previous state and the service’s actual acceptance time. This helper does not authorize the event.
- validate_
audience - A relying-party audience (Section 5): an origin for a relying application, or an Agent ID for a relying agent.
- validate_
controller - validate_
controller_ enumeration - Per-result check; caller authenticates the actor and resolves the document.
- validate_
delegation_ acceptance - Caller also enforces fresh HTTPS, live Identity replay rules, and atomic persistence.
- validate_
delegation_ envelope - validate_
delegation_ event_ authority - Pre-signing policy check over trusted document/state. No signature, HTTP, cache-age, live timestamp-window, or nonce verification is performed.
- validate_
delegation_ grant_ payload - validate_
delegation_ id - Delegation IDs are unreserved URL characters (
[A-Za-z0-9._~-]{1,128}) and never a dot segment: no percent-encoding, no look-alikes. - validate_
delegation_ query_ request - A public delegation query is an existence check and must include both
subjectandprincipal_id. Omitting either side makes it an enumeration query, which services must authorize before answering; passallow_enumerationwhen building such an authorized request.limitdefaults to 20; services SHOULD cap it at 100. - validate_
delegation_ revoke_ payload - validate_
delegation_ use - Audience/status/time only, after signature/history checks. Caller still authenticates the subject and enforces scopes and constraints.
- validate_
historical_ delegation - Caller authenticates the accepted record and previous state. This checks historical policy, not current status or application constraints.
- validate_
principal_ document - validate_
principal_ resolution - Checks the authoritative-read rule of Agent Delegation Section 3: a
principal document binds controller keys only when it is read at its own
id. A document served anywhere else is a copy; itscontrollersmust be discarded anddocument.idresolved instead. - verify_
delegation_ credential - Verifies a credential under Agent Delegation Section 8 with the online
service-trusting evidence policy: checks the accepted record of its latest
grant — signature, Controller binding, ceiling, and authority interval —
confirms that the grant matches the credential, and then checks use for
audienceatnow. The Section 5 management rule governs management, which the service enforced at acceptance; auditors replay it withaudit_delegation_history. Relying parties still enforce scopes and constraints and authenticate the subject.
Type Aliases§
- Delegation
Events Response - Agent Identity list of accepted records in service acceptance order.
- Delegation
Query Response - Agent Identity list of full credentials.
- Delegation
Record