SV-235818r627581_rule
V-235818
SRG-APP-000141
DKER-EE-002130
CAT I
10
When using the -v/--volume flags to mount volumes to containers in a docker run command, do not use docker.sock as a volume.
A reference for the docker run command can be found at https://docs.docker.com/engine/reference/run/.
This check should be executed on all nodes in a Docker Enterprise cluster.
via CLI:
As a Docker EE Admin, execute the following command using a UCP client bundle:
docker ps --all | grep -iv "ucp\|kube\|dtr" | awk '{print $1}' | xargs docker inspect --format '{{ .Id }}: Volumes={{ .Mounts }}' | grep -i "docker.sock\|docker_engine"
If the Docker socket is mounted inside containers, this is a finding.
V-235818
False
DKER-EE-002130
This check should be executed on all nodes in a Docker Enterprise cluster.
via CLI:
As a Docker EE Admin, execute the following command using a UCP client bundle:
docker ps --all | grep -iv "ucp\|kube\|dtr" | awk '{print $1}' | xargs docker inspect --format '{{ .Id }}: Volumes={{ .Mounts }}' | grep -i "docker.sock\|docker_engine"
If the Docker socket is mounted inside containers, this is a finding.
M
5281