TMAegis
aks-automatic のその他のルール

TMA-AKS-AUTOMATIC-5.4.2

Use private AKS clusters and disable the public API server FQDN

高レベル 2自動aks-automatic

説明

Provisioning AKS in private cluster mode limits control plane exposure by placing the Kubernetes API server on private addressing and requiring connectivity through approved private network paths rather than broad public network access. AKS Automatic preconfigures API Server VNet Integration, which places the API server behind an internal load balancer address in a delegated subnet. Requires the az CLI (logged in) with read access to the cluster named by AKS_RG and AKS_NAME. Requires enablePrivateCluster true and enablePublicFqdn false.

チェック方法

監査方法: シェルコマンド

shell
out=$(az aks show --resource-group "${AKS_RG:?set AKS_RG}" --name "${AKS_NAME:?set AKS_NAME}" --query '[apiServerAccessProfile.enablePrivateCluster, apiServerAccessProfile.enablePublicFqdn]' -o tsv) || exit 1
set -- $(printf '%s\n' "$out" | tr 'A-Z' 'a-z')
if [ "${1:-}" = true ] && [ "${2:-}" = false ]; then echo compliant; else echo "noncompliant: enablePrivateCluster=${1:-} enablePublicFqdn=${2:-}"; fi
期待される出力
compliant

修正方法

修正方法: ガイダンスまたは IaC パッチ

Use the apiServerAccessProfile results to determine whether the cluster must be moved to private cluster mode and whether the public FQDN must be disabled. Remediation should bring the cluster to enablePrivateCluster: true and, where required by policy, enablePublicFqdn: false; the detailed action depends on whether the cluster is new or existing. API Server VNet Integration is already preconfigured for AKS Automatic. 1. If enablePrivateCluster is false on a new deployment, create the cluster as private by using az aks create --sku automatic --enable-private-cluster --disable-public-fqdn when the requirement is to prevent publication of a public DNS name for the API server. 2. If enablePrivateCluster is false on an existing AKS Automatic cluster, enable private cluster mode through the supported AKS update path. A separate API Server VNet Integration conversion is not required. 3.

プロパティ

オペレーティングシステム
すべて
タグ
aks-automaticmanaged-servicesnetworkapi-server
参照
CIS Azure Kubernetes Service Automatic (AKS Automatic) Benchmark v1.0.0 - 5.4.2 Use private AKS clusters and disable the public API server FQDN

このホストをチェック

監査が許可されているマシンで実行してください。スキャンは読み取り専用です。

shell
tmaegis scan --target aks-automatic --level 2