Component: web-wallet/src/client.rs, lib/src/bip448_statechain/package.rs, lib/src/bip448_statechain/transaction.rs
Severity: High impact if triggered; explicitly documented as a PoC boundary — filing as a tracking issue.
Summary
If a previous owner broadcasts and confirms a stale update U(k) (always possible: all state locktimes are 1985–2001 timestamps, so every update gate is already open at all times), the current owner of state n > k has no wallet-supported recovery:
- The wallet's unilateral exit supports only
funding_update and settlement roles (submit_unilateral_exit; parse_recovery_role accepts only those two).
build_latest_state_recovery_package returns UnsupportedRecoveryRole::StateUpdate.
- The rebinding helpers needed to recover —
rebind_update_tx / rebind_settlement_tx — have no production callers (test-only usages), so rebinding the signed state-n update over the confirmed state-k output is not possible through any wallet flow.
- There is also no chain watcher that would even detect the stale spend (
funding_bindings tracks spends of the funding output but nothing acts on a stale state output appearing).
Result: a stale-state confirmation bricks the current owner's funds absent custom tooling.
What exists
- Consensus support works: the ignored integration test
bip448_latest_state_fast_forwards_over_confirmed_old_state proves the manual sequence (rebind state-3 update over confirmed state-1 output → mine → rebind settlement → recover to current owner).
- Docs disclose the gap (
docs/README.md, docs/bip448_rebindable_statechains.md — "no automatic stale-state watcher", "test-side orchestration").
Suggested direction (incremental)
- Detect: surface stale-state spends in the wallet (the
funding_bindings/outspend polling loop already has the data sources).
- Recover manually: expose a "rebind latest state over confirmed stale state" flow reusing
rebind_update_tx + build_state_templates + existing CPFP package builder, initially operator-triggered.
- Automate later: a watcher service is explicitly out of scope for the PoC; this issue can track that too.
Found during security review of feature/bip448-web-wallet-mutinynet @ 64d2423.
Component:
web-wallet/src/client.rs,lib/src/bip448_statechain/package.rs,lib/src/bip448_statechain/transaction.rsSeverity: High impact if triggered; explicitly documented as a PoC boundary — filing as a tracking issue.
Summary
If a previous owner broadcasts and confirms a stale update
U(k)(always possible: all state locktimes are 1985–2001 timestamps, so every update gate is already open at all times), the current owner of staten > khas no wallet-supported recovery:funding_updateandsettlementroles (submit_unilateral_exit;parse_recovery_roleaccepts only those two).build_latest_state_recovery_packagereturnsUnsupportedRecoveryRole::StateUpdate.rebind_update_tx/rebind_settlement_tx— have no production callers (test-only usages), so rebinding the signed state-nupdate over the confirmed state-koutput is not possible through any wallet flow.funding_bindingstracks spends of the funding output but nothing acts on a stale state output appearing).Result: a stale-state confirmation bricks the current owner's funds absent custom tooling.
What exists
bip448_latest_state_fast_forwards_over_confirmed_old_stateproves the manual sequence (rebind state-3 update over confirmed state-1 output → mine → rebind settlement → recover to current owner).docs/README.md,docs/bip448_rebindable_statechains.md— "no automatic stale-state watcher", "test-side orchestration").Suggested direction (incremental)
funding_bindings/outspend polling loop already has the data sources).rebind_update_tx+build_state_templates+ existing CPFP package builder, initially operator-triggered.Found during security review of
feature/bip448-web-wallet-mutinynet@ 64d2423.