A tool for brute-forcing Bitcoin private keys. The main purpose of this project is to contribute to the effort of solving the Bitcoin puzzle transaction: A transaction with 32 addresses that become increasingly difficult to crack.
- CUDA and OpenCL support for GPU acceleration
- Multi-GPU support with automatic keyspace partitioning
- Bidirectional (pincer) scanning - scan from both ends simultaneously for 2x faster average discovery
- Optimized for modern GPUs (RTX 4090, RTX 4070, etc.)
- Checkpoint/resume capability for long-running searches
# Build (CUDA)
make BUILD_CUDA=1
# Single GPU search
./bin/cuBitCrack -d 0 --keyspace 20000000000000000:3ffffffffffffffff -i addresses.txt -o found.txt
# Multi-GPU search (4 GPUs)
./bin/cuBitCrack --devices 0,1,2,3 --keyspace 20000000000000000:3ffffffffffffffff -i addresses.txt
# Bidirectional search (4 GPUs = 2 partitions, scanning from both ends)
./bin/cuBitCrack --devices 0,1,2,3 --bidir --keyspace 20000000000000000:3ffffffffffffffff -i addresses.txtBidirectional mode pairs GPUs to scan each partition from both ends simultaneously. This provides a 2x speedup on average because the key is found when either GPU reaches it.
Partition 0: Partition 1:
START ──────────── MID MID ──────────── END
│ │ │ │
GPU 0 ─────► ◄── GPU 1 GPU 2 ─────► ◄── GPU 3
(FWD) (BWD) (FWD) (BWD)
# Requires EVEN number of GPUs
./bin/cuBitCrack --devices 0,1 --bidir --keyspace START:END -i addresses.txt
# 4 GPUs = 2 partitions
./bin/cuBitCrack --devices 0,1,2,3 --bidir --keyspace START:END -i addresses.txt
# 8 GPUs = 4 partitions
./bin/cuBitCrack --devices 0,1,2,3,4,5,6,7 --bidir --keyspace START:END -i addresses.txt| Mode | Average keys to find target | Speedup |
|---|---|---|
| Forward-only | 50% of partition | 1x |
| Bidirectional | 25% of partition | 2x |
For uniformly distributed keys, bidirectional scanning finds the target in half the average time.
cuBitCrack [OPTIONS] [TARGETS]
Options:
-i, --in FILE Read addresses from FILE
-o, --out FILE Write found keys to FILE
-d, --device N Use device N (single GPU mode)
--devices N,N,N,... Use multiple devices (multi-GPU mode)
--bidir Enable bidirectional scanning (requires even GPU count)
-b, --blocks N Number of CUDA blocks
-t, --threads N Threads per block
-p, --points N Keys per thread
--keyspace START:END Search range in hex
--compression MODE 'compressed', 'uncompressed', or 'both'
--continue FILE Save/resume progress
--list-devices Show available GPUs
--stride N Increment by N (default: 1)
--share M/N Process Mth share of N total shares
- Single GPU: ~1.38 GKey/s
- Dual GPU: ~2.76 GKey/s
- Quad GPU: ~5.5 GKey/s
| GPU | Blocks | Threads | Points | Keys/iter |
|---|---|---|---|---|
| RTX 4090/4080 | 128 | 512 | 1024 | 67M |
| RTX 4070/3080 | 128 | 256 | 512 | 16M |
| RTX 3060/2080 | 64 | 256 | 256 | 4M |
# Single GPU
./bin/cuBitCrack -d 0 -b 128 -t 256 -p 512 \
--keyspace 20000000000000000:3ffffffffffffffff \
-i puzzle66.txt -o found.txt --continue checkpoint.txt
# 4 GPUs with bidirectional scanning
./bin/cuBitCrack --devices 0,1,2,3 --bidir -b 128 -t 256 -p 512 \
--keyspace 20000000000000000:3ffffffffffffffff \
-i puzzle66.txt -o found.txt./bin/cuBitCrack --keyspace 20000000000000000:3ffffffffffffffff \
--continue checkpoint.txt -i puzzle.txt# Default build (optimized for RTX 4090, compute capability 8.9)
make BUILD_CUDA=1
# For other GPUs
make BUILD_CUDA=1 COMPUTE_CAP=86 # RTX 3090
make BUILD_CUDA=1 COMPUTE_CAP=75 # RTX 2080
make BUILD_CUDA=1 COMPUTE_CAP=61 # GTX 1080make BUILD_OPENCL=1Open BitCrack.sln in Visual Studio 2019 and build:
cuKeyFinderfor CUDAclKeyFinderfor OpenCL
- CUDA Toolkit 12.x (for CUDA build)
- OpenCL SDK (for OpenCL build)
- g++ with C++17 support (Linux)
- Visual Studio 2019 (Windows)
- OpenCL is experimental - known bugs on some AMD/Intel devices
- Addresses can be compressed or uncompressed (use
--compressionoption) - Checkpoint files store search state for resumable searches
- Use
--list-devicesto see available GPUs
If you find this project useful, consider making a donation:
BTC: 1LqJ9cHPKxPXDRia4tteTJdLXnisnfHsof
LTC: LfwqkJY7YDYQWqgR26cg2T1F38YyojD67J
ETH: 0xd28082CD48E1B279425346E8f6C651C45A9023c5
Send questions or comments to bitcrack.project@gmail.com
If this work helped you, you can support me:
- USDT (ERC-20):
0xfba2de3360ae0d98ec44216191d143bc28676af5 - USDC (ERC-20):
0xfba2de3360ae0d98ec44216191d143bc28676af5 - BTC:
14EVe4ejvXrSS6s34AUBP9TMoSsuzShJ8o
Have a vibe-coding project you'd like to collaborate on? Get in touch: rawanaholdingslk@gmail.com