Skip to content

fix(security): block WebRTC around the browser egress proxy, survive an invalid status page ?lang= - #957

Merged
fclairamb merged 11 commits into
mainfrom
security/scan-specs-2026-11-20
Nov 21, 2026
Merged

fclairamb merged 11 commits into
mainfrom
security/scan-specs-2026-11-20

Conversation

@fclairamb

@fclairamb fclairamb commented Nov 20, 2026 •

Copy link
Copy Markdown
Owner

Fixes for the two low findings of the daily security scan of 2026-11-20. No High or Critical finding.

What changed

  • AS1, WebRTC around the browser egress proxy (specs/done/2026/11/2026-11-20-01-browser-egress-webrtc.md): under an enforcing egress policy, the Chrome SolidPing starts gets --webrtc-ip-handling-policy and --force-webrtc-ip-handling-policy=disable_non_proxied_udp (desktop Chrome and headless-shell each read one spelling), and every session (remote CDP included) removes RTCPeerConnection, webkitRTCPeerConnection and RTCDataChannel on each new document. A failed install fails the session open with an infra error. Live test with a private STUN listener (0 packets under enforcing, positive control without). The sidecar launches (docker-compose.yml, install docs) carry the flag, and the egress-policy doc gets a "WebRTC is off" layer.
  • AS2, invalid ?lang= blanks the status page (specs/done/2026/11/2026-11-20-02-status0-invalid-lang-crash.md): status0 limits languages to en/fr/de/es, every Intl/toLocale* call goes through a displayLocale() helper that falls back to en, and a top-level error boundary shows a reload message instead of a blank page. Unit tests for the helper, E2E for ?lang=123, en_, a-b-c and the ?lang=fr control.

Behaviour changes

  • Check scripts in browser / JS-browser checks and browser MCP probes no longer see WebRTC under an enforcing egress policy.
  • ?lang= values outside en/fr/de/es fall back to English; fr-CA resolves to fr.

Operator action

An existing remote headless-shell sidecar should add --force-webrtc-ip-handling-policy=disable_non_proxied_udp (a desktop-Chrome image: --webrtc-ip-handling-policy=disable_non_proxied_udp). The new-document script protects remote sessions without it, but the flag also blocks UDP at the network level.

Decided by autopilot

  • No open question in either spec; implemented as specified.

🤖 Generated with Claude Code

fclairamb and others added 7 commits November 20, 2026 07:36
An enforcing browser session could send WebRTC (ICE/STUN over UDP) to any
internal IP literal, around the guarded egress proxy. The Chrome SolidPing
starts now runs with a WebRTC IP handling policy forbidding non-proxied UDP
(both spellings: desktop Chrome reads --webrtc-ip-handling-policy,
headless-shell only --force-webrtc-ip-handling-policy), and every enforcing
session, remote CDP included, removes RTCPeerConnection, webkitRTCPeerConnection
and RTCDataChannel from every frame through a new-document script.

Spec: specs/todos/2026-11-20-01-browser-egress-webrtc.md

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Operator action: add --force-webrtc-ip-handling-policy=disable_non_proxied_udp
(headless-shell) to an existing browser sidecar.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…bRTC traffic to internal addresses, around the egress proxy

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…RTC traffic to internal addresses, around the egress proxy
i18next kept any ?lang= value it could not match as i18n.language, and that
raw value reached Intl / toLocaleString during render, which throws a
RangeError and unmounted the whole page (no error boundary).

- i18n: supportedLngs (en, fr, de, es) with nonExplicitSupportedLngs, so
  fr-CA resolves to fr and anything else falls back to en.
- lib/display-locale: one helper that returns a tag Intl accepts; every
  Intl / toLocale* call site uses it instead of i18n.language.
- AppErrorBoundary wraps the app and shows a reload message instead of a
  blank page if a render error still happens.

Co-Authored-By: Claude Haiku 5.5 <[email protected]>
…nguage tag blanks the public status page

Gate: make build-status0 + copy-status0; in web/status0: bun run lint,
typecheck:e2e, bun test src (177 pass), tsc -b; the new
e2e/invalid-lang-param.spec.ts run alone against a SP_RUNMODE=test side-car
(4/4 pass).

Co-Authored-By: Claude Haiku 5.5 <[email protected]>
@codecov

codecov Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 92.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 90.85%. Comparing base (a20f951) to head (2e34d7d).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
server/internal/checkers/checkbrowser/checker.go 91.66% 1 Missing ⚠️
server/internal/checkers/checkbrowser/session.go 92.30% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #957      +/-   ##
==========================================
- Coverage   90.86%   90.85%   -0.01%     
==========================================
  Files        1399     1399              
  Lines      144643   144656      +13     
==========================================
+ Hits       131425   131427       +2     
- Misses      13210    13221      +11     
  Partials        8        8              
Files with missing lines Coverage Δ
...rver/internal/checkers/checkbrowser/egressproxy.go 86.72% <ø> (+1.76%) ⬆️
server/internal/checkers/checkbrowser/checker.go 68.50% <91.66%> (+3.70%) ⬆️
server/internal/checkers/checkbrowser/session.go 77.00% <92.30%> (+4.55%) ⬆️

... and 21 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@fclairamb fclairamb added implemented Every spec of the PR is implemented and its batch gate was green automerge labels Nov 20, 2026
@fclairamb
fclairamb enabled auto-merge (squash) November 21, 2026 07:59
@fclairamb
fclairamb merged commit 79bdc82 into main Nov 21, 2026
36 checks passed
@fclairamb
fclairamb deleted the security/scan-specs-2026-11-20 branch November 21, 2026 08:36
fclairamb added a commit that referenced this pull request Nov 22, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.53.0](v0.52.0...v0.53.0)
(2026-11-22)


### Features

* **auth:** OIDC-only mode with IdP group admin roles
([#966](#966))
([1b51f89](1b51f89))
* **service:** install writes config.env, unit loads it via
EnvironmentFile
([#948](#948))
([e4b7fc4](e4b7fc4))


### Bug Fixes

* **aggregation:** drain the raw backlog in one run and log lag
([#978](#978))
([26b93cd](26b93cd))
* **deps:** update github.com/dop251/goja digest to 79d6ad3
([#972](#972))
([02c6821](02c6821))
* **deps:** update go dependencies (non-major)
([#955](#955))
([7dfbcd6](7dfbcd6))
* **deps:** update go dependencies (non-major)
([#968](#968))
([6c09bae](6c09bae))
* **deps:** update go dependencies (non-major)
([#979](#979))
([ee088b6](ee088b6))
* **deps:** update module github.com/oapi-codegen/oapi-codegen/v2 to
v2.9.0 ([#975](#975))
([1121e2e](1121e2e))
* **deps:** update module go.mongodb.org/mongo-driver/v2 to v2.10.1
([#950](#950))
([9e684c4](9e684c4))
* email validation, OAuth error display, translator crash guard, clone
slugs, watchdog pauses
([#959](#959))
([a20f951](a20f951))
* log OAuth code-exchange failures, show a refused sign-in on the
invitation page
([#974](#974))
([c4a8dca](c4a8dca))
* retry SMTP 4xx, 503 on agent auth DB errors, scope checkGroupUid to
the org ([#973](#973))
([88179aa](88179aa))
* **security:** block WebRTC around the browser egress proxy, survive an
invalid status page ?lang=
([#957](#957))
([79bdc82](79bdc82))
* **security:** keep OIDC-group admin grants revocable, mask resolved
channel references, contain browser popups
([#976](#976))
([6e0f09e](6e0f09e))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automerge autopilot implemented Every spec of the PR is implemented and its batch gate was green

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant