This specification defines a DID-method-agnostic identity authentication protocol for agents communicating over HTTP. A client identifies a verification method with a DID URL, signs the HTTP request using HTTP Message Signatures, and binds any request content using Digest Fields. The server resolves and validates the DID according to the applicable DID Method Binding Profile, verifies that the selected verification method is authorized for authentication, verifies replay protections, and then makes a separate authorization decision.
The Agent Identity layer enables agents operated by different platforms, organizations, and deployment environments to authenticate without a proprietary identity federation. Decentralized Identifiers (DIDs) are used as the identity primitive, while the HTTP authentication protocol remains independent of any particular DID method.
DID creation, resolution, update, deactivation, and method-specific trust
guarantees are defined by the applicable DID method and by
DID Method Binding Profiles. The
did:wba DID Method Specification
is maintained as a separate document.
This specification defines:
keyid;authentication relationship;This specification does not define:
As well as sections marked as non-normative, all authoring guidelines, diagrams, examples, and notes in this specification are non-normative. Everything else in this specification is normative.
The key words MAY, MUST, MUST NOT, SHOULD, and SHOULD NOT in this document are to be interpreted as described in RFC 2119 and RFC 8174 when, and only when, they appear in all capitals.
A conforming implementation of the AI Agent Protocol Web DID profile MUST
support the did:wba, did:web, and
did:webvh Binding Profiles defined in
DID Method Binding Profiles.
Implementations MAY support additional DID methods through additional
binding profiles.
The design reuses mature Web infrastructure, including DNS, HTTPS, Web PKI, HTTP caching, and ordinary Web hosting, while preserving the decentralized identity model. Each platform may retain its own account and domain management system, while agents interoperate through resolvable DID Documents and standardized verification methods.
Common authentication and authorization behavior is defined independently of any one DID method. Creation, resolution, update, deactivation, and method-specific validation remain governed by the selected DID method. An implementation MUST NOT assume that a security property defined by one DID method also applies to another DID method.
The DID method name encoded in the DID is authoritative. Implementations MUST select the resolver and Binding Profile from the DID itself and MUST NOT require duplicate metadata declaring the same DID method.
A DID is a verifiable identifier and is not necessarily a stable human-readable name. Rotation and persistence semantics are method-specific. An upper-layer naming system MAY provide stable user-facing references.
The keyid parameter in Signature-Input MUST be an
absolute DID URL that identifies a verification method. The verifier MUST
extract the primary DID from that DID URL and select the corresponding DID
Method Binding Profile from the method name encoded in the DID.
The verifier MUST perform the following steps:
keyid is a syntactically valid absolute DID URL.keyid.id matches the requested DID.keyid to a verification method in the validated DID Document.authentication relationship.Resolution or validation failure MUST fail authentication. An implementation MUST NOT fall back to another DID method and MUST NOT use an unvalidated DID Document merely because it contains a matching public key.
A client authenticates the server using HTTPS and authenticates itself by signing the HTTP request with a verification method authorized by its DID Document. The verifier resolves and validates the DID, verifies the verification relationship, validates the request signature, and separately evaluates authorization.
The first request uses the Signature-Input and
Signature fields defined by
RFC 9421. When a
request contains a message body, it also uses the
Content-Digest field defined by
RFC 9530.
sequenceDiagram
participant Client as Agent Client
participant Server as Agent Server
participant Resolver as DID Resolver
Client->>Server: Signed HTTP request
Server->>Resolver: Resolve DID selected from keyid
Resolver->>Resolver: Apply method-specific validation
Resolver-->>Server: Validated DID Document
Server->>Server: Verify authentication relationship,
HTTP signature, digest, time, and replay state
Server->>Server: Evaluate authorization independently
Server-->>Client: HTTP response; optional access token
Client->>Server: Subsequent request with access token
Server-->>Client: HTTP response
Clients MUST send authentication information using the
Signature-Input and Signature fields defined by
RFC 9421. When a request includes a message body, the client MUST also
send Content-Digest as defined by RFC 9530.
The minimum signature coverage set is:
@method;@target-uri;content-digest, when the request contains a message body.Recommended additional covered components are:
@authority;content-type;content-length.The signature parameters have the following requirements:
keyid: MUST be a complete DID URL identifying a
verification method in the client's DID Document.
created: MUST be present.expires: SHOULD be present.nonce: MAY be present. If the server issued a challenge
nonce, the client MUST use that nonce.
alg: OPTIONAL. A verifier may determine the algorithm from
the verification method type identified by keyid.
The client MUST sign with a key authorized by the DID Document's
authentication relationship. Any additional key-selection
requirement is defined by the selected DID Method Binding Profile.
Signed request using a did:web identity:
POST /orders HTTP/1.1
Host: api.example.com
Content-Type: application/json
Content-Digest: sha-256=:BASE64_SHA256_DIGEST:
Signature-Input: sig1=("@method" "@target-uri" "@authority" "content-digest");created=1733402096;expires=1733402156;nonce="abc123";keyid="did:web:client.example:agents:alice#key-1"
Signature: sig1=:BASE64_SIGNATURE:
Content-Digest according to RFC 9530.
authentication and permitted by the selected DID Method
Binding Profile.
Signature-Input, covering at least the required
components defined above.
Signature-Input, Signature, and, when
applicable, Content-Digest to the server.
The verifier MUST perform the following checks:
Signature-Input and Signature are
present and syntactically valid.
Content-Digest against the received content.
keyid and the primary DID.created and expires are within the
server's accepted time window. A window of one to five minutes is
recommended and MAY be configured by the deployment.
keyid.Content-Digest result in the authentication
decision whenever a message body is present.
created/expires window.
(keyid, nonce), (keyid, jti),
or an equivalent unique tuple.
After successful authentication and authorization, a server MAY return an access token so that subsequent requests do not require DID resolution and HTTP signature verification on every request. The token format is an implementation choice. JWT, as defined by RFC 7519, is one possible format.
The following token-generation details are non-normative. A JWT payload might contain:
{
"sub": "did:web:client.example:agents:alice",
"iat": 1733402096,
"exp": 1733488496,
"scope": "orders.read orders.write"
}
When a token is returned using this protocol, the server MUST return it in
the Authentication-Info response field and MUST NOT place it in
an Authorization response field.
Authentication-Info: access_token="eyJhbGciOi...", token_type="Bearer", expires_in=3600, scope="orders.read orders.write"
Sender-constrained access tokens SHOULD be preferred to reduce replay risk
after token disclosure. This specification does not define a complete
sender-constrained token profile. Implementations MAY reserve a key-binding
claim such as cnf and require a proof bound to the token in
subsequent requests.
Until a sender-constrained profile is selected, a deployment MAY use
Bearer. The client sends a Bearer token in subsequent requests:
Authorization: Bearer <access_token>
The server MUST validate the token's signature, expiration, audience or resource restrictions, subject, and authorization scope according to the selected token format and local policy.
403 Forbidden
A server should return 403 Forbidden when identity
authentication succeeds but the authenticated DID lacks permission to
access the resource.
Reusing the same DID across unrelated contexts can enable correlation. DID providers and agents SHOULD support purpose-specific DIDs, role-specific keys, or other pairwise or scoped identifiers where stable global correlation is unnecessary.
A stable upper-layer name MAY refer to a DID that changes according to the lifecycle rules of its DID method. Such naming and migration mechanisms are outside this specification.
DID resolution can reveal which identities a verifier is contacting. Implementations SHOULD consider privacy-preserving DNS resolution, caching, proxying, and data-minimization policies appropriate to their environment.
Content-Digest whenever request content is present.
subjectAltName and MUST NOT rely on
Common Name as the service identity.