switch to a 60 bit hash
[httpd-crcsyncproxy.git] / docs / manual / mod / mod_setenvif.xml.ko
blob02b0edd2ec4ec5162f6a780ea35a70254fdd3bbc
1 <?xml version="1.0" encoding="EUC-KR" ?>
2 <!DOCTYPE modulesynopsis SYSTEM "../style/modulesynopsis.dtd">
3 <?xml-stylesheet type="text/xsl" href="../style/manual.ko.xsl"?>
4 <!-- English Revision: 151408:658546 (outdated) -->
6 <!--
7 Licensed to the Apache Software Foundation (ASF) under one or more
8 contributor license agreements. See the NOTICE file distributed with
9 this work for additional information regarding copyright ownership.
10 The ASF licenses this file to You under the Apache License, Version 2.0
11 (the "License"); you may not use this file except in compliance with
12 the License. You may obtain a copy of the License at
14 http://www.apache.org/licenses/LICENSE-2.0
16 Unless required by applicable law or agreed to in writing, software
17 distributed under the License is distributed on an "AS IS" BASIS,
18 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 See the License for the specific language governing permissions and
20 limitations under the License.
21 -->
23 <modulesynopsis metafile="mod_setenvif.xml.meta">
25 <name>mod_setenvif</name>
26 <description>¿äûÀÇ ¼º°Ý¿¡ µû¶ó ȯ°æº¯¼ö ¼³Á¤À» º¯°æÇÑ´Ù</description>
27 <status>Base</status>
28 <sourcefile>mod_setenvif.c</sourcefile>
29 <identifier>setenvif_module</identifier>
32 <summary>
34 <p><module>mod_setenvif</module> ¸ðµâÀº ¿äûÀÇ ¼º°ÝÀÌ
35 Á¤±ÔÇ¥Çö½Ä¿¡ ÇØ´çÇÏ´ÂÁö ¿©ºÎ·Î ȯ°æº¯¼ö¸¦ ¼³Á¤ÇÑ´Ù. ¼­¹öÀÇ
36 ´Ù¸¥ ºÎºÐÀÌ ÇൿÀ» °áÁ¤ÇÒ¶§ ÀÌ È¯°æº¯¼ö¸¦ »ç¿ëÇÒ ¼ö ÀÖ´Ù.</p>
38 <p>¼³Á¤ÆÄÀÏ¿¡ ³ª¿À´Â ¼ø¼­´ë·Î Áö½Ã¾î¸¦ ó¸®ÇÑ´Ù. ±×·¡¼­
39 ºê¶ó¿ìÀú°¡ MSIE°¡ ¾Æ´Ï¶ó mozillaÀÎ °æ¿ì <code>netscape</code>¸¦
40 ¼³Á¤ÇÏ´Â ¾Æ·¡ ¿¹¿Í °°ÀÌ ¿©·¯ Áö½Ã¾î¸¦ ÇÔ²² »ç¿ëÇÒ ¼ö ÀÖ´Ù.</p>
42 <example>
43 BrowserMatch ^Mozilla netscape<br />
44 BrowserMatch MSIE !netscape<br />
45 </example>
46 </summary>
48 <seealso><a href="../env.html">¾ÆÆÄÄ¡ÀÇ È¯°æº¯¼ö</a></seealso>
50 <directivesynopsis>
51 <name>BrowserMatch</name>
52 <description>HTTP User-Agent¿¡ µû¶ó ȯ°æº¯¼ö¸¦ ¼³Á¤ÇÑ´Ù</description>
53 <syntax>BrowserMatch <em>regex [!]env-variable</em>[=<em>value</em>]
54 [[!]<em>env-variable</em>[=<em>value</em>]] ...</syntax>
55 <contextlist><context>server config</context>
56 <context>virtual host</context><context>directory</context>
57 <context>.htaccess</context></contextlist>
58 <override>FileInfo</override>
60 <usage>
61 <p><directive>BrowserMatch</directive>´Â <directive
62 module="mod_setenvif">SetEnvIf</directive> Áö½Ã¾îÀÇ Æ¯º°ÇÑ
63 °æ¿ì·Î, HTTP ¿äû Çì´õ <code>User-Agent</code>¿¡ µû¶ó ȯ°æº¯¼ö¸¦
64 ¼³Á¤ÇÑ´Ù. ´ÙÀ½ µÎ ÁÙÀº °°´Ù:</p>
65 <example>
66 BrowserMatchNoCase Robot is_a_robot<br />
67 SetEnvIfNoCase User-Agent Robot is_a_robot<br />
68 </example>
70 <p>Ãß°¡ ¿¹Á¦:</p>
71 <example>
72 BrowserMatch ^Mozilla forms jpeg=yes browser=netscape<br />
73 BrowserMatch "^Mozilla/[2-3]" tables agif frames javascript<br />
74 BrowserMatch MSIE !javascript<br />
75 </example>
76 </usage>
77 </directivesynopsis>
79 <directivesynopsis>
80 <name>BrowserMatchNoCase</name>
81 <description>´ë¼Ò¹®ÀÚ¸¦ ±¸º°ÇÏÁö¾Ê°í User-Agent¿¡ µû¶ó ȯ°æº¯¼ö¸¦
82 ¼³Á¤ÇÑ´Ù</description>
83 <syntax>BrowserMatchNoCase <em>regex [!]env-variable</em>[=<em>value</em>]
84 [[!]<em>env-variable</em>[=<em>value</em>]] ...</syntax>
85 <contextlist><context>server config</context>
86 <context>virtual host</context><context>directory</context>
87 <context>.htaccess</context></contextlist>
88 <override>FileInfo</override>
89 <compatibility>¾ÆÆÄÄ¡ 1.2 ÀÌ»ó (¾ÆÆÄÄ¡ 1.2¿¡¼­ ÀÌ Áö½Ã¾î´Â ÇöÀç
90 ¾ø¾îÁø mod_browser ¸ðµâ¿¡ ÀÖ¾ú´Ù)</compatibility>
92 <usage>
94 <p><directive>BrowserMatchNoCase</directive> Áö½Ã¾î´Â <directive
95 module="mod_setenvif">BrowserMatch</directive> Áö½Ã¾î¿Í
96 ÀÇ¹Ì»ó °°´Ù. ±×·¯³ª ÀÌ Áö½Ã¾î´Â ´ë¼Ò¹®ÀÚ¸¦ ±¸º°ÇÏÁö¾Ê´Â´Ù.
97 ¿¹¸¦ µé¾î:</p>
98 <example>
99 BrowserMatchNoCase mac platform=macintosh<br />
100 BrowserMatchNoCase win platform=windows<br />
101 </example>
103 <p><directive>BrowserMatch</directive>¿Í
104 <directive>BrowserMatchNoCase</directive> Áö½Ã¾î´Â
105 <directive module="mod_setenvif">SetEnvIf</directive>¿Í
106 <directive module="mod_setenvif">SetEnvIfNoCase</directive>
107 Áö½Ã¾îÀÇ Æ¯º°ÇÑ °æ¿ì´Ù. ´ÙÀ½ ÁÖ ÁÙÀº °°´Ù:</p>
108 <example>
109 BrowserMatchNoCase Robot is_a_robot<br />
110 SetEnvIfNoCase User-Agent Robot is_a_robot<br />
111 </example>
112 </usage>
113 </directivesynopsis>
115 <directivesynopsis>
116 <name>SetEnvIf</name>
117 <description>¿äûÀÇ ¼ºÁú¿¡ µû¶ó ȯ°æº¯¼ö¸¦ ¼³Á¤ÇÑ´Ù</description>
118 <syntax>SetEnvIf <em>attribute
119 regex [!]env-variable</em>[=<em>value</em>]
120 [[!]<em>env-variable</em>[=<em>value</em>]] ...</syntax>
121 <contextlist><context>server config</context>
122 <context>virtual host</context><context>directory</context>
123 <context>.htaccess</context></contextlist>
124 <override>FileInfo</override>
126 <usage>
127 <p><directive>SetEnvIf</directive> Áö½Ã¾î´Â ¿äûÀÇ ¼ºÁú¿¡
128 µû¶ó ȯ°æº¯¼ö¸¦ Á¤ÀÇÇÑ´Ù. ù¹ø° ¾Æ±Ô¸ÕÆ® <em>attribute</em>´Â
129 ´ÙÀ½ ¼¼°¡ÁöÁß Çϳª´Ù:</p>
131 <ol>
132 <li>HTTP ¿äû Çì´õ (´õ ÀÚ¼¼ÇÑ Á¤º¸´Â <a
133 href="http://www.rfc-editor.org/rfc/rfc2616.txt">RFC2616</a>
134 Âü°í); ¿¹¸¦ µé¾î: <code>Host</code>, <code>User-Agent</code>,
135 <code>Referer</code>, <code>Accept-Language</code>. Á¤±ÔÇ¥Çö½ÄÀ»
136 »ç¿ëÇÏ¿© ¿©·¯ ¿äû Çì´õ¸¦ ÁöĪÇÒ ¼ö ÀÖ´Ù.</li>
138 <li>¿äûÀÇ ´ÙÀ½ ¼ºÁúÁß Çϳª:
139 <ul>
140 <li><code>Remote_Host</code> - (ÀÖ´Ù¸é) ¿äûÇϴ Ŭ¶óÀ̾ðÆ®ÀÇ
141 È£½ºÆ®¸í</li>
143 <li><code>Remote_Addr</code> - ¿äûÇϴ Ŭ¶óÀ̾ðÆ®ÀÇ IP ÁÖ¼Ò</li>
145 <li><code>Server_Addr</code> - ¿äûÀ» ¹Þ´Â ¼­¹öÀÇ IP ÁÖ¼Ò
146 (2.0.43 ¹öÀü ÀÌÈÄ¿¡¸¸)</li>
148 <li><code>Request_Method</code> - »ç¿ëÇÑ ¸Þ½áµå À̸§
149 (<code>GET</code>, <code>POST</code>, <em>µîµî</em>)</li>
151 <li><code>Request_Protocol</code> - ¿äûÀÇ ÇÁ·ÎÅäÄÝ À̸§°ú
152 ¹öÀü (<em>¿¹¸¦ µé¾î</em>, "HTTP/0.9", "HTTP/1.1", <em>µî.</em>)</li>
154 <li><code>Request_URI</code> - HTTP ¿äû¿¡¼­ ¿äûÇÑ ÀÚ¿ø
155 -- ÀϹÝÀûÀ¸·Î URL¿¡¼­ ÁúÀǹ®ÀÚ¿­À» Á¦¿ÜÇÑ ½ºÅ´(scheme)°ú
156 È£½ºÆ® ÀÌÈÄ ºÎºÐ</li>
157 </ul>
158 </li>
160 <li>¿äû°ú ¿¬°üµÈ ȯ°æº¯¼ö À̸§. ±×·¡¼­ <directive>SetEnvIf</directive>
161 Áö½Ã¾î´Â ÀÌÀü Áö½Ã¾îÀÇ °á°ú¸¦ °Ë»çÇÒ ¼ö ÀÖ´Ù. ÀÌÀü¿¡
162 <code>SetEnvIf[NoCase]</code> Áö½Ã¾î·Î Á¤ÀÇÇÑ È¯°æº¯¼ö¸¸À»
163 °Ë»çÇÒ ¼ö ÀÖ´Ù. 'ÀÌÀü'À̶õ (¼­¹öÀü¿ª°ú °°ÀÌ) ´õ ³ÐÀº ¿µ¿ª ȤÀº
164 Áö½Ã¾îÀÇ ÇöÀç ¿µ¿ª ÀÌÀüÀ» ¶æÇÑ´Ù. ¿äû ¼ºÁúÀÌ ¾Æ´Ï°í Á¤±ÔÇ¥Çö½ÄÀÌ
165 ¾Æ´Ñ <em>attribute</em>´Â ȯ°æº¯¼ö·Î Ãë±ÞÇÑ´Ù.</li>
166 </ol>
168 <p>µÎ¹ø° ¾Æ±Ô¸ÕÆ®´Â (<em>regex</em>) <a
169 href="http://www.pcre.org/">Perl ȣȯ Á¤±ÔÇ¥Çö½Ä</a>ÀÌ´Ù.
170 ÀÌ´Â POSIX.2 egrepÀÇ Á¤±ÔÇ¥Çö½Ä°ú ºñ½ÁÇÏ´Ù. <em>regex</em>°¡
171 <em>attribute</em>¿¡ ´ëÀÀÇÏ¸é ³ª¸ÓÁö ¾Æ±Ô¸ÕÆ®¸¦ ó¸®ÇÑ´Ù.</p>
173 <p>³ª¸ÓÁö ¾Æ±Ô¸ÕÆ®´Â ¼³Á¤ÇÒ º¯¼ö¸í°ú (¼±ÅÃÀûÀÎ) ¼³Á¤°ªµéÀÌ´Ù.
174 ´ÙÀ½°ú °°Àº Çü½ÄÀÌ´Ù</p>
176 <ol>
177 <li><code><em>varname</em></code>, ȤÀº</li>
179 <li><code>!<em>varname</em></code>, ȤÀº</li>
181 <li><code><em>varname</em>=<em>value</em></code></li>
182 </ol>
184 <p>ù¹ø° ÇüÅ´ °ªÀ¸·Î "1"À» »ç¿ëÇÑ´Ù. µÎ¹ø° ÇüÅ´ º¯¼ö°¡
185 ÀÌ¹Ì Á¤ÀÇµÈ °æ¿ì º¯¼ö¸¦ Á¦°ÅÇÏ°í, ¼¼¹ø°´Â º¯¼öÀÇ °ªÀ¸·Î
186 <code><em>value</em></code>¸¦ ¼³Á¤ÇÑ´Ù. ¾ÆÆÄÄ¡ 2.0.51ºÎÅÍ
187 <var>value</var>¿¡ ÀÖ´Â <code>$1</code>..<code>$9</code>¸¦
188 <var>regex</var>ÀÇ °ýȣģ ÇÏÀ§Ç¥Çö½ÄÀ¸·Î ´ëüÇÑ´Ù.</p>
190 <example>
191 <title>¿¹Á¦:</title>
192 SetEnvIf Request_URI "\.gif$" object_is_image=gif<br />
193 SetEnvIf Request_URI "\.jpg$" object_is_image=jpg<br />
194 SetEnvIf Request_URI "\.xbm$" object_is_image=xbm<br />
195 :<br />
196 SetEnvIf Referer www\.mydomain\.com intra_site_referral<br />
197 :<br />
198 SetEnvIf object_is_image xbm XBIT_PROCESSING=1<br />
199 :<br />
200 SetEnvIf ^TS* ^[a-z].* HAVE_TS<br />
201 </example>
203 <p>óÀ½ ¼¼ ÁÙÀº À̹ÌÁö ÆÄÀÏÀ» ¿äûÇÑ °æ¿ì ȯ°æº¯¼ö
204 <code>object_is_image</code>¸¦ ¼³Á¤ÇÑ´Ù. ³×¹ø° ÁÙÀº ÆäÀÌÁö¸¦
205 <code>www.mydomain.com</code> À¥»çÀÌÆ®¿¡¼­ ÂüÁ¶ÇÑ °æ¿ì
206 <code>intra_site_referral</code>À» ¼³Á¤ÇÑ´Ù.</p>
208 <p>¸¶Áö¸· ¿¹´Â ¿äû¿¡ À̸§¿¡ "TS"·Î ½ÃÀÛÇÏ°í °ªÀÌ [a-z]
209 Áß Çϳª·Î ½ÃÀÛÇÏ´Â Çì´õ°¡ ÀÖ´Â °æ¿ì ȯ°æº¯¼ö
210 <code>HAVE_TS</code>¸¦ ¼³Á¤ÇÑ´Ù.</p>
211 </usage>
213 <seealso><a href="../env.html">¾ÆÆÄÄ¡ÀÇ È¯°æº¯¼ö</a>¿¡ ´õ ¸¹Àº
214 ¿¹Á¦°¡ ÀÖ´Ù.
215 </seealso>
216 </directivesynopsis>
218 <directivesynopsis>
219 <name>SetEnvIfNoCase</name>
220 <description>´ë¼Ò¹®ÀÚ¸¦ ±¸º°ÇÏÁö¾Ê°í ¿äûÀÇ ¼ºÁú¿¡ µû¶ó ȯ°æº¯¼ö¸¦
221 ¼³Á¤ÇÑ´Ù</description>
222 <syntax>SetEnvIfNoCase <em>attribute regex
223 [!]env-variable</em>[=<em>value</em>]
224 [[!]<em>env-variable</em>[=<em>value</em>]] ...</syntax>
225 <contextlist><context>server config</context>
226 <context>virtual host</context><context>directory</context>
227 <context>.htaccess</context></contextlist>
228 <override>FileInfo</override>
229 <compatibility>¾ÆÆÄÄ¡ 1.3 ÀÌÈÄ</compatibility>
231 <usage>
233 <p><directive>SetEnvIfNoCase</directive>´Â Àǹ̻ó <directive
234 module="mod_setenvif">SetEnvIf</directive> Áö½Ã¾î¿Í °°Áö¸¸,
235 ´ë¼Ò¹®ÀÚ¸¦ ±¸º°ÇÏÁö¾Ê°í Á¤±ÔÇ¥Çö½ÄÀ» ã´Â´Ù. ¿¹¸¦ µé¾î:</p>
236 <example>
237 SetEnvIfNoCase Host Apache\.Org site=apache
238 </example>
240 <p>ÀÌ °æ¿ì HTTP ¿äû Çì´õ <code>Host:</code>°¡
241 <code>Apache.Org</code>, <code>apache.org</code> µîÀ» Æ÷ÇÔÇϸé
242 <code>site</code> ȯ°æº¯¼ö¸¦ "<code>apache</code>"·Î ¼³Á¤ÇÑ´Ù.</p>
243 </usage>
244 </directivesynopsis>
245 </modulesynopsis>