Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
7d26181
chore: add local-verify.sh for the hermetic nextest suite
TaprootFreakAI Aug 22, 2026
e9c06bd
chore: drop internal hostname from local-verify.sh comment
TaprootFreakAI Aug 22, 2026
30778b4
fix: retry getJob while the kernel is busy proving
TaprootFreakAI Aug 22, 2026
e046457
fix: identical re-entrust is a no-op success
TaprootFreakAI Aug 22, 2026
a287d52
fix: sync spend counter from the kernel before a local mint
TaprootFreakAI Aug 22, 2026
a579365
fix: skip Alice mint when USD-Demo is already on the local node
TaprootFreakAI Aug 22, 2026
133ae4a
fix: skip stage-2 mint whenever USD-Demo already exists
TaprootFreakAI Aug 22, 2026
7a259ab
fix: skip completed local-e2e stages 2b, 3, 4 and 5
TaprootFreak Aug 22, 2026
fd5b14a
fix: recover Alice spend pubkey for journey stage 6 after a skipped send
TaprootFreak Aug 22, 2026
3f9ca72
fix: allow native verify_attestation and standalone stages 10/11
TaprootFreak Aug 22, 2026
2872982
fix: hydrate Pull records from SQL at boot and skip already-sent USD
TaprootFreak Aug 22, 2026
3899b54
fix: bind REST via ZKCOINS_HTTP_ADDR when a native stack is not on 4242
TaprootFreak Aug 22, 2026
087b82e
fix: re-entrust Alice before attestation and grant stages
TaprootFreak Aug 22, 2026
b0e6834
fix: skip node2 portability send when the account-head key is on NfLog
TaprootFreak Aug 22, 2026
a1355fb
fix: drop TODO from journey stage 8 now that recovery passes
TaprootFreak Aug 22, 2026
2a08592
docs: journey stages 2b-11 are fail-closed, not TODO
TaprootFreak Aug 22, 2026
5bb6e2a
fix: replay recovery when the served account head is already spent
TaprootFreak Aug 22, 2026
24821af
fix: treat NfLog first-occurrence as matching R or R' on SDR replay
TaprootFreak Aug 23, 2026
a89e3e1
fix: skip blossom re-fetch when recovery fold coin is already indexed
TaprootFreak Aug 23, 2026
ba99124
fix: continue recovery fold when an output_ref blob is missing
TaprootFreak Aug 23, 2026
88dd258
fix: prefer native verify_attestation for local-e2e stage 10
TaprootFreak Aug 23, 2026
f958381
fix: recovery outbox ZBE fallback and spent-head is not already insta…
TaprootFreak Aug 23, 2026
3dfdfc6
test: cover v1 publisher env loading fail-closed paths
TaprootFreak Aug 23, 2026
8e7a6e3
test: cover BalanceAttestationV1 decode fail-closed paths
TaprootFreak Aug 23, 2026
7352f61
test: cover kernel service fail-closed pin and owner paths
TaprootFreak Aug 23, 2026
fa27dda
test: cover inclusion-proof wire parse fail-closed paths
TaprootFreak Aug 23, 2026
a9d072d
test: empty blossom holder list is HoldersEmpty
TaprootFreak Aug 23, 2026
a964d46
test: cover extract_scan_tags missing and malformed tags
TaprootFreak Aug 23, 2026
0ce7eb6
test: reject extra inclusion-proof byte at depth 0
TaprootFreak Aug 24, 2026
3f906d0
test: cover asset_terms self-auth fail-closed v1/v2 paths
TaprootFreak Aug 24, 2026
fa9cbbf
test: reject issuer-side asset_terms guard failures
TaprootFreak Aug 24, 2026
4857579
test: name reconstitute double-spend and recipient mismatch
TaprootFreak Aug 24, 2026
cb75e41
test: name reconstitute size_final and truncated inclusion
TaprootFreak Aug 24, 2026
2241ea6
test: pin inclusion-proof extra byte at depth 1
TaprootFreak Aug 24, 2026
51c7506
test: pin inclusion-proof wire error strings
TaprootFreak Aug 24, 2026
b8e0953
test: name HolderOutcome fetch_error and ok display
TaprootFreak Aug 24, 2026
6d97508
test: name HoldersEmpty and AllHoldersFailed display
TaprootFreak Aug 24, 2026
a733e55
test: name ScanTags and DetectTagMismatch display
TaprootFreak Aug 24, 2026
d22929c
test: name remaining IncomingError string-arm display
TaprootFreak Aug 24, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,10 @@ the hermetic `node` + `shared` selection with:
cargo nextest run -p node -p shared --all-features --test-threads 8 -E 'not binary(api_remote)'
```

That command still needs `PUBLISHER_KEY` (32-byte hex, no default). The
wrapper `scripts/local-verify.sh` exports the same dummy key and Esplora
placeholders the CI job uses, then runs the line above.

`-E 'not binary(api_remote)'` drops the `api_remote` integration target
(`node/tests/api_remote.rs`). That suite talks to the live DEV node and does
not belong in a hermetic run; the CI workflow excludes it with the same
Expand Down
32 changes: 16 additions & 16 deletions deploy/local-e2e/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ What `up.sh` does, fail-closed:
./deploy/local-e2e/journey.sh # default: stages 1 + 2
./deploy/local-e2e/journey.sh --list
./deploy/local-e2e/journey.sh --stage 1 --stage 2
./deploy/local-e2e/journey.sh --stage 7 # named control (may be TODO)
./deploy/local-e2e/journey.sh --stage 7 # reorg control N-09
```

Signing and key derivation use **`@zkcoins/sdk`** against the live api
Expand Down Expand Up @@ -120,20 +120,20 @@ expect OOM (exit 137) during circuit construction rather than a logic failure.
| Stage | Mandate §3 | Status in this tree |
| --- | --- | --- |
| **1** | `GET /v1/info` equals pinned `circuit_digests` (`C`, `C_balance`) and bounds | **Hard** — digests + `finality_confirmations=6`, `max_tx_*=8`, `max_rx_coins=4`, `max_account_assets=32`, `activation_height=0` |
| **2** | Alice mint → job `completed` → nullifier inscribed → §3.10 `completed` after 6 blocks → balance `1_000_000_000` | **Hard driver** — entrust bundle, mint, SDK `refuseOrSignAndSubmit` (awaiting_signature recompute), mine, `/v1/chain/nullifier` + inscriptions, pull + parse balances |
| **2b** | Carol EUR-Demo token-standard-2 genesis + Alice receive; two-asset map | **TODO skeleton** — needs non-self mint delivery |
| **3–4** | Alice fee-less send to Bob (case (c)); publisher half-agg + inscription; Alice balance `999_750_000` | **Partial**: fee_address **negative** control is hard; positive send is **TODO** (Nostr/Blossom delivery gap) |
| **5** | Bob receive fold → balance `250_000` | **TODO skeleton** (depends on 3–4) |
| **6** | Confirmation link reports §3.10 `completed` for the payment | **TODO skeleton** for payment; mint §3.10 already checked in stage 2 |
| **7** | Reorg control N-09 | **TODO skeleton** |
| **8** | Recovery control Req 6 | **TODO skeleton** |
| **9** | Portability control Req 10 | **TODO skeleton** |
| **10** | Attestation control Req 9(b) | **TODO skeleton** (challenge surface probed) |
| **11** | Grant control Req 9(c) | **TODO skeleton** (challenge surface probed) |
| **2** | Alice mint → job `completed` → nullifier inscribed → §3.10 `completed` after 6 blocks → balance `1_000_000_000` | **Hard** — entrust bundle, mint, SDK `refuseOrSignAndSubmit` (awaiting_signature recompute), mine, `/v1/chain/nullifier` + inscriptions, pull + parse balances. Re-run skips mint when USD-Demo is already held. |
| **2b** | Carol EUR-Demo token-standard-2 genesis + Alice receive; two-asset map | **Hard** — re-run skips mint when EUR-Demo is already held |
| **3–4** | Alice fee-less send to Bob (case (c)); publisher half-agg + inscription; Alice balance `999_750_000` | **Hard** — `fee_address` negative control always runs; positive send skips when Alice is already at `999_750_000` |
| **5** | Bob receive fold → balance `250_000` | **Hard** — re-run skips receive when Bob already holds `250_000` |
| **6** | Confirmation link reports §3.10 `completed` for the payment | **Hard** — recovers Alice spend pubkey from inscriptions when the send stage was skipped |
| **7** | Reorg control N-09 | **Hard** — both nodes converge on size, root, and tip after a mined reorg |
| **8** | Recovery control Req 6 | **Hard** — second node reconstructs Bob from seed + chain + replicated blobs |
| **9** | Portability control Req 10 | **Hard** — second-node balances match; skips a redundant send when the account-head spend key is already on the NfLog |
| **10** | Attestation control Req 9(b) | **Hard** — produce + independent verify + tamper-reject |
| **11** | Grant control Req 9(c) | **Hard** — USD-scoped grant, in-scope pull ok, EUR out-of-scope refused |

Default `journey.sh` runs **1 + 2 only**, so a green default run does **not**
claim the full A-to-Z suite. Requesting a TODO stage exits non-zero with a
named message — never a silent pass.
claim the full A-to-Z suite. Pass `--stage` (repeatable) for 2b–11. First failed
assertion exits non-zero with `journey FAIL [stage N]: …` — never a silent pass.

## Fixtures (mandate §3)

Expand All @@ -156,9 +156,9 @@ named message — never a silent pass.
See `docs/local-stack.md` “Gaps / open items”. Material to journey completeness:

1. Esplora not bundled (residual boot + node `/health/ready`).
2. Nostr delivery client not fully wired into send/receive (blocks stages 3–6, 2b).
3. Recipient `IVPK` / Invoice off REST inventory — wallet must supply delivery credentials.
4. Kernel operational-bundle store is process-local (lost on node restart).
2. Recipient `IVPK` / Invoice off REST inventory — wallet must supply delivery credentials.
3. Kernel operational-bundle store is process-local (lost on node restart; the journey re-entrusts).
4. Account `send_counter` can lag the NfLog first-occurrence index by one; the journey walks the counter before mint/send.
5. Empty `ZKCOINS_BLOSSOM_ALLOWED_OPS` → uploads 403 (set op pubkeys when delivery is live).

## Verification (syntax)
Expand Down
Loading