Quantcast
Channel: Nginx Forum
Viewing all articles
Browse latest Browse all 53287

Re: [BUG] ngx_http_sub_filter_module can not handle ambiguous patterns

$
0
0
Hello!

On Fri, Dec 28, 2012 at 5:34 AM, Maxim Dounin <mdounin@mdounin.ru> wrote:
>
> It's a bug, and it's expected to be fixed soon.
>

Thank you :)

BTW, I've also noticed that this sub filter module cannot handle
single-byte user patterns either:

location = /t {
default_type text/html;
return 200 abc;
sub_filter a X;
}

Accessing /t yields "abc" instead of "Xbc" (tested with Nginx 1.2.6).

The state machine in the ngx_http_sub_parse function seems to assume
that the user pattern (ctx->match) is at least 2 bytes long, which
looks incorrect to me :)

Best regards,
-agentzh

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel

Viewing all articles
Browse latest Browse all 53287

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>