offer-receipt: the eip712 format has no conformance vectors (13 published, constants independently derived)
specs/extensions/extension-offer-and-receipt.md defines two signature formats, jws and eip712.
#3207 adds cross-implementation conformance vectors for JWS. A code search turns up nothing equivalent for EIP-712, so that half of the extension currently has no interop evidence.
Why this half is worth covering
Three of its rules break interoperability while an implementation's own test suite stays green, which is the failure mode that costs the most to find: the implementation verifies its own artifacts perfectly and nobody else's.
- The domain
chainIdis the constant 1, not the payment network. A reviewer who sees a payment settling on Base and "corrects" 1 to 8453 changes the domain separator, and every artifact produced afterwards is unverifiable everywhere else. - The canonical
typesare normative and are never transmitted. A verifier that accepts a sender-supplied schema has let the sender choose which bytes were signed. - Optional fields are signed at mandated empty values (
validUntil0,transaction""), not omitted. A fixed schema cannot express absence, so omission produces a different struct hash.
Two constants anyone can check first
Computed twice independently, once via eth_account and once from the raw EIP-712 definition, agreeing exactly:
| domain | separator |
|---|---|
x402 offer |
0x5dc92544087ab60aa57c539b9543f9282416b0dcf2c2ae0d4d0051052a9e61b6 |
x402 receipt |
0xfd7f8c81cdd24b25c99ba22e191cee41d8809abbc12e8fdbd42fddfa5bb9e406 |
Type hashes:
| type | hash |
|---|---|
Offer |
0x85143d3249b5e62ed5edd3d59a352d4e1181c775ff4f762f9c8a617f6bf1e97d |
Receipt |
0x616944bc4bb51b3d5fcbba8c559f76d57a93ac1e0d6659f1abbe95f92300c06f |
If an implementation's domain separator disagrees, nothing else will match either, so this is the cheapest first check available.
The set
13 vectors, 4 valid and 9 invalid, deterministic and regenerable, with published test keys that have never signed a real artifact:
https://pay.neuronto.com/.well-known/conformance/offer-receipt-eip712-vectors.json
Valid: a standard offer, a privacy-minimal receipt (transaction empty), a receipt carrying a transaction, and a well-formed offer whose validUntil has passed (expiry is an enforcement decision for the resource server, not a signature failure).
Invalid, each naming the layer expected to catch it: the chainId trap; an amount altered after signing; a valid signature from an unauthorized key, which is the attack §4.5.1 describes and which a verifier returning a single boolean cannot express; both optional-field omissions, including a receipt-side one because an offer-only set lets a verifier with no receipt schema check pass everything; a wrong-case domain name; a truncated signature; an invalid v byte; and a malicious transmitted types table with a signature valid under that table and invalid under the canonical one.
One honest note that belongs with any ECDSA set: a well-formed 65-byte signature never simply "fails", it recovers some address. So an altered payload, a wrong chainId and a wrong domain name all surface as an unexpected recovered signer, which is an authorization failure rather than a signature failure. The set says so rather than implying a cleaner taxonomy than the maths allows.
One vector was withdrawn before publishing
The first draft asserted that a verifier must reject an artifact that carries the canonical types. The specification puts that MUST NOT on the sender, so that vector would have invented a conformance rule. It was replaced with the malicious-schema case above, which tests a real verifier behaviour instead.
Form
Filed as an issue rather than a PR on purpose. #3207 is still open, and the repo's vector convention there is a vitest suite; adding a second set in a shape the maintainers have not settled on would be noise. Happy to file a PR in whatever form is wanted, including alongside #3207 if its author prefers one combined set covering both formats, or to hand the vectors over outright.
All 13 behave as published against our own implementation of the extension.
Source: x402-foundation/x402