From 710f6e67b86bc975ca2e17d1c1acf59467ec6a9a Mon Sep 17 00:00:00 2001 From: Muhammad Dzakwan Najmi Date: Sat, 21 Nov 2026 06:54:59 +0800 Subject: [PATCH] docs: the advisory and clean install of 0.8.0-beta.1, and three known limits Held until the pre-release was on npm (it is, under the beta tag since 2026-11-20); each text names the version it describes. SECURITY.md: the two MPP defects of 0.7.0 and their advisory, GHSA-7c36-rg54-r3v8, fixed in 0.8.0-beta.1; the sentence that said 0.7.0's own code had no advisory is corrected; the clean install of 0.8.0-beta.1 found no advisory (verify:clean-install, 2026-11-20), and the two ERESOLVE peer warnings npm prints for @stellar/mpp are named. docs/CHECKS.md: a Solana settlement sent as a version 1 transaction may be reported as failing (issue #22, not yet reproduced); X402-11 gives no verdict where test-network ledgers average 4 seconds or less. packages/cli/README.md: a paying wasit run checks its RPC before it starts the service, so an RPC that service.start itself starts is not up yet. --- SECURITY.md | 22 ++++++++++++++++++++-- docs/CHECKS.md | 26 ++++++++++++++++++++++++++ packages/cli/README.md | 2 +- 3 files changed, 47 insertions(+), 3 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index 6cdcb3d..efe0960 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -31,6 +31,15 @@ payer key if that account holds mainnet funds (read from the SDK's source, not run). Use a payer key that has never held mainnet funds. The advisory is [GHSA-wm3g-w88q-73xx](https://github.com/wasit-dev/wasit/security/advisories/GHSA-wm3g-w88q-73xx). +In 0.7.0, `MPP-01` paid on `stellar:pubnet` when the run named it, with no cap, +and a channel commitment was signed without checking the bytes the RPC returned +for it, so a run on the test network pointed at a mainnet RPC signed a +commitment valid on mainnet. Both are fixed in 0.8.0-beta.1 (npm tag `beta`): +every network but the test networks is refused before a key is read, and a +commitment is signed only when it names the run's channel, amount and network. +The advisory is +[GHSA-7c36-rg54-r3v8](https://github.com/wasit-dev/wasit/security/advisories/GHSA-7c36-rg54-r3v8). + ## Authorization **Only run Wasit against a service you own, or one whose operator has given you @@ -181,6 +190,13 @@ would not appear in that file until it was resolved. ## Known advisories in a clean install +In 0.8.0-beta.1 (npm tag `beta`), `npm run verify:clean-install` found no +advisory in a fresh install of all three packages (2026-11-20). During that +install npm prints two `ERESOLVE overriding peer dependency` warnings: +`@stellar/mpp` 0.7.1 declares the peer range `@stellar/stellar-sdk ^15.1.0`, +and Wasit uses 16.4.1, with which its MPP checks passed on the Stellar test +network (2026-11-16). The rest of this section describes 0.7.0. + `npm audit` on a fresh install of all three packages (0.7.0, measured 2026-10-08) reports nine packages: eight high, one moderate. Installing `@wasit-dev/cli` alone reports eight (seven high, one moderate), since it pulls @@ -201,8 +217,10 @@ arrive by two routes: `@stellar/mpp`, `@x402/stellar` and the three `@wasit-dev/*` packages appear in that count only because npm marks a package that depends on an affected one. -There is no advisory against Wasit 0.7.0's own code; versions up to 0.6.0 have -the `MPP-01` network issue described under [Testnet only](#testnet-only), +Wasit 0.7.0's own code has the two MPP defects of +[GHSA-7c36-rg54-r3v8](https://github.com/wasit-dev/wasit/security/advisories/GHSA-7c36-rg54-r3v8), +fixed in 0.8.0-beta.1; versions up to 0.6.0 have the `MPP-01` network issue +described under [Testnet only](#testnet-only), [GHSA-wm3g-w88q-73xx](https://github.com/wasit-dev/wasit/security/advisories/GHSA-wm3g-w88q-73xx). There is no downstream fix. The levers are `@stellar/mpp`'s two peer ranges, diff --git a/docs/CHECKS.md b/docs/CHECKS.md index 964c943..06aabaa 100644 --- a/docs/CHECKS.md +++ b/docs/CHECKS.md @@ -347,6 +347,20 @@ The transaction `PAYMENT-RESPONSE` names must have succeeded and moved exactly that cites another transaction fails, even a real and successful one ([0.6.0 verification run](evidence/2026-09-30-x402-0.6.0-verification-run.md)). +### A Solana settlement is reported as failing although it settled (`X402-06`) + +Known limit, reported in [issue #22](https://github.com/wasit-dev/Wasit/issues/22) +and not yet fixed. On Solana, Wasit reads the settlement transaction with +`getTransaction(..., { maxSupportedTransactionVersion: 0 })` +(`packages/core/src/x402/chains/svm.ts`). The report says that an RPC answers +that call with error -32015 when the settlement was sent as a version 1 +transaction, so a compliant settlement would be reported as failing. The cap is +in the code (two calls, lines 255 and 307 in 0.7.0 and in 0.8.0-beta.1); the RPC +behaviour is the reporter's, and we have not yet reproduced it. If a Solana run +fails at the settlement read and the RPC's answer mentions the transaction +version, read the transaction on an explorer before taking the FAIL as the +target's defect. + ### A forged signature is accepted (`X402-07`) The target served a payment whose authorization signature was corrupted: it @@ -373,6 +387,18 @@ An authorization past its window (`validBefore` on EVM, the auth entry's expirat ledger on Stellar, the recent blockhash on Solana) can never settle, so a target that serves it serves for nothing. Verify with the facilitator before serving; it refuses expired authorizations. +### No verdict on `X402-11` where ledgers close in 4 seconds or less + +`X402-11` does not send an authorization that stays valid more than 62 ledgers +past the latest one: 300 seconds at 5 seconds a ledger, plus 2 ledgers of slack +(0.8.0-beta.1). The x402 Stellar client turns the advertised lifetime into +ledgers with its own estimate of the ledger time, the recent ledgers' average +rounded up (`@x402/stellar` 2.28.0; 5 seconds when it cannot read them). On the +test network the recent ledgers averaged 5.00 seconds on 2026-11-17, so a +300-second lifetime is 60 ledgers. If they average 4 seconds or less, the same +lifetime becomes 75 ledgers or more, and `X402-11` discards the payment unsent, +with no verdict. It never passes because of it. + ### A charge to a muxed recipient is refused (`MPP-01`) A charge server on `@stellar/mpp` 0.7.1 configured with a muxed (`M...`) diff --git a/packages/cli/README.md b/packages/cli/README.md index a78569a..4d9f10c 100644 --- a/packages/cli/README.md +++ b/packages/cli/README.md @@ -109,7 +109,7 @@ wasit run --start # the payment tier, on a test network `wasit.config.json` (version 1) holds a service's endpoints, methods, request bodies and environments. The loader is strict: an unknown key is an error, and secrets, the mainnet opt-in and per-payment caps have no place in it. `wasit run` runs every endpoint (`--env`, `--endpoint`) and writes one report (`--json`, `--out`); it can start the service itself (`--start`, `--start-if-local`) and compare with the report of the default branch (`--baseline`). -Without `--read-only` or `--dry-run` the run is the payment tier. It pays on test networks only, when the environment has `operatedByMe: true` and the chain's key variable is set: at most $1.00 a payment and $5.00 a run (`maxRunUsd` can only lower it), only to the `payTo` and asset the config pins. In GitHub Actions it pays only on a push to the default branch, a schedule and `workflow_dispatch`; a pull request runs the read-only checks. In another CI the payment tier is refused with exit 2: use `--read-only` there. `--mainnet` is refused in this version. `wasit run --help` lists every option. +Without `--read-only` or `--dry-run` the run is the payment tier. It pays on test networks only, when the environment has `operatedByMe: true` and the chain's key variable is set: at most $1.00 a payment and $5.00 a run (`maxRunUsd` can only lower it), only to the `payTo` and asset the config pins. In GitHub Actions it pays only on a push to the default branch, a schedule and `workflow_dispatch`; a pull request runs the read-only checks. In another CI the payment tier is refused with exit 2: use `--read-only` there. `--mainnet` is refused in this version. A run that will pay checks its RPC before it starts the service, so an RPC that `service.start` itself starts is not up yet and the run stops with exit 2: start such an RPC before `wasit run`. `wasit run --help` lists every option. For an endpoint with a `reject` case in the config, on Stellar, the payment tier also runs `X402-11`: a valid payment is sent with the request the service must refuse, and the chain is read until that payment's authorization has expired, up to six minutes.