Repository navigation
Conversation
POST /query with {"access":"readers","channel":..,"pubkeys":[...]} says,
for up to 100 people, whether each can read the channel, by the check a
task's assignees meet: member rows, open channels, and the parents under
parent_access. Everyone named gets an entry, so false always means
"cannot read".
Only a signer who can read the channel may ask. Otherwise, and for a
missing or deleted channel alike, the request is refused with 403
"not-allowed", never answered with a list of falses. NOSTR.md states the
disclosure this allows: an asker learns that a named person reads the
channel through a parent the asker isn't in. NIP-11 advertises
buzz-channel-readers.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: morgmart <98432065+morgmart@users.noreply.github.com>
The shared read check, which both the assignee rule and the readers answer use, now says false for someone banned from the community, or an agent whose owner is, open channels included. A banned person can no longer be assigned to a task they can't open, and the readers answer agrees with the ban refusal they get when they ask for themselves. A timeout leaves reading alone. NIP-AR and NOSTR.md state the rule. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: morgmart <98432065+morgmart@users.noreply.github.com>
The readers answer now documents, as intended, that a ban can be inferred by comparing a "can't read" with the channel's member list, and that the relay never states the reason for someone else. The sentence on banned askers moves after the missing-channel refusal it was splitting. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: morgmart <98432065+morgmart@users.noreply.github.com>
jedwards27
left a comment
There was a problem hiding this comment.
🤖 :bot: Jude’s code review agent — blocking finding (GitHub comment review under repository agent-review policy).
Reviewed 2bedcb6a231b36a646f18276d4854ff92b8d86f5..ac63e76f5ed59f43ac60f6e9f7154b46ad6ebe5d at a clean checkout. Risk: high, because this is a newly advertised authorization answer for task readers. Recommended verdict: changes needed.
P1 — Include community admission in the named-reader verdict. crates/buzz-relay/src/handlers/channel_access.rs:152–181,200–215 runs can_read for each named key, checking bans and channel/parent/open access, but not relay admission. On require_relay_membership communities, removing a human from relay_members leaves their channel row intact (crates/buzz-db/src/store/relay_members.rs:285–307). This endpoint then reports read:true for that removed person (and for arbitrary nonmembers of an open channel), although their own /query request fails relay_membership_required at crates/buzz-relay/src/api/bridge.rs:1701–1725 via crates/buzz-relay/src/api/mod.rs:267–327. This defeats the endpoint’s stated “who can read”/task-refusal purpose. Author action: make named-reader results account for effective community admission on closed relays, and add a real POST /query regression for a revoked relay member who retains a private-channel row and an unadmitted key in an open channel. Preserve the request-bound NIP-FI/NIP-OA owner-delegation semantics; a bare agent pubkey is not equivalent to a direct roster row. Verification owner: PR author for fix/regression; reviewer for next-head integration.
Non-blocking: NOSTR.md:387–388 calls the result a “snapshot.” Its entries are concurrent reads, as with the existing multi-channel answer (handlers/channel_access.rs:90–108); this protocol does not promise the atomic/consistent cut that docs/nips/NIP-AR.md:184–198 explicitly requires for sync. Clarifying that this is a re-queryable, non-atomic observation would reduce ambiguity, but a transaction across 100 keys is not required for this PR.
Validation: clean HEAD=ac63e76f5ed59f43ac60f6e9f7154b46ad6ebe5d, git diff --check 2bedcb6a...HEAD passed after Hermit activation. Exact-head CI passed, including PostgreSQL tests, relay E2E, Rust unit/lint, and cross-compile. Source-traced the new HTTP reader route, channel predicate, roster revocation, and request admission. No independent local closed-relay run or native app journey was performed; this diff introduces a relay API and has no changed UI. The missing closed-roster regression is an author-owned defect, not a tooling-only hold. Documented parent/ban inference is accepted design, not an additional privacy finding.
Stacked on #9602 (assignees). Review only the last three commits; the base branch carries the rest of the stack.
What
The app can ask the relay which people can read a place, instead of guessing from member lists the viewer may not be allowed to read. Part 2 of the task refusals work (the "can't see this task anymore" line) uses this answer.
POST /querywith exactly[{"access":"readers","channel":<channel id>,"pubkeys":[...]}]: one lowercase channel ID and 1 to 100 distinct lowercase hex pubkeys. Any other shape is refused with 400.{"pubkey","read"}entry per person, in request order. Nobody is left out, sofalsealways means "cannot read".channel_access::can_read, the check a task's assignees meet: member rows, open channels, and the parents underparent_access. A conversation follows its home.blocked: you are bannedrefusal, the same answer feat(relay): answer what a viewer may do in channels, and say when to ask again #9582 gives.not-allowed: the signer cannot read this channel. A missing or deleted channel gets the identical refusal, so it can't be used to probe whether a private channel exists. A refusal is never a list of falses.buzz-channel-readers.Testing
a_reader_learns_who_else_can_read_a_place, throughPOST /query:parent_access nonetakes the project's readers away.a_banned_person_reads_nothinganda_banned_person_cannot_be_assigned:🤖 Generated with Claude Code