Tool · Keys & addresses
Schnorr signature
Sign, verify, then flip one bit and watch it fail
What it does
Type a message and the tool signs its SHA-256 digest with the private key, then verifies the signature against the public key. Use the Flip one bit buttons to change a single bit of the message, the signature or the public key, and watch verification fail. Press a button again to undo it.
How to read it
- A signature is 64 bytes: R.x, the x-coordinate of a one-time point, then the number s.
- The verifier recomputes a challenge e = TaggedHash(“BIP0340/challenge”, R.x ‖ P.x ‖ m) and checks s·G = R + e·P. Open How verification works to see every value.
- One flipped bit in any of the three inputs changes e (or s) completely, so the equation fails. There’s no “almost valid”.
Pearl specifics
- Pearl’s transaction signatures are Schnorr (BIP-340): Pearl has no ECDSA in transactions. (XMSS, a post-quantum signature, is an opt-in extra inside tapscript.)
- Pearl’s default signer picks the one-time nonce deterministically (RFC 6979, with extra data SHA-256(“BIP-340”)), so the same key and message always give the same signature. That’s what this tool uses.
- Real transactions sign a TapSighash digest of the transaction, not SHA-256 of some text. The math is the same.
- The key here is for learning only.
Under the hood
Runs entirely in your browser. Signing and verification are src/lib/keys.ts on top of the audited
@noble/curves. Unit tests check the official BIP-340 vectors, and that the deterministic signer reproduces
real Pearl signatures from the research, byte for byte.