S023: request headers (DNT, Sec-GPC, Save-Data) and third-party cookie blocking in the vendored servo-net

New vendor/servo-net/nacre.rs holds embedder-set state; http_loader and
websocket_loader read it. Settings rows are working switches; privacy mode
turns blocking on. Loopback smoke tests/smoke/privacy-net.txt, unit tests
for site matching. Patch list in DESIGN.md, D-017.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
astar76 2026-11-12 15:34:32 -06:00
commit f5cb6f76f8

View file

@ -4,9 +4,8 @@ Things to check or fix in the review passes before the first build. Remove an it
- discord.rs on Windows: named-pipe reads block (no read timeout on `File`). Read only during the handshake
there, or use a reader thread.
- Servo can't add request headers or strip cookies per request, so "Send Do Not Track & GPC" only sets
`navigator.globalPrivacyControl`/`doNotTrack` in pages, and "Block third-party cookies" is not possible.
Settings must say so (shown as "partial" / "not available with this engine").
- Done in S023: request headers (DNT, Sec-GPC, Save-Data) and third-party cookie blocking are patches in the
vendored servo-net (docs/DESIGN.md "Vendored servo-net patches"); `document.cookie` in cross-site frames is not covered.
- Servo's request interceptor holds a global lock while the embedder answers: `load_web_resource` must answer
synchronously, never keep a `WebResourceLoad` waiting.
- Intercepted responses skip redirect handling, so HTTPS-only and tracking-parameter stripping serve a tiny page