проблема с limit_except

Artem Danilenko darkden at mail.ru
Tue Nov 3 15:11:53 MSK 2009


Приветствую! 

Понадобилось нескольким сетям закрыть POST!

    location / {
 [skip]
limit_except  GET {
    deny    xx.xx.xx.0/20;
    deny    xy.xy.xy.0/24;
    allow   all;
}        proxy_pass  http://127.0.0.1/;
 [skip]
      }

    location @apache {
        proxy_pass  http://127.0.0.1/;
 [skip]
      }

Когда клиент из deny сетей пытается сделать POST, он получает 403 и это работает правильно, но тогда все остальные при POST, получают 404. В error.log видно, что запросы не идут на прокси, а идут в "root html" который в этом локейшене не определен, т.е. берется тот, что по умолчанию.

ЗЫ: Игорь, возможно сделать список всех модулей со статусом вкл. выкл. после конфигурации, до сборки? Было бы очень удобно и сразу видно, что лишнее, а что наоборот забыто.
nginx -V
nginx version: nginx/0.7.63
TLS SNI support enabled
configure arguments: --with-http_ssl_module --without-select_module --without-poll_module --without-http_charset_module --without-http_fastcgi_module --with-http_gzip_static_module --with-http_stub_status_module --without-http_empty_gif_module --without-http_ssi_module --without-http_browser_module --without-http_autoindex_module --without-http_userid_module --without-http_memcached_module --with-http_flv_module --with-http_realip_module --user=www-data --group=www-data

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nginx.org/pipermail/nginx-ru/attachments/20091103/cbdd5782/attachment.html>


More information about the nginx-ru mailing list