Skip to content

mystervee/Crypto-Wallet-Explorer

Repository files navigation

Crypto Wallet Explorer

CI

A simple, cross-platform wallet.dat scanner for Bitcoin-family wallets. It is intended for users to scan wallet files on their own machine to gain basic information on the contents of the wallet; balance is displayed where possible. It tries PyWallet for structured dumps when available, and safely falls back to read-only address discovery (Base58 + Bech32 + ETH 0x strings).

Features

  • Scans folders recursively for .dat and skips duplicate backups by content hash
  • PyWallet integration with JSON parsing and optional WSL fallback on Windows
  • Read-only fallback detection for BTC, LTC, DOGE, PPC, GRC, and ETH
  • Balance lookups (best-effort):
    • BTC via bitcoinlib services
    • LTC/DOGE via chain.so
    • PPC via chainz/cryptoid
  • Bech32 support for BTC (bc1…) and LTC (ltc1…)
  • CSV export including balance, dedup count, and first wallet path

Usage

From source (recommended for latest fixes):

Windows (PowerShell):

python -m venv .venv
\.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements.txt

Linux/macOS (bash):

python3 -m venv .venv
source .venv/bin/activate
python -m pip install -r requirements.txt

Run the scanner:

python .\Basic_Wallet_Scanner.py --dir <path-to-backups> --csv scan_results.csv

From release zip (prebuilt): download the latest release, extract, create a venv, install requirements, then run the command above.

Quick Start

  1. Create a virtual environment and install dependencies

Windows (PowerShell):

python -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements.txt

Linux/macOS (bash):

python3 -m venv .venv
source .venv/bin/activate
python -m pip install -r requirements.txt
  1. Run the scanner
python .\Basic_Wallet_Scanner.py --dir \\path\\to\\your\\backups --csv scan_results.csv

If --dir is omitted, the script will prompt for a folder.

  1. Review results
  • Console output shows discovered addresses grouped by coin
  • A scan_results.csv is saved (by default to the current working directory)

CLI Flags

  • --dir <folder>: Folder to scan (recursively) for .dat
  • --csv <path>: Output CSV path (default: scan_results.csv in CWD)
  • --no-balances: Skip all balance lookups
  • --max-per-coin <N>: Limit per-coin addresses printed to console per wallet (default 25)
  • --no-wsl: Disable WSL fallback for running pywallet on Windows

Examples:

# Minimal, prompt for folder
python .\Basic_Wallet_Scanner.py

# Specify folder and write CSV
python .\Basic_Wallet_Scanner.py --dir D:\Backups\Wallets --csv D:\out\scan.csv

# Faster console scanning; skip balances
python .\Basic_Wallet_Scanner.py --dir D:\Backups\Wallets --no-balances

Supported Coins

  • BTC: Base58 P2PKH/P2SH, Bech32 bc1…
  • LTC: Base58 P2PKH/P2SH, Bech32 ltc1…
  • DOGE: Base58 P2PKH/P2SH
  • PPC (Peercoin): Base58 P2PKH/P2SH
  • GRC (Gridcoin): Base58 P2PKH
  • ETH: Hex 0x addresses (detection only; no balances)

Output CSV Schema

Columns:

  • wallet: Source file path where the address was first seen
  • coin: BTC/LTC/DOGE/PPC/GRC/ETH
  • type: P2PKH/P2SH/BECH32/HEX
  • address: The discovered address string
  • balance: Numeric when looked up (BTC/LTC/DOGE/PPC); empty otherwise
  • count: Number of times this (coin, address) was encountered across all files
  • first_wallet: The first wallet file in which this address appeared

Windows + WSL (PyWallet Fallback)

PyWallet needs Berkeley DB (bsddb). On Windows this is tricky; the script will auto-try WSL if a local run fails with a bsddb error.

Inside WSL (Ubuntu/Debian):

sudo apt update
sudo apt install -y python3-bsddb3

No extra setup is required beyond having WSL installed; the script converts paths and invokes python3 within WSL for the pywallet step.

Testing

Developer tests live in tests/ and can be run with pytest:

python -m pip install -r requirements-dev.txt
pytest -q

Troubleshooting

  • PyWallet JSON parse errors: Make sure WSL + python3-bsddb3 is installed on Windows, or run natively on Linux.
  • Public API limits: LTC/DOGE/PPC balances use public endpoints and may rate-limit or return empty data. Rerun later or use --no-balances.
  • Very old/alt forks: Address version bytes vary. The fallback will label as UNKNOWN if it can’t map a version byte.
  • No addresses found: Some backups store keys encrypted or in non-standard formats; try the pywallet path on Linux.

Security and Privacy

  • Read-only: The scanner never writes to wallet files or transacts on any network.
  • Offline usage: For maximum privacy, run with --no-balances to avoid network calls; you’ll still get address discovery and CSV export.

Contributing

PRs welcome for:

  • Additional coin/version mappings and bech32 checksum verification
  • More reliable balance providers and optional API key support
  • Performance improvements and better CSV/reporting options

Releases

Prebuilt zips are published on the GitHub Releases page when a tag like v1.0.0 is pushed.

Contents:

  • Basic_Wallet_Scanner.py
  • pywallet/ (as shipped in this repo)
  • README.md, LICENSE, requirements.txt (and requirements-dev.txt if present)

Quick run from a release zip:

# 1) Extract zip and open a terminal in its folder
# 2) Create venv and install runtime deps
python -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements.txt

# 3) Run
python .\Basic_Wallet_Scanner.py --dir D:\Backups\Wallets --csv scan_results.csv

Credits

  • PyWallet by joric — Public Domain (includes portions under MIT and Apache-2 licenses). Repository: https://github.com/joric/pywallet. We vendor pywallet/pywallet.py and invoke it for structured wallet dumps when available. See headers in pywallet/pywallet.py for details.

Third-Party Licenses

This project vendors PyWallet (Public Domain) which itself includes components under permissive licenses:

See the attribution comments at the top of pywallet/pywallet.py for the authoritative list and license notes.

Disclaimer

This tool is provided “as is,” without warranty of any kind. Use at your own risk.

About

A simple, cross-platform wallet.dat scanner for Bitcoin-family wallets.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages