TMAegisBeta
openshift için daha fazla kural

Red Hat OpenShift

TMA-OPENSHIFT-4.2.4

Ensure that the --client-ca-file argument is set as appropriate

YüksekDüzey 1Otomatikopenshift

Açıklama

Enable Kubelet authentication using certificates. Reads every node's effective kubelet configuration with oc get --raw /api/v1/nodes/<node>/proxy/configz; requires a cluster-admin oc login. Every node must use /etc/kubernetes/kubelet-ca.crt.

Nasıl denetlenir

Denetim yöntemi: Kabuk komutu

shell
nodes=$(oc get nodes -o jsonpath='{range .items[*]}{.metadata.name}{"\n"}{end}') || exit 1
[ -n "$nodes" ] || exit 1
ok=1
for n in $nodes; do
  c=$(oc get --raw "/api/v1/nodes/$n/proxy/configz") || exit 1
  if ! { printf '%s' "$c" | grep -Eq '"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"'; }; then echo "noncompliant: $n"; ok=0; fi
done
if [ "$ok" -eq 1 ]; then echo compliant; fi
Beklenen çıktı
compliant

Nasıl düzeltilir

Düzeltme yöntemi: Kılavuz veya altyapı yaması

Set -client-ca-file argument to the appropriate location.

Özellikler

İşletim sistemleri
Herhangi biri
Etiketler
openshiftworker-node
Referans
CIS Red Hat OpenShift Container Platform Benchmark v2.0.0 - 4.2.4 Ensure that the --client-ca-file argument is set as appropriate

Bu ana makineyi denetle

Bunu denetleme izniniz olan bir makinede çalıştırın. Tarama salt okunurdur.

shell
tmaegis scan --target openshift