medium10 pts · first answer countskubernetesnetworkingsecurity
NetworkPolicy has no effect
You apply a default-deny ingress NetworkPolicy in a namespace, but Pods from other namespaces can still reach its Pods. The YAML is valid and the policy exists. What is the most likely cause?
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: default-deny
namespace: payments
spec:
podSelector: {}
policyTypes: [Ingress]