For AI agents: A markdown version of this page is available at https://docs.datadoghq.com/security/code_security/iac_security/iac_rules/kubernetes-anonymous-auth-is-not-set-to-false.md.
A documentation index is available at /llms.txt.
When kubelet or kube-apiserver are used, the --anonymous-auth flag should be set to false. The rule checks container command entries for those components and the KubeletConfiguration.authentication.anonymous.enabled attribute. An IncorrectValue issue is reported when --anonymous-auth is set to true or authentication.anonymous.enabled is not false.