Repository navigation
Audit v14: one wallet per create (CLI-1002), VK-751, note-store merge, block-body checks - #12
Merged
Merged
Conversation
…repeated at the write, in-flight guard on the create and import forms A second submit while PBKDF2 was still deriving passed both existence checks: two creates succeeded with different keys, the backup screen revealed the first and the vault ended on the second. - backend-shared.js: wallet.create/import are single-flight (the identical call gets the same promise, any other is refused), and the vault is written only after re-reading that none is stored, under an exclusive Web Lock where the platform has one. Never overwrites. - onboarding.js: the create and import forms hold an in-flight guard and disable the submit button until the call settles. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
…itional write merge instead of overwrite - A lost conditional write merged notes by index and kept the winner's copy whole, dropping the loser's spent flags and pending marks while the height cursor was kept: a spent note stayed spendable until a rescan. Notes now merge mark by mark (spent OR, pending kept), submissions only move forward, and the merged scanned_height is the nearer cursor when the further-read side did not hold every note. - The extension and desktop shells have no compareAndSet, so a scan that straddled a send's save wrote its stale copy over the submission record. The engine now keeps the same conditional-write contract itself (write_seq, read-compare-write under an in-process lock) and merges on a lost race. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
…fixed creator is "sent, sender unverified"; anything else is dropped The sender part of an envelope opens under the viewing key, which is handed out (delegated prover, auditor), so its holder could plant sent payments in the wallet's history. The bundle guest commits every output with from = the spender's pk, which the holder cannot choose. - ui/engine/wallet.js: the scan judges every row whose sender part opened by its creator (sentRole): own pk -> Sent; zero / rpl-mint / rpl2-pay / rpl3-pay -> kept with unverified: true, its own activity kind, never matched to a submission; anything else, a row with no creator included, is dropped. A page replaces what was stored for its leaves, so a rescan removes rows an older build kept. - backend-shared.js, lib/rows.js, backend.js, locales: the new 'out-unverified' activity kind and its title in all 20 languages. - core/crates/wallet-core: classify applies the same rule; scan_page reports `from` on every sent row and the unverified ones in their own list (sent_unverified), so the mobile apps, which read `sent` alone, never count one. Two tests added. NOT compiled or run here: the vendored node is not checked out in this worktree. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
…g after the broadcast reads as cancelled outcomeOf (send and withdraw) tested the abort before the phase, safe only because the engine's last abort checkpoint sits immediately before the broadcast. And isAbortError took code 20 for an abort, so a node answering the confirmation read with JSON-RPC code 20 made a broadcast transfer read as cancelled while Activity listed it pending. - From 'submitting' on the outcome is 'unknown' (or 'not-sent' when the node refused the broadcast), whatever the error or the cancel flag. - RpcError is named, and a node's own error is never an abort. - Tests pin the engine invariant for completeSend/Burn/Invoke: an abort signalled at the broadcast still records and resolves. Adding a checkpoint after the broadcast turns them red (checked by mutation). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
…is null or short is not read as empty — the deposit cursor stays under it The shared JS engine, the Android walk and the iOS walk all advanced the bridge-deposit cursor past a block whose header said tx_count > 0 and whose body came back null or with no transactions: a deposit in it was never looked for again. - ui/engine: checkBlockActions takes the header's tx_count and refuses a null or short body; depositsByHeader passes it, so the walk stops under the block, reports it (bridgeUnknown) and the next scan asks again. The one-block-at-a-time path stops at a null block under the node's own tip. Tests added; two fixtures that served an empty body under a header announcing one now serve what the header says. - android DepositWalk.java: the same rule (served()), with unit tests. NOT compiled or run: no JDK on this machine. - ios DepositWalk.swift / RpcClient.swift / WalletService.swift: the walk hands tx_count to the block read, and RpcClient.actions(ofBlock:) refuses a null or short body, with unit tests. Type-checked with swiftc only (RpcClient, DepositWalk, the walk tests); not built or run, and the WalletService call site was not type-checked. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
…eet snapshot tag, not a wallet release v0.8.6 on this repository marks the snapshot at the fullnode v0.8.6 release (manifests 0.8.3, vendored node v0.8.5). The note sits beside the build step's `git checkout v0.8.3`; the tag itself is untouched. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
…seq is a write counter, and the wallet's RPC error is named RpcError A second scan that adds nothing still writes the store (last_sync_ms), so write_seq moves the way rev does; the comparison leaves it out. The JSON-RPC refusal now carries name 'RpcError' (CLI-1006), which the send screen reads. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes for the audit v14 addendum. Includes the one Medium row, CLI-1002.
Changes
wallet-core).Tests
cargo test -p wallet-core: 151 passed, 2 ignored.wallet-ffiandwallet-wasmtype-check.Not verified
Release note
The VK-751 change spans the JS engine and the rebuilt core; they must ship together.
🤖 Generated with Claude Code
https://claude.ai/code/session_01GFs5h2CVCmdBKerZzH2Xrx