@rozoai/checkout 0.1.3 → 0.1.5

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,77 @@
1
+ # Review history
2
+
3
+ [← back to the README](../README.md) · [Safety design](safety.md)
4
+
5
+ This tool moves other people's money. It was reviewed adversarially before it
6
+ was written, again after it was written, and again after the first real payment.
7
+ This page is the record of that.
8
+
9
+ ## Design review — 3 rounds, before any code existed
10
+
11
+ The design was written as a plan document and reviewed by an independent model
12
+ with a standing instruction to hunt for anything that could lose funds. No code
13
+ was written until the plan passed with no P0 findings.
14
+
15
+ | Round | Verdict |
16
+ |---|---|
17
+ | 1 | 6 P0, 7 P1, 2 P2 — plan revised |
18
+ | 2 | still had P0s: several round-1 fixes were incomplete, plus one new P0 — plan revised again |
19
+ | 3 | no P0 — implementation began |
20
+
21
+ The P0s were about the plan being wrong regarding the payment rails, not about
22
+ style. Among them: the reuse rule was mis-stated (an existing order is reused
23
+ whenever it is merely unexpired, not only when it is unpaid); the binding
24
+ confirmation was placed before the deposit details existed, so it could not
25
+ bind them; and the payment link could be consumed by another payer between the
26
+ quote and the signature, which needed a re-check immediately before paying.
27
+
28
+ ## Code review — 2 rounds, after implementation
29
+
30
+ | Round | Verdict |
31
+ |---|---|
32
+ | 1 | 8 P0, 10 P1, 5 P2 |
33
+ | 2 | 20 of 23 resolved; 3 residual findings, then fixed |
34
+
35
+ The round-1 P0s were the interesting ones, and each is now a real code path
36
+ with its own error code and tests:
37
+
38
+ - the confirmation gate and the `--send` opt-in were documented but not
39
+ actually enforced
40
+ - the send-once claim was a check-then-act race that two concurrent processes
41
+ could both pass
42
+ - an unreadable `amountReceived` was treated as "no money received" rather than
43
+ as money
44
+ - the post-create comparison ignored security-critical fields when they were
45
+ simply absent
46
+ - payability was not re-proved immediately before signing, and incomplete
47
+ upstream state read as payable
48
+ - deposit instructions were not validated for completeness before being shown
49
+ - provider errors could leak credential-bearing URLs
50
+ - the tracked-secret check failed open when it could not consult git
51
+
52
+ ## First real payment
53
+
54
+ A live payment then settled in about a minute — and surfaced four more defects,
55
+ all fixed in 0.1.3:
56
+
57
+ - the built bundles crashed on newer Node because the bundler's CommonJS shim
58
+ was incomplete; it had never been caught because only `--help` was ever run
59
+ against a built bundle. The test suite now executes every bundle.
60
+ - the Stellar memo type was not stated anywhere, and sending that memo with the
61
+ wrong type loses the payment. It is `MEMO_TEXT`, and the deposit block now
62
+ says so.
63
+ - reusing an existing unpaid order, and asking for a coin that differs from it,
64
+ both read as errors rather than as the ordinary situations they are
65
+ - nothing showed how long an order had left, and a real payment nearly missed
66
+ its window
67
+
68
+ ## What this means for a reader
69
+
70
+ Every finding above is closed, and the behaviours they produced are covered by
71
+ the test suite, which runs entirely offline against recorded fixtures. The full
72
+ list of what this tool refuses to do, and why, is in
73
+ [docs/safety.md](safety.md).
74
+
75
+ The detailed review transcripts are kept internally; they quote source from
76
+ private repositories and so are not published here. The findings themselves are
77
+ summarised above in full — nothing material is omitted.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rozoai/checkout",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "type": "module",
5
5
  "description": "Pay an OpenRouter Coinbase Payment Link with BTC Lightning, or USDT/USDC on Solana, BNB Chain, Ethereum, Polygon, Base or Stellar.",
6
6
  "license": "MIT",
@@ -49,7 +49,7 @@
49
49
  "devDependencies": {
50
50
  "@solana/spl-token": "^0.4.9",
51
51
  "@solana/web3.js": "^1.95.0",
52
- "esbuild": "^0.24.0",
52
+ "esbuild": "^0.28.2",
53
53
  "viem": "^2.21.0"
54
54
  }
55
55
  }