request_body capture regex

2017-04-20 Thread Musta Fa
is it possible to capture POST data, but as soon there is a "password" then this word and its value to mask or exclude from log. i was trying to split request_body, but it not working correct: map $request_body $request_body_nopwd { "~(.*)(&|%5B)password(%5D)?\=" $1; } also if request dont have

custom ip address on port 80 not listening

2017-04-08 Thread Musta Fa
nginx/1.11.13 i have 4 server IPs, all registered in network interface and many domains and apps, also on different ports. all other ports are ok: custom_ip1:443, custom_ip1:5000, custom_ip1:81 custom_ip2:443, custom_ip2:5000, custom_ip2:81 custom_ip3:443, custom_ip3:5000, custom_ip3:81 but i c

Re: location and file extension regex

2016-12-03 Thread Musta Fa
oh this is insane now i open chrome incognito window and it works!! how is that even possible? how can browser still downloading this file? while new incognito session obeys nginx rules?? On Sat, Dec 3, 2016 at 2:54 PM, Francis Daly wrote: > On Sat, Dec 03, 2016 at 02:27:50PM +0000, Musta

Re: location and file extension regex

2016-12-03 Thread Musta Fa
at 12:19:44PM +0000, Musta Fa wrote: > > Hi there, > > > im trying to create some regex just to match before second slash and > only. > > and allow all subfolders: > > > > location ~ ^/([^/])+\.(tpl|xml)$ { return 404; } > > > > these files are

location and file extension regex

2016-12-03 Thread Musta Fa
im trying to create some regex just to match before second slash and only. and allow all subfolders: location ~ ^/([^/])+\.(tpl|xml)$ { return 404; } these files are located in root folder, and i dont want them to be downloaded, but other files in subfolder are downloadable. not sure why it not