nic-6443 commented on code in PR #2813:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/2813#discussion_r3656003475


##########
internal/webhook/v1/ingress_webhook.go:
##########
@@ -82,6 +83,10 @@ func (v *IngressCustomValidator) ValidateCreate(ctx 
context.Context, obj runtime
                return nil, fmt.Errorf("%s", 
sslvalidator.FormatConflicts(conflicts))
        }
 
+       if err := validateAnnotations(ingress); err != nil {

Review Comment:
   [P1] This guard only runs when the admission webhook is enabled, but the 
shipped configuration defaults `webhook.enable` to `false`. In default 
deployments, `ValidateCreate` and `ValidateUpdate` never run and the translator 
still silently drops csrf, so both create and update remain unprotected. 
`failurePolicy: Ignore` is not the only bypass. Please enforce this invariant 
in a path that always runs, with fail-closed behavior for updates, or make 
admission mandatory for this feature.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to