5.2.11 Minimize the admission of Windows HostProcess Containers

Information

Do not generally permit Windows containers to be run with the hostProcess flag set to true.

A Windows container making use of the hostProcess flag can interact with the underlying Windows cluster node. As per the Kubernetes documentation, this provides "privileged access" to the Windows node.

Where Windows containers are used inside a Kubernetes cluster, there should be at least one admission control policy which does not permit hostProcess Windows containers.

If you need to run Windows containers which require hostProcess this should be defined in a separate policy and you should carefully check to ensure that only limited service accounts and users are given permission to use that policy.

NOTE: Nessus has not performed this check. Please review the benchmark to ensure target compliance.

Solution

Add policies to each namespace in the cluster which has user workloads to restrict the admission of hostProcess containers.

Impact:

Pods defined with securityContext.windowsOptions.hostProcess: true will not be permitted unless they are run under a specific policy.

See Also

https://workbench.cisecurity.org/benchmarks/17568

Item Details

Category: CONFIGURATION MANAGEMENT

References: 800-53|CM-6

Plugin: Unix

Control ID: 7e4a93e6ef0e53a374610137247a3f328f6c070c3c0a77c796e03cc52f90c4de