fix(relay): distinguish unknown channel from not-a-member rejections - #7856
Closed
BachirSaaS wants to merge 1 commit into
Closed
BachirSaaS wants to merge 1 commit into
BachirSaaS wants to merge 1 commit into
Conversation
🔐 Codex Security Review
|
'restricted: not a channel member' was returned for two different conditions: the pubkey really is not a member of an existing channel, and the channel does not exist on this relay at all. Case 2 means the client is talking to the wrong relay, but on the wire it was indistinguishable from a permissions problem (block#7517). Extract open_visibility_or_unknown() for the two open-visibility fallback lookups (generic membership gate + edit-ownership re-gate): ChannelNotFound now maps to 'unknown: channel not found on this relay' while all other lookup errors keep failing closed to the previous membership rejection. Signed-off-by: BachirSaaS <bachir.dagodi@gmail.com>
BachirSaaS
force-pushed
the
fix/relay-channel-not-found
branch
from
September 24, 2026 01:17
620e3de to
bc910f8
Compare
Author
|
Closing — we'll maintain these fixes in our fork instead. Thanks for the look. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
restricted: not a channel memberwas returned for two very different conditions: the pubkey really is not a member of an existing channel, and the channel does not exist on this relay at all. Case 2 means the client is talking to the wrong relay, but on the wire it was indistinguishable from a permissions problem (#7517).Extract
open_visibility_or_unknown()for the two open-visibility fallback lookups (the generic membership gate and the edit-ownership re-gate):ChannelNotFoundnow maps tounknown: channel not found on this relayThe per-channel CLOSED exact-match list in buzz-acp (
CHANNEL_ACCESS_DENIED_REASONS) is unaffected — clients that special-case the old string see it unchanged.Testing
cargo test -p buzz-relay --lib open_visibility— new pure test covers all four branches (missing/open/private/other-error).Fixes #7517