Expand description
Local HTTP CONNECT / SOCKS5 proxy used to enforce hostname allowlists.
The OS sandbox cannot inspect connect() destinations (seccomp BPF sees a
pointer, not the sockaddr contents), so exact domain rules are enforced by
a loopback proxy: the sandbox permits connections only to the proxy, and
the proxy resolves DNS after deciding that a hostname is allowed.
Deny rules take precedence over allow rules; anything unmatched is denied.
Structs§
- Domain
Policy - Ordered domain rules; deny wins, then allow, then default deny.
- Domain
Rule - One hostname rule. Domains are case-insensitive;
*.example.comalso matches the bareexample.com, matching the existing allowlist semantics. - Network
Proxy - Running proxy. Dropping it stops both accept loops.
- Proxy
Endpoints - Loopback addresses the sandbox must allow outbound to.
Enums§
- Domain
Rule Action - Effect of a domain rule.
- Proxy
Decision - Decision for a proxy request. Unknown destinations are denied.
Functions§
- proxy_
enforcement_ available - Whether this platform can restrict a child to the proxy exactly.
- start_
proxy - Start HTTP and SOCKS5 listeners on ephemeral loopback ports.