Strict mTLS requires that mutual TLS be enabled across the entire service mesh, which can be set using a PeerAuthentication resource on a per-Namespace basis and, if set on the `istio-system` Namespace could disable it across the entire mesh. Disabling mTLS can reduce the security for traffic within that portion of the mesh and should be controlled. This policy prevents disabling strict mTLS in a PeerAuthentication resource by requiring the `mode` be set to either `UNSET` or `STRICT`.
apiVersion: kyverno.io/v1kind: ClusterPolicymetadata:name: enforce-strict-mtlsannotations:policies.kyverno.io/title: Enforce Istio Strict mTLSpolicies.kyverno.io/category: Istiopolicies.kyverno.io/severity: mediumpolicies.kyverno.io/subject: PeerAuthenticationkyverno.io/kyverno-version: 1.8.0policies.kyverno.io/minversion: 1.6.0kyverno.io/kubernetes-version: "1.24"policies.kyverno.io/description: Strict mTLS requires that mutual TLS be enabled across the entire service mesh, which can be set using a PeerAuthentication resource on a per-Namespace basis and, if set on the `istio-system` Namespace could disable it across the entire mesh. Disabling mTLS can reduce the security for traffic within that portion of the mesh and should be controlled. This policy prevents disabling strict mTLS in a PeerAuthentication resource by requiring the `mode` be set to either `UNSET` or `STRICT`.spec:validationFailureAction: Auditbackground: truerules:- name: validate-mtlsmatch:any:- resources:kinds:- PeerAuthenticationvalidate:message: PeerAuthentication resources may only set UNSET or STRICT for the mode.pattern:"=(spec)":"=(mtls)":"=(mode)": UNSET | STRICT
This policy prevents the use of the default project in an Application.
Services of type LoadBalancer when deployed inside AWS have support for transport encryption if it is enabled via an annotation. This policy requires that Services of type LoadBalancer contain the annotation service.beta.kubernetes.io/aws-load-balancer-ssl-cert with some value.
This policy prevents updates to the project field after an Application is created.