Skip to content

Commit c70b74a

Browse files
docs: update docs
1 parent 513d39c commit c70b74a

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

README.md

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ boundary-run -- bash
6868
If you prefer to run `boundary` directly, you'll need to handle privilege escalation:
6969
7070
```bash
71+
# Note: sys_admin is only needed in restricted environments (e.g., Docker with seccomp).
72+
# If boundary works without it on your system, you can remove +sys_admin from both flags.
7173
sudo -E env PATH=$PATH setpriv \
7274
--reuid=$(id -u) \
7375
--regid=$(id -g) \
7476
--clear-groups \
75-
# Note: sys_admin is only needed in restricted environments (e.g., Docker with seccomp).
76-
# If boundary works without it on your system, you can remove +sys_admin from both flags.
7777
--inh-caps=+net_admin,+sys_admin \
7878
--ambient-caps=+net_admin,+sys_admin \
7979
boundary --allow "domain=github.com" -- curl https://github.com
@@ -136,6 +136,18 @@ boundary-run --log-level debug --allow "domain=github.com" -- git pull # Debug
136136
| macOS | Not supported | - |
137137
| Windows | Not supported | - |
138138
139+
## Security and Privileges
140+
141+
**All processes are expected to run as non-root users** for security best practices:
142+
143+
- **boundary-parent**: The main boundary process that sets up network isolation
144+
- **boundary-child**: The child process created within the network namespace
145+
- **target/agent process**: The command you're running (e.g., `curl`, `npm`, `bash`)
146+
147+
The `boundary-run` wrapper script handles privilege escalation automatically using `setpriv` to drop privileges before launching boundary. This ensures all processes run with the minimum required capabilities (`CAP_NET_ADMIN` and optionally `CAP_SYS_ADMIN` for restricted environments) while executing as your regular user account.
148+
149+
If you run `boundary` directly with `sudo` (without `setpriv`), all processes will run as root, which is **not recommended** for security reasons. Always use `boundary-run` or the equivalent `setpriv` command shown in the [Direct Usage](#direct-usage) section.
150+
139151
## Command-Line Options
140152
141153
```text

0 commit comments

Comments
 (0)