Repository navigation
docs: add NET-009 for Tailscale route capture of isolation-mode egress - #11815
Conversation
Co-authored-by: Copilot <[email protected]>
|
@copilot merge main and resolve conflicts |
…9-tailscale-route-capture-3c88fb602c84a777 Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Merged |
Merged |
Documentation PreviewDocumentation has been built for this PR. To view locally:
Built from commit 7d942d9 |
There was a problem hiding this comment.
🟡 Changes recommended
Both generated diagnosis catalogs still omit NET-009, causing the read-only freshness check to fail until a trusted reviewer regenerates and commits them.
3 open issues
The trusted refresh still needs to be included before merge: both.github/agents/diagnose-awf.md… · New This probe cannot reliably confirm or exclude route capture: it omits the main table, and policy… · Newtailscale up --resetresets unrelated preferences, including disabling an existing--shields-up… · New
What changed in this PR
Adds NET-009 to AWF’s diagnostic registry for suspected Tailscale route capture affecting network-isolation egress, distinguishing it from allowlist denials and subnet collisions.
Changes:
- Documents symptoms, a routing probe, workaround guidance, and supporting references.
- Adds NET-009 to the generated finding index and symptom lookup table.
- Leaves runtime code unchanged.
| File | Description |
|---|---|
docs/diagnostics/README.md |
Adds NET-009 to the finding and symptom indexes. |
docs/diagnostics/findings/network/NET-009.json |
Defines the routing diagnosis, evidence limits, probe, and workaround. |
Review effort: Balanced (adaptive)
| | NET-006 | network | awf-net subnet collides with host or cluster DNS resolver or routes | workaround | [`findings/network/NET-006.json`](./findings/network/NET-006.json) | | ||
| | NET-007 | network | Compose refuses to start because a leftover awf-net belongs to another project | fixed | [`findings/network/NET-007.json`](./findings/network/NET-007.json) | | ||
| | NET-008 | network | Denied hostname lookups reach the resolver because a Squid IP exception resolves names | fixed | [`findings/network/NET-008.json`](./findings/network/NET-008.json) | | ||
| | NET-009 | network | Network-isolation egress fails with HIER_NONE after the host accepts overlapping Tailscale routes | workaround | [`findings/network/NET-009.json`](./findings/network/NET-009.json) | |
| "command": "ip rule show; ip route show table 52", | ||
| "expect": "A policy rule whose lookup is table 52 that precedes the main table, with routes that overlap the runner's default gateway subnet, indicates this cause. An absent table 52 or non-overlapping routes rules it out and points to NET-002 or NET-006. Both reads expose host routing only and no credentials, and no traffic is sent.", |
| "readOnly": true, | ||
| "secretSafe": true | ||
| }, | ||
| "action": "Before the AWF step, reconfigure Tailscale so it does not accept advertised subnet routes (for example tailscale up --reset --accept-routes=false) and do not configure an exit node; direct tailnet peer connectivity for private MCP servers was reported to keep working. If subnet routes are required, make sure none overlaps the runner gateway path or covers the default route, or use Tailscale userspace networking for private endpoints only. Keep the domain allowlist and DNS filtering unchanged, do not switch to a wildcard allowlist, and do not run AWF with extra host network capabilities to rewrite host routes. Report persistent HIER_NONE with redacted routing output instead of widening egress.", |
|
@copilot address review feedback |
Addressed the routing probe and Tailscale workaround in |
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
|
✅ Copilot review passed with no inline comments. @github-actions[bot] Add the |
|
@copilot merge main and resolve conflicts |
…9-tailscale-route-capture-3c88fb602c84a777 Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Merged |
|
@merge main and resolve conflicts |
Co-authored-by: Copilot App <[email protected]>
| - **Discriminating conditions:** AWF runs with network isolation, so Squid egresses through the dual-homed awf-ext bridge and the host routing tables · A Tailscale step runs on the runner and accepts advertised subnet routes (--accept-routes), which add policy routes in table 52 consulted before the main table · An accepted subnet may capture Squid's traffic to a resolver or API destination via the tailnet interface · A policy denial (TCP_DENIED / 403) or an awf-net subnet collision (NET-006) is a different cause and does not match · The route-capture mechanism comes from one reporter's analysis; only the routing-acceptance change below was validated | ||
| - **Root cause:** In network-isolation mode AWF delegates egress to the host network stack and does not install or pin host policy routes. A Tailscale step that accepts advertised subnet routes inserts policy-routing entries ahead of the main table; the reporter suspected an accepted subnet captured Squid's outbound connections or name lookups into the tailnet interface. The earlier theory that a non-portable resolver such as 168.63.129.16 was the sole cause was not sufficient: the resolver-filtering change was merged and later reverted, and the failure persisted until route acceptance was disabled. The mechanism rests on one reporter's investigation. | ||
| - **Safe probe:** `ip rule show; ip route show table main; ip route show table 52` → Compare the policy rules and table 52 with the main routes; this is preliminary evidence, not proof that Squid's traffic is captured or unaffected. For each affected resolver and API destination IP, perform a host-side `ip route get <destination-ip> from <squid-awf-ext-ip> iif <awf-ext-host-bridge>` lookup using Squid's actual source address and ingress bridge; include any applicable policy marks. A tailnet interface in the result supports route capture, but packet marks, NAT and firewall rules can affect the actual path. No matching route or an absent table 52 alone does not rule out routing or other causes such as NET-002 and NET-006. These lookups send no traffic; redact routing details before sharing. | ||
| - **Action:** Before the AWF step, if policy permits, disable acceptance of advertised subnet routes with `tailscale set --accept-routes=false`, preserving other Tailscale preferences. Direct tailnet peer connectivity for private MCP servers was reported to keep working. Deployments requiring subnet routes or exit-node egress must use a policy-approved alternative; consult the network administrator about routes covering affected resolver and API destinations or an approved isolated runner. Do not reset unrelated Tailscale settings or bypass a required exit node. Keep the domain allowlist and DNS filtering unchanged, do not switch to a wildcard allowlist, and do not run AWF with extra host network capabilities to rewrite host routes. Report persistent HIER_NONE with redacted routing output instead of widening egress. |


Caution
Protected files were modified in this change.
This pull request is in
request-reviewmode and requires explicit human scrutiny before merge.Protected files:
README.mdAllow intentional protected-file changes
If this workflow is intended to modify these files, add specific filenames or folder prefixes to
safe-outputs.create-pull-request.protected-files.excludein the workflow Markdown frontmatter. For example, to allow.changeset/*, exclude the folder using.changeset/:Keep your existing policy and exclusions. Folder exclusions use path prefixes, not glob patterns, and allow all files beneath that folder, including subfolders. Other protected files still require review. If
allowed-filesis configured, these paths must also match it. Rungh aw compileafter updating the workflow.Coverage
since2026-11-12;updatedSince/since2026-11-19T05:17Z;historyBefore2026-11-05T05:17Z;historyFloor2025-10-16.reviewQueue.firstTime(PRs [mount-docs] Clarify Cloud Hypervisor export set in mount-policy.md #11125–chore: refresh canonical model sources #11306, merged 2026-11-05 to 2026-11-08). Deferred queue is 0. 154 candidates remain in the backlog and are not yet reviewed.no-impactfor the network boundary (enclave/runtime, AI-credit accounting, CI and docs-maintenance work). Receipts were written to/tmp/gh-aw/cache-memory/diagnosis/receipts.json.npm run diagnostics:freshness: no overdue records.Finding added: NET-009
workaround. Version scope: introducedunknown, fixedunknown.CONNECTto an allowlisted API host returns503 TCP_TUNNEL:HIER_NONE(server field-:-). The same workflow works in host-access mode, or in isolation mode without Tailscale.TCP_DENIED/ 403 denial and anawf-netsubnet collision (NET-006) are different causes. This record covers the case where host policy routing captures Squid's own egress.ip rule show; ip route show table 52.tailscale up --reset --accept-routes=false) and use no exit node, before the AWF step. Otherwise keep accepted subnets from overlapping the gateway path. Keep the allowlist and DNS filtering unchanged, and do not widen egress.Current-main evidence
src/compose-network.tsbuildComposeNetworks(): isolation mode makes Squid dual-homed onawf-ext, so egress depends on host routing.src/dns-resolver.tsfilterForNetworkIsolation()preserves detected resolvers, andsrc/dns-resolver.test.tsasserts that Tailscale Magic DNS is kept.Validation
npm run diagnostics:validatereports "Registry valid: 36 finding(s)".npm run diagnostics:renderwas run, and only thedocs/diagnostics/README.mdindex change is included..github/agents/diagnose-awf.mdand.github/workflows/shared/diagnosis-findings.mdchanges were deliberately left out of this PR for trusted CI or reviewer refresh.