direction / prototype
Asymmetric vanity npubs
A human-readable Nostr name that is also hard to impersonate, without a NIP-05 server.
A Nostr identity is a public key. That is secure and decentralized, and completely unreadable. The usual fixes are a NIP-05 handle, which is readable but needs a server, or a vanity npub, which is readable but gives an attacker the same name for the same grinding cost. This note is about a third option: a name that is readable and expensive to copy, with no registry and no server.
The problem
Zooko’s triangle says a name can be human-readable, secure against impersonation, and decentralized — pick two. The Nostr ecosystem mostly picks two:
| Approach | Readable | Secure | Decentralized |
|---|---|---|---|
| Raw npub | no | yes | yes |
| NIP-05 handle | yes | yes | no, needs a server |
| Pure vanity npub | partly | no | yes |
A pure vanity npub such as npub1meshmate… has no anti-phishing asymmetry. Finding the same prefix costs an attacker about what it cost the owner. The name is a label, not a proof. If someone presents a different key with the same word, the user has to compare the rest of the string by eye, which is exactly the thing people do not do.
Two zones
The idea is to stop treating the npub as one string. Split it into two zones with different jobs:
npub1[meshmate][random][qpqpqpqpqp][random]
^^^^^^^^^ vanity ^^^^^^^^^^ anti-phish
human-readable low-entropy outlier
- Vanity zone. A word, ground for. This is the part a person remembers.
- Anti-phish zone. The most statistically anomalous window in the npub: the window with the lowest Shannon entropy, measured at several lengths against a baseline of random npubs. It is discovered, not constructed. Among the candidates that already contain the vanity word, the owner picks the one with the strongest natural outlier.
- Disjoint charsets. The vanity zone uses only the characters in the word; the anti-phish zone uses only the complement. The two zones therefore render in different palettes. The name pops, and the fingerprint is visible next to it.
The z-score of the outlier is the proof-of-work receipt. A stronger outlier means more grinding, and a higher cost to forge. The owner pays only for the vanity prefix; the outlier is free among the candidates.
Why the asymmetry holds
The owner accepts any candidate with a strong outlier. The attacker must reproduce that specific outlier. Those are different problems.
The repository’s model numbers, for the word meshmate:
| Metric | Value |
|---|---|
| Vanity grind | ~2^37 keys |
| Attacker exact match | >>2^60 |
| Asymmetry | >1,000,000:1 |
These are model estimates, not a live adversarial measurement. The claim is directional: finding any low-entropy window is cheap, and matching a named one is not.
Grinding without custody
An eight-character word is hours to days on consumer hardware, which makes “vanity npub as a service” attractive. The naive version requires the user to hand over the nsec. Offset grinding avoids that.
On secp256k1, P = k·G. Adding a constant d to the secret key shifts the public key predictably:
(k + d)·G = k·G + d·G = P + d·G
A service can start from the user’s public key P, add G repeatedly, encode each candidate, and check for the word and the outlier. It returns the offset d. The user computes (k + d) mod n. The service never sees k, and the user never shares it.
Selling the offset atomically
An offset is easy to copy and hard to find, so selling one needs an atomic exchange. The shape is a hash lock:
- The seller commits
h = H(d). - The buyer locks payment to “reveal
dand sign with the seller’s key”. - If the seller never claims, a timelock refunds the buyer.
- When the seller claims,
dbecomes public — but the payment output is already spent. Knowingdalone is useless without the signature.
That is the same dual-condition shape as a Cashu or Lightning HTLC, applied to a grinding offset instead of a payment. The interesting part is not the escrow; it is that the secret being sold is a small integer that changes the buyer’s key, not a bearer token.
What is not solved
- No production client. The repository has the ADRs, analysis scripts and visualisations, not a wallet or a client that renders the two zones.
- The baseline needs reproduction. The entropy baseline and the outlier scanner should be independently re-run before anyone treats a z-score as a security parameter.
- Lookalikes are separate. Homoglyphs, transposed characters and social engineering are not solved by a fingerprint.
- Rotation costs a new grind. A new key means a new vanity prefix and a new outlier.
- No standard. Clients would need to agree on the rendering, the charset split and the z-score check. Until then this is a convention, not an identity layer.
- The numbers are models. They are useful for the argument; they are not a measurement against a funded attacker.
Status
Direction / prototype. The idea is a cheap, decentralized anti-phishing layer that does not need a NIP-05 server. The repository contains the design records and the analysis; it is not a shipped identity system.
Get involved
asymmetric-vanity-npubs— the ADRs, the analysis and the visualisations.- If you run a Nostr client, the useful contribution is rendering the two zones and showing the z-score next to the name.
- If you have a key-grinding setup, re-running the baseline is the most useful check.
Issues and questions: open one in the repo, or message the TollGate team on Nostr (npub1zzt0d0s2f4lsanpd7nkjep5r79p7ljq7aw37eek64hf0ef6v0mxqgwljrv, also in the index).
← Back to Thoughts · Next: Trusted without being identified →