Impact & Risk Analysis
- Severity: Medium
- CIS Benchmark: CIS 5.4
- Impact: Network Spoofing & Privilege Escalation. By default, Docker containers retain capabilities like
NET_RAW, which allows an attacker to create spoofed network traffic. If a container is compromised, having unnecessary kernel capabilities (likeSYS_CHROOTorDAC_OVERRIDE) allows the attacker to bypass file permissions or escape the container isolation.
Common Misconfiguration
Running containers with the default Docker capability set, or worse, using--cap-add=ALL. The default set includes capabilities like NET_RAW which are often not required for standard web applications but pose a security risk.
Vulnerable Example
Secure Example
Audit Procedure
Run the following command to inspect the capabilities of running containers:- Result: Review the output for each container.
- Fail: If
NET_RAWis not inCapDrop(unless explicitly required), or ifCapAddcontains unnecessary privileges. - Pass: If the container uses
CapDrop=ALLor explicitly dropsNET_RAWand other unused capabilities.
Remediation
You should restrict the capabilities to the minimum required for the container to function. To remove unneeded capabilities (specificallyNET_RAW):

