[SECURITY] netcat (nc) available in sandbox image #808
Copy link
Copy link
Closed
Description
Summary
The base sandbox image includes nc (netcat), a standard tool for reverse shells, port scanning, and data exfiltration. While the OpenShell proxy blocks outbound connections to unauthorised hosts, netcat shouldn't be in the image at all.
Reproduction
$ which nc
/usr/bin/nc
Impact
If a proxy bypass is ever found, netcat is the first tool an attacker (or prompt-injected agent) would reach for. It enables:
- Reverse shell connections
- Port scanning of internal networks
- Raw TCP data exfiltration
The proxy currently blocks these, but defence-in-depth means removing the tool regardless.
Recommendation
Remove netcat-openbsd and netcat-traditional from the sandbox image. Also audit for other unnecessary network tools (nmap, socat, telnet, etc.).
Environment
- openshell 0.0.14
- Base sandbox image:
ghcr.io/nvidia/openshell-community/sandboxes/base:latest
Metadata
Metadata
Assignees
Labels
No labels
Activity
fix: remove gcc and netcat from sandbox image (NVIDIA#807, NVIDIA#808)
cluster2600 commentedon Mar 24, 2026
Related: #796 proposes a command pattern denylist that would provide application-level coverage for this class of issue. Worth addressing together — the image hardening here is the defence-in-depth layer (remove the tool entirely), whilst #796 catches the patterns even if the tool is present via a different path.
fix: harden sandbox image — remove unnecessary tools, drop capabiliti…
BenediktSchackenberg commentedon Mar 24, 2026
Addressed in #830 — netcat variants are now explicitly purged from the runtime image.
fix: remove gcc and netcat from sandbox image (NVIDIA#807, NVIDIA#808)
fix: harden sandbox image — remove unnecessary tools, drop capabiliti…
fix: harden sandbox image — remove unnecessary tools, drop capabiliti…
fix: harden sandbox image — remove gcc/netcat, add process limits, dr…
BenediktSchackenberg commentedon Mar 26, 2026
Fixed via #830 (merged). The sandbox image no longer includes gcc, g++, make, or netcat — removed from the runtime stage.
fix: remove gcc and netcat from sandbox image (NVIDIA#807, NVIDIA#808)
fix: harden sandbox image — remove gcc/netcat, add process limits, dr…
fix: remove gcc and netcat from sandbox image (NVIDIA#807, NVIDIA#808)