Foundations
Error Model
AAuth adopts the Signature-Error response header from the Signature-Key draft. Every verification failure returns a 401 with a machine-readable error code — the response body is not authoritative.
Anatomy
HTTP/1.1 401 Unauthorized
Signature-Error: error=invalid_input,
required_input=("@method" "@authority" "@path"
"signature-key" "content-digest")
Content-Type: application/problem+json
{
"type": "urn:ietf:params:sig-error:invalid_input",
"title": "Missing required covered components",
"status": 401
}The header is the authoritative source. Problem Details (RFC 9457) in the body is a convenience for operators — machine clients MUST read the header.
Error codes AAuth uses
| error | Status | When it fires |
|---|---|---|
invalid_request | 400 / 401 | Required signature header (Signature, Signature-Input, or Signature-Key) is missing or malformed. |
invalid_input | 401 | Signature-Input does not cover all required components. Response SHOULD include |
invalid_signature | 401 | Signature does not verify, or the created timestamp is outside the validity window. |
unsupported_algorithm | 401 | The signing algorithm in the key/signature is not on the server's accept list. Response MUST include |
invalid_key | 401 | The public key in Signature-Key could not be parsed, is malformed, or doesn't meet trust requirements. |
unknown_key | 401 | For sig=jwks_uri — the referenced kid was not found at the published jwks_uri. Server SHOULD re-fetch the JWKS once before returning this to handle key rotation gracefully. |
invalid_jwt | 401 | For sig=jwt or sig=jkt-jwt — the JWT is malformed or its signature failed verification. |
expired_jwt | 401 | For sig=jwt or sig=jkt-jwt — the JWT exp claim is in the past. |
Authentication vs Authorization
401 + Signature-Error
The signature or its keying material is wrong. The client can (and often should) retry with corrected parameters.
403 Forbidden
Signature verified and identity is known, but policy denies the request. The response MUST NOT include Signature-Error or Accept-Signature— this isn't a signing problem.
Further reading