Skip to content

Prevent duplicate Buzz surfaces from bypassing relay egress controls (VERIA-146) - #205

Open
veria-ai[bot] wants to merge 2 commits into
mainfrom
veria/146-duplicate-buzz-surfaces-bypass-relay-spe
Open

veria-ai[bot] wants to merge 2 commits into
mainfrom
veria/146-duplicate-buzz-surfaces-bypass-relay-spe

Conversation

@veria-ai

@veria-ai veria-ai Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

Security fix: Duplicate Buzz Surfaces Bypass Relay-Specific Egress Controls

What was wrong

packages/core/src/manifest.ts accepted repeated surface kinds in non-private deployments, while packages/core/src/gateway.ts routed replies through a map keyed only by kind. Multiple Buzz connections could therefore share public-channel consent and route a private conversation's reply through another relay and signer.

What changed

  • Added a uniqueness check in packages/core/src/manifest.ts that rejects repeated surface kinds with an error on surfaces.
  • Added the same check at the start of buildAdapters in packages/cli/src/surfaces.ts, before constructing any adapters.
  • Changed the Gateway constructor in packages/core/src/gateway.ts to reject duplicate adapter kinds instead of overwriting an existing registration, before any adapter starts.
  • Added regression tests in the manifest, adapter-construction, and gateway test files covering duplicate kinds, public/private Buzz configurations, and programmatic callers that bypass manifest validation.

Why this is safe

Rejecting duplicate kinds removes the ambiguous connection identity that allowed cross-relay consent reuse and reply routing. Configurations with one surface per kind retain their existing routing and egress behavior; configurations with repeated kinds now fail before adapters start.

Fixes VERIA-146


This PR was generated by Veria AI.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@coderabbitai

coderabbitai Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

Ask an organization administrator to verify that this bot has an active assigned CodeRabbit review seat. See the seat-assignment guide. After the seat is confirmed, request a review again.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@greptile-apps

greptile-apps Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The change reaches setup and routing for every surface kind.

Update the affected CLI tests before merging; keep the new duplicate rejection.

Fix All in Claude CodeFindings

  1. P1 Existing CLI tests now fail ▶

Reviews (1) · Last reviewed commit: "Prevent duplicate Buzz surfaces from byp..." · Reviewed by Greptile

Comment thread packages/core/src/manifest.ts Resolved
The manifest now rejects repeated surface kinds, so the two-Buzz-surface
fixtures in register and run-directory exercise a config that can no
longer load, and rehearse's two-relay case is refused at load with the
manifest's message.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant