refactor: implement vulnerability detection in Rust crate#11
Closed
satsfy wants to merge 8 commits intostealth-bitcoin:mainfrom
Closed
refactor: implement vulnerability detection in Rust crate#11satsfy wants to merge 8 commits intostealth-bitcoin:mainfrom
satsfy wants to merge 8 commits intostealth-bitcoin:mainfrom
Conversation
This was referenced Mar 24, 2026
b88e61c to
ab40852
Compare
Collaborator
Author
|
This new rebase implementation blends my solution and Breno's solution from #15. I force-pushed the branch after reconciling the overlapping architecture changes so the result keeps the single canonical execution path, removes the leftover compatibility layer, and preserves the cleaner domain/core separation. |
71dbe40 to
87e459e
Compare
Removed from crates/stealth-bitcoincore and moved to bitcoincore as a standalone package. This change is part of the refactor to create separate packages for each component of the stealth project, allowing for better modularity and separation of concerns.
87e459e to
9411892
Compare
Collaborator
Author
|
Supplanted by pr #16 |
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.
Partially solves #10
This PR is a combination of rust refactors from @brenorb in #15 and me.
Implement the wallet analysis engine in a dedicated Rust crate. Deletes the old deprecated Python solution. Ports 5 privacy heuristics inspired by am-i-exposed.
New privacy heuristics in this PR:
This PR:
core,api,cli,bitcoincore, and a new shared domain crate.AnalysisEngine+BlockchainGatewayarchitecture so API, CLI, and library usage all go through one main scan path.coreinto a separate crate (types→ later renameddomain/stealth-domain).stealth-bitcoincore) implementing the gateway abstraction, including descriptor import, wallet scanning, tx fetching, and cookie/auth handling.stealth-api) withPOST /api/wallet/scan, request validation, structured error responses, RPC autodetection, and regtest end-to-end tests.stealth-cli) that can scan a single descriptor, multiple descriptors from a file, or raw UTXOs, with text/json output modes.TxGraphaway from the old live-RPC/lazy-fetch shape into a prebuilt graph fromWalletHistory, with precomputed caches and a spending index for deterministic analysis.core/src/scanner.rs) after earlier demoting it, so the PR ends with the legacy path deleted rather than merely discouraged.Reviewer Notes
Open the branch locally, run
cargo buildto verify it compiles and runcargo test. Inspect the e2e test inapi/or the integration tests inengine/.Run the api with
cargo run --bin stealth-apiand test that call: