Skip to content

security(api): a duplicate voice-realtime route hides an undecided auth question, in a closed issue #17851

Open

Description

@mrveiss

A security decision was escalated correctly, and the escalation was closed

POST /api/voice/realtime/tools/call is registered twice:

registration role declared auth
api.voice:realtime_router core, wins Depends(get_current_user) and an is_admin_role check (#12717)
api.realtime_session:router feature, dead none declared

They are different implementations, not a copy. The dead one passes a session_id through realtime_mcp_bridge for which the winner has no equivalent.

So neither obvious resolution is safe. Deleting the dead handler drops a capability that nothing else provides. Re-pathing it makes a handler with no declared auth reachable.

Why this is being filed rather than fixed

repo_tests/no_duplicate_route_registration_16908_test.py:120-133 records all of the above at the call site and ends:

Asked on the issue rather than decided here.

That was the right call. The author refused to decide a security question inside a route-cleanup change, wrote the full reasoning where the next reader would meet it, and escalated.

#16908 was then closed, with the entry still live in KNOWN_DUPLICATES at :135-137. Its other three criteria are genuinely delivered — the re-pathing at knowledge_ai_stack.py:84 and :271, the guard with a reach floor and an unresolved-sources refusal at :142-146, and the mutation-proved header at :226. Only the resolution criterion is outstanding, and it is outstanding by design.

The closure did not undo the work. It undid the escalation. A live authorization decision now sits in a baseline inside a closed issue, which is the one place nobody looks for one.

Found by the v0.9.0 closure-evidence sweep (#17361), on the first substantive issue of a randomly drawn sample. Eleven issues verified before it by convenience sampling were all cleanly delivered, which is exactly why the random draw mattered.

The decision needed

Someone with authority over the voice/realtime surface must choose:

  1. Delete api.realtime_session:router's handler and accept losing the session_id path through realtime_mcp_bridge, or re-provide it on the winner.
  2. Re-path it and give it declared auth first. It must not become reachable without one.
  3. Keep the collision and record why the shadowed handler is acceptable indefinitely.

Acceptance criteria

  • One of the three above is chosen and recorded on this issue with its reasoning.
  • If 1 or 2: the KNOWN_DUPLICATES entry is removed, and test_the_baseline_only_lists_duplicates_that_still_exist confirms it rather than a person asserting it.
  • If 2: a test proves the re-pathed handler rejects an unauthenticated caller, and a contrast case proves it accepts an authorised one.
  • If 3: the KNOWN_DUPLICATES comment states the decision and this issue number, so the next reader meets a decision rather than an open question.
  • api.realtime_session:router's session_id/realtime_mcp_bridge path is either preserved or explicitly dropped with a reason. It is not lost as a side effect.

Refs #16908, #12717, #17361

Activity

  1. added this to the M7 - Voice milestone on Oct 31, 2026
  2. removed this from the M7 - Voice milestone on Nov 3, 2026
  3. added and removed on Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions