TMA-OPENSHIFT-4.2.3
Ensure that the --authorization-mode argument is not set to AlwaysAllow
심각레벨 1자동openshift
설명
Do not allow all requests. Enable explicit authorization. Reads every node's effective kubelet configuration with oc get --raw /api/v1/nodes/<node>/proxy/configz; requires a cluster-admin oc login.
점검 방법
감사 방식: 셸 명령
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 '"authorization":\{"mode":"AlwaysAllow"' && printf '%s' "$c" | grep -Eq '"authorization":\{"mode":"'; }; then echo "noncompliant: $n"; ok=0; fi
done
if [ "$ok" -eq 1 ]; then echo compliant; fi- 예상 출력
compliant
조치 방법
조치 방식: 가이드 또는 인프라 패치
Set authorization.mode to 'Webhook'
속성
- 운영 체제
- 모두
- 태그
- openshiftworker-node
- 참고 자료
- CIS Red Hat OpenShift Container Platform Benchmark v2.0.0 - 4.2.3 Ensure that the --authorization-mode argument is not set to AlwaysAllow
이 호스트 점검하기
감사 권한이 있는 시스템에서 실행하세요. 스캔은 읽기 전용입니다.
shell
tmaegis scan --target openshift