Docker
TMA-DOCKER-NO-PRIVILEGED
Ensure no running container is privileged
Nghiêm trọngCấp 1Tự độngdocker
Mô tả
Privileged containers have nearly full host access.
Cách kiểm tra
Phương pháp kiểm tra: Lệnh shell
shell
ids=$(docker ps -q) || exit 1; [ -z "$ids" ] && { echo 0; exit 0; }; out=$(docker inspect --format '{{.HostConfig.Privileged}}' $ids) || exit 1; printf '%s\n' "$out" | grep -c true || true- Đầu ra mong đợi
0
Cách khắc phục
Phương pháp khắc phục: Hướng dẫn hoặc bản vá hạ tầng
Remove 'privileged: true' from the container/compose/Kubernetes spec and redeploy
Thuộc tính
- Hệ điều hành
- Bất kỳ
- Thẻ
- dockercontainers
- Tham chiếu
- CIS Docker Benchmark - Container runtime
Kiểm tra máy này
Chạy lệnh này trên máy bạn được phép kiểm tra. Lần quét chỉ ở chế độ đọc.
shell
tmaegis scan --target docker