agent-receipt-verify 0.2.7 → 0.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,28 @@
1
+ {
2
+ "schema_version": "3.0.0",
3
+ "verifies": "attempt-identity",
4
+ "requires_chain_read": false,
5
+ "provenance": [
6
+ "x402 specification v2 section 5.5, Settlement and Refusal Identity Invariant, as proposed in x402-foundation/x402 pull request 3776 on branch spec/settlement-refusal-identity-invariant and not on main",
7
+ "the gap these cover was named by ruiruii in erc-8004/erc-8004-contracts#99 on 18 October 2026: each of the four evidence layers depends on an attempt identity that none of them defines",
8
+ "section 5.5 closes by referring to \"the normative conformance tests in the specification repository for the required negative cases\"; at the time of writing those did not exist"
9
+ ],
10
+ "id": "attempt-identity-reference-canonicalized-first",
11
+ "clause": "reference-over-transmitted-bytes",
12
+ "encodes": "The second inverse trap: a reference to a signed artifact taken over a canonicalized form instead of the transmitted bytes.",
13
+ "description": "The attempt references a separately signed offer. The reference hash matches a key-sorted rewrite of that offer rather than the bytes that were signed, so the reference names an object nobody signed. This is the exact mirror of the key-order case: there, canonicalizing is required; here, it destroys the thing. An implementation that applies one rule to both will fail one of these two vectors, and which one it fails says which half it misread.",
14
+ "input": {
15
+ "signed_artifact_reference": {
16
+ "transmitted": "{\"version\":1,\"amount\":\"1000\",\"payTo\":\"0x2888F36548a900B9b08d584524e1f73BC563eC26\"}",
17
+ "reference_hash": "96ea208143f35d56469ee10bc81467bdcfccc19eecea0e9754f861f2de68fe27",
18
+ "note": "the hash of a key-sorted rewrite, not of what was signed"
19
+ }
20
+ },
21
+ "expected": {
22
+ "outcome": "FAIL",
23
+ "reason_code": "REFERENCE_CANONICALIZED_BEFORE_HASHING"
24
+ },
25
+ "limits": [
26
+ "The checker recomputes both candidate hashes itself rather than trusting the note, so a mislabelled vector cannot pass."
27
+ ]
28
+ }
@@ -0,0 +1,26 @@
1
+ {
2
+ "schema_version": "3.0.0",
3
+ "verifies": "attempt-identity",
4
+ "requires_chain_read": false,
5
+ "provenance": [
6
+ "x402 specification v2 section 5.5, Settlement and Refusal Identity Invariant, as proposed in x402-foundation/x402 pull request 3776 on branch spec/settlement-refusal-identity-invariant and not on main",
7
+ "the gap these cover was named by ruiruii in erc-8004/erc-8004-contracts#99 on 18 October 2026: each of the four evidence layers depends on an attempt identity that none of them defines",
8
+ "section 5.5 closes by referring to \"the normative conformance tests in the specification repository for the required negative cases\"; at the time of writing those did not exist"
9
+ ],
10
+ "id": "attempt-identity-reference-over-transmitted",
11
+ "clause": "reference-over-transmitted-bytes",
12
+ "encodes": "The positive control for the second trap.",
13
+ "description": "The reference hash is the digest of the artifact exactly as transmitted, which is what the signature covers.",
14
+ "input": {
15
+ "signed_artifact_reference": {
16
+ "transmitted": "{\"version\":1,\"amount\":\"1000\",\"payTo\":\"0x2888F36548a900B9b08d584524e1f73BC563eC26\"}",
17
+ "reference_hash": "a0c86bd7167da34f3f06ae274b8284ab1daea5802f10bf1df11e9b54b24182c5"
18
+ }
19
+ },
20
+ "expected": {
21
+ "outcome": "PASS"
22
+ },
23
+ "limits": [
24
+ "This says the reference names the signed bytes. It does not check that the signature over them is valid."
25
+ ]
26
+ }
@@ -0,0 +1,103 @@
1
+ {
2
+ "schema_version": "3.0.0",
3
+ "verifies": "attempt-identity",
4
+ "requires_chain_read": false,
5
+ "provenance": [
6
+ "x402 specification v2 section 5.5, Settlement and Refusal Identity Invariant, as proposed in x402-foundation/x402 pull request 3776 on branch spec/settlement-refusal-identity-invariant and not on main",
7
+ "the gap these cover was named by ruiruii in erc-8004/erc-8004-contracts#99 on 18 October 2026: each of the four evidence layers depends on an attempt identity that none of them defines",
8
+ "section 5.5 closes by referring to \"the normative conformance tests in the specification repository for the required negative cases\"; at the time of writing those did not exist"
9
+ ],
10
+ "id": "attempt-identity-settle-rederives-downstream",
11
+ "clause": "derive-once-at-ingress",
12
+ "encodes": "The core negative case: identity recomputed downstream from content the facilitator did not capture at ingress.",
13
+ "description": "Three paths take the identity from the ingress snapshot and /settle recomputes it from the request body as it reads it at settle time. The value happens to come out the same here, which is what makes this case worth having: an implementation that only compares values will report conformance, because the defect is in WHERE the value came from, not in what it was this time.",
14
+ "input": {
15
+ "ingress": {
16
+ "snapshot": {
17
+ "method": "POST",
18
+ "path": "/api/paid/verify-ownership",
19
+ "query": "",
20
+ "body": {
21
+ "endpoint": "https://example.com/api/health",
22
+ "ownerAddress": "0x1111111111111111111111111111111111111111",
23
+ "method": "dns-txt"
24
+ },
25
+ "payTo": "0x2888f36548a900b9b08d584524e1f73bc563ec26",
26
+ "asset": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
27
+ "network": "eip155:8453",
28
+ "amount": "1000",
29
+ "scheme": "exact"
30
+ },
31
+ "identity": "2ed52a521f9762c3adc24c8048a4ee04a3796202a34c335585fc953e15c97196"
32
+ },
33
+ "paths": [
34
+ {
35
+ "path": "challenge-quote",
36
+ "snapshot": {
37
+ "method": "POST",
38
+ "path": "/api/paid/verify-ownership",
39
+ "query": "",
40
+ "body": {
41
+ "endpoint": "https://example.com/api/health",
42
+ "ownerAddress": "0x1111111111111111111111111111111111111111",
43
+ "method": "dns-txt"
44
+ },
45
+ "payTo": "0x2888f36548a900b9b08d584524e1f73bc563ec26",
46
+ "asset": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
47
+ "network": "eip155:8453",
48
+ "amount": "1000",
49
+ "scheme": "exact"
50
+ },
51
+ "identity": "2ed52a521f9762c3adc24c8048a4ee04a3796202a34c335585fc953e15c97196",
52
+ "derived_from": "ingress-snapshot"
53
+ },
54
+ {
55
+ "path": "settle",
56
+ "snapshot": {
57
+ "method": "POST",
58
+ "path": "/api/paid/verify-ownership",
59
+ "query": "",
60
+ "body": {
61
+ "endpoint": "https://example.com/api/health",
62
+ "ownerAddress": "0x1111111111111111111111111111111111111111",
63
+ "method": "dns-txt"
64
+ },
65
+ "payTo": "0x2888f36548a900b9b08d584524e1f73bc563ec26",
66
+ "asset": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
67
+ "network": "eip155:8453",
68
+ "amount": "1000",
69
+ "scheme": "exact"
70
+ },
71
+ "identity": "2ed52a521f9762c3adc24c8048a4ee04a3796202a34c335585fc953e15c97196",
72
+ "derived_from": "request-body-at-settle-time"
73
+ },
74
+ {
75
+ "path": "refusal",
76
+ "snapshot": {
77
+ "method": "POST",
78
+ "path": "/api/paid/verify-ownership",
79
+ "query": "",
80
+ "body": {
81
+ "endpoint": "https://example.com/api/health",
82
+ "ownerAddress": "0x1111111111111111111111111111111111111111",
83
+ "method": "dns-txt"
84
+ },
85
+ "payTo": "0x2888f36548a900b9b08d584524e1f73bc563ec26",
86
+ "asset": "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
87
+ "network": "eip155:8453",
88
+ "amount": "1000",
89
+ "scheme": "exact"
90
+ },
91
+ "identity": "2ed52a521f9762c3adc24c8048a4ee04a3796202a34c335585fc953e15c97196",
92
+ "derived_from": "ingress-snapshot"
93
+ }
94
+ ]
95
+ },
96
+ "expected": {
97
+ "outcome": "FAIL",
98
+ "reason_code": "IDENTITY_REDERIVED_DOWNSTREAM"
99
+ },
100
+ "limits": [
101
+ "A recorded observation cannot prove where a value came from; this vector tests that a checker reads the declared origin instead of only comparing values."
102
+ ]
103
+ }
@@ -0,0 +1,29 @@
1
+ {
2
+ "schema_version": "3.0.0",
3
+ "verifies": "attempt-identity",
4
+ "requires_chain_read": false,
5
+ "provenance": [
6
+ "x402 specification v2 section 5.5, Settlement and Refusal Identity Invariant, as proposed in x402-foundation/x402 pull request 3776 on branch spec/settlement-refusal-identity-invariant and not on main",
7
+ "the gap these cover was named by ruiruii in erc-8004/erc-8004-contracts#99 on 18 October 2026: each of the four evidence layers depends on an attempt identity that none of them defines",
8
+ "section 5.5 closes by referring to \"the normative conformance tests in the specification repository for the required negative cases\"; at the time of writing those did not exist"
9
+ ],
10
+ "id": "attempt-identity-settled-despite-mismatch",
11
+ "clause": "countersignature-recompute-or-refuse",
12
+ "encodes": "The money half of the same clause: a mismatch that did not stop settlement.",
13
+ "description": "The counterparty correctly refused to sign, and the interaction settled anyway. The clause says that on a mismatch the interaction MUST NOT settle, so refusing to sign while still taking the money satisfies the letter of one sentence and breaks the one that matters.",
14
+ "input": {
15
+ "countersignature": {
16
+ "ingress_value": "2ed52a521f9762c3adc24c8048a4ee04a3796202a34c335585fc953e15c97196",
17
+ "recomputed": "b1b9009e0c9e7d66fc4e47a66303e8ccdddce8cc3462bc9de007abf524855bcb",
18
+ "signed": false,
19
+ "settled": true
20
+ }
21
+ },
22
+ "expected": {
23
+ "outcome": "FAIL",
24
+ "reason_code": "SETTLED_DESPITE_MISMATCH"
25
+ },
26
+ "limits": [
27
+ "Whether money actually moved is a chain question and is not read here."
28
+ ]
29
+ }