[Security Review] Daily Security Review – 2026-06-20 #5320
Closed
Replies: 2 comments
-
|
🔮 The ancient spirits stir, and the smoke test agent has passed through this discussion. The omens are favorable, and the build should now be judged by the forge. Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "registry.npmjs.org"See Network Configuration for more information.
|
Beta Was this translation helpful? Give feedback.
0 replies
-
|
This discussion was automatically closed because it expired on 2026-06-27T12:59:08.329Z.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
📊 Executive Summary
Deep evidence-based static security review of
gh-aw-firewallat commit6707484. The firewall implements strong multi-layer controls. Overall posture: GOOD — no critical findings.🔍 Firewall Escape Test Context
Pre-fetched context (
/tmp/gh-aw/escape-test-summary.txt) contained GitHub Actions runner metadata from theSecret Diggerworkflow run24273493151(2026-04-11) — not a structured escape-test report. Key signals from that record:GH_AW_SECRET_VERIFICATION_RESULT: success— credential isolation validatedGH_AW_LOCKDOWN_CHECK_FAILED: false— lockdown protections heldnoopoutputs — no successful breachThis review fills the static-analysis gap.
🛡️ Architecture Security Analysis
Network Security
Strengths (
setup-iptables.sh,host-iptables-rules.ts):sysctl net.ipv6.conf.all.disable_ipv6=1— prevents Happy Eyeballs bypass172.30.0.10:3128; explicitCONNECTfor proxy-aware toolsacl dst_ipv4 dstdom_regex+acl dst_ipv6forwarded_for delete+via offprevent container IP leakage127.0.0.11(Docker embedded); iptables DROP blocks non-configured upstreamsWeakness:
http_proxy(lowercase) intentionally absent. HTTP traffic relies solely on iptables DNAT — if the init container NAT rule fails before commit, HTTP egresses unfiltered (very unlikely but not impossible).Container Security
Strengths (
agent-service.ts,entrypoint.sh, seccomp-profile.json):NET_ADMINnever granted to agent; iptables setup isolated toawf-iptables-initsidecarSYS_CHROOT + SYS_ADMINdropped viacapsh --drop=...before user code runs (entrypoint.sh:run_chroot_command)cap_drop: [NET_RAW, SYS_PTRACE, SYS_MODULE, SYS_RAWIO, MKNOD]no-new-privileges:truesecurity_opt/host/procwithhidepid=2— prevents reading other process/proc/[pid]/environtmpfsoverlays overworkDirand MCP log dirs prevent agent readingdocker-compose.yml(plaintext secrets)environmem_limit: 6g,pids_limit: 1000; UID/GID 0 rejectedWeakness:
apparmor:unconfined(agent-service.ts:110) — required to allowmount -t procduring startup. AppArmor provides no protection during the startup window beforecapshdropsSYS_ADMIN.Domain Validation
Strengths (
src/domain-validation.ts,src/squid/domain-acl.ts):SQUID_DANGEROUS_CHARS = /[\s\0"';#]/` applied at both parse time and interpolation timeDOMAIN_DANGEROUS_CHARSadditionally blocks backslash*,*.*) explicitly rejectedassertSafeForSquidConfig()called at every interpolation point — defense-in-depthNo weaknesses identified here.
Input Validation
Strengths:
execaused with array args throughout — no shell injection.AWF_PREFLIGHT_BINARYvalidated with^[a-zA-Z0-9_][a-zA-Z0-9_.-]*$. IPv4 validated with full octet regex. Port ranges reject leading zeros.Weakness (
compose-sanitizer.ts:4):Env vars named
PASSWORD,AUTH,CRED,CERT,PWare NOT redacted in diagnostic dumps.agent-service.ts:94,entrypoint.sh:run_chroot_commandcompose-sanitizer.ts:4--enable-host-accessDNAT bypass skips Squid domain ACL for host traffic on 80/443setup-iptables.sh:~185setup-iptables.sh:~280policy-manifest.ts,setup-iptables.sh:228setup-iptables.sh:296AWF_HOST_SERVICE_PORTSbypasses DANGEROUS_PORTS for host gatewaysetup-iptables.sh:200--upstream-proxy) routes all traffic through attacker-controlled proxy if misconfiguredsrc/squid/upstream-proxy.ts🎯 Attack Surface Map
--allow-domains--enable-host-access✅ Recommendations
🟠 High
H1 — Narrow the AppArmor-unconfined + SYS_ADMIN window
Write a minimal AppArmor profile permitting only
mountto/host/proc, or dropSYS_ADMINimmediately after the procfs mount insideentrypoint.shrather than waiting for the user-codecapshinvocation. This collapses the window where bothSYS_ADMINandapparmor:unconfinedare simultaneously active.🟡 Medium
M1 — Broaden compose sanitizer pattern (
compose-sanitizer.ts:4):M2 — Log
--enable-host-accessdomain-bypass prominently at WARN level at container startup and document the trade-off in CLI help text. Operators may not realize domain filtering is bypassed for localhost traffic.M3 — HTTP_PROXY defense-in-depth: Consider setting
http_proxyfor non-curl tools while using a curl wrapper or test-flag workaround to avoid the httpoxy/exit-code side effect.🔵 Low
L1 — Auto-generate the shell dangerous-ports array from the TypeScript constant, or add a CI test asserting parity.
L2 — Raise iptables LOG rates to
60/min --limit-burst 100for better burst forensics.L3 — Add troubleshooting note explaining TLS error (proxy-unaware) vs TCP_DENIED (proxy-aware) blocked HTTPS.
L4 — Surface
AWF_HOST_SERVICE_PORTSdangerous-port bypass at WARN log level.📈 Security Metrics
unconfined(startup window only; SYS_ADMIN dropped before user code)Static analysis only — no dynamic escape testing performed in this run.
Beta Was this translation helpful? Give feedback.
All reactions