CIS-4.1.8 - Ensure that the client certificate authorities file ownership is set to root:root

Ensure that the client certificate authorities file ownership is set to root:root

Note: to enable this control run Kubescape with host sensor (see here)

Framework

CIS

Severity

High

Description of the the issue

The certificate authorities file controls the authorities used to validate API requests. You should set its file ownership to maintain the integrity of the file. The file should be owned by root:root.

Related resources

What does this control test

Ensure that the certificate authorities file ownership is set to root:root.

How to check it manually

Run the following command:

ps -ef | grep kubelet

Find the file specified by the --client-ca-file argument.

Run the following command:

stat -c %U:%G <filename>

Verify that the ownership is set to root:root.

Remediation

Run the following command to modify the ownership of the --client-ca-file.

chown root:root <filename>

Impact Statement

None

Default Value

By default no --client-ca-file is specified.

Example

No example