-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lua-resty-waf breaks nginx even in simulate mode #2378
Comments
Hi @dcherniv, can you give an example POST request that I can use to regenerate this myself? Also please post the generated Nginx configuration. |
I can't reproduce on my test cluster. The issue only manifests when i promote the controller to our dev environment. Will get back to this ticket with more info. |
@ElvinEfendi
|
@dcherniv in the example at https://github.com/p0pr0ck5/lua-resty-waf#synopsis it explicitly mentions that options will be inherited. Also the default mode is SIMULATE(https://github.com/p0pr0ck5/lua-resty-waf#mode) so even if inheritance does not work it should still be running in simulate mode in every phase and not block requests. |
@dcherniv at this point I'd try setting |
I will try to reproduce tomorrow via Postman, maybe it's doing something that i cannot reproduce with curl. |
NGINX Ingress controller version:
0.13.0
Kubernetes version (use
kubectl version
):Environment:
GCP
GCP
container os
uname -a
):`Linux nginx-ingress-controller-5d6959bbb8-drq8x 4.4.86+ Basic structure #1 SMP Thu Dec 7 20:11:11 PST 2017 x86_64 GNU/Linux
What happened:
Lua-resty-waf causes nginx to return 403 for requests that were previously working in 0.10.2 even in simulate mode. When this happens, lua doesn't log anything to the console. I just see nginx returning 403s.
What you expected to happen:
Lua notifying but not blocking traffic, nginx passing traffic through when lua-resty-waf is in simulate mode.
How to reproduce it (as minimally and precisely as possible):
Update nginx controller to 0.13.0 add lua annotations:
Try to make a semi-complex POST request, nginx returns:
I don't see a usual lua log entry that would have followed if it had been caught by lua. I.E. the following is not present when i get 403s:
Anything else we need to know:
If i downgrade back to 0.10.2, disable lua annotations and upgrade back to 0.13.0, the same exact request works fine.
The text was updated successfully, but these errors were encountered: