Home / Blog / Practical Quantum Safe Bitcoin: Comments
Tech News

Practical Quantum Safe Bitcoin: Comments

Espresso Systems published Practical Quantum Safe Bitcoin (PQSB), showing 0.76-second RTX 5090 signing and four mainnet spends across Legacy and SegWit.

By Dillip Chowdary • Dec 06, 2026 • Source: github.com

Practical Quantum Safe Bitcoin: Comments
Image: github.com

At a glance

Product
Practical Quantum Safe Bitcoin (PQSB)
Formats
Legacy PQSB (Script), SegWit PQSB (P2WSH)
Security levels
Legacy 92-140 bits; SegWit 64-95 bits
RTX 5090 rate
4.05 billion tries per second
Mainnet blocks
978,456; 978,542; 978,560; 978,653
Software status
Experimental, unaudited, plaintext secrets

Espresso Systems published the Practical Quantum Safe Bitcoin (PQSB) codebase on GitHub, bundling the research paper, implementation tools, benchmark records, and Lean 4 formalizations. The release builds two quantum-resistant Bitcoin vault designs: Legacy PQSB, which relies on legacy Bitcoin Script, and SegWit PQSB, which supports SegWit v0 and standard P2WSH mempool relay limits. Four spends across both designs have already been mined on Bitcoin mainnet.

This article covers the signing benchmarks, local vault builder setup, mainnet transaction explorer, and security caveats documented in the repository. It is written for Bitcoin developers, node operators, and researchers testing quantum-safe spending workflows on regtest or small mainnet amounts using Python, Rust, C, and optional CUDA or Metal GPU solvers.

01Faster signing and mainnet relay gains

Legacy PQSB spans seven classical forgery targets from 92 to 140 bits, while SegWit PQSB offers six levels from 64 to 95 bits. At a 124-bit target, Legacy PQSB requires about 2^28.7 expected signing trials, with 30 spends averaging 0.76 seconds on an RTX 5090. Optimised solvers estimate 24 seconds on a MacBook M3 GPU and 41 seconds on four x86 cores with SHA extensions, and a 124-bit spend mined in block 978,560.

Raising Legacy PQSB to roughly 132 bits increases expected trials to 2^35.2, taking about nine seconds on an RTX 5090 or 12 minutes on an M3 GPU. SegWit PQSB fits standard P2WSH relay limits so any Bitcoin node propagates spends, requiring 2^31.8 trials at 80 bits. That 80-bit tier takes roughly one second on an RTX 5090 or 72 seconds on an M3 GPU, with mainnet spends mined in blocks 978,456, 978,542, and 978,653.

02Building and running the local vault

The implementation-app directory provides both a browser interface and a terminal CLI that walk users through choosing SegWit or Legacy mode, mainnet or regtest, and a hardware-matched security level. Each payment requires fresh secrets, so the builder creates and tracks a separate vault per spend. Running the software requires Python 3.12 or later without extra packages, a C compiler, and Rust on Linux, macOS, or Windows WSL2 Ubuntu 24.04 or later.

  1. Clone and compile Run git clone https://github.com/EspressoSystems/PQSB.git, change into PQSB/pqai-btc-everything/implementation-app, and execute solver/build.sh for CPU, Metal on Apple silicon, or CUDA when nvcc is on PATH.
  2. Build the verifier Run (cd verifier && cargo build --release) inside implementation-app to compile Bitcoin Core's consensus library for transaction checks.
  3. Configure CUDA on WSL2 Install only cuda-toolkit from NVIDIA's WSL-Ubuntu repository rather than a Linux driver, add /usr/local/cuda/bin to PATH, and match nvidia-smi limits before rerunning solver/build.sh.
  4. Launch on regtest Start python3 tools/pqsb_app.py for the local 127.0.0.1 web page or BITCOIN_BIN=/path/to/bitcoin/bin python3 tools/pqsb_cli.py --regtest to test with play coins.

New vaults default to 80 bits for SegWit and 124 bits for Legacy, though any level from the tables can be selected, and SegWit vaults holding real value should use 80 bits or more. Solver computation costs are separate from Bitcoin transaction fees.

Advertisement

Tech Pulse Daily

Get tomorrow's pulse first

Join engineers who read Tech Pulse before stand-up. Free, weekday mornings.

03Mainnet explorer and repository archive layout

A local explorer scans Bitcoin Core blocks starting from block 978,243 using python3 -m qsb2 scan --follow --mempool to write explorer/index.json. It validates each PQSB spend against the script model, Bitcoin Core's consensus library, relay limits, T's lengths, and pins. Serving the static interface via python3 -m http.server -d explorer 8000 displays transactions at http://127.0.0.1:8000/ while keeping node RPC calls restricted to localhost.

The repository separates Paper/introspection-pqsb.pdf and its LaTeX source from pqsb-lean/, which holds machine-checked Lean 4 proofs of counting, work, and forgery bounds. Under pqai-btc-everything/, BENCHMARKS.md and benchmarks/ record measured and estimated RTX 5090 and M3 figures. Earlier code snapshots sit in implementation-main/, implementation-cuda/, and implementation-metal/ alongside the main implementation-app/ suite.

04Unaudited code and plaintext key caveats

Note: The PQSB codebase is experimental, unaudited software, and users should never trust it with coins they cannot afford to lose. Secrets are stored in plaintext in this demo, and any mistake in key generation, script execution, or handling lock.json can permanently lose coins.

While pqsb-lean/ machine-checks the paper's mathematical bounds, no formal proof verifies the Python, C, or Rust implementation scripts themselves. Legacy PQSB's list selections also have no clamp, meaning the claim that every accepted spend selects disclosed entries is a tested argument rather than a formal proof. Users should run every step on regtest first before locking small amounts on mainnet.

05SegWit PQSB levels and hardware benchmarks

SegWit PQSB uses a P2WSH lock with pins, searching across seven to ten positions, one to six pins, and up to 127 commitments within standard relay rules. Every script contains 201 operations, producing spends around 1,060 vB with nine positions or 1,076 vB with eight. Hardware benchmarks reach 4.05 billion tries per second on an RTX 5090 and 51.2 million tries per second on a MacBook M3 GPU.

LevelPositionsCommitmentsPinsLengths of TBytesSigner triesRTX 5090MacBook M3 GPU4 x86 cores
64979458, 8 × 591,9852^15.79under a secondunder a secondunder a second
72979457, 8 × 591,9852^23.79under a secondunder a secondunder a second
80979456, 8 × 591,9852^31.79under a second73 s88 s
87888655, 7 × 592,1762^37.7959 s77 min94 min
88979455, 8 × 591,9852^39.794 min5.2 hours6.3 hours
95888655, 58, 6 × 592,1762^45.794.2 hours14 days17 days

Levels 87 and 95 use eight positions and six pins to sit one bit below 88 and 96 while requiring a quarter of the signing tries. Across the table, higher forgery resistance trades exponential solver time against standard mempool relayability on unmodified Bitcoin nodes.

Frequently asked questions

What is the difference between Legacy PQSB and SegWit PQSB?

Legacy PQSB depends on legacy Bitcoin Script and spans seven forgery levels from 92 to 140 bits. SegWit PQSB supports SegWit v0 across six levels from 64 to 95 bits and fits standard P2WSH relay limits so any Bitcoin node relays its spends.

How fast does PQSB sign transactions on consumer hardware?

On one RTX 5090, 30 Legacy PQSB spends at 124 bits averaged 0.76 seconds, while an 80-bit SegWit PQSB spend takes under a second. On a MacBook M3 GPU, optimised estimates are 24 seconds for 124-bit Legacy and 73 seconds for 80-bit SegWit.

Is PQSB safe to use for securing large Bitcoin holdings?

No, the repository states that PQSB is experimental, unaudited software that stores secrets in plaintext. While pqsb-lean/ machine-checks the paper's math, the scripts themselves are not formally proved, so users should test on regtest and avoid locking funds they cannot afford to lose.

What software is required to run the PQSB builder locally?

The builder in implementation-app/ requires Python 3.12 or later without extra packages, a C compiler for the solver, and Rust for Bitcoin Core's consensus verifier. It runs on Linux, macOS, or Windows via WSL2 with Ubuntu 24.04 or later.

Sources

Dillip Chowdary

Author

Dillip Chowdary

Writes Tech Bytes coverage of AI, engineering, and the tools that actually ship. Editor of Tech Pulse Daily.

Related on Tech Bytes

Advertisement

5-min tech signal

Weekday briefing for engineers who skip the noise.

No spam · Unsubscribe anytime

Advertisement

✈️ CareerPilot

Your AI job-search copilot

Match your resume against live Ashby, Greenhouse & Lever openings — fit scores, job-specific resume optimization and email alerts.

Find matching jobs →

Free Tools

Browse all tools →