Repository navigation
Network
A sandbox reaches only what you allow, and every attempt is logged.

| Mode | Behaviour |
|---|---|
whitelist (default) |
Only allowed destinations are reachable. |
blacklist |
Everything public is reachable except denied destinations. |
boxquell mode mybox blacklist
boxquell policy mybox # show the rules of a sandboxPrivate and local addresses (your LAN, the host itself) stay closed in both modes until a rule names them.
boxquell allow mybox example.com # one name
boxquell allow mybox '*.example.com:443' # subdomains, one port
boxquell allow mybox 192.168.1.20:5432 # an address in your network
boxquell deny mybox 10.0.0.0/8 # a whole network
boxquell unrule mybox "allow example.com" # remove a rule| Form | Example |
|---|---|
| Name | example.com |
| Wildcard | *.example.com |
| Name and port | *.example.com:443 |
| IP address | 192.0.2.7 |
| Address and port | 192.168.1.20:5432 |
| Network | 10.0.0.0/8 |
The first matching rule wins, and address rules are checked before name rules.
In whitelist mode a connection must go to an address that an allowed name resolved to, and the name a client presents (TLS SNI, HTTP Host) must match. An allowed address cannot be used to reach a different site. DNS is answered by the daemon: names that are not allowed do not resolve.
Note
Git over SSH needs the port allowed: boxquell allow mybox github.com:22.
boxquell allow mybox registry.npmjs.org --for 2h # 30m, 2h, 1d
boxquell read mybox docs.example.com --for 1d--for ends the rule after that long. The rule form in the app has a choice of duration, and the notifications offer "for 1 hour" next to Allow.
boxquell read mybox docs.example.comA read-only rule lets web requests that fetch through (GET, HEAD and OPTIONS) and refuses those that send or change something (POST and the like).
- It works for websites. For HTTPS, Boxquell looks into the requests and answers with a certificate of the sandbox's own authority. The sandbox trusts it.
- Other kinds of connection to a read-only destination are refused, because they cannot be checked.
boxquell set mybox --upload-limit 200 --download-limit 2000 # MiB per run; 0 for no limitWhen the sandbox has sent or received that much to or from destinations outside, its network is cut off until you let it continue. The interface offers to let it continue. Data limits count what passes to and from destinations outside, not the terminal or the project folder.
boxquell set mybox --download-speed 2000 --upload-speed 500 # kbit per second; 0 for no limitThe limits apply at once, also to open connections. They are also under Network in the app.
The Network tab of a sandbox shows what it sent and received per hour or day, and the destinations that carried most of it.
What installed software and the system's package manager need is open by itself. It is shown under Network, and you can switch each destination off. Before an install, a sheet lists what comes along and which destinations it opens.
Note
If you switch off a destination that installed software needs, that software may stop working. The log shows what was refused (boxquell logs mybox --blocked).
Denies no sandbox can undo, and allows every sandbox gets.
boxquell global allow example.com
boxquell global deny tracker.example
boxquell global unrule "deny example.com"
boxquell global lsboxquell lockdown on # every sandbox loses the network at once; open connections stop carrying data
boxquell lockdown off
boxquell lockdown # show the stateThe web UI has the same switch in its sidebar, and the tray icon has an emergency stop. A lockdown survives a restart of the daemon.
boxquell logs mybox # last 50 entries
boxquell logs mybox -f --blocked # follow, blocked attempts only
boxquell logs -n 200 # all sandboxes, 200 linesEach DNS lookup and connection attempt is recorded with destination, verdict, rule, bytes and duration. A connection attempt cannot be hidden from the log.

Allowed connections in the log have a Block button, to block that destination from there.
When a connection is blocked you get a desktop notification and a message in the UI with a button to allow the destination. Each destination is announced at most once a minute; every attempt is in the log either way. The Notifications page lists blocked connections to allow, ignore or dismiss.

Switch the two messages off:
boxquell config notify-blocked off
boxquell config toast-blocked offBoxquell also warns when an installed agent has no credential.
The guest is IPv4-only, and UDP other than DNS is refused, so there is no QUIC; clients fall back to TCP. A gateway on your own computer (localhost) is reachable from the sandbox as 10.0.2.2.
Next: Usage and Costs | Secrets | Security Model | Command Reference
Boxquell is licensed under Apache-2.0 or MIT, at your option. | Repository | Releases | Changelog | Report a vulnerability