I have been working on converting from apache to nginx and I have a rule
RewriteRule \.(asp|aspx|php|jsp)$ - [F,L]
to block all of those. What would be the best way to convert that to nginx and is there a way to do it in one place so that all
virtualhosts share it?
If I could put that in one place so it applies to everything I serve with nginx it would be much easier to add other things to it over time. Mostly I want to completely block many extensions since it makes analyzing errors much simpler.
Thanks