Repository navigation
Releases
Releases · ohstr/ncli
v0.8.0-rc.54
Added
- Adds a control plane to the huddle
/rtcdoor onncli relay: a client announcesmedia(mic, camera or screen sharelive/off) and saysleavebefore hanging up, the relay fans both out with each peer's media also listed onjoined, andleftnow carriesreason(leave,evictedordropped). A stopped camera or a hang-up no longer looks like a lost connection to the other side;joinedlistsfeaturesso clients can tell. (#253)
Fixed
- Fixes WebRTC huddle peers on
ncli relaynever hearing about anyone else joining or leaving: the room's control messages were discarded for them. Revoking a peer's relay membership now also closes its WebRTC session instead of leaving it connected outside the room. (#253) - Fixes the relay's own NIP-66 stats (kind 30166) keeping stale zap totals until another event arrived, when the zap ranking refreshed after the stats were published. (#258)
- Fixes
ncli bunkersometimes missing its identity's profile name and NIP-05 when a relay sent the profile and EOSE together. (#260)
v0.8.0-rc.53
Changed
- Bumps
github.com/ohstr/nmilattov0.5.0-rc.54: a private-transport item whoseparamsis present but not an object (a literalnull, string, number or array) is now refused at serve and build time, closing a cross-implementationph-mismatch (nmilat NMILAT-0010). Also carries nmilat rc.50-rc.54.
v0.8.0-rc.52
Added
- Adds a warning, logged once per peer, when per-IP limits are set and a request carries
X-Forwarded-FororX-Real-IPfrom a peer not inlimits.trustedProxies: every client behind it shares one per-IP limit. (#251)
Changed
- Changes NIP-86 to count against
limits.http: per IP, and per signer whenperPubkeyis set, but never the admins (relay key,nip86.admins), so a flood sharing their IP can't lock them out. A replayed header spends only the IP's budget, and a refusal is a 429 withRetry-After. (#250, #251) - Changes the shipped public configs and the recommended
limits:block to allow 300 reads a minute per IP (burst 600) instead of 60, and 120 HTTP requests a minute instead of 60. (#251) - Changes the release workflow to fail when GoReleaser finishes without pushing
ghcr.io/ohstr/ncli:<version>, which the release's own pins name. (#251) - Changes the JSON every command prints to keep
<,>and&as written instead of\u003c,\u003eand\u0026, such asgroup:<kind>inrelay --check --json's warnings. (#250) - Changes releases to ship pinned to themselves: the release workflow refuses to tag unless every relay image pin (chart, stacks, examples, rigs) names the version being released. Before, a release always pinned the one before it. (#249)
- Changes the public example relay configs and the public-search stack to ship with the recommended
limits:block, so they no longer start with "no rate limits configured". (#249)
Fixed
- Fixes the Helm chart (now 0.3.1) and Compose stacks running the rc.50 relay image, which lacks rc.51's fixes and ignores its new keys (
limits,listen,membership.roles,groups.create). They now run 0.8.0-rc.52, and the chart's notes say which image it runs. (#249) - Fixes the relay publishing each hosted group's kind 39001 and 39003 under the default moderation policy at every start before applying
groups.rolesandgroups.roleDescriptions, which briefly dropped every non-admin role from the group's admin list. Both are now in place before startup republishes them (nmilat v0.5.0-rc.52). (#251) - Fixes the NIP-86 IP block not covering the HTTP bridge for some requests; only NIP-86 itself, at
/, now stays reachable from a blocked IP. (#250) - Fixes a banned key joining calls when
huddle.requireMembershipis off; a ban now refuses joins either way. (#250) - Fixes
blossom list --allreportingunsupported(exit 8) when another server failed with a retryable network error, and failing when a server answered with no blobs. It now fails only if no server answered, asnetworkif any failure was retryable. (#250) - Fixes
blossom mirrorreporting a 404 whose reason says the source couldn't be fetched asunsupported; it is nownot_found, while a bare 404, or one like "unknown URL path", staysunsupported. (#250, #251) - Fixes NIP-86's rate-limit (429) and failed-login (401) answers lacking the CORS headers of
nip86.allowedOrigins, which hid them from a browser app. (#251) - Fixes unknown config keys being reported lowercased (
pprofadr); they are now named as the file writes them. A role id with a dot gets its own error instead of an unknown key. (#250) - Fixes
nip11.limitation.min_pow_difficultyandnip11.supported_nipsfailing--checkwith no hint; the error now says to usepow.min, and that the relay computessupported_nips. (#250)
v0.8.0-rc.51
Added
- Adds roles that carry tasks (
membership.roles): each NIP-43 role lists what its members may do, such as NIP-86 methods (createclaim,banpubkey), Blossom uploads, joining calls or creating groups (groups.create), and NIP-86supportedmethodstells each caller its own set. Withoutmembership.rolesormembership.members, existing settings behave as before except for the changes listed under Changed. (#243) - Adds unknown-key reporting to the relay config:
ncli relay --checkfails (invalid_input) naming every key the relay doesn't know, such as a typo, and a normal start logs a warning for each, on stderr and in the log file; a key left with no value counts too. (#236) - Adds
listen(host:port) to the relay config, to bind one address instead of every interface onport. When set it wins overport, the admin listener's default port and the admin commands follow it, and--checkrejects a host that does not resolve;NCLI_LISTEN/NCLI_PORTnow reach the relay even with no such key in the file. (#237) - Adds opt-in rate limits to the relay (
limits): EVENT, REQ/COUNT, the HTTP bridge and Blossom per pubkey and per IP, plus connections per IP, with members optionally exempt and refusals counted inncli_relay_rate_limited_total. A limit left unset is no limit, and a public relay without any, or a per-pubkey limit that never applies, gets a warning, also listed inrelay --check --json's"warnings". (#241) - Adds a warning, at startup and in
relay --check, whenlistenis on loopback with per-IP limits butlimits.trustedProxiesdoesn't cover that address: behind a local reverse proxy every client would share one per-IP limit. (#245)
Changed
- Changes the Helm chart (now 0.2.0) and Compose stacks to pin their images: MinIO by digest, and the relay to the release candidate
0.8.0-rc.50instead oflatest, which was the 0.6.0 release. The relay pin moves to each new release. (#235) - Lets a chart image take an optional
digest, and adds the pinned MinIO digest only to the default image: pin a mirror or another tag with an exacttagor its owndigest.helm upgrade --reuse-valueskeeps an older chart's images, so use--reset-then-reuse-values. (#235) - Changes
membership.memberClaims, when unset, to follownip11.limitation.membership_required: on a relay withmembership_requiredand NIP-86 enabled, a member'screateclaimis now refused (401) and only admins mint invites. SetmemberClaims: trueto keep the old behaviour. (#234) - Changes a NIP-43 invite request (REQ kind 28935) to need
createclaim, as NIP-86createclaimdoes: it now gives a code only to admins, members whenmemberClaimsis on, and roles that list it. Before, any connection allowed to read got one. (#243) - Changes
huddle.requireMembershipto admit the relay's admins (nip11.pubkey,nip86.admins) even when they are not members. (#243) - Changes a banned member to lose
createclaim(NIP-86 and invite requests) and joins to calls underhuddle.requireMembership. Before, the ban only stopped its events and Blossom uploads. (#243) - Changes NIP-43 role ids to be stored lowercase:
createrole,assignrole, enrolling and invites lowercase them, andunassignrole hostalso removesHost. (#243)
Fixed
- Fixes the relay's Blossom answering 404 for a blob at the root (
/<sha256>), where BUD-01 serves it;/media/<sha256>still works.ncli blossom downloadof a full URL now fetches that URL first, then asks servers by hash, and reports a URL serving other bytes asnot_found. (#244) - Fixes
ncli blossom list,upload --optimizeandmirrorreporting a server without that endpoint asnot_foundor a retryablenetworkerror; they now reportunsupported(exit 8), and the relay says those endpoints are not supported. A 3xx, 405 or 501 from any Blossom endpoint is nowunsupportedtoo, where it wasnetworkorinvalid_input. (#244) - Fixes
relay --check --jsonlisting"warnings": []while logging thatportis ignored becauselistenis set (or thatpow.stricthas nopow.min); it now lists every config warning, and startup logs each once. (#245) - Fixes the Blossom blob URLs the relay returns having no file extension, which BUD-02 requires: they now end in one for the blob's type, or
.binwhen it is unknown (nmilat v0.5.0-rc.51). (#243) - Fixes
POST /eventsaccepting a non-member's event into a private, closed or restricted NIP-29 group; it now refuses it (403) as the WebSocket does, and refuses group moderation kinds and requests (9000-9022) with a 400, since they only work over a WebSocket (nmilat v0.5.0-rc.51). (#246) - Fixes the relay's Blossom serving a blob, with whatever type its uploader gave, as a page on the relay's own origin: every blob now comes with
nosniffand a sandboxing CSP, an untyped blob isapplication/octet-stream, and anything but images, audio, video and plain text downloads as an attachment (nmilat v0.5.0-rc.51). (#246) - Fixes NIP-86
allowpubkeyon someone already a member, which re-enrolled them and dropped their roles: it now leaves the member unchanged. (#243)
v0.8.0-rc.50
Added
- Adds option details to
ncli form(NIP-PFdetailtags): a spec option'sdetail, or theform createprompt, says what choosing it does.form showandform respondprint it under the option, and--jsonincludes it. (#227)
Fixed
- Fixes GO-2026-6888 (excessive memory use decompressing a crafted brotli stream) by moving to brotli v1.2.7. (#227)
v0.8.0-rc.49
Added
- Adds
POST /count(NIP-45) to the relay's HTTP bridge (httpBridge.count.enabled), with the same rules asPOST /query. (#224) - Adds seat notices (
groups.membershipNotices): the relay tells a member, live, when they gain or lose a seat in a group. Only that member and relay admins can read one. (#224) - Adds presence (
presence.enabled):POST /queryfor kind 40902 answers whether each author is online. (#224) - Adds Blossom on the relay's own origin (
blossom): members upload, anyone or only members download, and files live in a directory or MinIO. (#224)
Changed
- Changes
build/relay/todeploy/: one Helm chart with optional Meilisearch and MinIO, and a ready-to-run stack per kind of relay (dev,personal,public-search,community). Secrets reach the relay asNCLI_*variables. (#224) - Changes the relay to serve gift wraps (kind 1059) only to a reader logged in (NIP-42) as their recipient, so a signer policy must allow kind 22242 for its key to read them.
recipientOnlyKinds: []restores the old behaviour. (#224)
Fixed
v0.8.0-rc.48
Added
- Adds
dm reactanddm unreact: NIP-25 reactions and their NIP-09 retractions inside NIP-17 gift wraps, to the conversation's participants and a copy to yourself.dm readshows them asreaction/deleteentries, and--foldapplies the deletions (each only to its own author's events) and folds reactions into the messages they react to. - Adds the signer's
nipoa_attestmethod andattestrule (subordinates, a requiredmax_until,kinds): an attestation is signed only when such a rule allows it, so existing policies refuse every one.signer check --method nipoa_attest --subordinate --conditionsdecides one offline. - Adds
ncli id attest, which signs a NIP-OA owner attestation with--identityor through--signerand prints theauthtag, verified. - Adds
ncli form create/list/show/respond/withdraw/result: NIP-PF forms (kinds 1069, 1019, 1070) -- questions with the recommended option and why, notes required on some options, defaults, quorum and an end, answered in one response and closed by the author with a result (decided, default, cancelled). A form is private (--to: gift-wrapped to each responder and to you), in a NIP-29 group (--group --relay) or public;respondrefuses a response the form doesn't accept before anything is sent. Every rule is nmilat'snippf. - Adds the
ncli-formsskill. - Adds labels to
dmandform: an event'sttags print as#label(printable ASCII, every other rune escaped) after the author and before the subject or title, anddm send --labelsets them. - Adds
--auth(andNCLI_AUTH_TAG) to every command that signs through--signer: a NIP-OAauthtag, checked against the signer's key, added to every event it signs whose kind and time its conditions allow -- on a DM's or a private form's rumor too, inside the seal; never on a seal, a gift wrap or a NIP-42 login event. - Adds the signer selector
tags_one: the event must carry exactly one tag of each named key, with a listed value. Unliketags, an event with a second same-named tag doesn't match, so a NIP-42 login can be bound to one relay. The example policies use it forrelay. - Adds
ncli nip98 <url> <method>, which prints a NIP-98Authorizationheader signed with--identityor through--signer;--payload-filebinds the request body. - Adds NIP-OA attestations to
dm read,dm verify,groups read/feedand theformcommands: anauthtag is checked,--jsongivesattested_by,attest_validandattest_trusted, and text output shows[agent of <owner>]for an owner named in--trust-owners(word:--attest-label),[attested by <owner>, owner not trusted]or[invalid attestation], in the client's column after the author.
Changed
- Changes subjects, titles and message lines to print a non-ASCII letter that sits beside ASCII letters as an escape (look-alikes such as a Cyrillic
е), collapse padding, and cap titles at 200 runes.
Fixed
- Fixes ncli's own NIP-98 headers (relay admin, huddle) tagging their anti-replay value
nonce, which NIP-13 reads as a proof-of-work claim, so a socket signer's client refused them. They tagsalt, as nmilat'snip98.Signdoes; verifiers never read it, so old and new headers interoperate. - Fixes the signer charging an
unwrap_fromrule's rate before it knew the seal's author, so gift wraps from anyone could use up a listed sender's rate. The rate is charged only for a wrap the rule releases; refused wraps are remembered and refused again without decryption;dm readretries a wrap refused for rate instead of skipping it. - Fixes text output printing fields a relay or another author controls (message content and subject, reactions, group, space and profile fields, decoded NIP-19/token identifiers, relay hints and labels, identity relays, NIP-85 stat values, every relay publish result, and Blossom server responses and blob listings) raw: control, separator and format characters (bidi, zero-width, tags) and invalid UTF-8 now print as Go escapes, and multi-line content stays indented, so remote text can't forge a line, move the cursor or reorder what the terminal shows.
--jsonis unchanged. - Fixes
find -fanddm read -flosing messages: a gift wrap that didn't open (or was dated in the future) no longer moves the resume point, a saved resume point ahead of now is dropped, and a resubscription pages back through a relay's stored events past its per-request cap, so a backdated wrap under a flood is still delivered.
v0.8.0-rc.47
Added
- Adds the proposed NIP-86
createclaimwithlimitsandgetclaimmethods, so a host's app can mint an invite with an explicit per-code expiry or use-limit and read any code's state back.ncli relay invites creategains--expires-atand--no-expiry, andncli relay invites get <code>shows a code's claim, expiry, max-uses and uses, including expired or used-up ones. (#221) - Adds the
membership.inviteMaxTTL(default 30 days) andinviteAllowNoExpiry(default false) config keys, which cap how far an absolute expiry may be set and gate never-expiring codes. A requested limit outside policy is refused, never silently clamped. (#221) - Adds NIP-43 member claims: with
membership.memberClaims(default true), a plain member — not only an admin — may mint an invite viacreateclaim, scoped to justcreateclaimandsupportedmethods. Set it false to keep the Relay Management API admin-only. (#221)
Fixed
- Fixes the vault password prompt failing with
inappropriate ioctl for devicewhen the event is piped into a signing command (e.g.ncli event new … | ncli publish -e - --signer <label>). The prompt now reads from the controlling terminal, like ssh/sudo, and falls back to a clear "set NCLI_VAULT_PASSWORD" error when no terminal is available instead of the cryptic ioctl one. (#206)
v0.8.0-rc.46
Fixed
- Fixes a NIP-46 consent flaw where approving a bunker
connectsilently granted every permission the app requested, permanently, even for an "Approve Once". The approval now shows the requested scope, "Approve Once" remembers nothing, and sensitive kinds (0/3/5 -- identity, contacts, deletion) always require per-request consent. (#204)
v0.8.0-rc.45
Changed
- Builds with nmilat v0.5.0-rc.47, which renames a circlehub1 connection's
fields and refuses unsigned cash tokens and connections.event validate
checks an AltZap receipt by rules 1-9 (ValidateAltZapReceiptForRelay),
offline, as it does NIP-57's receipts; rule 10 needs the LNURL server.