peakwinter/python-nginx

Probably incorrect regular expression in directive parsing

Closed this issue · 0 comments

If in nginx.conf there is directive with a block, directives map, geo, upstream, etc. are not parsed correctly. For example:

http {
...
map_any_world anyvalue;
if ($slow) {
set $limit_rate 4k;
}
...
}

r'^\s*map\s*(.*?)\s*{' match:

map_any_world anyvalue;
if ($slow) {

expected - No matches

#32