NIP-39 Identity, NIP-86 Relay Administration, and Two-Way Relay Attestation Across the Nostr Suite

Shipping NIP-86 JSON-RPC relay administration and browser console management, SNIP-03 two-way NIP-11 relay operator attestation in pgpstr, NIP-39 kind:10011 identity migrations for SNIP-01/bukkitstr, and NIP-58 kind:10008 profile badge upgrades in ocweb.

NIP-39 Identity, NIP-86 Relay Administration, and Two-Way Relay Attestation Across the Nostr Suite

Over the past week, development across the Nostr and Sovereign Wellbeing stack focused on three core themes: giving relay operators sovereign browser-based management tools, migrating identity protocols off overloaded kind:0 metadata onto dedicated NIP-39 kind:10011 and NIP-58 kind:10008 records, and introducing cryptographic two-way verification between Nostr relays and their operators.


1. NIP-86 Relay Administration & Micro-Relay Hardening

All six Wellbeing Go micro-relays (cellibacy-relay, holyfit-relay, nunlock-relay, saintstream-relay, sistercharge-relay, and thehabit-relay) now implement the NIP-86 Relay Management API, enabling live administrative control without SSH restarts or manual config edits.

To pair with those relays, the new Nostr Relay Manager web console provides a browser-native administration interface powered by NIP-98 (kind:27235) signed JSON-RPC over NIP-07 extensions:

  • Live Stored Event Explorer: Inspect stored events in real time with rendered cards, raw JSON inspection, and one-click moderation actions attributed to the moderator pubkey.
  • Access & Network Firewalls: Ban or allow pubkeys, ban specific events, block or unblock IP addresses, and dynamically toggle allowed event kinds.
  • Live NIP-11 Overrides: Update relay name, description, and icon directly through changerelayname, changerelaydescription, and changerelayicon.
  • Badge-Gated Groups: holyfit-relay also adds NIP-29 group support gated by NIP-58 badges with NIP-70 protected-event enforcement.

2. Two-Way Relay Operator Attestation (SNIP-03)

Anyone can place an arbitrary pubkey inside a relay’s NIP-11 information document. To make operator identity cryptographically verifiable, SNIP-03 (Section 4) now formalizes a two-way handshake between a relay and its operator’s PGP root identity:

  1. Relay → Operator (NIP-11): The relay’s NIP-11 JSON advertises "pubkey": "<operator_hex_pubkey>" (with standard NIP-11 CORS headers enabled for browser verification).
  2. Operator → Relay (kind:34301): The operator lists operated relay WebSocket URLs as r tags on their kind:34301 proof event alongside a matching Verifying that I operate the following Nostr relays: section inside the OpenPGP-clearsigned payload.

Both directions must agree before a client marks a relay as verified. Unilateral NIP-11 pubkey values fail attestation, and unconfirmed r-tag claims in a user’s proof are flagged and rejected as impersonation.

In pgpstr, the web tool now includes:

  • Direct verification for both Nostr public keys (npub / hex) and relay URLs (wss:// / ws://).
  • An Existing Proof Status card showing live signature, Nostr text, kind:10011 link, and relay attestation checks upon connecting.
  • An interactive Relay Ownership builder with live NIP-11 pubkey matching and automatic nostr-proof.txt template generation.

3. Moving External Identities Out of kind:0 (NIP-39 kind:10011)

Across Nostr, external platform claims (github, twitter, pgp, minecraft, etc.) have moved out of kind:0 profile metadata into dedicated replaceable kind:10011 external identity lists. Both SNIP-01 and SNIP-03 and their reference clients now follow that model:

  • pgpstr (SNIP-03): Queries NIP-65 (kind:10002) read and write relays for the latest kind:10011 right before publishing, merging updated pgp:<fingerprint> tags non-destructively so existing external identity tags remain intact.
  • bukkitstr (SNIP-01):
    • Updated 01.md and BukkitstrPlugin to look up Minecraft usernames exclusively from NIP-39 kind:10011 events (["i", "minecraft", "<username>"]) across NIP-65 relays, plus npub1 decoding support in /nostrauth.
    • Updated the embedded Go dev relay to accept kind:10011 and fixed WebSocket framing in writePump() so queued protocol frames (EVENT and EOSE) are each delivered in their own WebSocket message.
    • Updated web-auth to verify whether a player’s kind:10011 already links their Minecraft username and append it non-destructively if missing before signing the ephemeral kind:21337 challenge.

4. Nostr Genesis (ocweb) & NIP-58 kind:10008 Profile Badges

While SNIP-04 (oc Origin Claim) remains anchored on kind:0 because it points internally to a Nostr event rather than an external identity, NIP-58 Profile Badges have transitioned in the Nostr specification from addressable kind:30008 (d=profile_badges) to replaceable kind:10008.

ocweb has been updated with:

  • NIP-58 kind:10008 Migration: Reads kind:10008 first with an automatic fallback to legacy kind:30008 (d=profile_badges), and writes standard kind:10008 events when saving badge layouts or claiming awards.
  • Safer kind:0 Merges & Socket Hardening: Queries NIP-65 read and write relays before updating oc tags, pins nostr-tools@2.25.2, enforces WebSocket handshake watchdogs and beforeunload cleanup, and escapes rendered event content to prevent XSS.

5. Android & Documentation Housekeeping

  • Cleaned up obsolete blossom_servers configuration across all six Wellbeing Android repositories (Cellibacy, Holy Fit, Nunlock, Saint Stream, Sister Charge, and The Habit).
  • Updated SNIP-10 (v3.0.1) documentation to clarify immediate legacy kind EOL and current Blossom tooling references.

Write a comment