# HG changeset patch # User Igor Sysoev # Date 1167050224 0 # Node ID ff762576da78a50e4e0dfceb781414564d83730b # Parent f16424aa5d8948474d033ad663ac63b0da62852b limit the ngx_http_index_module methods to GET, HEAD and POST diff --git a/src/http/modules/ngx_http_index_module.c b/src/http/modules/ngx_http_index_module.c --- a/src/http/modules/ngx_http_index_module.c +++ b/src/http/modules/ngx_http_index_module.c @@ -140,6 +140,10 @@ ngx_http_index_handler(ngx_http_request_ return NGX_DECLINED; } + if (!(r->method & (NGX_HTTP_GET|NGX_HTTP_HEAD|NGX_HTTP_POST))) { + return NGX_DECLINED; + } + /* TODO: Win32 */ if (r->zero_in_uri) { return NGX_DECLINED;