Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
kangaroo — GPU-accelerated Pollard's Kangaroo algorithm for solving the Elliptic Curve Discrete Logarithm Problem (ECDLP) on secp256k1, supporting Vulkan, Metal, and DX12 backends. | Kitploit
Tools/GitHubGitHub/oritwoen/kangaroo
Encryption/Decryption ToolsVulnerability AnalysisCryptographyBinary AnalysisPapers & ResearchLearning & Education
GitHuboritwoen/kangaroo

kangaroo

GPU-accelerated Pollard's Kangaroo algorithm for solving the Elliptic Curve Discrete Logarithm Problem (ECDLP) on secp256k1, supporting Vulkan, Metal, and DX12 backends.

View Repository
2517166 months agoReviewed by Kitploit

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

Kangaroo

Crates.io Downloads License Ask DeepWiki

GPU-accelerated Pollard's Kangaroo algorithm for solving the Elliptic Curve Discrete Logarithm Problem (ECDLP) on secp256k1.

Features

  • 🖥️ Cross-platform GPU — Vulkan (AMD, NVIDIA, Intel), Metal (Apple Silicon), DX12 (Windows) via wgpu
  • 🦀 Pure Rust + WGSL — no CUDA dependency, compute shaders compiled at runtime
  • ⚡ Distinguished Points — efficient collision detection with auto-tuned DP bits
  • 🔄 Negation map — ~1.29× speedup via Y-parity directed walks with cycle guards
  • 🦘 Multi-set kangaroos — tame, wild1, wild2 herds for higher collision probability
  • 🎯 Modular constraints — if k ≡ R (mod M), reduce search space by factor M
  • ⚙️ Auto-calibration — GPU dispatch timing and workgroup size tuned at startup
  • 📊 Built-in benchmarks — --benchmark to test hardware, --save-benchmarks to record results
  • 📦 Data providers — pluggable puzzle sources (boha integration for Bitcoin puzzles)
  • 💻 CPU fallback — pure CPU solver for testing and comparison

Why This Project?

Most existing Kangaroo implementations (JeanLucPons/Kangaroo, RCKangaroo, etc.) only support NVIDIA GPUs via CUDA. This implementation uses WebGPU/wgpu which provides cross-platform GPU compute through Vulkan, Metal, and DX12.

Installation

Arch Linux (AUR)

paru -S kangaroo

Cargo

cargo install kangaroo

From source

git clone https://github.com/oritwoen/kangaroo
cd kangaroo
cargo build --release

With boha provider

cargo build --release --features boha

Usage

kangaroo --pubkey <PUBKEY> --start <START> --range <BITS>

Arguments

ArgumentDefaultDescription
-t, --target-Data provider target (e.g., boha:b1000/135)
-p, --pubkey-Target public key (compressed hex, 33 bytes)
-s, --start0Start of search range (hex, without 0x prefix)
-r, --range32Search range in bits (key is in [start, start + 2^range - 1])
-d, --dp-bitsautoDistinguished point bits
-k, --kangaroosautoNumber of parallel kangaroos
--gpu0GPU device index
--backendautoGPU backend: auto, vulkan, dx12, metal, gl
-o, --output-Output file for result
-q, --quietfalseMinimal output, just print found key
--max-ops0Max operations (0 = unlimited)
--cpufalseUse CPU solver instead of GPU
--jsonfalseOutput benchmark results in JSON format
--benchmarkfalseRun benchmark suite
--save-benchmarksfalseSave benchmark results to BENCHMARKS.md when --benchmark is used
--mod-step1Modular step M (hex): search only k ≡ R (mod M)
--mod-start0Modular residue R (hex): 0 ≤ R < M
--list-providersfalseList available puzzles from providers

Either --target or --pubkey is required.

Examples

Using data provider (boha):

# Solve puzzle using boha data (auto: pubkey, start, range)
kangaroo --target boha:b1000/66

# Override range (search smaller subset)
kangaroo --target boha:b1000/66 --range 60

# List available puzzles
kangaroo --list-providers

Manual parameters:

kangaroo \
    --pubkey 03a2efa402fd5268400c77c20e574ba86409ededee7c4020e4b9f0edbee53de0d4 \
    --start 8000000000 \
    --range 40

With modular constraint (k ≡ 37 mod 60):

kangaroo \
    --pubkey 03a2efa402fd5268400c77c20e574ba86409ededee7c4020e4b9f0edbee53de0d4 \
    --start 8000000000 \
    --range 40 \
    --mod-step 3c \
    --mod-start 25

This reduces the search space by ~60×. Useful when partial key structure is known (e.g., key generated with a predictable step pattern).

How It Works

The Pollard's Kangaroo algorithm solves the discrete logarithm problem in O(√n) time where n is the search range. It works by:

  1. Tame kangaroos start from a known point and make random jumps
  2. Wild kangaroos start from the target public key and make the same type of jumps
  3. When a wild and tame kangaroo land on the same point (collision), we can compute the private key

Distinguished Points (DP) optimization: Instead of storing all visited points, we only store points whose x-coordinate has a specific number of leading zero bits. This dramatically reduces memory usage while still allowing collision detection.

Performance

Expected operations: ~2^(range_bits/2)

Run kangaroo --benchmark to test your hardware without touching files. Use kangaroo --benchmark --save-benchmarks to update BENCHMARKS.md.

Use Cases

Use CaseExample
Partial key decodedPuzzle gives ~240 bits, need to find remaining ~16
Key in known rangeKnow key is between X and Y
Verify near-solutionHave candidate, search ±N bits around it

NOT useful for:

  • Full 256-bit key search (mathematically impossible)
  • BIP39 passphrase brute-force (use dictionary attack instead)
  • Puzzles without partial key information

Library Usage

use kangaroo::{KangarooSolver, GpuContext, GpuBackend, parse_pubkey, parse_hex_u256, verify_key};

fn main() -> anyhow::Result<()> {
    let pubkey = parse_pubkey("03...")?;
    let start = parse_hex_u256("8000000000")?;

    let ctx = pollster::block_on(GpuContext::new(0, GpuBackend::Auto))?;
    let mut solver = KangarooSolver::new(
        ctx,
        pubkey.clone(),
        start,
        40,  // range_bits
        12,  // dp_bits
        1024, // num_kangaroos
    )?;

    loop {
        if let Some(key) = solver.step()? {
            if verify_key(&key, &pubkey) {
                println!("Found: {}", hex::encode(&key));
                break;
            }
        }
    }

    Ok(())
}

Data Providers

Kangaroo supports external data providers for puzzle sources. Providers supply pubkey, key range, and other puzzle metadata.

boha (optional feature)

boha provides crypto puzzle data including Bitcoin Puzzle Transaction (b1000).

Build with boha support:

cargo build --release --features boha

Usage:

# Solve specific puzzle
kangaroo --target boha:b1000/66

# List solvable puzzles (unsolved with known pubkey)
kangaroo --list-providers

Provider validates range overrides - you cannot search outside the puzzle's key range.

Architecture

Download Tool