comparison src/http/modules/proxy/ngx_http_proxy_handler.c @ 52:0d75d65c642f NGINX_0_1_26

nginx 0.1.26 *) Change: the invalid client header lines are now ignored and logged at the info level. *) Change: the server name is also logged in error log. *) Feature: the ngx_http_auth_basic_module module and the auth_basic and auth_basic_user_file directives.
author Igor Sysoev <http://sysoev.ru>
date Tue, 22 Mar 2005 00:00:00 +0300
parents 72eb30262aac
children bcb5fce0b038
comparison
equal deleted inserted replaced
51:43f383e47efc 52:0d75d65c642f
360 ngx_string("LMF"), 360 ngx_string("LMF"),
361 ngx_string("PDE") 361 ngx_string("PDE")
362 }; 362 };
363 363
364 364
365 #if (NGX_PCRE)
365 static ngx_str_t ngx_http_proxy_uri = ngx_string("/"); 366 static ngx_str_t ngx_http_proxy_uri = ngx_string("/");
367 #endif
366 368
367 369
368 static ngx_int_t ngx_http_proxy_handler(ngx_http_request_t *r) 370 static ngx_int_t ngx_http_proxy_handler(ngx_http_request_t *r)
369 { 371 {
370 ngx_http_proxy_ctx_t *p; 372 ngx_http_proxy_ctx_t *p;
810 r = ctx->proxy->request; 812 r = ctx->proxy->request;
811 uc = ctx->proxy->lcf->upstream; 813 uc = ctx->proxy->lcf->upstream;
812 peer = &ctx->proxy->upstream->peer; 814 peer = &ctx->proxy->upstream->peer;
813 815
814 p = ngx_snprintf(buf, len, 816 p = ngx_snprintf(buf, len,
815 " while %s, client: %V, URL: %V, upstream: http://%V%s%V", 817 " while %s, client: %V, host: %V, URL: \"%V\","
818 " upstream: http://%V%s%V",
816 ctx->proxy->action, 819 ctx->proxy->action,
817 &r->connection->addr_text, 820 &r->connection->addr_text,
821 &r->server_name,
818 &r->unparsed_uri, 822 &r->unparsed_uri,
819 &peer->peers->peer[peer->cur_peer].name, 823 &peer->peers->peer[peer->cur_peer].name,
820 ctx->proxy->lcf->upstream->uri_separator, 824 ctx->proxy->lcf->upstream->uri_separator,
821 &ctx->proxy->lcf->upstream->uri); 825 &ctx->proxy->lcf->upstream->uri);
822 len -= p - buf; 826 len -= p - buf;