The Budget-Attestation envelope is one COSE_Sign1 object [RFC9052] whose
payload is a Budget-Claims map encoded in deterministic CBOR [RFC8949]. The
CDDL notation below uses [RFC8610]. Encoders MUST follow [RFC8949],
Section 4.2.1, and Verifiers MUST reject non-deterministic encodings.
Verifiers MUST use the protected-header bstr and payload bstr as received when
constructing Sig_structure; they MUST NOT re-encode either one first.¶
Verifiers MUST reject duplicate keys in the COSE header maps, Budget-Claims,
and Request-Binding. Duplicate detection MUST occur before encoded pairs are
collapsed into a map. A header label present in both the protected and
unprotected header maps also causes rejection. Budget-Claims uses integer
labels; the names in the CDDL comments are descriptive and are not encoded.¶
The COSE_Sign1 object can use tag 18 or the untagged four-element array.
Verifiers SHOULD accept both forms subject to the carriage rules; Issuers
SHOULD send the tagged form unless a deployment profile specifies otherwise.
An untagged proof in an HTTP body requires the cose-type parameter
(Section 7.3); field carriage does not. The payload MUST contain the
Budget-Claims bstr; a detached null payload MUST be rejected. The protected
header map MUST contain the algorithm header parameter and, when multiple
Issuer keys are available, a kid that identifies the key. The unprotected
header map MUST be empty. A crit protected header parameter MUST be
understood before the proof is accepted.¶
The base profile assigns no COSE content type to Budget-Claims. Issuers MUST
omit ctyp, and Verifiers MUST reject it. A separately selected and versioned
extension can define an exact protected ctyp value and its verification
rules. It MUST treat ctyp as a signed consistency check and MUST NOT use it
to select an authority profile. The HTTP media type
application/delegation-proof+cose describes the outer representation, not
the COSE payload.¶
This profile permits exactly one Issuer signature: the signature element of
COSE_Sign1. Issuers MUST NOT use COSE_Sign, a countersignature, a
signature-bearing Budget-Claims field, a second signature slot, or a trailing
signature object. Verifiers MUST reject these constructions.¶
The signature input is the COSE_Sign1 Sig_structure defined by [RFC9052]:
context string Signature1, the received protected-header bstr, an empty
external_aad bstr unless another profile specifies a value, and the received
Budget-Claims payload bstr. Verifiers MUST reject a non-deterministically
encoded protected header or Budget-Claims payload.¶
Budget-Claims = {
1 => uint, ; version
2 => tstr, ; issuer identifier
3 => tstr, ; delegated requester identifier
4 => tstr, ; authorized budget total or limit
5 => tstr, ; remaining budget
6 => tstr, ; currency or metered-unit identifier
7 => [+ tstr], ; permitted rails/actions/classes
8 => uint, ; issued-at ms since Unix epoch
9 => uint, ; expires-at ms since Unix epoch
10 => bstr .size (16..64), ; nonce from the Delegation challenge
? 11 => bstr, ; reserved profile extension slot
? 12 => bstr .size 32, ; reserved digest extension slot
13 => tstr, ; verifier or merchant binding
? 14 => Request-Binding ; signed request binding
}
Request-Binding = {
"method" => tstr,
"uri-h" => bstr .size 32,
"origin" => tstr,
? "body-h" => bstr .size 32
}
¶
Fields 4 and 5 carry decimal strings. A Verifier MUST parse them according
to the selected currency or metered-unit policy and MUST reject ambiguous or
unparseable values. A minimum budget, unit, or action advertised in a
challenge is authoritative only if it appears in the signed claims.¶
Fields 11 and 12 are optional extension slots. Issuers using the base
cose-ml-dsa profile MUST omit them; Verifiers MUST accept their absence. A
Verifier MUST reject either field unless the selected extension profile
defines and the Verifier supports its type, byte semantics, verification,
failure behavior, and version negotiation. A profile that uses field 12 MUST
also define its digest algorithm and covered bytes. The Verifier MUST NOT
infer the profile from a field's length or contents or retry under another
profile after rejection.¶
Field 12 does not replace field 14, the preflight target-content digest,
validation of any Content-Digest field, or computation of the protected
request's content digest.¶
Field 14, when present, carries a signed Request-Binding structure. An
Issuer binding a Budget-Attestation to a specific protected request MUST use
field 14 as defined in Section 5.3. Other types or meanings for label
14 MUST be rejected. Without field 14, the signed claims describe authorized
actions and bounds rather than one HTTP target. The Verifier can still issue
a compact credential bound to a particular protected request after preflight.¶