comparison xml/en/docs/http/ngx_http_realip_module.xml @ 518:65750bdde8fb

Documented recent changes.
author Ruslan Ermilov <ru@nginx.com>
date Tue, 15 May 2012 14:57:21 +0000
parents 31e81dcc4ffd
children a8daad8e83bb
comparison
equal deleted inserted replaced
517:dba57bb42fec 518:65750bdde8fb
24 24
25 <section id="example" name="Example Configuration"> 25 <section id="example" name="Example Configuration">
26 26
27 <para> 27 <para>
28 <example> 28 <example>
29 set_real_ip_from 192.168.1.0/24; 29 set_real_ip_from 192.168.1.0/24;
30 set_real_ip_from 192.168.2.1; 30 set_real_ip_from 192.168.2.1;
31 real_ip_header X-Real-IP; 31 set_real_ip_from 2001:0db8::/32;
32 real_ip_header X-Forwarded-For;
33 real_ip_recursive on;
32 </example> 34 </example>
33 </para> 35 </para>
34 36
35 </section> 37 </section>
36 38
46 <context>http</context> 48 <context>http</context>
47 <context>server</context> 49 <context>server</context>
48 <context>location</context> 50 <context>location</context>
49 51
50 <para> 52 <para>
51 Describes trusted IPv4 addresses that are known to send correct 53 Defines trusted addresses that are known to send correct
52 replacement addresses. 54 replacement addresses.
53 If the special value <literal>unix:</literal> is specified, 55 If the special value <literal>unix:</literal> is specified,
54 all UNIX-domain sockets will be trusted. 56 all UNIX-domain sockets will be trusted.
57 <note>
58 IPv6 addresses are supported starting from version 1.3.0.
59 </note>
55 </para> 60 </para>
56 61
57 </directive> 62 </directive>
58 63
59 64
68 <context>location</context> 73 <context>location</context>
69 74
70 <para> 75 <para>
71 Defines a request header field used to send 76 Defines a request header field used to send
72 the address for a replacement. 77 the address for a replacement.
73 In case of the <header>X-Forwarded-For</header> field, 78 </para>
74 the last address in the field’s value is used. 79
75 For other fields the whole value is used. 80 </directive>
81
82
83 <directive name="real_ip_recursive">
84 <syntax><literal>on</literal> | <literal>off</literal></syntax>
85 <default>off</default>
86 <context>http</context>
87 <context>server</context>
88 <context>location</context>
89 <appeared-in>1.3.0</appeared-in>
90
91 <para>
92 If recursive search is disabled, an original client address that
93 matches one of the trusted addresses is replaced by the last
94 address sent in the request header field defined by the
95 <link id="real_ip_header"/> directive.
96 If recursive search is enabled, an original client address that
97 matches one of the trusted addresses is replaced by the last
98 non-trusted address sent in the request header field.
76 </para> 99 </para>
77 100
78 </directive> 101 </directive>
79 102
80 </section> 103 </section>