]>
Commit | Line | Data |
---|---|---|
3a278cb8 | 1 | |
9cef6668 | 2 | # |
262a0e14 | 3 | # $Id$ |
9cef6668 | 4 | # |
6845f129 | 5 | # SQUID Web Proxy Cache http://www.squid-cache.org/ |
9cef6668 | 6 | # ---------------------------------------------------------- |
7 | # | |
2b6662ba | 8 | # Squid is the result of efforts by numerous individuals from |
9 | # the Internet community; see the CONTRIBUTORS file for full | |
10 | # details. Many organizations have provided support for Squid's | |
11 | # development; see the SPONSORS file for full details. Squid is | |
12 | # Copyrighted (C) 2000 by the Regents of the University of | |
13 | # California; see the COPYRIGHT file for full details. Squid | |
14 | # incorporates software developed and/or copyrighted by other | |
15 | # sources; see the CREDITS file for full details. | |
9cef6668 | 16 | # |
17 | # This program is free software; you can redistribute it and/or modify | |
18 | # it under the terms of the GNU General Public License as published by | |
19 | # the Free Software Foundation; either version 2 of the License, or | |
20 | # (at your option) any later version. | |
96d88dcb | 21 | # |
9cef6668 | 22 | # This program is distributed in the hope that it will be useful, |
23 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
24 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
25 | # GNU General Public License for more details. | |
96d88dcb | 26 | # |
9cef6668 | 27 | # You should have received a copy of the GNU General Public License |
28 | # along with this program; if not, write to the Free Software | |
29 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. | |
30 | # | |
31 | ||
0f74202c | 32 | COMMENT_START |
cccac0a2 | 33 | WELCOME TO SQUID @VERSION@ |
34 | ---------------------------- | |
3a278cb8 | 35 | |
cccac0a2 | 36 | This is the default Squid configuration file. You may wish |
37 | to look at the Squid home page (http://www.squid-cache.org/) | |
38 | for the FAQ and other documentation. | |
3a278cb8 | 39 | |
cccac0a2 | 40 | The default Squid config file shows what the defaults for |
41 | various options happen to be. If you don't need to change the | |
42 | default, you shouldn't uncomment the line. Doing so may cause | |
43 | run-time problems. In some cases "none" refers to no default | |
44 | setting at all, while in other cases it refers to a valid | |
45 | option - the comments for that keyword indicate if this is the | |
46 | case. | |
debd9a31 | 47 | |
cccac0a2 | 48 | COMMENT_END |
3a278cb8 | 49 | |
592a09dc | 50 | COMMENT_START |
51 | Configuration options can be included using the "include" directive. | |
52 | Include takes a list of files to include. Quoting and wildcards is | |
53 | supported. | |
54 | ||
55 | For example, | |
56 | ||
57 | include /path/to/included/file/squid.acl.config | |
58 | ||
59 | Includes can be nested up to a hard-coded depth of 16 levels. | |
60 | This arbitrary restriction is to prevent recursive include references | |
61 | from causing Squid entering an infinite loop whilst trying to load | |
62 | configuration files. | |
63 | COMMENT_END | |
64 | ||
5473c134 | 65 | COMMENT_START |
41bd17a4 | 66 | OPTIONS FOR AUTHENTICATION |
5473c134 | 67 | ----------------------------------------------------------------------------- |
68 | COMMENT_END | |
69 | ||
41bd17a4 | 70 | NAME: auth_param |
71 | TYPE: authparam | |
72 | LOC: Config.authConfiguration | |
cccac0a2 | 73 | DEFAULT: none |
74 | DOC_START | |
41bd17a4 | 75 | This is used to define parameters for the various authentication |
76 | schemes supported by Squid. | |
cccac0a2 | 77 | |
41bd17a4 | 78 | format: auth_param scheme parameter [setting] |
cccac0a2 | 79 | |
41bd17a4 | 80 | The order in which authentication schemes are presented to the client is |
81 | dependent on the order the scheme first appears in config file. IE | |
82 | has a bug (it's not RFC 2617 compliant) in that it will use the basic | |
83 | scheme if basic is the first entry presented, even if more secure | |
84 | schemes are presented. For now use the order in the recommended | |
85 | settings section below. If other browsers have difficulties (don't | |
86 | recognize the schemes offered even if you are using basic) either | |
87 | put basic first, or disable the other schemes (by commenting out their | |
88 | program entry). | |
cccac0a2 | 89 | |
41bd17a4 | 90 | Once an authentication scheme is fully configured, it can only be |
91 | shutdown by shutting squid down and restarting. Changes can be made on | |
92 | the fly and activated with a reconfigure. I.E. You can change to a | |
93 | different helper, but not unconfigure the helper completely. | |
cccac0a2 | 94 | |
41bd17a4 | 95 | Please note that while this directive defines how Squid processes |
96 | authentication it does not automatically activate authentication. | |
97 | To use authentication you must in addition make use of ACLs based | |
98 | on login name in http_access (proxy_auth, proxy_auth_regex or | |
99 | external with %LOGIN used in the format tag). The browser will be | |
100 | challenged for authentication on the first such acl encountered | |
101 | in http_access processing and will also be re-challenged for new | |
102 | login credentials if the request is being denied by a proxy_auth | |
103 | type acl. | |
cccac0a2 | 104 | |
41bd17a4 | 105 | WARNING: authentication can't be used in a transparently intercepting |
106 | proxy as the client then thinks it is talking to an origin server and | |
107 | not the proxy. This is a limitation of bending the TCP/IP protocol to | |
108 | transparently intercepting port 80, not a limitation in Squid. | |
13b5cd0c AJ |
109 | Ports flagged 'transparent', 'intercept', or 'tproxy' have authentication |
110 | disabled. | |
cccac0a2 | 111 | |
41bd17a4 | 112 | === Parameters for the basic scheme follow. === |
cccac0a2 | 113 | |
41bd17a4 | 114 | "program" cmdline |
115 | Specify the command for the external authenticator. Such a program | |
116 | reads a line containing "username password" and replies "OK" or | |
117 | "ERR" in an endless loop. "ERR" responses may optionally be followed | |
118 | by a error description available as %m in the returned error page. | |
119 | If you use an authenticator, make sure you have 1 acl of type proxy_auth. | |
cccac0a2 | 120 | |
41bd17a4 | 121 | By default, the basic authentication scheme is not used unless a |
122 | program is specified. | |
cccac0a2 | 123 | |
41bd17a4 | 124 | If you want to use the traditional NCSA proxy authentication, set |
125 | this line to something like | |
307b83b7 | 126 | |
41bd17a4 | 127 | auth_param basic program @DEFAULT_PREFIX@/libexec/ncsa_auth @DEFAULT_PREFIX@/etc/passwd |
9e7dbc51 | 128 | |
d2a89ac1 AJ |
129 | "utf8" on|off |
130 | HTTP uses iso-latin-1 as characterset, while some authentication | |
131 | backends such as LDAP expects UTF-8. If this is set to on Squid will | |
132 | translate the HTTP iso-latin-1 charset to UTF-8 before sending the | |
133 | username & password to the helper. | |
134 | ||
41bd17a4 | 135 | "children" numberofchildren |
136 | The number of authenticator processes to spawn. If you start too few | |
137 | Squid will have to wait for them to process a backlog of credential | |
138 | verifications, slowing it down. When password verifications are | |
139 | done via a (slow) network you are likely to need lots of | |
140 | authenticator processes. | |
141 | auth_param basic children 5 | |
9e7dbc51 | 142 | |
41bd17a4 | 143 | "concurrency" concurrency |
144 | The number of concurrent requests the helper can process. | |
145 | The default of 0 is used for helpers who only supports | |
146 | one request at a time. Setting this changes the protocol used to | |
147 | include a channel number first on the request/response line, allowing | |
148 | multiple requests to be sent to the same helper in parallell without | |
149 | wating for the response. | |
150 | Must not be set unless it's known the helper supports this. | |
151 | auth_param basic concurrency 0 | |
0fdafae7 | 152 | |
41bd17a4 | 153 | "realm" realmstring |
154 | Specifies the realm name which is to be reported to the | |
155 | client for the basic proxy authentication scheme (part of | |
156 | the text the user will see when prompted their username and | |
157 | password). There is no default. | |
158 | auth_param basic realm Squid proxy-caching web server | |
d1b63fc8 | 159 | |
41bd17a4 | 160 | "credentialsttl" timetolive |
161 | Specifies how long squid assumes an externally validated | |
162 | username:password pair is valid for - in other words how | |
163 | often the helper program is called for that user. Set this | |
164 | low to force revalidation with short lived passwords. Note | |
165 | setting this high does not impact your susceptibility | |
166 | to replay attacks unless you are using an one-time password | |
167 | system (such as SecureID). If you are using such a system, | |
168 | you will be vulnerable to replay attacks unless you also | |
169 | use the max_user_ip ACL in an http_access rule. | |
cccac0a2 | 170 | |
41bd17a4 | 171 | "casesensitive" on|off |
172 | Specifies if usernames are case sensitive. Most user databases are | |
173 | case insensitive allowing the same username to be spelled using both | |
174 | lower and upper case letters, but some are case sensitive. This | |
175 | makes a big difference for user_max_ip ACL processing and similar. | |
176 | auth_param basic casesensitive off | |
cccac0a2 | 177 | |
41bd17a4 | 178 | === Parameters for the digest scheme follow === |
cccac0a2 | 179 | |
41bd17a4 | 180 | "program" cmdline |
181 | Specify the command for the external authenticator. Such | |
182 | a program reads a line containing "username":"realm" and | |
183 | replies with the appropriate H(A1) value hex encoded or | |
184 | ERR if the user (or his H(A1) hash) does not exists. | |
185 | See rfc 2616 for the definition of H(A1). | |
186 | "ERR" responses may optionally be followed by a error description | |
187 | available as %m in the returned error page. | |
cccac0a2 | 188 | |
41bd17a4 | 189 | By default, the digest authentication scheme is not used unless a |
190 | program is specified. | |
b8c0c06d | 191 | |
41bd17a4 | 192 | If you want to use a digest authenticator, set this line to |
193 | something like | |
cccac0a2 | 194 | |
7ce93108 | 195 | auth_param digest program @DEFAULT_PREFIX@/bin/digest_pw_auth @DEFAULT_PREFIX@/etc/digpass |
cccac0a2 | 196 | |
d2a89ac1 AJ |
197 | "utf8" on|off |
198 | HTTP uses iso-latin-1 as characterset, while some authentication | |
199 | backends such as LDAP expects UTF-8. If this is set to on Squid will | |
200 | translate the HTTP iso-latin-1 charset to UTF-8 before sending the | |
201 | username & password to the helper. | |
202 | ||
41bd17a4 | 203 | "children" numberofchildren |
204 | The number of authenticator processes to spawn (no default). | |
205 | If you start too few Squid will have to wait for them to | |
206 | process a backlog of H(A1) calculations, slowing it down. | |
207 | When the H(A1) calculations are done via a (slow) network | |
208 | you are likely to need lots of authenticator processes. | |
209 | auth_param digest children 5 | |
cccac0a2 | 210 | |
41bd17a4 | 211 | "realm" realmstring |
212 | Specifies the realm name which is to be reported to the | |
213 | client for the digest proxy authentication scheme (part of | |
214 | the text the user will see when prompted their username and | |
215 | password). There is no default. | |
216 | auth_param digest realm Squid proxy-caching web server | |
cccac0a2 | 217 | |
41bd17a4 | 218 | "nonce_garbage_interval" timeinterval |
219 | Specifies the interval that nonces that have been issued | |
220 | to client_agent's are checked for validity. | |
cccac0a2 | 221 | |
41bd17a4 | 222 | "nonce_max_duration" timeinterval |
223 | Specifies the maximum length of time a given nonce will be | |
224 | valid for. | |
cccac0a2 | 225 | |
41bd17a4 | 226 | "nonce_max_count" number |
227 | Specifies the maximum number of times a given nonce can be | |
228 | used. | |
cccac0a2 | 229 | |
41bd17a4 | 230 | "nonce_strictness" on|off |
231 | Determines if squid requires strict increment-by-1 behavior | |
232 | for nonce counts, or just incrementing (off - for use when | |
233 | useragents generate nonce counts that occasionally miss 1 | |
234 | (ie, 1,2,4,6)). Default off. | |
cccac0a2 | 235 | |
41bd17a4 | 236 | "check_nonce_count" on|off |
237 | This directive if set to off can disable the nonce count check | |
238 | completely to work around buggy digest qop implementations in | |
239 | certain mainstream browser versions. Default on to check the | |
240 | nonce count to protect from authentication replay attacks. | |
cccac0a2 | 241 | |
41bd17a4 | 242 | "post_workaround" on|off |
243 | This is a workaround to certain buggy browsers who sends | |
244 | an incorrect request digest in POST requests when reusing | |
245 | the same nonce as acquired earlier on a GET request. | |
cccac0a2 | 246 | |
41bd17a4 | 247 | === NTLM scheme options follow === |
cccac0a2 | 248 | |
41bd17a4 | 249 | "program" cmdline |
250 | Specify the command for the external NTLM authenticator. | |
251 | Such a program reads exchanged NTLMSSP packets with | |
252 | the browser via Squid until authentication is completed. | |
253 | If you use an NTLM authenticator, make sure you have 1 acl | |
254 | of type proxy_auth. By default, the NTLM authenticator_program | |
255 | is not used. | |
cccac0a2 | 256 | |
41bd17a4 | 257 | auth_param ntlm program @DEFAULT_PREFIX@/bin/ntlm_auth |
cccac0a2 | 258 | |
41bd17a4 | 259 | "children" numberofchildren |
260 | The number of authenticator processes to spawn (no default). | |
261 | If you start too few Squid will have to wait for them to | |
262 | process a backlog of credential verifications, slowing it | |
263 | down. When credential verifications are done via a (slow) | |
264 | network you are likely to need lots of authenticator | |
265 | processes. | |
cccac0a2 | 266 | |
41bd17a4 | 267 | auth_param ntlm children 5 |
cccac0a2 | 268 | |
41bd17a4 | 269 | "keep_alive" on|off |
270 | If you experience problems with PUT/POST requests when using the | |
271 | Negotiate authentication scheme then you can try setting this to | |
272 | off. This will cause Squid to forcibly close the connection on | |
273 | the initial requests where the browser asks which schemes are | |
274 | supported by the proxy. | |
cccac0a2 | 275 | |
41bd17a4 | 276 | auth_param ntlm keep_alive on |
cccac0a2 | 277 | |
41bd17a4 | 278 | === Options for configuring the NEGOTIATE auth-scheme follow === |
cccac0a2 | 279 | |
41bd17a4 | 280 | "program" cmdline |
281 | Specify the command for the external Negotiate authenticator. | |
282 | This protocol is used in Microsoft Active-Directory enabled setups with | |
283 | the Microsoft Internet Explorer or Mozilla Firefox browsers. | |
284 | Its main purpose is to exchange credentials with the Squid proxy | |
285 | using the Kerberos mechanisms. | |
286 | If you use a Negotiate authenticator, make sure you have at least one acl | |
287 | of type proxy_auth active. By default, the negotiate authenticator_program | |
288 | is not used. | |
289 | The only supported program for this role is the ntlm_auth | |
290 | program distributed as part of Samba, version 4 or later. | |
cccac0a2 | 291 | |
41bd17a4 | 292 | auth_param negotiate program @DEFAULT_PREFIX@/bin/ntlm_auth --helper-protocol=gss-spnego |
cccac0a2 | 293 | |
41bd17a4 | 294 | "children" numberofchildren |
295 | The number of authenticator processes to spawn (no default). | |
296 | If you start too few Squid will have to wait for them to | |
297 | process a backlog of credential verifications, slowing it | |
298 | down. When crendential verifications are done via a (slow) | |
299 | network you are likely to need lots of authenticator | |
300 | processes. | |
301 | auth_param negotiate children 5 | |
d3803853 | 302 | |
41bd17a4 | 303 | "keep_alive" on|off |
304 | If you experience problems with PUT/POST requests when using the | |
305 | Negotiate authentication scheme then you can try setting this to | |
306 | off. This will cause Squid to forcibly close the connection on | |
307 | the initial requests where the browser asks which schemes are | |
308 | supported by the proxy. | |
527ee50d | 309 | |
41bd17a4 | 310 | auth_param negotiate keep_alive on |
cccac0a2 | 311 | |
41bd17a4 | 312 | NOCOMMENT_START |
313 | #Recommended minimum configuration per scheme: | |
314 | #auth_param negotiate program <uncomment and complete this line to activate> | |
315 | #auth_param negotiate children 5 | |
316 | #auth_param negotiate keep_alive on | |
317 | #auth_param ntlm program <uncomment and complete this line to activate> | |
318 | #auth_param ntlm children 5 | |
319 | #auth_param ntlm keep_alive on | |
320 | #auth_param digest program <uncomment and complete this line> | |
321 | #auth_param digest children 5 | |
322 | #auth_param digest realm Squid proxy-caching web server | |
323 | #auth_param digest nonce_garbage_interval 5 minutes | |
324 | #auth_param digest nonce_max_duration 30 minutes | |
325 | #auth_param digest nonce_max_count 50 | |
326 | #auth_param basic program <uncomment and complete this line> | |
327 | #auth_param basic children 5 | |
328 | #auth_param basic realm Squid proxy-caching web server | |
329 | #auth_param basic credentialsttl 2 hours | |
330 | NOCOMMENT_END | |
331 | DOC_END | |
cccac0a2 | 332 | |
41bd17a4 | 333 | NAME: authenticate_cache_garbage_interval |
334 | TYPE: time_t | |
335 | DEFAULT: 1 hour | |
336 | LOC: Config.authenticateGCInterval | |
337 | DOC_START | |
338 | The time period between garbage collection across the username cache. | |
339 | This is a tradeoff between memory utilization (long intervals - say | |
340 | 2 days) and CPU (short intervals - say 1 minute). Only change if you | |
341 | have good reason to. | |
342 | DOC_END | |
cccac0a2 | 343 | |
41bd17a4 | 344 | NAME: authenticate_ttl |
345 | TYPE: time_t | |
346 | DEFAULT: 1 hour | |
347 | LOC: Config.authenticateTTL | |
348 | DOC_START | |
349 | The time a user & their credentials stay in the logged in | |
350 | user cache since their last request. When the garbage | |
351 | interval passes, all user credentials that have passed their | |
352 | TTL are removed from memory. | |
353 | DOC_END | |
cccac0a2 | 354 | |
41bd17a4 | 355 | NAME: authenticate_ip_ttl |
356 | TYPE: time_t | |
357 | LOC: Config.authenticateIpTTL | |
358 | DEFAULT: 0 seconds | |
359 | DOC_START | |
360 | If you use proxy authentication and the 'max_user_ip' ACL, | |
361 | this directive controls how long Squid remembers the IP | |
362 | addresses associated with each user. Use a small value | |
363 | (e.g., 60 seconds) if your users might change addresses | |
364 | quickly, as is the case with dialups. You might be safe | |
365 | using a larger value (e.g., 2 hours) in a corporate LAN | |
366 | environment with relatively static address assignments. | |
367 | DOC_END | |
cccac0a2 | 368 | |
3d1e3e43 | 369 | COMMENT_START |
370 | ACCESS CONTROLS | |
371 | ----------------------------------------------------------------------------- | |
372 | COMMENT_END | |
373 | ||
41bd17a4 | 374 | NAME: external_acl_type |
375 | TYPE: externalAclHelper | |
376 | LOC: Config.externalAclHelperList | |
cccac0a2 | 377 | DEFAULT: none |
cccac0a2 | 378 | DOC_START |
41bd17a4 | 379 | This option defines external acl classes using a helper program |
380 | to look up the status | |
cccac0a2 | 381 | |
41bd17a4 | 382 | external_acl_type name [options] FORMAT.. /path/to/helper [helper arguments..] |
cccac0a2 | 383 | |
41bd17a4 | 384 | Options: |
cccac0a2 | 385 | |
41bd17a4 | 386 | ttl=n TTL in seconds for cached results (defaults to 3600 |
387 | for 1 hour) | |
388 | negative_ttl=n | |
389 | TTL for cached negative lookups (default same | |
390 | as ttl) | |
391 | children=n Number of acl helper processes spawn to service | |
392 | external acl lookups of this type. (default 5) | |
393 | concurrency=n concurrency level per process. Only used with helpers | |
394 | capable of processing more than one query at a time. | |
395 | cache=n result cache size, 0 is unbounded (default) | |
396 | grace=n Percentage remaining of TTL where a refresh of a | |
397 | cached entry should be initiated without needing to | |
398 | wait for a new reply. (default 0 for no grace period) | |
399 | protocol=2.5 Compatibility mode for Squid-2.5 external acl helpers | |
cc192b50 | 400 | ipv4 / ipv6 IP-mode used to communicate to this helper. |
401 | For compatability with older configurations and helpers | |
1de68cc1 | 402 | the default is 'ipv4'. |
cccac0a2 | 403 | |
41bd17a4 | 404 | FORMAT specifications |
cccac0a2 | 405 | |
41bd17a4 | 406 | %LOGIN Authenticated user login name |
407 | %EXT_USER Username from external acl | |
408 | %IDENT Ident user name | |
409 | %SRC Client IP | |
410 | %SRCPORT Client source port | |
411 | %URI Requested URI | |
412 | %DST Requested host | |
413 | %PROTO Requested protocol | |
414 | %PORT Requested port | |
415 | %PATH Requested URL path | |
416 | %METHOD Request method | |
417 | %MYADDR Squid interface address | |
418 | %MYPORT Squid http_port number | |
419 | %PATH Requested URL-path (including query-string if any) | |
420 | %USER_CERT SSL User certificate in PEM format | |
421 | %USER_CERTCHAIN SSL User certificate chain in PEM format | |
422 | %USER_CERT_xx SSL User certificate subject attribute xx | |
423 | %USER_CA_xx SSL User certificate issuer attribute xx | |
7b0ca1e8 | 424 | |
c68c9682 | 425 | %>{Header} HTTP request header "Header" |
7b0ca1e8 | 426 | %>{Hdr:member} |
c68c9682 | 427 | HTTP request header "Hdr" list member "member" |
7b0ca1e8 | 428 | %>{Hdr:;member} |
41bd17a4 | 429 | HTTP request header list member using ; as |
430 | list separator. ; can be any non-alphanumeric | |
431 | character. | |
cccac0a2 | 432 | |
c68c9682 | 433 | %<{Header} HTTP reply header "Header" |
7b0ca1e8 | 434 | %<{Hdr:member} |
c68c9682 | 435 | HTTP reply header "Hdr" list member "member" |
7b0ca1e8 AJ |
436 | %<{Hdr:;member} |
437 | HTTP reply header list member using ; as | |
438 | list separator. ; can be any non-alphanumeric | |
439 | character. | |
440 | ||
41bd17a4 | 441 | In addition to the above, any string specified in the referencing |
442 | acl will also be included in the helper request line, after the | |
443 | specified formats (see the "acl external" directive) | |
cccac0a2 | 444 | |
41bd17a4 | 445 | The helper receives lines per the above format specification, |
446 | and returns lines starting with OK or ERR indicating the validity | |
447 | of the request and optionally followed by additional keywords with | |
448 | more details. | |
cccac0a2 | 449 | |
41bd17a4 | 450 | General result syntax: |
cccac0a2 | 451 | |
41bd17a4 | 452 | OK/ERR keyword=value ... |
cccac0a2 | 453 | |
41bd17a4 | 454 | Defined keywords: |
cccac0a2 | 455 | |
41bd17a4 | 456 | user= The users name (login) |
457 | password= The users password (for login= cache_peer option) | |
458 | message= Message describing the reason. Available as %o | |
459 | in error pages | |
460 | tag= Apply a tag to a request (for both ERR and OK results) | |
461 | Only sets a tag, does not alter existing tags. | |
462 | log= String to be logged in access.log. Available as | |
463 | %ea in logformat specifications | |
934b03fc | 464 | |
41bd17a4 | 465 | If protocol=3.0 (the default) then URL escaping is used to protect |
466 | each value in both requests and responses. | |
6a566b9c | 467 | |
41bd17a4 | 468 | If using protocol=2.5 then all values need to be enclosed in quotes |
469 | if they may contain whitespace, or the whitespace escaped using \. | |
470 | And quotes or \ characters within the keyword value must be \ escaped. | |
1e5562e3 | 471 | |
41bd17a4 | 472 | When using the concurrency= option the protocol is changed by |
473 | introducing a query channel tag infront of the request/response. | |
474 | The query channel tag is a number between 0 and concurrency-1. | |
cccac0a2 | 475 | DOC_END |
476 | ||
41bd17a4 | 477 | NAME: acl |
478 | TYPE: acl | |
479 | LOC: Config.aclList | |
1f5bd0a4 | 480 | DEFAULT: all src all |
cccac0a2 | 481 | DOC_START |
41bd17a4 | 482 | Defining an Access List |
cccac0a2 | 483 | |
375eeb3b AJ |
484 | Every access list definition must begin with an aclname and acltype, |
485 | followed by either type-specific arguments or a quoted filename that | |
486 | they are read from. | |
cccac0a2 | 487 | |
375eeb3b AJ |
488 | acl aclname acltype argument ... |
489 | acl aclname acltype "file" ... | |
cccac0a2 | 490 | |
375eeb3b | 491 | When using "file", the file should contain one item per line. |
cccac0a2 | 492 | |
41bd17a4 | 493 | By default, regular expressions are CASE-SENSITIVE. To make |
494 | them case-insensitive, use the -i option. | |
cccac0a2 | 495 | |
e988aa40 AJ |
496 | |
497 | ***** ACL TYPES AVAILABLE ***** | |
498 | ||
375eeb3b AJ |
499 | acl aclname src ip-address/netmask ... # clients IP address |
500 | acl aclname src addr1-addr2/netmask ... # range of addresses | |
501 | acl aclname dst ip-address/netmask ... # URL host's IP address | |
502 | acl aclname myip ip-address/netmask ... # local socket IP address | |
cccac0a2 | 503 | |
41bd17a4 | 504 | acl aclname arp mac-address ... (xx:xx:xx:xx:xx:xx notation) |
505 | # The arp ACL requires the special configure option --enable-arp-acl. | |
506 | # Furthermore, the ARP ACL code is not portable to all operating systems. | |
507 | # It works on Linux, Solaris, Windows, FreeBSD, and some other *BSD variants. | |
508 | # | |
509 | # NOTE: Squid can only determine the MAC address for clients that are on | |
510 | # the same subnet. If the client is on a different subnet, then Squid cannot | |
511 | # find out its MAC address. | |
934b03fc | 512 | |
375eeb3b AJ |
513 | acl aclname srcdomain .foo.com ... # reverse lookup, from client IP |
514 | acl aclname dstdomain .foo.com ... # Destination server from URL | |
515 | acl aclname srcdom_regex [-i] \.foo\.com ... # regex matching client name | |
516 | acl aclname dstdom_regex [-i] \.foo\.com ... # regex matching server | |
41bd17a4 | 517 | # For dstdomain and dstdom_regex a reverse lookup is tried if a IP |
518 | # based URL is used and no match is found. The name "none" is used | |
519 | # if the reverse lookup fails. | |
9bc73deb | 520 | |
375eeb3b AJ |
521 | acl aclname src_as number ... |
522 | acl aclname dst_as number ... | |
e988aa40 AJ |
523 | # Except for access control, AS numbers can be used for |
524 | # routing of requests to specific caches. Here's an | |
525 | # example for routing all requests for AS#1241 and only | |
526 | # those to mycache.mydomain.net: | |
527 | # acl asexample dst_as 1241 | |
528 | # cache_peer_access mycache.mydomain.net allow asexample | |
529 | # cache_peer_access mycache_mydomain.net deny all | |
7f7db318 | 530 | |
6db78a1a AJ |
531 | acl aclname peername myPeer ... |
532 | # match against a named cache_peer entry | |
533 | # set unique name= on cache_peer lines for reliable use. | |
534 | ||
375eeb3b AJ |
535 | acl aclname time [day-abbrevs] [h1:m1-h2:m2] |
536 | # day-abbrevs: | |
537 | # S - Sunday | |
538 | # M - Monday | |
539 | # T - Tuesday | |
540 | # W - Wednesday | |
541 | # H - Thursday | |
542 | # F - Friday | |
543 | # A - Saturday | |
544 | # h1:m1 must be less than h2:m2 | |
545 | ||
546 | acl aclname url_regex [-i] ^http:// ... # regex matching on whole URL | |
41bd17a4 | 547 | acl aclname urlpath_regex [-i] \.gif$ ... # regex matching on URL path |
e988aa40 | 548 | |
375eeb3b AJ |
549 | acl aclname port 80 70 21 ... |
550 | acl aclname port 0-1024 ... # ranges allowed | |
551 | acl aclname myport 3128 ... # (local socket TCP port) | |
197f6b3c | 552 | acl aclname myportname 3128 ... # http(s)_port name |
e988aa40 | 553 | |
375eeb3b | 554 | acl aclname proto HTTP FTP ... |
e988aa40 | 555 | |
375eeb3b | 556 | acl aclname method GET POST ... |
e988aa40 AJ |
557 | |
558 | acl aclname http_status 200 301 500- 400-403 ... # status code in reply | |
559 | ||
375eeb3b | 560 | acl aclname browser [-i] regexp ... |
41bd17a4 | 561 | # pattern match on User-Agent header (see also req_header below) |
e988aa40 | 562 | |
375eeb3b | 563 | acl aclname referer_regex [-i] regexp ... |
41bd17a4 | 564 | # pattern match on Referer header |
565 | # Referer is highly unreliable, so use with care | |
e988aa40 | 566 | |
375eeb3b | 567 | acl aclname ident username ... |
41bd17a4 | 568 | acl aclname ident_regex [-i] pattern ... |
569 | # string match on ident output. | |
570 | # use REQUIRED to accept any non-null ident. | |
cf5cc17e | 571 | |
41bd17a4 | 572 | acl aclname proxy_auth [-i] username ... |
573 | acl aclname proxy_auth_regex [-i] pattern ... | |
574 | # list of valid usernames | |
575 | # use REQUIRED to accept any valid username. | |
576 | # | |
577 | # NOTE: when a Proxy-Authentication header is sent but it is not | |
578 | # needed during ACL checking the username is NOT logged | |
579 | # in access.log. | |
580 | # | |
581 | # NOTE: proxy_auth requires a EXTERNAL authentication program | |
582 | # to check username/password combinations (see | |
583 | # auth_param directive). | |
584 | # | |
e988aa40 AJ |
585 | # NOTE: proxy_auth can't be used in a transparent/intercepting proxy |
586 | # as the browser needs to be configured for using a proxy in order | |
41bd17a4 | 587 | # to respond to proxy authentication. |
8e8d4f30 | 588 | |
41bd17a4 | 589 | acl aclname snmp_community string ... |
590 | # A community string to limit access to your SNMP Agent | |
591 | # Example: | |
592 | # | |
593 | # acl snmppublic snmp_community public | |
934b03fc | 594 | |
41bd17a4 | 595 | acl aclname maxconn number |
596 | # This will be matched when the client's IP address has | |
597 | # more than <number> HTTP connections established. | |
1e5562e3 | 598 | |
41bd17a4 | 599 | acl aclname max_user_ip [-s] number |
600 | # This will be matched when the user attempts to log in from more | |
601 | # than <number> different ip addresses. The authenticate_ip_ttl | |
602 | # parameter controls the timeout on the ip entries. | |
603 | # If -s is specified the limit is strict, denying browsing | |
604 | # from any further IP addresses until the ttl has expired. Without | |
605 | # -s Squid will just annoy the user by "randomly" denying requests. | |
606 | # (the counter is reset each time the limit is reached and a | |
607 | # request is denied) | |
608 | # NOTE: in acceleration mode or where there is mesh of child proxies, | |
609 | # clients may appear to come from multiple addresses if they are | |
610 | # going through proxy farms, so a limit of 1 may cause user problems. | |
cccac0a2 | 611 | |
375eeb3b | 612 | acl aclname req_mime_type [-i] mime-type ... |
41bd17a4 | 613 | # regex match against the mime type of the request generated |
614 | # by the client. Can be used to detect file upload or some | |
615 | # types HTTP tunneling requests. | |
616 | # NOTE: This does NOT match the reply. You cannot use this | |
617 | # to match the returned file type. | |
cccac0a2 | 618 | |
41bd17a4 | 619 | acl aclname req_header header-name [-i] any\.regex\.here |
620 | # regex match against any of the known request headers. May be | |
621 | # thought of as a superset of "browser", "referer" and "mime-type" | |
622 | # ACLs. | |
cccac0a2 | 623 | |
375eeb3b | 624 | acl aclname rep_mime_type [-i] mime-type ... |
41bd17a4 | 625 | # regex match against the mime type of the reply received by |
626 | # squid. Can be used to detect file download or some | |
627 | # types HTTP tunneling requests. | |
628 | # NOTE: This has no effect in http_access rules. It only has | |
629 | # effect in rules that affect the reply data stream such as | |
630 | # http_reply_access. | |
cccac0a2 | 631 | |
41bd17a4 | 632 | acl aclname rep_header header-name [-i] any\.regex\.here |
633 | # regex match against any of the known reply headers. May be | |
634 | # thought of as a superset of "browser", "referer" and "mime-type" | |
635 | # ACLs. | |
cccac0a2 | 636 | |
375eeb3b | 637 | acl aclname external class_name [arguments...] |
41bd17a4 | 638 | # external ACL lookup via a helper class defined by the |
639 | # external_acl_type directive. | |
cccac0a2 | 640 | |
41bd17a4 | 641 | acl aclname user_cert attribute values... |
642 | # match against attributes in a user SSL certificate | |
643 | # attribute is one of DN/C/O/CN/L/ST | |
cccac0a2 | 644 | |
41bd17a4 | 645 | acl aclname ca_cert attribute values... |
646 | # match against attributes a users issuing CA SSL certificate | |
647 | # attribute is one of DN/C/O/CN/L/ST | |
cccac0a2 | 648 | |
41bd17a4 | 649 | acl aclname ext_user username ... |
650 | acl aclname ext_user_regex [-i] pattern ... | |
651 | # string match on username returned by external acl helper | |
652 | # use REQUIRED to accept any non-null user name. | |
0ab50441 HN |
653 | # |
654 | acl aclname tag tagvalue ... | |
655 | # string match on tag returned by external acl helper | |
cccac0a2 | 656 | |
41bd17a4 | 657 | Examples: |
658 | acl macaddress arp 09:00:2b:23:45:67 | |
659 | acl myexample dst_as 1241 | |
660 | acl password proxy_auth REQUIRED | |
661 | acl fileupload req_mime_type -i ^multipart/form-data$ | |
662 | acl javascript rep_mime_type -i ^application/x-javascript$ | |
cccac0a2 | 663 | |
41bd17a4 | 664 | NOCOMMENT_START |
665 | #Recommended minimum configuration: | |
41bd17a4 | 666 | acl manager proto cache_object |
ee776778 | 667 | acl localhost src 127.0.0.1/32 |
41bd17a4 | 668 | acl to_localhost dst 127.0.0.0/8 |
ee776778 | 669 | # |
670 | # Example rule allowing access from your local networks. | |
671 | # Adapt to list your (internal) IP networks from where browsing | |
672 | # should be allowed | |
673 | acl localnet src 10.0.0.0/8 # RFC1918 possible internal network | |
674 | acl localnet src 172.16.0.0/12 # RFC1918 possible internal network | |
675 | acl localnet src 192.168.0.0/16 # RFC1918 possible internal network | |
676 | # | |
41bd17a4 | 677 | acl SSL_ports port 443 |
678 | acl Safe_ports port 80 # http | |
679 | acl Safe_ports port 21 # ftp | |
680 | acl Safe_ports port 443 # https | |
681 | acl Safe_ports port 70 # gopher | |
682 | acl Safe_ports port 210 # wais | |
683 | acl Safe_ports port 1025-65535 # unregistered ports | |
684 | acl Safe_ports port 280 # http-mgmt | |
685 | acl Safe_ports port 488 # gss-http | |
686 | acl Safe_ports port 591 # filemaker | |
687 | acl Safe_ports port 777 # multiling http | |
688 | acl CONNECT method CONNECT | |
689 | NOCOMMENT_END | |
690 | DOC_END | |
cccac0a2 | 691 | |
3d674977 AJ |
692 | NAME: follow_x_forwarded_for |
693 | TYPE: acl_access | |
694 | IFDEF: FOLLOW_X_FORWARDED_FOR | |
695 | LOC: Config.accessList.followXFF | |
696 | DEFAULT: none | |
697 | DEFAULT_IF_NONE: deny all | |
698 | DOC_START | |
699 | Allowing or Denying the X-Forwarded-For header to be followed to | |
700 | find the original source of a request. | |
701 | ||
702 | Requests may pass through a chain of several other proxies | |
703 | before reaching us. The X-Forwarded-For header will contain a | |
704 | comma-separated list of the IP addresses in the chain, with the | |
705 | rightmost address being the most recent. | |
706 | ||
707 | If a request reaches us from a source that is allowed by this | |
708 | configuration item, then we consult the X-Forwarded-For header | |
709 | to see where that host received the request from. If the | |
710 | X-Forwarded-For header contains multiple addresses, and if | |
711 | acl_uses_indirect_client is on, then we continue backtracking | |
712 | until we reach an address for which we are not allowed to | |
713 | follow the X-Forwarded-For header, or until we reach the first | |
714 | address in the list. (If acl_uses_indirect_client is off, then | |
715 | it's impossible to backtrack through more than one level of | |
716 | X-Forwarded-For addresses.) | |
717 | ||
718 | The end result of this process is an IP address that we will | |
719 | refer to as the indirect client address. This address may | |
720 | be treated as the client address for access control, delay | |
721 | pools and logging, depending on the acl_uses_indirect_client, | |
722 | delay_pool_uses_indirect_client and log_uses_indirect_client | |
723 | options. | |
724 | ||
725 | SECURITY CONSIDERATIONS: | |
726 | ||
727 | Any host for which we follow the X-Forwarded-For header | |
728 | can place incorrect information in the header, and Squid | |
729 | will use the incorrect information as if it were the | |
730 | source address of the request. This may enable remote | |
731 | hosts to bypass any access control restrictions that are | |
732 | based on the client's source addresses. | |
733 | ||
734 | For example: | |
735 | ||
736 | acl localhost src 127.0.0.1 | |
737 | acl my_other_proxy srcdomain .proxy.example.com | |
738 | follow_x_forwarded_for allow localhost | |
739 | follow_x_forwarded_for allow my_other_proxy | |
740 | DOC_END | |
741 | ||
742 | NAME: acl_uses_indirect_client | |
743 | COMMENT: on|off | |
744 | TYPE: onoff | |
745 | IFDEF: FOLLOW_X_FORWARDED_FOR | |
746 | DEFAULT: on | |
747 | LOC: Config.onoff.acl_uses_indirect_client | |
748 | DOC_START | |
749 | Controls whether the indirect client address | |
750 | (see follow_x_forwarded_for) is used instead of the | |
751 | direct client address in acl matching. | |
752 | DOC_END | |
753 | ||
754 | NAME: delay_pool_uses_indirect_client | |
755 | COMMENT: on|off | |
756 | TYPE: onoff | |
97a616ca | 757 | IFDEF: FOLLOW_X_FORWARDED_FOR DELAY_POOLS |
3d674977 AJ |
758 | DEFAULT: on |
759 | LOC: Config.onoff.delay_pool_uses_indirect_client | |
760 | DOC_START | |
761 | Controls whether the indirect client address | |
762 | (see follow_x_forwarded_for) is used instead of the | |
763 | direct client address in delay pools. | |
764 | DOC_END | |
765 | ||
766 | NAME: log_uses_indirect_client | |
767 | COMMENT: on|off | |
768 | TYPE: onoff | |
769 | IFDEF: FOLLOW_X_FORWARDED_FOR | |
770 | DEFAULT: on | |
771 | LOC: Config.onoff.log_uses_indirect_client | |
772 | DOC_START | |
773 | Controls whether the indirect client address | |
774 | (see follow_x_forwarded_for) is used instead of the | |
775 | direct client address in the access log. | |
776 | DOC_END | |
777 | ||
41bd17a4 | 778 | NAME: http_access |
779 | TYPE: acl_access | |
780 | LOC: Config.accessList.http | |
781 | DEFAULT: none | |
782 | DEFAULT_IF_NONE: deny all | |
783 | DOC_START | |
784 | Allowing or Denying access based on defined access lists | |
cccac0a2 | 785 | |
41bd17a4 | 786 | Access to the HTTP port: |
787 | http_access allow|deny [!]aclname ... | |
cccac0a2 | 788 | |
41bd17a4 | 789 | NOTE on default values: |
cccac0a2 | 790 | |
41bd17a4 | 791 | If there are no "access" lines present, the default is to deny |
792 | the request. | |
cccac0a2 | 793 | |
41bd17a4 | 794 | If none of the "access" lines cause a match, the default is the |
795 | opposite of the last line in the list. If the last line was | |
796 | deny, the default is allow. Conversely, if the last line | |
797 | is allow, the default will be deny. For these reasons, it is a | |
798 | good idea to have an "deny all" or "allow all" entry at the end | |
799 | of your access lists to avoid potential confusion. | |
cccac0a2 | 800 | |
41bd17a4 | 801 | NOCOMMENT_START |
802 | #Recommended minimum configuration: | |
803 | # | |
804 | # Only allow cachemgr access from localhost | |
805 | http_access allow manager localhost | |
806 | http_access deny manager | |
807 | # Deny requests to unknown ports | |
808 | http_access deny !Safe_ports | |
809 | # Deny CONNECT to other than SSL ports | |
810 | http_access deny CONNECT !SSL_ports | |
811 | # | |
812 | # We strongly recommend the following be uncommented to protect innocent | |
813 | # web applications running on the proxy server who think the only | |
814 | # one who can access services on "localhost" is a local user | |
815 | #http_access deny to_localhost | |
816 | # | |
817 | # INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS | |
c8f4eac4 | 818 | |
ee776778 | 819 | # Example rule allowing access from your local networks. |
820 | # Adapt localnet in the ACL section to list your (internal) IP networks | |
821 | # from where browsing should be allowed | |
822 | http_access allow localnet | |
7d90757b | 823 | |
41bd17a4 | 824 | # And finally deny all other access to this proxy |
825 | http_access deny all | |
826 | NOCOMMENT_END | |
827 | DOC_END | |
7d90757b | 828 | |
41bd17a4 | 829 | NAME: http_reply_access |
830 | TYPE: acl_access | |
831 | LOC: Config.accessList.reply | |
832 | DEFAULT: none | |
833 | DOC_START | |
834 | Allow replies to client requests. This is complementary to http_access. | |
cccac0a2 | 835 | |
41bd17a4 | 836 | http_reply_access allow|deny [!] aclname ... |
cccac0a2 | 837 | |
41bd17a4 | 838 | NOTE: if there are no access lines present, the default is to allow |
839 | all replies | |
1a224843 | 840 | |
41bd17a4 | 841 | If none of the access lines cause a match the opposite of the |
842 | last line will apply. Thus it is good practice to end the rules | |
843 | with an "allow all" or "deny all" entry. | |
cccac0a2 | 844 | DOC_END |
845 | ||
41bd17a4 | 846 | NAME: icp_access |
847 | TYPE: acl_access | |
848 | LOC: Config.accessList.icp | |
849 | DEFAULT: none | |
850 | DEFAULT_IF_NONE: deny all | |
5473c134 | 851 | DOC_START |
41bd17a4 | 852 | Allowing or Denying access to the ICP port based on defined |
853 | access lists | |
5473c134 | 854 | |
41bd17a4 | 855 | icp_access allow|deny [!]aclname ... |
5473c134 | 856 | |
41bd17a4 | 857 | See http_access for details |
858 | ||
859 | NOCOMMENT_START | |
ee776778 | 860 | #Allow ICP queries from local networks only |
df2eec10 AJ |
861 | #icp_access allow localnet |
862 | #icp_access deny all | |
41bd17a4 | 863 | NOCOMMENT_END |
5473c134 | 864 | DOC_END |
865 | ||
41bd17a4 | 866 | NAME: htcp_access |
867 | IFDEF: USE_HTCP | |
868 | TYPE: acl_access | |
869 | LOC: Config.accessList.htcp | |
870 | DEFAULT: none | |
871 | DEFAULT_IF_NONE: deny all | |
5473c134 | 872 | DOC_START |
41bd17a4 | 873 | Allowing or Denying access to the HTCP port based on defined |
874 | access lists | |
5473c134 | 875 | |
41bd17a4 | 876 | htcp_access allow|deny [!]aclname ... |
5473c134 | 877 | |
41bd17a4 | 878 | See http_access for details |
5473c134 | 879 | |
0b48417e | 880 | NOTE: The default if no htcp_access lines are present is to |
881 | deny all traffic. This default may cause problems with peers | |
882 | using the htcp or htcp-oldsquid options. | |
883 | ||
ee776778 | 884 | NOCOMMENT_START |
885 | #Allow HTCP queries from local networks only | |
df2eec10 AJ |
886 | #htcp_access allow localnet |
887 | #htcp_access deny all | |
ee776778 | 888 | NOCOMMENT_END |
41bd17a4 | 889 | DOC_END |
5473c134 | 890 | |
41bd17a4 | 891 | NAME: htcp_clr_access |
892 | IFDEF: USE_HTCP | |
893 | TYPE: acl_access | |
894 | LOC: Config.accessList.htcp_clr | |
895 | DEFAULT: none | |
896 | DEFAULT_IF_NONE: deny all | |
897 | DOC_START | |
898 | Allowing or Denying access to purge content using HTCP based | |
899 | on defined access lists | |
5473c134 | 900 | |
41bd17a4 | 901 | htcp_clr_access allow|deny [!]aclname ... |
5473c134 | 902 | |
41bd17a4 | 903 | See http_access for details |
5473c134 | 904 | |
41bd17a4 | 905 | #Allow HTCP CLR requests from trusted peers |
906 | acl htcp_clr_peer src 172.16.1.2 | |
907 | htcp_clr_access allow htcp_clr_peer | |
5473c134 | 908 | DOC_END |
909 | ||
41bd17a4 | 910 | NAME: miss_access |
911 | TYPE: acl_access | |
912 | LOC: Config.accessList.miss | |
df2eec10 | 913 | DEFAULT: allow all |
5473c134 | 914 | DOC_START |
41bd17a4 | 915 | Use to force your neighbors to use you as a sibling instead of |
916 | a parent. For example: | |
5473c134 | 917 | |
41bd17a4 | 918 | acl localclients src 172.16.0.0/16 |
919 | miss_access allow localclients | |
920 | miss_access deny !localclients | |
5473c134 | 921 | |
41bd17a4 | 922 | This means only your local clients are allowed to fetch |
923 | MISSES and all other clients can only fetch HITS. | |
5473c134 | 924 | |
41bd17a4 | 925 | By default, allow all clients who passed the http_access rules |
926 | to fetch MISSES from us. | |
41bd17a4 | 927 | DOC_END |
928 | ||
929 | NAME: ident_lookup_access | |
930 | TYPE: acl_access | |
931 | IFDEF: USE_IDENT | |
932 | DEFAULT: none | |
933 | DEFAULT_IF_NONE: deny all | |
4daaf3cb | 934 | LOC: Ident::TheConfig.identLookup |
5473c134 | 935 | DOC_START |
41bd17a4 | 936 | A list of ACL elements which, if matched, cause an ident |
937 | (RFC 931) lookup to be performed for this request. For | |
938 | example, you might choose to always perform ident lookups | |
939 | for your main multi-user Unix boxes, but not for your Macs | |
940 | and PCs. By default, ident lookups are not performed for | |
941 | any requests. | |
5473c134 | 942 | |
41bd17a4 | 943 | To enable ident lookups for specific client addresses, you |
944 | can follow this example: | |
5473c134 | 945 | |
4daaf3cb | 946 | acl ident_aware_hosts src 198.168.1.0/24 |
41bd17a4 | 947 | ident_lookup_access allow ident_aware_hosts |
948 | ident_lookup_access deny all | |
5473c134 | 949 | |
4daaf3cb | 950 | Only src type ACL checks are fully supported. A srcdomain |
41bd17a4 | 951 | ACL might work at times, but it will not always provide |
952 | the correct result. | |
953 | DOC_END | |
5473c134 | 954 | |
5b0f5383 | 955 | NAME: reply_body_max_size |
956 | COMMENT: size [acl acl...] | |
957 | TYPE: acl_b_size_t | |
958 | DEFAULT: none | |
959 | LOC: Config.ReplyBodySize | |
960 | DOC_START | |
961 | This option specifies the maximum size of a reply body. It can be | |
962 | used to prevent users from downloading very large files, such as | |
963 | MP3's and movies. When the reply headers are received, the | |
964 | reply_body_max_size lines are processed, and the first line where | |
965 | all (if any) listed ACLs are true is used as the maximum body size | |
966 | for this reply. | |
967 | ||
968 | This size is checked twice. First when we get the reply headers, | |
969 | we check the content-length value. If the content length value exists | |
970 | and is larger than the allowed size, the request is denied and the | |
971 | user receives an error message that says "the request or reply | |
972 | is too large." If there is no content-length, and the reply | |
973 | size exceeds this limit, the client's connection is just closed | |
974 | and they will receive a partial reply. | |
975 | ||
976 | WARNING: downstream caches probably can not detect a partial reply | |
977 | if there is no content-length header, so they will cache | |
978 | partial responses and give them out as hits. You should NOT | |
979 | use this option if you have downstream caches. | |
980 | ||
981 | WARNING: A maximum size smaller than the size of squid's error messages | |
982 | will cause an infinite loop and crash squid. Ensure that the smallest | |
983 | non-zero value you use is greater that the maximum header size plus | |
984 | the size of your largest error page. | |
985 | ||
986 | If you set this parameter none (the default), there will be | |
987 | no limit imposed. | |
3bc32f2f AJ |
988 | |
989 | Configuration Format is: | |
990 | reply_body_max_size SIZE UNITS [acl ...] | |
991 | ie. | |
992 | reply_body_max_size 10 MB | |
993 | ||
5b0f5383 | 994 | DOC_END |
995 | ||
996 | COMMENT_START | |
997 | NETWORK OPTIONS | |
998 | ----------------------------------------------------------------------------- | |
999 | COMMENT_END | |
1000 | ||
1001 | NAME: http_port ascii_port | |
1002 | TYPE: http_port_list | |
1003 | DEFAULT: none | |
1004 | LOC: Config.Sockaddr.http | |
1005 | DOC_START | |
1006 | Usage: port [options] | |
1007 | hostname:port [options] | |
1008 | 1.2.3.4:port [options] | |
1009 | ||
1010 | The socket addresses where Squid will listen for HTTP client | |
1011 | requests. You may specify multiple socket addresses. | |
1012 | There are three forms: port alone, hostname with port, and | |
1013 | IP address with port. If you specify a hostname or IP | |
1014 | address, Squid binds the socket to that specific | |
1015 | address. This replaces the old 'tcp_incoming_address' | |
1016 | option. Most likely, you do not need to bind to a specific | |
1017 | address, so you can use the port number alone. | |
1018 | ||
1019 | If you are running Squid in accelerator mode, you | |
1020 | probably want to listen on port 80 also, or instead. | |
1021 | ||
1022 | The -a command line option may be used to specify additional | |
1023 | port(s) where Squid listens for proxy request. Such ports will | |
1024 | be plain proxy ports with no options. | |
1025 | ||
1026 | You may specify multiple socket addresses on multiple lines. | |
1027 | ||
1028 | Options: | |
1029 | ||
e77bdb4e | 1030 | intercept Support for IP-Layer interception of |
5b0f5383 | 1031 | outgoing requests without browser settings. |
13b5cd0c | 1032 | NP: disables authentication and IPv6 on the port. |
5b0f5383 | 1033 | |
1034 | tproxy Support Linux TPROXY for spoofing outgoing | |
1035 | connections using the client IP address. | |
13b5cd0c | 1036 | NP: disables authentication and IPv6 on the port. |
5b0f5383 | 1037 | |
1038 | accel Accelerator mode. Also needs at least one of | |
1039 | vhost / vport / defaultsite. | |
1040 | ||
1041 | defaultsite=domainname | |
1042 | What to use for the Host: header if it is not present | |
1043 | in a request. Determines what site (not origin server) | |
1044 | accelerators should consider the default. | |
1045 | Implies accel. | |
1046 | ||
1047 | vhost Accelerator mode using Host header for virtual | |
1048 | domain support. Implies accel. | |
1049 | ||
1050 | vport Accelerator with IP based virtual host support. | |
1051 | Implies accel. | |
1052 | ||
1053 | vport=NN As above, but uses specified port number rather | |
1054 | than the http_port number. Implies accel. | |
1055 | ||
1056 | protocol= Protocol to reconstruct accelerated requests with. | |
1057 | Defaults to http. | |
1058 | ||
d67acb4e AJ |
1059 | connection-auth[=on|off] |
1060 | use connection-auth=off to tell Squid to prevent | |
1061 | forwarding Microsoft connection oriented authentication | |
1062 | (NTLM, Negotiate and Kerberos) | |
1063 | ||
5b0f5383 | 1064 | disable-pmtu-discovery= |
1065 | Control Path-MTU discovery usage: | |
1066 | off lets OS decide on what to do (default). | |
1067 | transparent disable PMTU discovery when transparent | |
1068 | support is enabled. | |
1069 | always disable always PMTU discovery. | |
1070 | ||
1071 | In many setups of transparently intercepting proxies | |
1072 | Path-MTU discovery can not work on traffic towards the | |
1073 | clients. This is the case when the intercepting device | |
1074 | does not fully track connections and fails to forward | |
1075 | ICMP must fragment messages to the cache server. If you | |
1076 | have such setup and experience that certain clients | |
1077 | sporadically hang or never complete requests set | |
1078 | disable-pmtu-discovery option to 'transparent'. | |
1079 | ||
4c9da963 | 1080 | sslBump Intercept each CONNECT request matching ssl_bump ACL, |
1081 | establish secure connection with the client and with | |
1082 | the server, decrypt HTTP messages as they pass through | |
1083 | Squid, and treat them as unencrypted HTTP messages, | |
1084 | becoming the man-in-the-middle. | |
1085 | ||
1086 | When this option is enabled, additional options become | |
1087 | available to specify SSL-related properties of the | |
1088 | client-side connection: cert, key, version, cipher, | |
1089 | options, clientca, cafile, capath, crlfile, dhparams, | |
1090 | sslflags, and sslcontext. See the https_port directive | |
1091 | for more information on these options. | |
1092 | ||
1093 | The ssl_bump option is required to fully enable | |
1094 | the SslBump feature. | |
1095 | ||
81b6e9a7 | 1096 | name= Specifies a internal name for the port. Defaults to |
1097 | the port specification (port or addr:port) | |
1098 | ||
68924b6d | 1099 | tcpkeepalive[=idle,interval,timeout] |
b2130d58 | 1100 | Enable TCP keepalive probes of idle connections |
1101 | idle is the initial time before TCP starts probing | |
1102 | the connection, interval how often to probe, and | |
1103 | timeout the time before giving up. | |
1104 | ||
5b0f5383 | 1105 | If you run Squid on a dual-homed machine with an internal |
1106 | and an external interface we recommend you to specify the | |
1107 | internal address:port in http_port. This way Squid will only be | |
1108 | visible on the internal address. | |
1109 | ||
1110 | NOCOMMENT_START | |
1111 | # Squid normally listens to port 3128 | |
1112 | http_port @DEFAULT_HTTP_PORT@ | |
1113 | NOCOMMENT_END | |
1114 | DOC_END | |
1115 | ||
1116 | NAME: https_port | |
1117 | IFDEF: USE_SSL | |
1118 | TYPE: https_port_list | |
1119 | DEFAULT: none | |
1120 | LOC: Config.Sockaddr.https | |
1121 | DOC_START | |
1122 | Usage: [ip:]port cert=certificate.pem [key=key.pem] [options...] | |
1123 | ||
1124 | The socket address where Squid will listen for HTTPS client | |
1125 | requests. | |
1126 | ||
1127 | This is really only useful for situations where you are running | |
1128 | squid in accelerator mode and you want to do the SSL work at the | |
1129 | accelerator level. | |
1130 | ||
1131 | You may specify multiple socket addresses on multiple lines, | |
1132 | each with their own SSL certificate and/or options. | |
1133 | ||
1134 | Options: | |
1135 | ||
1136 | accel Accelerator mode. Also needs at least one of | |
1137 | defaultsite or vhost. | |
1138 | ||
1139 | defaultsite= The name of the https site presented on | |
1140 | this port. Implies accel. | |
1141 | ||
1142 | vhost Accelerator mode using Host header for virtual | |
1143 | domain support. Requires a wildcard certificate | |
1144 | or other certificate valid for more than one domain. | |
1145 | Implies accel. | |
1146 | ||
1147 | protocol= Protocol to reconstruct accelerated requests with. | |
1148 | Defaults to https. | |
1149 | ||
1150 | cert= Path to SSL certificate (PEM format). | |
1151 | ||
1152 | key= Path to SSL private key file (PEM format) | |
1153 | if not specified, the certificate file is | |
1154 | assumed to be a combined certificate and | |
1155 | key file. | |
1156 | ||
1157 | version= The version of SSL/TLS supported | |
1158 | 1 automatic (default) | |
1159 | 2 SSLv2 only | |
1160 | 3 SSLv3 only | |
1161 | 4 TLSv1 only | |
1162 | ||
1163 | cipher= Colon separated list of supported ciphers. | |
1164 | ||
1165 | options= Various SSL engine options. The most important | |
1166 | being: | |
1167 | NO_SSLv2 Disallow the use of SSLv2 | |
1168 | NO_SSLv3 Disallow the use of SSLv3 | |
1169 | NO_TLSv1 Disallow the use of TLSv1 | |
1170 | SINGLE_DH_USE Always create a new key when using | |
1171 | temporary/ephemeral DH key exchanges | |
1172 | See src/ssl_support.c or OpenSSL SSL_CTX_set_options | |
1173 | documentation for a complete list of options. | |
1174 | ||
1175 | clientca= File containing the list of CAs to use when | |
1176 | requesting a client certificate. | |
1177 | ||
1178 | cafile= File containing additional CA certificates to | |
1179 | use when verifying client certificates. If unset | |
1180 | clientca will be used. | |
1181 | ||
1182 | capath= Directory containing additional CA certificates | |
1183 | and CRL lists to use when verifying client certificates. | |
1184 | ||
1185 | crlfile= File of additional CRL lists to use when verifying | |
1186 | the client certificate, in addition to CRLs stored in | |
1187 | the capath. Implies VERIFY_CRL flag below. | |
1188 | ||
1189 | dhparams= File containing DH parameters for temporary/ephemeral | |
1190 | DH key exchanges. | |
1191 | ||
1192 | sslflags= Various flags modifying the use of SSL: | |
1193 | DELAYED_AUTH | |
1194 | Don't request client certificates | |
1195 | immediately, but wait until acl processing | |
1196 | requires a certificate (not yet implemented). | |
1197 | NO_DEFAULT_CA | |
1198 | Don't use the default CA lists built in | |
1199 | to OpenSSL. | |
1200 | NO_SESSION_REUSE | |
1201 | Don't allow for session reuse. Each connection | |
1202 | will result in a new SSL session. | |
1203 | VERIFY_CRL | |
1204 | Verify CRL lists when accepting client | |
1205 | certificates. | |
1206 | VERIFY_CRL_ALL | |
1207 | Verify CRL lists for all certificates in the | |
1208 | client certificate chain. | |
1209 | ||
1210 | sslcontext= SSL session ID context identifier. | |
1211 | ||
1212 | vport Accelerator with IP based virtual host support. | |
1213 | ||
1214 | vport=NN As above, but uses specified port number rather | |
1215 | than the https_port number. Implies accel. | |
1216 | ||
81b6e9a7 | 1217 | name= Specifies a internal name for the port. Defaults to |
1218 | the port specification (port or addr:port) | |
1219 | ||
5b0f5383 | 1220 | DOC_END |
1221 | ||
41bd17a4 | 1222 | NAME: tcp_outgoing_tos tcp_outgoing_ds tcp_outgoing_dscp |
1223 | TYPE: acl_tos | |
5473c134 | 1224 | DEFAULT: none |
41bd17a4 | 1225 | LOC: Config.accessList.outgoing_tos |
5473c134 | 1226 | DOC_START |
41bd17a4 | 1227 | Allows you to select a TOS/Diffserv value to mark outgoing |
1228 | connections with, based on the username or source address | |
1229 | making the request. | |
5473c134 | 1230 | |
41bd17a4 | 1231 | tcp_outgoing_tos ds-field [!]aclname ... |
cccac0a2 | 1232 | |
41bd17a4 | 1233 | Example where normal_service_net uses the TOS value 0x00 |
7def7206 | 1234 | and good_service_net uses 0x20 |
cccac0a2 | 1235 | |
41bd17a4 | 1236 | acl normal_service_net src 10.0.0.0/255.255.255.0 |
1237 | acl good_service_net src 10.0.1.0/255.255.255.0 | |
2c73de90 | 1238 | tcp_outgoing_tos 0x00 normal_service_net |
41bd17a4 | 1239 | tcp_outgoing_tos 0x20 good_service_net |
fa38076e | 1240 | |
41bd17a4 | 1241 | TOS/DSCP values really only have local significance - so you should |
575cb927 AJ |
1242 | know what you're specifying. For more information, see RFC2474, |
1243 | RFC2475, and RFC3260. | |
cccac0a2 | 1244 | |
41bd17a4 | 1245 | The TOS/DSCP byte must be exactly that - a octet value 0 - 255, or |
1246 | "default" to use whatever default your host has. Note that in | |
1247 | practice often only values 0 - 63 is usable as the two highest bits | |
1248 | have been redefined for use by ECN (RFC3168). | |
cccac0a2 | 1249 | |
41bd17a4 | 1250 | Processing proceeds in the order specified, and stops at first fully |
1251 | matching line. | |
cccac0a2 | 1252 | |
41bd17a4 | 1253 | Note: The use of this directive using client dependent ACLs is |
1254 | incompatible with the use of server side persistent connections. To | |
1255 | ensure correct results it is best to set server_persisten_connections | |
1256 | to off when using this directive in such configurations. | |
cccac0a2 | 1257 | DOC_END |
1258 | ||
41bd17a4 | 1259 | NAME: clientside_tos |
1260 | TYPE: acl_tos | |
cccac0a2 | 1261 | DEFAULT: none |
41bd17a4 | 1262 | LOC: Config.accessList.clientside_tos |
cccac0a2 | 1263 | DOC_START |
41bd17a4 | 1264 | Allows you to select a TOS/Diffserv value to mark client-side |
1265 | connections with, based on the username or source address | |
1266 | making the request. | |
1267 | DOC_END | |
cccac0a2 | 1268 | |
575cb927 AJ |
1269 | NAME: qos_flows |
1270 | TYPE: QosConfig | |
7172612f | 1271 | IFDEF: USE_ZPH_QOS |
575cb927 AJ |
1272 | DEFAULT: none |
1273 | LOC: Config.zph | |
7172612f | 1274 | DOC_START |
575cb927 AJ |
1275 | Allows you to select a TOS/DSCP value to mark outgoing |
1276 | connections with, based on where the reply was sourced. | |
7172612f | 1277 | |
575cb927 AJ |
1278 | TOS values really only have local significance - so you should |
1279 | know what you're specifying. For more information, see RFC2474, | |
1280 | RFC2475, and RFC3260. | |
7172612f | 1281 | |
575cb927 AJ |
1282 | The TOS/DSCP byte must be exactly that - octet value 0x00-0xFF. |
1283 | Note that in practice often only values up to 0x3F are usable | |
1284 | as the two highest bits have been redefined for use by ECN | |
1285 | (RFC3168). | |
7172612f | 1286 | |
575cb927 AJ |
1287 | This setting is configured by setting the source TOS values: |
1288 | ||
1289 | local-hit=0xFF Value to mark local cache hits. | |
1290 | ||
1291 | sibling-hit=0xFF Value to mark hits from sibling peers. | |
1292 | ||
1293 | parent-hit=0xFF Value to mark hits from parent peers. | |
1294 | ||
1295 | ||
2201bec6 AJ |
1296 | NOTE: 'miss' preserve feature is only possible on Linux at this time. |
1297 | ||
575cb927 AJ |
1298 | For the following to work correctly, you will need to patch your |
1299 | linux kernel with the TOS preserving ZPH patch. | |
1300 | The kernel patch can be downloaded from http://zph.bratcheda.org | |
1301 | ||
575cb927 AJ |
1302 | disable-preserve-miss |
1303 | If set, any HTTP response towards clients will | |
1304 | have the TOS value of the response comming from the | |
1305 | remote server masked with the value of miss-mask. | |
1306 | ||
1307 | miss-mask=0xFF | |
1308 | Allows you to mask certain bits in the TOS received from the | |
1309 | remote server, before copying the value to the TOS sent | |
1310 | towards clients. | |
1311 | Default: 0xFF (TOS from server is not changed). | |
7172612f | 1312 | |
7172612f AJ |
1313 | DOC_END |
1314 | ||
41bd17a4 | 1315 | NAME: tcp_outgoing_address |
1316 | TYPE: acl_address | |
1317 | DEFAULT: none | |
1318 | LOC: Config.accessList.outgoing_address | |
1319 | DOC_START | |
1320 | Allows you to map requests to different outgoing IP addresses | |
1321 | based on the username or source address of the user making | |
1322 | the request. | |
7f7db318 | 1323 | |
41bd17a4 | 1324 | tcp_outgoing_address ipaddr [[!]aclname] ... |
c33aa074 | 1325 | |
41bd17a4 | 1326 | Example where requests from 10.0.0.0/24 will be forwarded |
1327 | with source address 10.1.0.1, 10.0.2.0/24 forwarded with | |
1328 | source address 10.1.0.2 and the rest will be forwarded with | |
1329 | source address 10.1.0.3. | |
9197cd13 | 1330 | |
17148b2f | 1331 | acl normal_service_net src 10.0.0.0/24 |
1332 | acl good_service_net src 10.0.2.0/24 | |
1333 | tcp_outgoing_address 10.1.0.1 normal_service_net | |
1334 | tcp_outgoing_address 10.1.0.2 good_service_net | |
1335 | tcp_outgoing_address 10.1.0.3 | |
9197cd13 | 1336 | |
41bd17a4 | 1337 | Processing proceeds in the order specified, and stops at first fully |
1338 | matching line. | |
cccac0a2 | 1339 | |
41bd17a4 | 1340 | Note: The use of this directive using client dependent ACLs is |
1341 | incompatible with the use of server side persistent connections. To | |
1342 | ensure correct results it is best to set server_persistent_connections | |
1343 | to off when using this directive in such configurations. | |
cc192b50 | 1344 | |
1345 | ||
1346 | IPv6 Magic: | |
1347 | ||
1348 | Squid is built with a capability of bridging the IPv4 and IPv6 internets. | |
1349 | tcp_outgoing_address as exampled above breaks this bridging by forcing | |
1350 | all outbound traffic through a certain IPv4 which may be on the wrong | |
1351 | side of the IPv4/IPv6 boundary. | |
1352 | ||
1353 | To operate with tcp_outgoing_address and keep the bridging benefits | |
1354 | an additional ACL needs to be used which ensures the IPv6-bound traffic | |
1355 | is never forced or permitted out the IPv4 interface. | |
1356 | ||
1357 | acl to_ipv6 dst ipv6 | |
1358 | tcp_outgoing_address 2002::c001 good_service_net to_ipv6 | |
17148b2f | 1359 | tcp_outgoing_address 10.1.0.2 good_service_net !to_ipv6 |
cc192b50 | 1360 | |
1361 | tcp_outgoing_address 2002::beef normal_service_net to_ipv6 | |
17148b2f | 1362 | tcp_outgoing_address 10.1.0.1 normal_service_net !to_ipv6 |
cc192b50 | 1363 | |
1364 | tcp_outgoing_address 2002::1 to_ipv6 | |
17148b2f | 1365 | tcp_outgoing_address 10.1.0.3 !to_ipv6 |
6db78a1a AJ |
1366 | |
1367 | WARNING: | |
1368 | 'dst ipv6' bases its selection assuming DIRECT access. | |
1369 | If peers are used the peername ACL are needed to select outgoing | |
1370 | address which can link to the peer. | |
1371 | ||
cccac0a2 | 1372 | DOC_END |
1373 | ||
41bd17a4 | 1374 | COMMENT_START |
1375 | SSL OPTIONS | |
1376 | ----------------------------------------------------------------------------- | |
1377 | COMMENT_END | |
1378 | ||
1379 | NAME: ssl_unclean_shutdown | |
1380 | IFDEF: USE_SSL | |
cccac0a2 | 1381 | TYPE: onoff |
1382 | DEFAULT: off | |
41bd17a4 | 1383 | LOC: Config.SSL.unclean_shutdown |
cccac0a2 | 1384 | DOC_START |
41bd17a4 | 1385 | Some browsers (especially MSIE) bugs out on SSL shutdown |
1386 | messages. | |
cccac0a2 | 1387 | DOC_END |
1388 | ||
41bd17a4 | 1389 | NAME: ssl_engine |
1390 | IFDEF: USE_SSL | |
cccac0a2 | 1391 | TYPE: string |
41bd17a4 | 1392 | LOC: Config.SSL.ssl_engine |
1393 | DEFAULT: none | |
cccac0a2 | 1394 | DOC_START |
41bd17a4 | 1395 | The OpenSSL engine to use. You will need to set this if you |
1396 | would like to use hardware SSL acceleration for example. | |
cccac0a2 | 1397 | DOC_END |
1398 | ||
41bd17a4 | 1399 | NAME: sslproxy_client_certificate |
1400 | IFDEF: USE_SSL | |
cccac0a2 | 1401 | DEFAULT: none |
41bd17a4 | 1402 | LOC: Config.ssl_client.cert |
1403 | TYPE: string | |
cccac0a2 | 1404 | DOC_START |
41bd17a4 | 1405 | Client SSL Certificate to use when proxying https:// URLs |
cccac0a2 | 1406 | DOC_END |
1407 | ||
41bd17a4 | 1408 | NAME: sslproxy_client_key |
1409 | IFDEF: USE_SSL | |
cccac0a2 | 1410 | DEFAULT: none |
41bd17a4 | 1411 | LOC: Config.ssl_client.key |
1412 | TYPE: string | |
cccac0a2 | 1413 | DOC_START |
41bd17a4 | 1414 | Client SSL Key to use when proxying https:// URLs |
cccac0a2 | 1415 | DOC_END |
1416 | ||
41bd17a4 | 1417 | NAME: sslproxy_version |
1418 | IFDEF: USE_SSL | |
1419 | DEFAULT: 1 | |
1420 | LOC: Config.ssl_client.version | |
1421 | TYPE: int | |
cccac0a2 | 1422 | DOC_START |
41bd17a4 | 1423 | SSL version level to use when proxying https:// URLs |
cccac0a2 | 1424 | DOC_END |
1425 | ||
41bd17a4 | 1426 | NAME: sslproxy_options |
1427 | IFDEF: USE_SSL | |
1428 | DEFAULT: none | |
1429 | LOC: Config.ssl_client.options | |
1430 | TYPE: string | |
cccac0a2 | 1431 | DOC_START |
41bd17a4 | 1432 | SSL engine options to use when proxying https:// URLs |
cccac0a2 | 1433 | DOC_END |
1434 | ||
41bd17a4 | 1435 | NAME: sslproxy_cipher |
1436 | IFDEF: USE_SSL | |
1437 | DEFAULT: none | |
1438 | LOC: Config.ssl_client.cipher | |
1439 | TYPE: string | |
cccac0a2 | 1440 | DOC_START |
41bd17a4 | 1441 | SSL cipher list to use when proxying https:// URLs |
cccac0a2 | 1442 | DOC_END |
1443 | ||
41bd17a4 | 1444 | NAME: sslproxy_cafile |
1445 | IFDEF: USE_SSL | |
1446 | DEFAULT: none | |
1447 | LOC: Config.ssl_client.cafile | |
1448 | TYPE: string | |
cccac0a2 | 1449 | DOC_START |
41bd17a4 | 1450 | file containing CA certificates to use when verifying server |
1451 | certificates while proxying https:// URLs | |
cccac0a2 | 1452 | DOC_END |
0976f8db | 1453 | |
41bd17a4 | 1454 | NAME: sslproxy_capath |
1455 | IFDEF: USE_SSL | |
5473c134 | 1456 | DEFAULT: none |
41bd17a4 | 1457 | LOC: Config.ssl_client.capath |
1458 | TYPE: string | |
5473c134 | 1459 | DOC_START |
41bd17a4 | 1460 | directory containing CA certificates to use when verifying |
1461 | server certificates while proxying https:// URLs | |
5473c134 | 1462 | DOC_END |
1463 | ||
4c9da963 | 1464 | NAME: ssl_bump |
1465 | IFDEF: USE_SSL | |
1466 | TYPE: acl_access | |
1467 | LOC: Config.accessList.ssl_bump | |
1468 | DEFAULT: none | |
1469 | DOC_START | |
1470 | This ACL controls which CONNECT requests to an http_port | |
1471 | marked with an sslBump flag are actually "bumped". Please | |
1472 | see the sslBump flag of an http_port option for more details | |
1473 | about decoding proxied SSL connections. | |
1474 | ||
1475 | By default, no requests are bumped. | |
1476 | ||
1477 | See also: http_port sslBump | |
1478 | ||
1479 | NOCOMMENT_START | |
1480 | # Example: Bump all requests except those originating from localhost and | |
1481 | # those going to webax.com or example.com sites. | |
1482 | # | |
1483 | # acl localhost src 127.0.0.1/32 | |
1484 | # acl broken_sites dstdomain .webax.com | |
1485 | # acl broken_sites dstdomain .example.com | |
1486 | # ssl_bump deny localhost | |
1487 | # ssl_bump deny broken_sites | |
1488 | # ssl_bump allow all | |
1489 | NOCOMMENT_END | |
1490 | DOC_END | |
1491 | ||
41bd17a4 | 1492 | NAME: sslproxy_flags |
1493 | IFDEF: USE_SSL | |
1494 | DEFAULT: none | |
1495 | LOC: Config.ssl_client.flags | |
1496 | TYPE: string | |
5473c134 | 1497 | DOC_START |
41bd17a4 | 1498 | Various flags modifying the use of SSL while proxying https:// URLs: |
4c9da963 | 1499 | DONT_VERIFY_PEER Accept certificates that fail verification. |
1500 | For refined control, see sslproxy_cert_error. | |
41bd17a4 | 1501 | NO_DEFAULT_CA Don't use the default CA list built in |
1502 | to OpenSSL. | |
5473c134 | 1503 | DOC_END |
1504 | ||
4c9da963 | 1505 | |
1506 | NAME: sslproxy_cert_error | |
1507 | IFDEF: USE_SSL | |
1508 | DEFAULT: none | |
1509 | LOC: Config.ssl_client.cert_error | |
1510 | TYPE: acl_access | |
1511 | DOC_START | |
1512 | Use this ACL to bypass server certificate validation errors. | |
1513 | ||
1514 | For example, the following lines will bypass all validation errors | |
1515 | when talking to servers located at 172.16.0.0/16. All other | |
1516 | validation errors will result in ERR_SECURE_CONNECT_FAIL error. | |
1517 | ||
1518 | acl BrokenServersAtTrustedIP dst 172.16.0.0/16 | |
1519 | sslproxy_cert_error allow BrokenServersAtTrustedIP | |
1520 | sslproxy_cert_error deny all | |
1521 | ||
1522 | This option must use fast ACL expressions only. Expressions that use | |
1523 | external lookups or communication result in unpredictable behavior or | |
1524 | crashes. | |
1525 | ||
1526 | Without this option, all server certificate validation errors | |
1527 | terminate the transaction. Bypassing validation errors is dangerous | |
1528 | because an error usually implies that the server cannot be trusted and | |
1529 | the connection may be insecure. | |
1530 | ||
1531 | See also: sslproxy_flags and DONT_VERIFY_PEER. | |
1532 | ||
1533 | NOCOMMENT_START | |
1534 | #Default setting: | |
1535 | # sslproxy_cert_error deny all | |
1536 | NOCOMMENT_END | |
1537 | DOC_END | |
1538 | ||
1539 | ||
1540 | ||
41bd17a4 | 1541 | NAME: sslpassword_program |
1542 | IFDEF: USE_SSL | |
1543 | DEFAULT: none | |
1544 | LOC: Config.Program.ssl_password | |
1545 | TYPE: string | |
5473c134 | 1546 | DOC_START |
41bd17a4 | 1547 | Specify a program used for entering SSL key passphrases |
1548 | when using encrypted SSL certificate keys. If not specified | |
1549 | keys must either be unencrypted, or Squid started with the -N | |
1550 | option to allow it to query interactively for the passphrase. | |
5473c134 | 1551 | DOC_END |
1552 | ||
cccac0a2 | 1553 | COMMENT_START |
41bd17a4 | 1554 | OPTIONS WHICH AFFECT THE NEIGHBOR SELECTION ALGORITHM |
cccac0a2 | 1555 | ----------------------------------------------------------------------------- |
1556 | COMMENT_END | |
1557 | ||
41bd17a4 | 1558 | NAME: cache_peer |
1559 | TYPE: peer | |
1560 | DEFAULT: none | |
1561 | LOC: Config.peers | |
cccac0a2 | 1562 | DOC_START |
41bd17a4 | 1563 | To specify other caches in a hierarchy, use the format: |
cccac0a2 | 1564 | |
41bd17a4 | 1565 | cache_peer hostname type http-port icp-port [options] |
cccac0a2 | 1566 | |
41bd17a4 | 1567 | For example, |
cccac0a2 | 1568 | |
41bd17a4 | 1569 | # proxy icp |
1570 | # hostname type port port options | |
1571 | # -------------------- -------- ----- ----- ----------- | |
1572 | cache_peer parent.foo.net parent 3128 3130 proxy-only default | |
1573 | cache_peer sib1.foo.net sibling 3128 3130 proxy-only | |
1574 | cache_peer sib2.foo.net sibling 3128 3130 proxy-only | |
cccac0a2 | 1575 | |
41bd17a4 | 1576 | type: either 'parent', 'sibling', or 'multicast'. |
d5277f40 | 1577 | |
41bd17a4 | 1578 | proxy-port: The port number where the cache listens for proxy |
1579 | requests. | |
8d6275c0 | 1580 | |
41bd17a4 | 1581 | icp-port: Used for querying neighbor caches about |
1582 | objects. To have a non-ICP neighbor | |
df2eec10 | 1583 | specify '0' for the ICP port. |
41bd17a4 | 1584 | NOTE: Also requires icp_port option enabled to send/receive |
1585 | requests via this method. | |
a78278e2 | 1586 | |
41bd17a4 | 1587 | options: proxy-only |
1588 | weight=n | |
1589 | basetime=n | |
1590 | ttl=n | |
1591 | no-query | |
1592 | background-ping | |
1593 | default | |
1594 | round-robin | |
1595 | weighted-round-robin | |
1596 | carp | |
f7e1d9ce HN |
1597 | userhash |
1598 | sourcehash | |
41bd17a4 | 1599 | multicast-responder |
1600 | closest-only | |
1601 | no-digest | |
1602 | no-netdb-exchange | |
1603 | no-delay | |
1604 | login=user:password | PASS | *:password | |
1605 | connect-timeout=nn | |
ff9970cc | 1606 | connect-fail-limit=nn |
41bd17a4 | 1607 | digest-url=url |
1608 | allow-miss | |
1609 | max-conn=n | |
1610 | htcp | |
1611 | htcp-oldsquid | |
4f4fa815 BR |
1612 | htcp-no-clr |
1613 | htcp-no-purge-clr | |
1614 | htcp-only-clr | |
1615 | htcp-forward-clr | |
41bd17a4 | 1616 | originserver |
1617 | name=xxx | |
1618 | forceddomain=name | |
1619 | ssl | |
1620 | sslcert=/path/to/ssl/certificate | |
1621 | sslkey=/path/to/ssl/key | |
1622 | sslversion=1|2|3|4 | |
1623 | sslcipher=... | |
1624 | ssloptions=... | |
1625 | front-end-https[=on|auto] | |
d67acb4e | 1626 | connection-auth[=on|off|auto] |
cccac0a2 | 1627 | |
41bd17a4 | 1628 | use 'proxy-only' to specify objects fetched |
1629 | from this cache should not be saved locally. | |
cccac0a2 | 1630 | |
41bd17a4 | 1631 | use 'weight=n' to affect the selection of a peer |
1632 | during any weighted peer-selection mechanisms. | |
1633 | The weight must be an integer; default is 1, | |
1634 | larger weights are favored more. | |
1635 | This option does not affect parent selection if a peering | |
1636 | protocol is not in use. | |
cccac0a2 | 1637 | |
41bd17a4 | 1638 | use 'basetime=n' to specify a base amount to |
1639 | be subtracted from round trip times of parents. | |
1640 | It is subtracted before division by weight in calculating | |
1641 | which parent to fectch from. If the rtt is less than the | |
1642 | base time the rtt is set to a minimal value. | |
cccac0a2 | 1643 | |
41bd17a4 | 1644 | use 'ttl=n' to specify a IP multicast TTL to use |
1645 | when sending an ICP queries to this address. | |
1646 | Only useful when sending to a multicast group. | |
1647 | Because we don't accept ICP replies from random | |
1648 | hosts, you must configure other group members as | |
1649 | peers with the 'multicast-responder' option below. | |
5473c134 | 1650 | |
41bd17a4 | 1651 | use 'no-query' to NOT send ICP queries to this |
1652 | neighbor. | |
5473c134 | 1653 | |
41bd17a4 | 1654 | use 'background-ping' to only send ICP queries to this |
1655 | neighbor infrequently. This is used to keep the neighbor | |
1656 | round trip time updated and is usually used in | |
1657 | conjunction with weighted-round-robin. | |
cccac0a2 | 1658 | |
41bd17a4 | 1659 | use 'default' if this is a parent cache which can |
1660 | be used as a "last-resort" if a peer cannot be located | |
1661 | by any of the peer-selection mechanisms. | |
1662 | If specified more than once, only the first is used. | |
cccac0a2 | 1663 | |
41bd17a4 | 1664 | use 'round-robin' to define a set of parents which |
1665 | should be used in a round-robin fashion in the | |
1666 | absence of any ICP queries. | |
cccac0a2 | 1667 | |
41bd17a4 | 1668 | use 'weighted-round-robin' to define a set of parents |
1669 | which should be used in a round-robin fashion with the | |
1670 | frequency of each parent being based on the round trip | |
1671 | time. Closer parents are used more often. | |
1672 | Usually used for background-ping parents. | |
cccac0a2 | 1673 | |
41bd17a4 | 1674 | use 'carp' to define a set of parents which should |
1675 | be used as a CARP array. The requests will be | |
1676 | distributed among the parents based on the CARP load | |
382db7eb | 1677 | balancing hash function based on their weight. |
cccac0a2 | 1678 | |
f7e1d9ce HN |
1679 | use 'userhash' to load-balance amongst a set of parents |
1680 | based on the client proxy_auth or ident username. | |
1681 | ||
1682 | use 'sourcehash' to load-balance amongst a set of parents | |
1683 | based on the client source ip. | |
1684 | ||
41bd17a4 | 1685 | 'multicast-responder' indicates the named peer |
1686 | is a member of a multicast group. ICP queries will | |
1687 | not be sent directly to the peer, but ICP replies | |
1688 | will be accepted from it. | |
cccac0a2 | 1689 | |
41bd17a4 | 1690 | 'closest-only' indicates that, for ICP_OP_MISS |
1691 | replies, we'll only forward CLOSEST_PARENT_MISSes | |
1692 | and never FIRST_PARENT_MISSes. | |
cccac0a2 | 1693 | |
41bd17a4 | 1694 | use 'no-digest' to NOT request cache digests from |
1695 | this neighbor. | |
cccac0a2 | 1696 | |
41bd17a4 | 1697 | 'no-netdb-exchange' disables requesting ICMP |
1698 | RTT database (NetDB) from the neighbor. | |
cccac0a2 | 1699 | |
41bd17a4 | 1700 | use 'no-delay' to prevent access to this neighbor |
1701 | from influencing the delay pools. | |
7d90757b | 1702 | |
41bd17a4 | 1703 | use 'login=user:password' if this is a personal/workgroup |
1704 | proxy and your parent requires proxy authentication. | |
1705 | Note: The string can include URL escapes (i.e. %20 for | |
1706 | spaces). This also means % must be written as %%. | |
7d90757b | 1707 | |
41bd17a4 | 1708 | use 'login=PASS' if users must authenticate against |
1709 | the upstream proxy or in the case of a reverse proxy | |
1710 | configuration, the origin web server. This will pass | |
1711 | the users credentials as they are to the peer. | |
1712 | This only works for the Basic HTTP authentication scheme. | |
1713 | Note: To combine this with proxy_auth both proxies must | |
1714 | share the same user database as HTTP only allows for | |
1715 | a single login (one for proxy, one for origin server). | |
1716 | Also be warned this will expose your users proxy | |
1717 | password to the peer. USE WITH CAUTION | |
7d90757b | 1718 | |
41bd17a4 | 1719 | use 'login=*:password' to pass the username to the |
1720 | upstream cache, but with a fixed password. This is meant | |
1721 | to be used when the peer is in another administrative | |
1722 | domain, but it is still needed to identify each user. | |
1723 | The star can optionally be followed by some extra | |
1724 | information which is added to the username. This can | |
1725 | be used to identify this proxy to the peer, similar to | |
1726 | the login=username:password option above. | |
cccac0a2 | 1727 | |
41bd17a4 | 1728 | use 'connect-timeout=nn' to specify a peer |
1729 | specific connect timeout (also see the | |
1730 | peer_connect_timeout directive) | |
7f7db318 | 1731 | |
ff9970cc AJ |
1732 | use 'connect-fail-limit=nn' to specify how many times |
1733 | connecting to a peer must fail before it is marked as | |
1734 | down. Default is 10. | |
1735 | ||
41bd17a4 | 1736 | use 'digest-url=url' to tell Squid to fetch the cache |
1737 | digest (if digests are enabled) for this host from | |
1738 | the specified URL rather than the Squid default | |
1739 | location. | |
cccac0a2 | 1740 | |
41bd17a4 | 1741 | use 'allow-miss' to disable Squid's use of only-if-cached |
1742 | when forwarding requests to siblings. This is primarily | |
1743 | useful when icp_hit_stale is used by the sibling. To | |
1744 | extensive use of this option may result in forwarding | |
1745 | loops, and you should avoid having two-way peerings | |
1746 | with this option. (for example to deny peer usage on | |
1747 | requests from peer by denying cache_peer_access if the | |
1748 | source is a peer) | |
cccac0a2 | 1749 | |
41bd17a4 | 1750 | use 'max-conn=n' to limit the amount of connections Squid |
1751 | may open to this peer. | |
cccac0a2 | 1752 | |
41bd17a4 | 1753 | use 'htcp' to send HTCP, instead of ICP, queries |
1754 | to the neighbor. You probably also want to | |
1755 | set the "icp port" to 4827 instead of 3130. | |
0b48417e | 1756 | You MUST also set htcp_access expicitly. The default of |
1757 | deny all will prevent peer traffic. | |
cccac0a2 | 1758 | |
41bd17a4 | 1759 | use 'htcp-oldsquid' to send HTCP to old Squid versions |
0b48417e | 1760 | You MUST also set htcp_access expicitly. The default of |
1761 | deny all will prevent peer traffic. | |
cccac0a2 | 1762 | |
4f4fa815 BR |
1763 | use 'htcp-no-clr' to send HTCP to the neighbor but without |
1764 | sending any CLR requests. This cannot be used with | |
1765 | htcp-only-clr. | |
1766 | ||
1767 | use 'htcp-no-purge-clr' to send HTCP to the neighbor | |
1768 | including CLRs but only when they do not result from | |
1769 | PURGE requests. | |
1770 | ||
1771 | use 'htcp-only-clr' to send HTCP to the neighbor but ONLY | |
1772 | CLR requests. This cannot be used with htcp-no-clr. | |
1773 | ||
1774 | use 'htcp-forward-clr' to forward any HTCP CLR requests | |
1775 | this proxy receives to the peer. | |
1776 | ||
41bd17a4 | 1777 | 'originserver' causes this parent peer to be contacted as |
1778 | a origin server. Meant to be used in accelerator setups. | |
cccac0a2 | 1779 | |
41bd17a4 | 1780 | use 'name=xxx' if you have multiple peers on the same |
1781 | host but different ports. This name can be used to | |
1782 | differentiate the peers in cache_peer_access and similar | |
6db78a1a | 1783 | directives. Including the peername ACL type. |
cccac0a2 | 1784 | |
41bd17a4 | 1785 | use 'forceddomain=name' to forcibly set the Host header |
1786 | of requests forwarded to this peer. Useful in accelerator | |
1787 | setups where the server (peer) expects a certain domain | |
1788 | name and using redirectors to feed this domain name | |
1789 | is not feasible. | |
64658378 | 1790 | |
41bd17a4 | 1791 | use 'ssl' to indicate connections to this peer should |
1792 | be SSL/TLS encrypted. | |
cccac0a2 | 1793 | |
41bd17a4 | 1794 | use 'sslcert=/path/to/ssl/certificate' to specify a client |
1795 | SSL certificate to use when connecting to this peer. | |
4c9fa5d5 | 1796 | |
41bd17a4 | 1797 | use 'sslkey=/path/to/ssl/key' to specify the private SSL |
1798 | key corresponding to sslcert above. If 'sslkey' is not | |
1799 | specified 'sslcert' is assumed to reference a | |
1800 | combined file containing both the certificate and the key. | |
4c9fa5d5 | 1801 | |
41bd17a4 | 1802 | use sslversion=1|2|3|4 to specify the SSL version to use |
1803 | when connecting to this peer | |
1804 | 1 = automatic (default) | |
1805 | 2 = SSL v2 only | |
1806 | 3 = SSL v3 only | |
1807 | 4 = TLS v1 only | |
cccac0a2 | 1808 | |
41bd17a4 | 1809 | use sslcipher=... to specify the list of valid SSL ciphers |
1810 | to use when connecting to this peer. | |
cccac0a2 | 1811 | |
41bd17a4 | 1812 | use ssloptions=... to specify various SSL engine options: |
1813 | NO_SSLv2 Disallow the use of SSLv2 | |
1814 | NO_SSLv3 Disallow the use of SSLv3 | |
1815 | NO_TLSv1 Disallow the use of TLSv1 | |
1816 | See src/ssl_support.c or the OpenSSL documentation for | |
1817 | a more complete list. | |
cccac0a2 | 1818 | |
41bd17a4 | 1819 | use sslcafile=... to specify a file containing |
1820 | additional CA certificates to use when verifying the | |
1821 | peer certificate. | |
cccac0a2 | 1822 | |
41bd17a4 | 1823 | use sslcapath=... to specify a directory containing |
1824 | additional CA certificates to use when verifying the | |
1825 | peer certificate. | |
cccac0a2 | 1826 | |
41bd17a4 | 1827 | use sslcrlfile=... to specify a certificate revocation |
1828 | list file to use when verifying the peer certificate. | |
1829 | ||
1830 | use sslflags=... to specify various flags modifying the | |
1831 | SSL implementation: | |
1832 | DONT_VERIFY_PEER | |
1833 | Accept certificates even if they fail to | |
1834 | verify. | |
1835 | NO_DEFAULT_CA | |
1836 | Don't use the default CA list built in | |
1837 | to OpenSSL. | |
1838 | DONT_VERIFY_DOMAIN | |
1839 | Don't verify the peer certificate | |
1840 | matches the server name | |
cccac0a2 | 1841 | |
41bd17a4 | 1842 | use ssldomain= to specify the peer name as advertised |
1843 | in it's certificate. Used for verifying the correctness | |
1844 | of the received peer certificate. If not specified the | |
1845 | peer hostname will be used. | |
cccac0a2 | 1846 | |
41bd17a4 | 1847 | use front-end-https to enable the "Front-End-Https: On" |
1848 | header needed when using Squid as a SSL frontend in front | |
1849 | of Microsoft OWA. See MS KB document Q307347 for details | |
1850 | on this header. If set to auto the header will | |
1851 | only be added if the request is forwarded as a https:// | |
1852 | URL. | |
d67acb4e AJ |
1853 | |
1854 | use connection-auth=off to tell Squid that this peer does | |
1855 | not support Microsoft connection oriented authentication, | |
1856 | and any such challenges received from there should be | |
1857 | ignored. Default is auto to automatically determine the | |
1858 | status of the peer. | |
41bd17a4 | 1859 | DOC_END |
cccac0a2 | 1860 | |
41bd17a4 | 1861 | NAME: cache_peer_domain cache_host_domain |
1862 | TYPE: hostdomain | |
1863 | DEFAULT: none | |
1864 | LOC: none | |
1865 | DOC_START | |
1866 | Use to limit the domains for which a neighbor cache will be | |
1867 | queried. Usage: | |
cccac0a2 | 1868 | |
41bd17a4 | 1869 | cache_peer_domain cache-host domain [domain ...] |
1870 | cache_peer_domain cache-host !domain | |
cccac0a2 | 1871 | |
41bd17a4 | 1872 | For example, specifying |
cccac0a2 | 1873 | |
41bd17a4 | 1874 | cache_peer_domain parent.foo.net .edu |
cccac0a2 | 1875 | |
41bd17a4 | 1876 | has the effect such that UDP query packets are sent to |
1877 | 'bigserver' only when the requested object exists on a | |
1878 | server in the .edu domain. Prefixing the domainname | |
1879 | with '!' means the cache will be queried for objects | |
1880 | NOT in that domain. | |
cccac0a2 | 1881 | |
41bd17a4 | 1882 | NOTE: * Any number of domains may be given for a cache-host, |
1883 | either on the same or separate lines. | |
1884 | * When multiple domains are given for a particular | |
1885 | cache-host, the first matched domain is applied. | |
1886 | * Cache hosts with no domain restrictions are queried | |
1887 | for all requests. | |
1888 | * There are no defaults. | |
1889 | * There is also a 'cache_peer_access' tag in the ACL | |
1890 | section. | |
1891 | DOC_END | |
dd9b1776 | 1892 | |
41bd17a4 | 1893 | NAME: cache_peer_access |
1894 | TYPE: peer_access | |
1895 | DEFAULT: none | |
1896 | LOC: none | |
1897 | DOC_START | |
1898 | Similar to 'cache_peer_domain' but provides more flexibility by | |
1899 | using ACL elements. | |
cccac0a2 | 1900 | |
41bd17a4 | 1901 | cache_peer_access cache-host allow|deny [!]aclname ... |
dd9b1776 | 1902 | |
41bd17a4 | 1903 | The syntax is identical to 'http_access' and the other lists of |
1904 | ACL elements. See the comments for 'http_access' below, or | |
1905 | the Squid FAQ (http://www.squid-cache.org/FAQ/FAQ-10.html). | |
1906 | DOC_END | |
dd9b1776 | 1907 | |
41bd17a4 | 1908 | NAME: neighbor_type_domain |
1909 | TYPE: hostdomaintype | |
1910 | DEFAULT: none | |
1911 | LOC: none | |
1912 | DOC_START | |
1913 | usage: neighbor_type_domain neighbor parent|sibling domain domain ... | |
cccac0a2 | 1914 | |
41bd17a4 | 1915 | Modifying the neighbor type for specific domains is now |
1916 | possible. You can treat some domains differently than the the | |
1917 | default neighbor type specified on the 'cache_peer' line. | |
1918 | Normally it should only be necessary to list domains which | |
1919 | should be treated differently because the default neighbor type | |
1920 | applies for hostnames which do not match domains listed here. | |
6bf4f823 | 1921 | |
41bd17a4 | 1922 | EXAMPLE: |
dbe3992d | 1923 | cache_peer cache.foo.org parent 3128 3130 |
41bd17a4 | 1924 | neighbor_type_domain cache.foo.org sibling .com .net |
1925 | neighbor_type_domain cache.foo.org sibling .au .de | |
1926 | DOC_END | |
6bf4f823 | 1927 | |
41bd17a4 | 1928 | NAME: dead_peer_timeout |
1929 | COMMENT: (seconds) | |
1930 | DEFAULT: 10 seconds | |
1931 | TYPE: time_t | |
1932 | LOC: Config.Timeout.deadPeer | |
1933 | DOC_START | |
1934 | This controls how long Squid waits to declare a peer cache | |
1935 | as "dead." If there are no ICP replies received in this | |
1936 | amount of time, Squid will declare the peer dead and not | |
1937 | expect to receive any further ICP replies. However, it | |
1938 | continues to send ICP queries, and will mark the peer as | |
1939 | alive upon receipt of the first subsequent ICP reply. | |
699acd19 | 1940 | |
41bd17a4 | 1941 | This timeout also affects when Squid expects to receive ICP |
1942 | replies from peers. If more than 'dead_peer' seconds have | |
1943 | passed since the last ICP reply was received, Squid will not | |
1944 | expect to receive an ICP reply on the next query. Thus, if | |
1945 | your time between requests is greater than this timeout, you | |
1946 | will see a lot of requests sent DIRECT to origin servers | |
1947 | instead of to your parents. | |
1948 | DOC_END | |
cccac0a2 | 1949 | |
437823b4 AJ |
1950 | NAME: forward_max_tries |
1951 | DEFAULT: 10 | |
1952 | TYPE: int | |
1953 | LOC: Config.forward_max_tries | |
1954 | DOC_START | |
1955 | Controls how many different forward paths Squid will try | |
1956 | before giving up. See also forward_timeout. | |
1957 | DOC_END | |
1958 | ||
41bd17a4 | 1959 | NAME: hierarchy_stoplist |
1960 | TYPE: wordlist | |
1961 | DEFAULT: none | |
1962 | LOC: Config.hierarchy_stoplist | |
1963 | DOC_START | |
1964 | A list of words which, if found in a URL, cause the object to | |
1965 | be handled directly by this cache. In other words, use this | |
1966 | to not query neighbor caches for certain objects. You may | |
1967 | list this option multiple times. | |
1968 | Note: never_direct overrides this option. | |
cccac0a2 | 1969 | NOCOMMENT_START |
41bd17a4 | 1970 | #We recommend you to use at least the following line. |
1971 | hierarchy_stoplist cgi-bin ? | |
6b698a21 | 1972 | NOCOMMENT_END |
1973 | DOC_END | |
0976f8db | 1974 | |
41bd17a4 | 1975 | COMMENT_START |
1976 | MEMORY CACHE OPTIONS | |
1977 | ----------------------------------------------------------------------------- | |
1978 | COMMENT_END | |
1979 | ||
1980 | NAME: cache_mem | |
1981 | COMMENT: (bytes) | |
1982 | TYPE: b_size_t | |
df2eec10 | 1983 | DEFAULT: 256 MB |
41bd17a4 | 1984 | LOC: Config.memMaxSize |
6b698a21 | 1985 | DOC_START |
41bd17a4 | 1986 | NOTE: THIS PARAMETER DOES NOT SPECIFY THE MAXIMUM PROCESS SIZE. |
1987 | IT ONLY PLACES A LIMIT ON HOW MUCH ADDITIONAL MEMORY SQUID WILL | |
1988 | USE AS A MEMORY CACHE OF OBJECTS. SQUID USES MEMORY FOR OTHER | |
1989 | THINGS AS WELL. SEE THE SQUID FAQ SECTION 8 FOR DETAILS. | |
1990 | ||
1991 | 'cache_mem' specifies the ideal amount of memory to be used | |
1992 | for: | |
1993 | * In-Transit objects | |
1994 | * Hot Objects | |
1995 | * Negative-Cached objects | |
1996 | ||
1997 | Data for these objects are stored in 4 KB blocks. This | |
1998 | parameter specifies the ideal upper limit on the total size of | |
1999 | 4 KB blocks allocated. In-Transit objects take the highest | |
2000 | priority. | |
2001 | ||
2002 | In-transit objects have priority over the others. When | |
2003 | additional space is needed for incoming data, negative-cached | |
2004 | and hot objects will be released. In other words, the | |
2005 | negative-cached and hot objects will fill up any unused space | |
2006 | not needed for in-transit objects. | |
2007 | ||
2008 | If circumstances require, this limit will be exceeded. | |
2009 | Specifically, if your incoming request rate requires more than | |
2010 | 'cache_mem' of memory to hold in-transit objects, Squid will | |
2011 | exceed this limit to satisfy the new requests. When the load | |
2012 | decreases, blocks will be freed until the high-water mark is | |
2013 | reached. Thereafter, blocks will be used to store hot | |
2014 | objects. | |
6b698a21 | 2015 | DOC_END |
0976f8db | 2016 | |
41bd17a4 | 2017 | NAME: maximum_object_size_in_memory |
2018 | COMMENT: (bytes) | |
2019 | TYPE: b_size_t | |
df2eec10 | 2020 | DEFAULT: 512 KB |
41bd17a4 | 2021 | LOC: Config.Store.maxInMemObjSize |
6b698a21 | 2022 | DOC_START |
41bd17a4 | 2023 | Objects greater than this size will not be attempted to kept in |
2024 | the memory cache. This should be set high enough to keep objects | |
2025 | accessed frequently in memory to improve performance whilst low | |
2026 | enough to keep larger objects from hoarding cache_mem. | |
6b698a21 | 2027 | DOC_END |
0976f8db | 2028 | |
41bd17a4 | 2029 | NAME: memory_replacement_policy |
2030 | TYPE: removalpolicy | |
2031 | LOC: Config.memPolicy | |
2032 | DEFAULT: lru | |
6b698a21 | 2033 | DOC_START |
41bd17a4 | 2034 | The memory replacement policy parameter determines which |
2035 | objects are purged from memory when memory space is needed. | |
7f7db318 | 2036 | |
41bd17a4 | 2037 | See cache_replacement_policy for details. |
2038 | DOC_END | |
6b698a21 | 2039 | |
41bd17a4 | 2040 | COMMENT_START |
2041 | DISK CACHE OPTIONS | |
2042 | ----------------------------------------------------------------------------- | |
2043 | COMMENT_END | |
6b698a21 | 2044 | |
41bd17a4 | 2045 | NAME: cache_replacement_policy |
2046 | TYPE: removalpolicy | |
2047 | LOC: Config.replPolicy | |
2048 | DEFAULT: lru | |
2049 | DOC_START | |
2050 | The cache replacement policy parameter determines which | |
2051 | objects are evicted (replaced) when disk space is needed. | |
6b698a21 | 2052 | |
41bd17a4 | 2053 | lru : Squid's original list based LRU policy |
2054 | heap GDSF : Greedy-Dual Size Frequency | |
2055 | heap LFUDA: Least Frequently Used with Dynamic Aging | |
2056 | heap LRU : LRU policy implemented using a heap | |
6b698a21 | 2057 | |
41bd17a4 | 2058 | Applies to any cache_dir lines listed below this. |
7f7db318 | 2059 | |
41bd17a4 | 2060 | The LRU policies keeps recently referenced objects. |
0976f8db | 2061 | |
41bd17a4 | 2062 | The heap GDSF policy optimizes object hit rate by keeping smaller |
2063 | popular objects in cache so it has a better chance of getting a | |
2064 | hit. It achieves a lower byte hit rate than LFUDA though since | |
2065 | it evicts larger (possibly popular) objects. | |
0976f8db | 2066 | |
41bd17a4 | 2067 | The heap LFUDA policy keeps popular objects in cache regardless of |
2068 | their size and thus optimizes byte hit rate at the expense of | |
2069 | hit rate since one large, popular object will prevent many | |
2070 | smaller, slightly less popular objects from being cached. | |
0976f8db | 2071 | |
41bd17a4 | 2072 | Both policies utilize a dynamic aging mechanism that prevents |
2073 | cache pollution that can otherwise occur with frequency-based | |
2074 | replacement policies. | |
7d90757b | 2075 | |
41bd17a4 | 2076 | NOTE: if using the LFUDA replacement policy you should increase |
2077 | the value of maximum_object_size above its default of 4096 KB to | |
2078 | to maximize the potential byte hit rate improvement of LFUDA. | |
dc1af3cf | 2079 | |
41bd17a4 | 2080 | For more information about the GDSF and LFUDA cache replacement |
2081 | policies see http://www.hpl.hp.com/techreports/1999/HPL-1999-69.html | |
2082 | and http://fog.hpl.external.hp.com/techreports/98/HPL-98-173.html. | |
6b698a21 | 2083 | DOC_END |
0976f8db | 2084 | |
41bd17a4 | 2085 | NAME: cache_dir |
2086 | TYPE: cachedir | |
2087 | DEFAULT: none | |
41bd17a4 | 2088 | LOC: Config.cacheSwap |
6b698a21 | 2089 | DOC_START |
41bd17a4 | 2090 | Usage: |
0976f8db | 2091 | |
41bd17a4 | 2092 | cache_dir Type Directory-Name Fs-specific-data [options] |
0976f8db | 2093 | |
41bd17a4 | 2094 | You can specify multiple cache_dir lines to spread the |
2095 | cache among different disk partitions. | |
0976f8db | 2096 | |
41bd17a4 | 2097 | Type specifies the kind of storage system to use. Only "ufs" |
2098 | is built by default. To enable any of the other storage systems | |
2099 | see the --enable-storeio configure option. | |
0976f8db | 2100 | |
41bd17a4 | 2101 | 'Directory' is a top-level directory where cache swap |
2102 | files will be stored. If you want to use an entire disk | |
2103 | for caching, this can be the mount-point directory. | |
2104 | The directory must exist and be writable by the Squid | |
2105 | process. Squid will NOT create this directory for you. | |
0976f8db | 2106 | |
41bd17a4 | 2107 | The ufs store type: |
0976f8db | 2108 | |
41bd17a4 | 2109 | "ufs" is the old well-known Squid storage format that has always |
2110 | been there. | |
0976f8db | 2111 | |
41bd17a4 | 2112 | cache_dir ufs Directory-Name Mbytes L1 L2 [options] |
0976f8db | 2113 | |
41bd17a4 | 2114 | 'Mbytes' is the amount of disk space (MB) to use under this |
2115 | directory. The default is 100 MB. Change this to suit your | |
2116 | configuration. Do NOT put the size of your disk drive here. | |
2117 | Instead, if you want Squid to use the entire disk drive, | |
2118 | subtract 20% and use that value. | |
0976f8db | 2119 | |
41bd17a4 | 2120 | 'Level-1' is the number of first-level subdirectories which |
2121 | will be created under the 'Directory'. The default is 16. | |
0976f8db | 2122 | |
41bd17a4 | 2123 | 'Level-2' is the number of second-level subdirectories which |
2124 | will be created under each first-level directory. The default | |
2125 | is 256. | |
0976f8db | 2126 | |
41bd17a4 | 2127 | The aufs store type: |
7f7db318 | 2128 | |
41bd17a4 | 2129 | "aufs" uses the same storage format as "ufs", utilizing |
2130 | POSIX-threads to avoid blocking the main Squid process on | |
2131 | disk-I/O. This was formerly known in Squid as async-io. | |
38f9c547 | 2132 | |
41bd17a4 | 2133 | cache_dir aufs Directory-Name Mbytes L1 L2 [options] |
38f9c547 | 2134 | |
41bd17a4 | 2135 | see argument descriptions under ufs above |
38f9c547 | 2136 | |
41bd17a4 | 2137 | The diskd store type: |
38f9c547 | 2138 | |
41bd17a4 | 2139 | "diskd" uses the same storage format as "ufs", utilizing a |
2140 | separate process to avoid blocking the main Squid process on | |
2141 | disk-I/O. | |
4c3ef9b2 | 2142 | |
41bd17a4 | 2143 | cache_dir diskd Directory-Name Mbytes L1 L2 [options] [Q1=n] [Q2=n] |
0976f8db | 2144 | |
41bd17a4 | 2145 | see argument descriptions under ufs above |
0976f8db | 2146 | |
41bd17a4 | 2147 | Q1 specifies the number of unacknowledged I/O requests when Squid |
2148 | stops opening new files. If this many messages are in the queues, | |
2149 | Squid won't open new files. Default is 64 | |
0976f8db | 2150 | |
41bd17a4 | 2151 | Q2 specifies the number of unacknowledged messages when Squid |
2152 | starts blocking. If this many messages are in the queues, | |
2153 | Squid blocks until it receives some replies. Default is 72 | |
0976f8db | 2154 | |
41bd17a4 | 2155 | When Q1 < Q2 (the default), the cache directory is optimized |
2156 | for lower response time at the expense of a decrease in hit | |
2157 | ratio. If Q1 > Q2, the cache directory is optimized for | |
2158 | higher hit ratio at the expense of an increase in response | |
2159 | time. | |
0976f8db | 2160 | |
41bd17a4 | 2161 | The coss store type: |
0976f8db | 2162 | |
db263d62 AJ |
2163 | NP: COSS filesystem in Squid-3 has been deemed too unstable for |
2164 | production use and has thus been removed from this release. | |
2165 | We hope that it can be made usable again soon. | |
2166 | ||
41bd17a4 | 2167 | block-size=n defines the "block size" for COSS cache_dir's. |
2168 | Squid uses file numbers as block numbers. Since file numbers | |
2169 | are limited to 24 bits, the block size determines the maximum | |
2170 | size of the COSS partition. The default is 512 bytes, which | |
2171 | leads to a maximum cache_dir size of 512<<24, or 8 GB. Note | |
2172 | you should not change the coss block size after Squid | |
2173 | has written some objects to the cache_dir. | |
0976f8db | 2174 | |
41bd17a4 | 2175 | The coss file store has changed from 2.5. Now it uses a file |
2176 | called 'stripe' in the directory names in the config - and | |
2177 | this will be created by squid -z. | |
0976f8db | 2178 | |
41bd17a4 | 2179 | Common options: |
0976f8db | 2180 | |
41bd17a4 | 2181 | no-store, no new objects should be stored to this cache_dir |
0976f8db | 2182 | |
41bd17a4 | 2183 | max-size=n, refers to the max object size this storedir supports. |
2184 | It is used to initially choose the storedir to dump the object. | |
2185 | Note: To make optimal use of the max-size limits you should order | |
2186 | the cache_dir lines with the smallest max-size value first and the | |
2187 | ones with no max-size specification last. | |
0976f8db | 2188 | |
41bd17a4 | 2189 | Note for coss, max-size must be less than COSS_MEMBUF_SZ, |
2190 | which can be changed with the --with-coss-membuf-size=N configure | |
2191 | option. | |
bebc043b | 2192 | NOCOMMENT_START |
df2eec10 | 2193 | # cache_dir ufs @DEFAULT_SWAP_DIR@ 100 16 256 |
bebc043b | 2194 | NOCOMMENT_END |
6b698a21 | 2195 | DOC_END |
0976f8db | 2196 | |
41bd17a4 | 2197 | NAME: store_dir_select_algorithm |
2198 | TYPE: string | |
2199 | LOC: Config.store_dir_select_algorithm | |
2200 | DEFAULT: least-load | |
6b698a21 | 2201 | DOC_START |
41bd17a4 | 2202 | Set this to 'round-robin' as an alternative. |
6b698a21 | 2203 | DOC_END |
0976f8db | 2204 | |
41bd17a4 | 2205 | NAME: max_open_disk_fds |
2206 | TYPE: int | |
2207 | LOC: Config.max_open_disk_fds | |
2208 | DEFAULT: 0 | |
6b698a21 | 2209 | DOC_START |
41bd17a4 | 2210 | To avoid having disk as the I/O bottleneck Squid can optionally |
2211 | bypass the on-disk cache if more than this amount of disk file | |
2212 | descriptors are open. | |
2213 | ||
2214 | A value of 0 indicates no limit. | |
6b698a21 | 2215 | DOC_END |
0976f8db | 2216 | |
41bd17a4 | 2217 | NAME: minimum_object_size |
6b698a21 | 2218 | COMMENT: (bytes) |
47f6e231 | 2219 | TYPE: b_int64_t |
6b698a21 | 2220 | DEFAULT: 0 KB |
41bd17a4 | 2221 | LOC: Config.Store.minObjectSize |
6b698a21 | 2222 | DOC_START |
41bd17a4 | 2223 | Objects smaller than this size will NOT be saved on disk. The |
2224 | value is specified in kilobytes, and the default is 0 KB, which | |
2225 | means there is no minimum. | |
6b698a21 | 2226 | DOC_END |
0976f8db | 2227 | |
41bd17a4 | 2228 | NAME: maximum_object_size |
2229 | COMMENT: (bytes) | |
2230 | TYPE: b_int64_t | |
2231 | DEFAULT: 4096 KB | |
2232 | LOC: Config.Store.maxObjectSize | |
777831e0 | 2233 | DOC_START |
41bd17a4 | 2234 | Objects larger than this size will NOT be saved on disk. The |
2235 | value is specified in kilobytes, and the default is 4MB. If | |
2236 | you wish to get a high BYTES hit ratio, you should probably | |
2237 | increase this (one 32 MB object hit counts for 3200 10KB | |
2238 | hits). If you wish to increase speed more than your want to | |
2239 | save bandwidth you should leave this low. | |
777831e0 | 2240 | |
41bd17a4 | 2241 | NOTE: if using the LFUDA replacement policy you should increase |
2242 | this value to maximize the byte hit rate improvement of LFUDA! | |
2243 | See replacement_policy below for a discussion of this policy. | |
6b698a21 | 2244 | DOC_END |
0976f8db | 2245 | |
41bd17a4 | 2246 | NAME: cache_swap_low |
2247 | COMMENT: (percent, 0-100) | |
5473c134 | 2248 | TYPE: int |
41bd17a4 | 2249 | DEFAULT: 90 |
2250 | LOC: Config.Swap.lowWaterMark | |
2251 | DOC_NONE | |
2252 | ||
2253 | NAME: cache_swap_high | |
2254 | COMMENT: (percent, 0-100) | |
2255 | TYPE: int | |
2256 | DEFAULT: 95 | |
2257 | LOC: Config.Swap.highWaterMark | |
6b698a21 | 2258 | DOC_START |
41bd17a4 | 2259 | |
2260 | The low- and high-water marks for cache object replacement. | |
2261 | Replacement begins when the swap (disk) usage is above the | |
2262 | low-water mark and attempts to maintain utilization near the | |
2263 | low-water mark. As swap utilization gets close to high-water | |
2264 | mark object eviction becomes more aggressive. If utilization is | |
2265 | close to the low-water mark less replacement is done each time. | |
2266 | ||
2267 | Defaults are 90% and 95%. If you have a large cache, 5% could be | |
2268 | hundreds of MB. If this is the case you may wish to set these | |
2269 | numbers closer together. | |
6b698a21 | 2270 | DOC_END |
0976f8db | 2271 | |
5473c134 | 2272 | COMMENT_START |
41bd17a4 | 2273 | LOGFILE OPTIONS |
5473c134 | 2274 | ----------------------------------------------------------------------------- |
2275 | COMMENT_END | |
0976f8db | 2276 | |
41bd17a4 | 2277 | NAME: logformat |
2278 | TYPE: logformat | |
2279 | LOC: Config.Log.logformats | |
5473c134 | 2280 | DEFAULT: none |
6b698a21 | 2281 | DOC_START |
41bd17a4 | 2282 | Usage: |
0976f8db | 2283 | |
41bd17a4 | 2284 | logformat <name> <format specification> |
0976f8db | 2285 | |
41bd17a4 | 2286 | Defines an access log format. |
6b698a21 | 2287 | |
41bd17a4 | 2288 | The <format specification> is a string with embedded % format codes |
5473c134 | 2289 | |
41bd17a4 | 2290 | % format codes all follow the same basic structure where all but |
2291 | the formatcode is optional. Output strings are automatically escaped | |
2292 | as required according to their context and the output format | |
2293 | modifiers are usually not needed, but can be specified if an explicit | |
2294 | output format is desired. | |
6b698a21 | 2295 | |
41bd17a4 | 2296 | % ["|[|'|#] [-] [[0]width] [{argument}] formatcode |
0976f8db | 2297 | |
41bd17a4 | 2298 | " output in quoted string format |
2299 | [ output in squid text log format as used by log_mime_hdrs | |
2300 | # output in URL quoted format | |
2301 | ' output as-is | |
5473c134 | 2302 | |
41bd17a4 | 2303 | - left aligned |
2304 | width field width. If starting with 0 the | |
2305 | output is zero padded | |
2306 | {arg} argument such as header name etc | |
5473c134 | 2307 | |
41bd17a4 | 2308 | Format codes: |
5473c134 | 2309 | |
41bd17a4 | 2310 | >a Client source IP address |
2311 | >A Client FQDN | |
2312 | >p Client source port | |
2313 | <A Server IP address or peer name | |
2314 | la Local IP address (http_port) | |
2315 | lp Local port number (http_port) | |
2316 | ts Seconds since epoch | |
2317 | tu subsecond time (milliseconds) | |
2318 | tl Local time. Optional strftime format argument | |
2319 | default %d/%b/%Y:%H:%M:%S %z | |
2320 | tg GMT time. Optional strftime format argument | |
2321 | default %d/%b/%Y:%H:%M:%S %z | |
2322 | tr Response time (milliseconds) | |
2323 | >h Request header. Optional header name argument | |
2324 | on the format header[:[separator]element] | |
2325 | <h Reply header. Optional header name argument | |
2326 | as for >h | |
2327 | un User name | |
2328 | ul User name from authentication | |
2329 | ui User name from ident | |
2330 | us User name from SSL | |
2331 | ue User name from external acl helper | |
2332 | Hs HTTP status code | |
2333 | Ss Squid request status (TCP_MISS etc) | |
2334 | Sh Squid hierarchy status (DEFAULT_PARENT etc) | |
2335 | mt MIME content type | |
2336 | rm Request method (GET/POST etc) | |
2337 | ru Request URL | |
2338 | rp Request URL-Path excluding hostname | |
2339 | rv Request protocol version | |
2340 | et Tag returned by external acl | |
2341 | ea Log string returned by external acl | |
2342 | <st Reply size including HTTP headers | |
1a86db31 AJ |
2343 | >st Request size including HTTP headers |
2344 | st Request+Reply size including HTTP headers | |
41bd17a4 | 2345 | <sH Reply high offset sent |
2346 | <sS Upstream object size | |
2347 | % a literal % character | |
5473c134 | 2348 | |
7d9acc3c AJ |
2349 | The default formats available (which do not need re-defining) are: |
2350 | ||
2351 | logformat squid %ts.%03tu %6tr %>a %Ss/%03Hs %<st %rm %ru %un %Sh/%<A %mt | |
2352 | logformat squidmime %ts.%03tu %6tr %>a %Ss/%03Hs %<st %rm %ru %un %Sh/%<A %mt [%>h] [%<h] | |
41bd17a4 | 2353 | logformat common %>a %ui %un [%tl] "%rm %ru HTTP/%rv" %Hs %<st %Ss:%Sh |
2354 | logformat combined %>a %ui %un [%tl] "%rm %ru HTTP/%rv" %Hs %<st "%{Referer}>h" "%{User-Agent}>h" %Ss:%Sh | |
5473c134 | 2355 | DOC_END |
2356 | ||
41bd17a4 | 2357 | NAME: access_log cache_access_log |
2358 | TYPE: access_log | |
2359 | LOC: Config.Log.accesslogs | |
02424612 | 2360 | DEFAULT: none |
01ddaf65 | 2361 | DEFAULT_IF_NONE: @DEFAULT_ACCESS_LOG@ squid |
5473c134 | 2362 | DOC_START |
41bd17a4 | 2363 | These files log client request activities. Has a line every HTTP or |
2364 | ICP request. The format is: | |
2365 | access_log <filepath> [<logformat name> [acl acl ...]] | |
2366 | access_log none [acl acl ...]] | |
5473c134 | 2367 | |
41bd17a4 | 2368 | Will log to the specified file using the specified format (which |
2369 | must be defined in a logformat directive) those entries which match | |
2370 | ALL the acl's specified (which must be defined in acl clauses). | |
2371 | If no acl is specified, all requests will be logged to this file. | |
5473c134 | 2372 | |
41bd17a4 | 2373 | To disable logging of a request use the filepath "none", in which case |
2374 | a logformat name should not be specified. | |
5473c134 | 2375 | |
41bd17a4 | 2376 | To log the request via syslog specify a filepath of "syslog": |
5473c134 | 2377 | |
41bd17a4 | 2378 | access_log syslog[:facility.priority] [format [acl1 [acl2 ....]]] |
2379 | where facility could be any of: | |
2380 | authpriv, daemon, local0 .. local7 or user. | |
5473c134 | 2381 | |
41bd17a4 | 2382 | And priority could be any of: |
2383 | err, warning, notice, info, debug. | |
df2eec10 AJ |
2384 | |
2385 | Default: | |
2386 | access_log @DEFAULT_ACCESS_LOG@ squid | |
41bd17a4 | 2387 | DOC_END |
5473c134 | 2388 | |
5b0f5383 | 2389 | NAME: log_access |
2390 | TYPE: acl_access | |
2391 | LOC: Config.accessList.log | |
2392 | DEFAULT: none | |
2393 | COMMENT: allow|deny acl acl... | |
2394 | DOC_START | |
2395 | This options allows you to control which requests gets logged | |
2396 | to access.log (see access_log directive). Requests denied for | |
2397 | logging will also not be accounted for in performance counters. | |
2398 | DOC_END | |
2399 | ||
41bd17a4 | 2400 | NAME: cache_store_log |
2401 | TYPE: string | |
df2eec10 | 2402 | DEFAULT: none |
41bd17a4 | 2403 | LOC: Config.Log.store |
2404 | DOC_START | |
2405 | Logs the activities of the storage manager. Shows which | |
2406 | objects are ejected from the cache, and which objects are | |
df2eec10 AJ |
2407 | saved and for how long. To disable, enter "none" or remove the line. |
2408 | There are not really utilities to analyze this data, so you can safely | |
41bd17a4 | 2409 | disable it. |
df2eec10 AJ |
2410 | NOCOMMENT_START |
2411 | # cache_store_log @DEFAULT_STORE_LOG@ | |
2412 | NOCOMMENT_END | |
5473c134 | 2413 | DOC_END |
2414 | ||
41bd17a4 | 2415 | NAME: cache_swap_state cache_swap_log |
2416 | TYPE: string | |
2417 | LOC: Config.Log.swap | |
5473c134 | 2418 | DEFAULT: none |
2419 | DOC_START | |
41bd17a4 | 2420 | Location for the cache "swap.state" file. This index file holds |
2421 | the metadata of objects saved on disk. It is used to rebuild | |
2422 | the cache during startup. Normally this file resides in each | |
2423 | 'cache_dir' directory, but you may specify an alternate | |
2424 | pathname here. Note you must give a full filename, not just | |
2425 | a directory. Since this is the index for the whole object | |
2426 | list you CANNOT periodically rotate it! | |
5473c134 | 2427 | |
41bd17a4 | 2428 | If %s can be used in the file name it will be replaced with a |
2429 | a representation of the cache_dir name where each / is replaced | |
2430 | with '.'. This is needed to allow adding/removing cache_dir | |
2431 | lines when cache_swap_log is being used. | |
5473c134 | 2432 | |
41bd17a4 | 2433 | If have more than one 'cache_dir', and %s is not used in the name |
2434 | these swap logs will have names such as: | |
5473c134 | 2435 | |
41bd17a4 | 2436 | cache_swap_log.00 |
2437 | cache_swap_log.01 | |
2438 | cache_swap_log.02 | |
5473c134 | 2439 | |
41bd17a4 | 2440 | The numbered extension (which is added automatically) |
2441 | corresponds to the order of the 'cache_dir' lines in this | |
2442 | configuration file. If you change the order of the 'cache_dir' | |
2443 | lines in this file, these index files will NOT correspond to | |
2444 | the correct 'cache_dir' entry (unless you manually rename | |
2445 | them). We recommend you do NOT use this option. It is | |
2446 | better to keep these index files in each 'cache_dir' directory. | |
5473c134 | 2447 | DOC_END |
2448 | ||
41bd17a4 | 2449 | NAME: logfile_rotate |
2450 | TYPE: int | |
2451 | DEFAULT: 10 | |
2452 | LOC: Config.Log.rotateNumber | |
5473c134 | 2453 | DOC_START |
41bd17a4 | 2454 | Specifies the number of logfile rotations to make when you |
2455 | type 'squid -k rotate'. The default is 10, which will rotate | |
2456 | with extensions 0 through 9. Setting logfile_rotate to 0 will | |
2457 | disable the file name rotation, but the logfiles are still closed | |
2458 | and re-opened. This will enable you to rename the logfiles | |
2459 | yourself just before sending the rotate signal. | |
5473c134 | 2460 | |
41bd17a4 | 2461 | Note, the 'squid -k rotate' command normally sends a USR1 |
2462 | signal to the running squid process. In certain situations | |
2463 | (e.g. on Linux with Async I/O), USR1 is used for other | |
2464 | purposes, so -k rotate uses another signal. It is best to get | |
2465 | in the habit of using 'squid -k rotate' instead of 'kill -USR1 | |
2466 | <pid>'. | |
62493678 AJ |
2467 | |
2468 | Note, from Squid-3.1 this option has no effect on the cache.log, | |
2469 | that log can be rotated separately by using debug_options | |
41bd17a4 | 2470 | DOC_END |
5473c134 | 2471 | |
41bd17a4 | 2472 | NAME: emulate_httpd_log |
2473 | COMMENT: on|off | |
2474 | TYPE: onoff | |
2475 | DEFAULT: off | |
2476 | LOC: Config.onoff.common_log | |
2477 | DOC_START | |
2478 | The Cache can emulate the log file format which many 'httpd' | |
2479 | programs use. To disable/enable this emulation, set | |
2480 | emulate_httpd_log to 'off' or 'on'. The default | |
2481 | is to use the native log format since it includes useful | |
2482 | information Squid-specific log analyzers use. | |
5473c134 | 2483 | DOC_END |
2484 | ||
41bd17a4 | 2485 | NAME: log_ip_on_direct |
2486 | COMMENT: on|off | |
2487 | TYPE: onoff | |
5473c134 | 2488 | DEFAULT: on |
41bd17a4 | 2489 | LOC: Config.onoff.log_ip_on_direct |
5473c134 | 2490 | DOC_START |
41bd17a4 | 2491 | Log the destination IP address in the hierarchy log tag when going |
2492 | direct. Earlier Squid versions logged the hostname here. If you | |
2493 | prefer the old way set this to off. | |
2494 | DOC_END | |
5473c134 | 2495 | |
41bd17a4 | 2496 | NAME: mime_table |
2497 | TYPE: string | |
2498 | DEFAULT: @DEFAULT_MIME_TABLE@ | |
2499 | LOC: Config.mimeTablePathname | |
2500 | DOC_START | |
2501 | Pathname to Squid's MIME table. You shouldn't need to change | |
2502 | this, but the default file contains examples and formatting | |
2503 | information if you do. | |
5473c134 | 2504 | DOC_END |
2505 | ||
41bd17a4 | 2506 | NAME: log_mime_hdrs |
2507 | COMMENT: on|off | |
2508 | TYPE: onoff | |
2509 | LOC: Config.onoff.log_mime_hdrs | |
2510 | DEFAULT: off | |
2511 | DOC_START | |
2512 | The Cache can record both the request and the response MIME | |
2513 | headers for each HTTP transaction. The headers are encoded | |
2514 | safely and will appear as two bracketed fields at the end of | |
2515 | the access log (for either the native or httpd-emulated log | |
2516 | formats). To enable this logging set log_mime_hdrs to 'on'. | |
2517 | DOC_END | |
5473c134 | 2518 | |
41bd17a4 | 2519 | NAME: useragent_log |
2520 | TYPE: string | |
2521 | LOC: Config.Log.useragent | |
2522 | DEFAULT: none | |
2523 | IFDEF: USE_USERAGENT_LOG | |
5473c134 | 2524 | DOC_START |
41bd17a4 | 2525 | Squid will write the User-Agent field from HTTP requests |
2526 | to the filename specified here. By default useragent_log | |
2527 | is disabled. | |
5473c134 | 2528 | DOC_END |
2529 | ||
41bd17a4 | 2530 | NAME: referer_log referrer_log |
2531 | TYPE: string | |
2532 | LOC: Config.Log.referer | |
2533 | DEFAULT: none | |
2534 | IFDEF: USE_REFERER_LOG | |
5473c134 | 2535 | DOC_START |
41bd17a4 | 2536 | Squid will write the Referer field from HTTP requests to the |
2537 | filename specified here. By default referer_log is disabled. | |
2538 | Note that "referer" is actually a misspelling of "referrer" | |
2539 | however the misspelt version has been accepted into the HTTP RFCs | |
2540 | and we accept both. | |
5473c134 | 2541 | DOC_END |
2542 | ||
41bd17a4 | 2543 | NAME: pid_filename |
2544 | TYPE: string | |
2545 | DEFAULT: @DEFAULT_PID_FILE@ | |
2546 | LOC: Config.pidFilename | |
5473c134 | 2547 | DOC_START |
41bd17a4 | 2548 | A filename to write the process-id to. To disable, enter "none". |
5473c134 | 2549 | DOC_END |
2550 | ||
41bd17a4 | 2551 | NAME: log_fqdn |
2552 | COMMENT: on|off | |
2553 | TYPE: onoff | |
2554 | DEFAULT: off | |
2555 | LOC: Config.onoff.log_fqdn | |
5473c134 | 2556 | DOC_START |
41bd17a4 | 2557 | Turn this on if you wish to log fully qualified domain names |
2558 | in the access.log. To do this Squid does a DNS lookup of all | |
2559 | IP's connecting to it. This can (in some situations) increase | |
2560 | latency, which makes your cache seem slower for interactive | |
2561 | browsing. | |
5473c134 | 2562 | DOC_END |
2563 | ||
41bd17a4 | 2564 | NAME: client_netmask |
2565 | TYPE: address | |
2566 | LOC: Config.Addrs.client_netmask | |
2567 | DEFAULT: 255.255.255.255 | |
5473c134 | 2568 | DOC_START |
41bd17a4 | 2569 | A netmask for client addresses in logfiles and cachemgr output. |
2570 | Change this to protect the privacy of your cache clients. | |
2571 | A netmask of 255.255.255.0 will log all IP's in that range with | |
2572 | the last digit set to '0'. | |
5473c134 | 2573 | DOC_END |
2574 | ||
41bd17a4 | 2575 | NAME: forward_log |
2576 | IFDEF: WIP_FWD_LOG | |
2577 | TYPE: string | |
2578 | DEFAULT: none | |
2579 | LOC: Config.Log.forward | |
5473c134 | 2580 | DOC_START |
41bd17a4 | 2581 | Logs the server-side requests. |
5473c134 | 2582 | |
41bd17a4 | 2583 | This is currently work in progress. |
5473c134 | 2584 | DOC_END |
2585 | ||
41bd17a4 | 2586 | NAME: strip_query_terms |
5473c134 | 2587 | TYPE: onoff |
41bd17a4 | 2588 | LOC: Config.onoff.strip_query_terms |
5473c134 | 2589 | DEFAULT: on |
2590 | DOC_START | |
41bd17a4 | 2591 | By default, Squid strips query terms from requested URLs before |
2592 | logging. This protects your user's privacy. | |
5473c134 | 2593 | DOC_END |
2594 | ||
41bd17a4 | 2595 | NAME: buffered_logs |
2596 | COMMENT: on|off | |
2597 | TYPE: onoff | |
2598 | DEFAULT: off | |
2599 | LOC: Config.onoff.buffered_logs | |
5473c134 | 2600 | DOC_START |
41bd17a4 | 2601 | cache.log log file is written with stdio functions, and as such |
2602 | it can be buffered or unbuffered. By default it will be unbuffered. | |
2603 | Buffering it can speed up the writing slightly (though you are | |
2604 | unlikely to need to worry unless you run with tons of debugging | |
2605 | enabled in which case performance will suffer badly anyway..). | |
6b698a21 | 2606 | DOC_END |
0976f8db | 2607 | |
2b753521 | 2608 | NAME: netdb_filename |
2609 | TYPE: string | |
2610 | DEFAULT: @DEFAULT_NETDB_FILE@ | |
2611 | LOC: Config.netdbFilename | |
fb6a61d1 | 2612 | IFDEF: USE_ICMP |
2b753521 | 2613 | DOC_START |
2614 | A filename where Squid stores it's netdb state between restarts. | |
2615 | To disable, enter "none". | |
2616 | DOC_END | |
2617 | ||
62493678 AJ |
2618 | COMMENT_START |
2619 | OPTIONS FOR TROUBLESHOOTING | |
2620 | ----------------------------------------------------------------------------- | |
2621 | COMMENT_END | |
2622 | ||
2623 | NAME: cache_log | |
2624 | TYPE: string | |
2625 | DEFAULT: none | |
2626 | DEFAULT_IF_NONE: @DEFAULT_CACHE_LOG@ | |
2627 | LOC: Debug::cache_log | |
2628 | DOC_START | |
2629 | Cache logging file. This is where general information about | |
2630 | your cache's behavior goes. You can increase the amount of data | |
2631 | logged to this file and how often its rotated with "debug_options" | |
2632 | DOC_END | |
2633 | ||
2634 | NAME: debug_options | |
2635 | TYPE: eol | |
47df1aa7 | 2636 | DEFAULT: ALL,1 |
62493678 AJ |
2637 | LOC: Debug::debugOptions |
2638 | DOC_START | |
2639 | Logging options are set as section,level where each source file | |
2640 | is assigned a unique section. Lower levels result in less | |
2641 | output, Full debugging (level 9) can result in a very large | |
2642 | log file, so be careful. | |
2643 | ||
2644 | The magic word "ALL" sets debugging levels for all sections. | |
2645 | We recommend normally running with "ALL,1". | |
2646 | ||
47df1aa7 AJ |
2647 | The rotate=N option can be used to keep more or less of these logs |
2648 | than would otherwise be kept by logfile_rotate. | |
62493678 AJ |
2649 | For most uses a single log should be enough to monitor current |
2650 | events affecting Squid. | |
2651 | DOC_END | |
2652 | ||
2653 | NAME: coredump_dir | |
2654 | TYPE: string | |
2655 | LOC: Config.coredump_dir | |
2656 | DEFAULT: none | |
2657 | DEFAULT_IF_NONE: none | |
2658 | DOC_START | |
2659 | By default Squid leaves core files in the directory from where | |
2660 | it was started. If you set 'coredump_dir' to a directory | |
2661 | that exists, Squid will chdir() to that directory at startup | |
2662 | and coredump files will be left there. | |
2663 | ||
2664 | NOCOMMENT_START | |
2665 | # Leave coredumps in the first cache dir | |
2666 | coredump_dir @DEFAULT_SWAP_DIR@ | |
2667 | NOCOMMENT_END | |
2668 | DOC_END | |
2669 | ||
2670 | ||
41bd17a4 | 2671 | COMMENT_START |
2672 | OPTIONS FOR FTP GATEWAYING | |
2673 | ----------------------------------------------------------------------------- | |
2674 | COMMENT_END | |
2675 | ||
2676 | NAME: ftp_user | |
2677 | TYPE: string | |
2678 | DEFAULT: Squid@ | |
2679 | LOC: Config.Ftp.anon_user | |
6b698a21 | 2680 | DOC_START |
41bd17a4 | 2681 | If you want the anonymous login password to be more informative |
2682 | (and enable the use of picky ftp servers), set this to something | |
2683 | reasonable for your domain, like wwwuser@somewhere.net | |
7f7db318 | 2684 | |
41bd17a4 | 2685 | The reason why this is domainless by default is the |
2686 | request can be made on the behalf of a user in any domain, | |
2687 | depending on how the cache is used. | |
2688 | Some ftp server also validate the email address is valid | |
2689 | (for example perl.com). | |
6b698a21 | 2690 | DOC_END |
0976f8db | 2691 | |
41bd17a4 | 2692 | NAME: ftp_list_width |
2693 | TYPE: size_t | |
2694 | DEFAULT: 32 | |
2695 | LOC: Config.Ftp.list_width | |
6b698a21 | 2696 | DOC_START |
41bd17a4 | 2697 | Sets the width of ftp listings. This should be set to fit in |
2698 | the width of a standard browser. Setting this too small | |
2699 | can cut off long filenames when browsing ftp sites. | |
6b698a21 | 2700 | DOC_END |
9e7dbc51 | 2701 | |
41bd17a4 | 2702 | NAME: ftp_passive |
2703 | TYPE: onoff | |
2704 | DEFAULT: on | |
2705 | LOC: Config.Ftp.passive | |
6b698a21 | 2706 | DOC_START |
41bd17a4 | 2707 | If your firewall does not allow Squid to use passive |
2708 | connections, turn off this option. | |
a689bd4e | 2709 | |
2710 | Use of ftp_epsv_all option requires this to be ON. | |
2711 | DOC_END | |
2712 | ||
2713 | NAME: ftp_epsv_all | |
2714 | TYPE: onoff | |
2715 | DEFAULT: off | |
2716 | LOC: Config.Ftp.epsv_all | |
2717 | DOC_START | |
2718 | FTP Protocol extensions permit the use of a special "EPSV ALL" command. | |
2719 | ||
2720 | NATs may be able to put the connection on a "fast path" through the | |
2721 | translator, as the EPRT command will never be used and therefore, | |
2722 | translation of the data portion of the segments will never be needed. | |
2723 | ||
2724 | When a client only expects to do two-way FTP transfers this may be useful. | |
2725 | If squid finds that it must do a three-way FTP transfer after issuing | |
2726 | an EPSV ALL command, the FTP session will fail. | |
2727 | ||
2728 | If you have any doubts about this option do not use it. | |
2729 | Squid will nicely attempt all other connection methods. | |
2730 | ||
51ee534d AJ |
2731 | Requires ftp_passive to be ON (default) for any effect. |
2732 | DOC_END | |
2733 | ||
2734 | NAME: ftp_epsv | |
2735 | TYPE: onoff | |
2736 | DEFAULT: on | |
2737 | LOC: Config.Ftp.epsv | |
2738 | DOC_START | |
2739 | FTP Protocol extensions permit the use of a special "EPSV" command. | |
2740 | ||
2741 | NATs may be able to put the connection on a "fast path" through the | |
2742 | translator using EPSV, as the EPRT command will never be used and therefore, | |
2743 | translation of the data portion of the segments will never be needed. | |
2744 | ||
2745 | Turning this OFF will prevent EPSV being attempted. | |
2746 | WARNING: Doing so will convert Squid back to the old behavior with all | |
2747 | the related problems with external NAT devices/layers. | |
2748 | ||
2749 | Requires ftp_passive to be ON (default) for any effect. | |
41bd17a4 | 2750 | DOC_END |
9e7dbc51 | 2751 | |
41bd17a4 | 2752 | NAME: ftp_sanitycheck |
2753 | TYPE: onoff | |
2754 | DEFAULT: on | |
2755 | LOC: Config.Ftp.sanitycheck | |
2756 | DOC_START | |
2757 | For security and data integrity reasons Squid by default performs | |
2758 | sanity checks of the addresses of FTP data connections ensure the | |
2759 | data connection is to the requested server. If you need to allow | |
2760 | FTP connections to servers using another IP address for the data | |
2761 | connection turn this off. | |
2762 | DOC_END | |
9e7dbc51 | 2763 | |
41bd17a4 | 2764 | NAME: ftp_telnet_protocol |
2765 | TYPE: onoff | |
2766 | DEFAULT: on | |
2767 | LOC: Config.Ftp.telnet | |
2768 | DOC_START | |
2769 | The FTP protocol is officially defined to use the telnet protocol | |
2770 | as transport channel for the control connection. However, many | |
2771 | implementations are broken and does not respect this aspect of | |
2772 | the FTP protocol. | |
2773 | ||
2774 | If you have trouble accessing files with ASCII code 255 in the | |
2775 | path or similar problems involving this ASCII code you can | |
2776 | try setting this directive to off. If that helps, report to the | |
2777 | operator of the FTP server in question that their FTP server | |
2778 | is broken and does not follow the FTP standard. | |
2779 | DOC_END | |
2780 | ||
2781 | COMMENT_START | |
2782 | OPTIONS FOR EXTERNAL SUPPORT PROGRAMS | |
2783 | ----------------------------------------------------------------------------- | |
2784 | COMMENT_END | |
2785 | ||
2786 | NAME: diskd_program | |
2787 | TYPE: string | |
2788 | DEFAULT: @DEFAULT_DISKD@ | |
2789 | LOC: Config.Program.diskd | |
2790 | DOC_START | |
2791 | Specify the location of the diskd executable. | |
2792 | Note this is only useful if you have compiled in | |
2793 | diskd as one of the store io modules. | |
2794 | DOC_END | |
2795 | ||
2796 | NAME: unlinkd_program | |
2797 | IFDEF: USE_UNLINKD | |
2798 | TYPE: string | |
2799 | DEFAULT: @DEFAULT_UNLINKD@ | |
2800 | LOC: Config.Program.unlinkd | |
2801 | DOC_START | |
2802 | Specify the location of the executable for file deletion process. | |
2803 | DOC_END | |
2804 | ||
2805 | NAME: pinger_program | |
2806 | TYPE: string | |
2807 | DEFAULT: @DEFAULT_PINGER@ | |
cc192b50 | 2808 | LOC: Config.pinger.program |
41bd17a4 | 2809 | IFDEF: USE_ICMP |
2810 | DOC_START | |
2811 | Specify the location of the executable for the pinger process. | |
2812 | DOC_END | |
2813 | ||
cc192b50 | 2814 | NAME: pinger_enable |
2815 | TYPE: onoff | |
2816 | DEFAULT: on | |
2817 | LOC: Config.pinger.enable | |
2818 | IFDEF: USE_ICMP | |
2819 | DOC_START | |
2820 | Control whether the pinger is active at run-time. | |
2821 | Enables turning ICMP pinger on and off with a simple squid -k reconfigure. | |
2822 | DOC_END | |
2823 | ||
2824 | ||
41bd17a4 | 2825 | COMMENT_START |
2826 | OPTIONS FOR URL REWRITING | |
2827 | ----------------------------------------------------------------------------- | |
2828 | COMMENT_END | |
2829 | ||
2830 | NAME: url_rewrite_program redirect_program | |
2831 | TYPE: wordlist | |
2832 | LOC: Config.Program.redirect | |
2833 | DEFAULT: none | |
2834 | DOC_START | |
2835 | Specify the location of the executable for the URL rewriter. | |
2836 | Since they can perform almost any function there isn't one included. | |
2837 | ||
2838 | For each requested URL rewriter will receive on line with the format | |
2839 | ||
c71adec1 | 2840 | URL <SP> client_ip "/" fqdn <SP> user <SP> method [<SP> kvpairs]<NL> |
2841 | ||
2842 | In the future, the rewriter interface will be extended with | |
2843 | key=value pairs ("kvpairs" shown above). Rewriter programs | |
2844 | should be prepared to receive and possibly ignore additional | |
2845 | whitespace-separated tokens on each input line. | |
41bd17a4 | 2846 | |
2847 | And the rewriter may return a rewritten URL. The other components of | |
2848 | the request line does not need to be returned (ignored if they are). | |
2849 | ||
2850 | The rewriter can also indicate that a client-side redirect should | |
2851 | be performed to the new URL. This is done by prefixing the returned | |
2852 | URL with "301:" (moved permanently) or 302: (moved temporarily). | |
2853 | ||
2854 | By default, a URL rewriter is not used. | |
2855 | DOC_END | |
2856 | ||
2857 | NAME: url_rewrite_children redirect_children | |
2858 | TYPE: int | |
2859 | DEFAULT: 5 | |
2860 | LOC: Config.redirectChildren | |
2861 | DOC_START | |
2862 | The number of redirector processes to spawn. If you start | |
2863 | too few Squid will have to wait for them to process a backlog of | |
2864 | URLs, slowing it down. If you start too many they will use RAM | |
2865 | and other system resources. | |
2866 | DOC_END | |
2867 | ||
2868 | NAME: url_rewrite_concurrency redirect_concurrency | |
2869 | TYPE: int | |
2870 | DEFAULT: 0 | |
2871 | LOC: Config.redirectConcurrency | |
2872 | DOC_START | |
2873 | The number of requests each redirector helper can handle in | |
2874 | parallel. Defaults to 0 which indicates the redirector | |
2875 | is a old-style single threaded redirector. | |
6a171502 AJ |
2876 | |
2877 | When this directive is set to a value >= 1 then the protocol | |
2878 | used to communicate with the helper is modified to include | |
2879 | a request ID in front of the request/response. The request | |
2880 | ID from the request must be echoed back with the response | |
2881 | to that request. | |
41bd17a4 | 2882 | DOC_END |
2883 | ||
2884 | NAME: url_rewrite_host_header redirect_rewrites_host_header | |
2885 | TYPE: onoff | |
2886 | DEFAULT: on | |
2887 | LOC: Config.onoff.redir_rewrites_host | |
2888 | DOC_START | |
2889 | By default Squid rewrites any Host: header in redirected | |
2890 | requests. If you are running an accelerator this may | |
2891 | not be a wanted effect of a redirector. | |
2892 | ||
2893 | WARNING: Entries are cached on the result of the URL rewriting | |
2894 | process, so be careful if you have domain-virtual hosts. | |
2895 | DOC_END | |
2896 | ||
2897 | NAME: url_rewrite_access redirector_access | |
2898 | TYPE: acl_access | |
2899 | DEFAULT: none | |
2900 | LOC: Config.accessList.redirector | |
2901 | DOC_START | |
2902 | If defined, this access list specifies which requests are | |
2903 | sent to the redirector processes. By default all requests | |
2904 | are sent. | |
2905 | DOC_END | |
2906 | ||
2907 | NAME: url_rewrite_bypass redirector_bypass | |
2908 | TYPE: onoff | |
2909 | LOC: Config.onoff.redirector_bypass | |
2910 | DEFAULT: off | |
2911 | DOC_START | |
2912 | When this is 'on', a request will not go through the | |
2913 | redirector if all redirectors are busy. If this is 'off' | |
2914 | and the redirector queue grows too large, Squid will exit | |
2915 | with a FATAL error and ask you to increase the number of | |
2916 | redirectors. You should only enable this if the redirectors | |
2917 | are not critical to your caching system. If you use | |
2918 | redirectors for access control, and you enable this option, | |
2919 | users may have access to pages they should not | |
2920 | be allowed to request. | |
2921 | DOC_END | |
2922 | ||
2923 | COMMENT_START | |
2924 | OPTIONS FOR TUNING THE CACHE | |
2925 | ----------------------------------------------------------------------------- | |
2926 | COMMENT_END | |
2927 | ||
f04b37d8 | 2928 | NAME: cache no_cache |
2929 | TYPE: acl_access | |
2930 | DEFAULT: none | |
2931 | LOC: Config.accessList.noCache | |
41bd17a4 | 2932 | DOC_START |
240887f0 | 2933 | A list of ACL elements which, if matched and denied, cause the request to |
f04b37d8 | 2934 | not be satisfied from the cache and the reply to not be cached. |
2935 | In other words, use this to force certain objects to never be cached. | |
41bd17a4 | 2936 | |
240887f0 | 2937 | You must use the words 'allow' or 'deny' to indicate whether items |
2938 | matching the ACL should be allowed or denied into the cache. | |
f04b37d8 | 2939 | |
240887f0 | 2940 | Default is to allow all to be cached. |
41bd17a4 | 2941 | DOC_END |
2942 | ||
2943 | NAME: refresh_pattern | |
2944 | TYPE: refreshpattern | |
2945 | LOC: Config.Refresh | |
2946 | DEFAULT: none | |
2947 | DOC_START | |
2948 | usage: refresh_pattern [-i] regex min percent max [options] | |
9e7dbc51 | 2949 | |
6b698a21 | 2950 | By default, regular expressions are CASE-SENSITIVE. To make |
2951 | them case-insensitive, use the -i option. | |
9e7dbc51 | 2952 | |
41bd17a4 | 2953 | 'Min' is the time (in minutes) an object without an explicit |
2954 | expiry time should be considered fresh. The recommended | |
2955 | value is 0, any higher values may cause dynamic applications | |
2956 | to be erroneously cached unless the application designer | |
2957 | has taken the appropriate actions. | |
9e7dbc51 | 2958 | |
41bd17a4 | 2959 | 'Percent' is a percentage of the objects age (time since last |
2960 | modification age) an object without explicit expiry time | |
2961 | will be considered fresh. | |
5b807763 | 2962 | |
41bd17a4 | 2963 | 'Max' is an upper limit on how long objects without an explicit |
2964 | expiry time will be considered fresh. | |
9e7dbc51 | 2965 | |
41bd17a4 | 2966 | options: override-expire |
2967 | override-lastmod | |
2968 | reload-into-ims | |
2969 | ignore-reload | |
2970 | ignore-no-cache | |
2971 | ignore-no-store | |
4ca08219 | 2972 | ignore-must-revalidate |
41bd17a4 | 2973 | ignore-private |
2974 | ignore-auth | |
2975 | refresh-ims | |
a0ec9f68 | 2976 | |
41bd17a4 | 2977 | override-expire enforces min age even if the server |
9b2ad080 HN |
2978 | sent an explicit expiry time (e.g., with the |
2979 | Expires: header or Cache-Control: max-age). Doing this | |
2980 | VIOLATES the HTTP standard. Enabling this feature | |
2981 | could make you liable for problems which it causes. | |
6468fe10 | 2982 | |
04925576 AJ |
2983 | Note: override-expire does not enforce staleness - it only extends |
2984 | freshness / min. If the server returns a Expires time which | |
2985 | is longer than your max time, Squid will still consider | |
2986 | the object fresh for that period of time. | |
2987 | ||
41bd17a4 | 2988 | override-lastmod enforces min age even on objects |
2989 | that were modified recently. | |
934b03fc | 2990 | |
41bd17a4 | 2991 | reload-into-ims changes client no-cache or ``reload'' |
2992 | to If-Modified-Since requests. Doing this VIOLATES the | |
2993 | HTTP standard. Enabling this feature could make you | |
2994 | liable for problems which it causes. | |
dba79ac5 | 2995 | |
41bd17a4 | 2996 | ignore-reload ignores a client no-cache or ``reload'' |
2997 | header. Doing this VIOLATES the HTTP standard. Enabling | |
2998 | this feature could make you liable for problems which | |
2999 | it causes. | |
9bc73deb | 3000 | |
41bd17a4 | 3001 | ignore-no-cache ignores any ``Pragma: no-cache'' and |
3002 | ``Cache-control: no-cache'' headers received from a server. | |
3003 | The HTTP RFC never allows the use of this (Pragma) header | |
3004 | from a server, only a client, though plenty of servers | |
3005 | send it anyway. | |
3006 | ||
3007 | ignore-no-store ignores any ``Cache-control: no-store'' | |
3008 | headers received from a server. Doing this VIOLATES | |
3009 | the HTTP standard. Enabling this feature could make you | |
3010 | liable for problems which it causes. | |
3011 | ||
4ca08219 AJ |
3012 | ignore-must-revalidate ignores any ``Cache-Control: must-revalidate`` |
3013 | headers received from a server. Doing this VIOLATES | |
3014 | the HTTP standard. Enabling this feature could make you | |
3015 | liable for problems which it causes. | |
3016 | ||
41bd17a4 | 3017 | ignore-private ignores any ``Cache-control: private'' |
3018 | headers received from a server. Doing this VIOLATES | |
3019 | the HTTP standard. Enabling this feature could make you | |
3020 | liable for problems which it causes. | |
3021 | ||
3022 | ignore-auth caches responses to requests with authorization, | |
3023 | as if the originserver had sent ``Cache-control: public'' | |
3024 | in the response header. Doing this VIOLATES the HTTP standard. | |
3025 | Enabling this feature could make you liable for problems which | |
3026 | it causes. | |
3027 | ||
3028 | refresh-ims causes squid to contact the origin server | |
3029 | when a client issues an If-Modified-Since request. This | |
3030 | ensures that the client will receive an updated version | |
3031 | if one is available. | |
3032 | ||
3033 | Basically a cached object is: | |
3034 | ||
3035 | FRESH if expires < now, else STALE | |
3036 | STALE if age > max | |
3037 | FRESH if lm-factor < percent, else STALE | |
3038 | FRESH if age < min | |
3039 | else STALE | |
3040 | ||
3041 | The refresh_pattern lines are checked in the order listed here. | |
3042 | The first entry which matches is used. If none of the entries | |
3043 | match the default will be used. | |
3044 | ||
3045 | Note, you must uncomment all the default lines if you want | |
3046 | to change one. The default setting is only active if none is | |
3047 | used. | |
3048 | ||
3049 | Suggested default: | |
3050 | NOCOMMENT_START | |
3051 | refresh_pattern ^ftp: 1440 20% 10080 | |
3052 | refresh_pattern ^gopher: 1440 0% 1440 | |
89db45fa | 3053 | refresh_pattern -i (/cgi-bin/|\?) 0 0% 0 |
41bd17a4 | 3054 | refresh_pattern . 0 20% 4320 |
3055 | NOCOMMENT_END | |
3056 | DOC_END | |
3057 | ||
3058 | NAME: quick_abort_min | |
3059 | COMMENT: (KB) | |
3060 | TYPE: kb_int64_t | |
3061 | DEFAULT: 16 KB | |
3062 | LOC: Config.quickAbort.min | |
3063 | DOC_NONE | |
3064 | ||
3065 | NAME: quick_abort_max | |
3066 | COMMENT: (KB) | |
3067 | TYPE: kb_int64_t | |
3068 | DEFAULT: 16 KB | |
3069 | LOC: Config.quickAbort.max | |
3070 | DOC_NONE | |
3071 | ||
3072 | NAME: quick_abort_pct | |
3073 | COMMENT: (percent) | |
3074 | TYPE: int | |
3075 | DEFAULT: 95 | |
3076 | LOC: Config.quickAbort.pct | |
3077 | DOC_START | |
3078 | The cache by default continues downloading aborted requests | |
3079 | which are almost completed (less than 16 KB remaining). This | |
3080 | may be undesirable on slow (e.g. SLIP) links and/or very busy | |
3081 | caches. Impatient users may tie up file descriptors and | |
3082 | bandwidth by repeatedly requesting and immediately aborting | |
3083 | downloads. | |
3084 | ||
3085 | When the user aborts a request, Squid will check the | |
3086 | quick_abort values to the amount of data transfered until | |
3087 | then. | |
3088 | ||
3089 | If the transfer has less than 'quick_abort_min' KB remaining, | |
3090 | it will finish the retrieval. | |
3091 | ||
3092 | If the transfer has more than 'quick_abort_max' KB remaining, | |
3093 | it will abort the retrieval. | |
3094 | ||
3095 | If more than 'quick_abort_pct' of the transfer has completed, | |
3096 | it will finish the retrieval. | |
3097 | ||
3098 | If you do not want any retrieval to continue after the client | |
3099 | has aborted, set both 'quick_abort_min' and 'quick_abort_max' | |
3100 | to '0 KB'. | |
3101 | ||
3102 | If you want retrievals to always continue if they are being | |
3103 | cached set 'quick_abort_min' to '-1 KB'. | |
3104 | DOC_END | |
60d096f4 | 3105 | |
41bd17a4 | 3106 | NAME: read_ahead_gap |
3107 | COMMENT: buffer-size | |
3108 | TYPE: b_int64_t | |
3109 | LOC: Config.readAheadGap | |
3110 | DEFAULT: 16 KB | |
3111 | DOC_START | |
3112 | The amount of data the cache will buffer ahead of what has been | |
3113 | sent to the client when retrieving an object from another server. | |
3114 | DOC_END | |
53e738c6 | 3115 | |
41bd17a4 | 3116 | NAME: negative_ttl |
ac9cc053 | 3117 | IFDEF: HTTP_VIOLATIONS |
41bd17a4 | 3118 | COMMENT: time-units |
3119 | TYPE: time_t | |
3120 | LOC: Config.negativeTtl | |
ac9cc053 | 3121 | DEFAULT: 0 seconds |
41bd17a4 | 3122 | DOC_START |
ac9cc053 AJ |
3123 | Set the Default Time-to-Live (TTL) for failed requests. |
3124 | Certain types of failures (such as "connection refused" and | |
3125 | "404 Not Found") are able to be negatively-cached for a short time. | |
3126 | Modern web servers should provide Expires: header, however if they | |
3127 | do not this can provide a minimum TTL. | |
3128 | The default is not to cache errors with unknown expiry details. | |
3129 | ||
3130 | Note that this is different from negative caching of DNS lookups. | |
39956c7c AJ |
3131 | |
3132 | WARNING: Doing this VIOLATES the HTTP standard. Enabling | |
3133 | this feature could make you liable for problems which it | |
3134 | causes. | |
41bd17a4 | 3135 | DOC_END |
53e738c6 | 3136 | |
41bd17a4 | 3137 | NAME: positive_dns_ttl |
3138 | COMMENT: time-units | |
3139 | TYPE: time_t | |
3140 | LOC: Config.positiveDnsTtl | |
3141 | DEFAULT: 6 hours | |
3142 | DOC_START | |
3143 | Upper limit on how long Squid will cache positive DNS responses. | |
3144 | Default is 6 hours (360 minutes). This directive must be set | |
3145 | larger than negative_dns_ttl. | |
3146 | DOC_END | |
c4ab8329 | 3147 | |
41bd17a4 | 3148 | NAME: negative_dns_ttl |
3149 | COMMENT: time-units | |
3150 | TYPE: time_t | |
3151 | LOC: Config.negativeDnsTtl | |
3152 | DEFAULT: 1 minutes | |
3153 | DOC_START | |
3154 | Time-to-Live (TTL) for negative caching of failed DNS lookups. | |
3155 | This also sets the lower cache limit on positive lookups. | |
3156 | Minimum value is 1 second, and it is not recommendable to go | |
3157 | much below 10 seconds. | |
3158 | DOC_END | |
7df0bfd7 | 3159 | |
41bd17a4 | 3160 | NAME: range_offset_limit |
3161 | COMMENT: (bytes) | |
3162 | TYPE: b_int64_t | |
3163 | LOC: Config.rangeOffsetLimit | |
3164 | DEFAULT: 0 KB | |
3165 | DOC_START | |
3166 | Sets a upper limit on how far into the the file a Range request | |
3167 | may be to cause Squid to prefetch the whole file. If beyond this | |
3168 | limit Squid forwards the Range request as it is and the result | |
3169 | is NOT cached. | |
c4ab8329 | 3170 | |
41bd17a4 | 3171 | This is to stop a far ahead range request (lets say start at 17MB) |
3172 | from making Squid fetch the whole object up to that point before | |
3173 | sending anything to the client. | |
a7ad6e4e | 3174 | |
ab275c7b AJ |
3175 | A value of 0 causes Squid to never fetch more than the |
3176 | client requested. (default) | |
3177 | ||
41bd17a4 | 3178 | A value of -1 causes Squid to always fetch the object from the |
3179 | beginning so it may cache the result. (2.0 style) | |
a7ad6e4e | 3180 | |
ab275c7b AJ |
3181 | NP: Using -1 here will override any quick_abort settings that may |
3182 | otherwise apply to the range request. The range request will | |
3183 | be fully fetched from start to finish regardless of the client | |
3184 | actions. This affects bandwidth usage. | |
41bd17a4 | 3185 | DOC_END |
d95b862f | 3186 | |
41bd17a4 | 3187 | NAME: minimum_expiry_time |
3188 | COMMENT: (seconds) | |
3189 | TYPE: time_t | |
3190 | LOC: Config.minimum_expiry_time | |
3191 | DEFAULT: 60 seconds | |
3192 | DOC_START | |
3193 | The minimum caching time according to (Expires - Date) | |
3194 | Headers Squid honors if the object can't be revalidated | |
649fa918 | 3195 | defaults to 60 seconds. In reverse proxy environments it |
41bd17a4 | 3196 | might be desirable to honor shorter object lifetimes. It |
3197 | is most likely better to make your server return a | |
3198 | meaningful Last-Modified header however. In ESI environments | |
3199 | where page fragments often have short lifetimes, this will | |
3200 | often be best set to 0. | |
3201 | DOC_END | |
c68e9c6b | 3202 | |
41bd17a4 | 3203 | NAME: store_avg_object_size |
3204 | COMMENT: (kbytes) | |
3e62bd58 | 3205 | TYPE: kb_int64_t |
41bd17a4 | 3206 | DEFAULT: 13 KB |
3207 | LOC: Config.Store.avgObjectSize | |
3208 | DOC_START | |
3209 | Average object size, used to estimate number of objects your | |
3210 | cache can hold. The default is 13 KB. | |
cccac0a2 | 3211 | DOC_END |
3212 | ||
41bd17a4 | 3213 | NAME: store_objects_per_bucket |
3214 | TYPE: int | |
3215 | DEFAULT: 20 | |
3216 | LOC: Config.Store.objectsPerBucket | |
3217 | DOC_START | |
3218 | Target number of objects per bucket in the store hash table. | |
3219 | Lowering this value increases the total number of buckets and | |
3220 | also the storage maintenance rate. The default is 20. | |
3221 | DOC_END | |
3222 | ||
3223 | COMMENT_START | |
3224 | HTTP OPTIONS | |
3225 | ----------------------------------------------------------------------------- | |
3226 | COMMENT_END | |
3227 | ||
f04b37d8 | 3228 | NAME: request_header_max_size |
3229 | COMMENT: (KB) | |
3230 | TYPE: b_size_t | |
df2eec10 | 3231 | DEFAULT: 64 KB |
f04b37d8 | 3232 | LOC: Config.maxRequestHeaderSize |
3233 | DOC_START | |
3234 | This specifies the maximum size for HTTP headers in a request. | |
3235 | Request headers are usually relatively small (about 512 bytes). | |
3236 | Placing a limit on the request header size will catch certain | |
3237 | bugs (for example with persistent connections) and possibly | |
3238 | buffer-overflow or denial-of-service attacks. | |
3239 | DOC_END | |
3240 | ||
3241 | NAME: reply_header_max_size | |
3242 | COMMENT: (KB) | |
3243 | TYPE: b_size_t | |
df2eec10 | 3244 | DEFAULT: 64 KB |
f04b37d8 | 3245 | LOC: Config.maxReplyHeaderSize |
3246 | DOC_START | |
3247 | This specifies the maximum size for HTTP headers in a reply. | |
3248 | Reply headers are usually relatively small (about 512 bytes). | |
3249 | Placing a limit on the reply header size will catch certain | |
3250 | bugs (for example with persistent connections) and possibly | |
3251 | buffer-overflow or denial-of-service attacks. | |
3252 | DOC_END | |
3253 | ||
3254 | NAME: request_body_max_size | |
3255 | COMMENT: (bytes) | |
3256 | TYPE: b_int64_t | |
3257 | DEFAULT: 0 KB | |
3258 | LOC: Config.maxRequestBodySize | |
3259 | DOC_START | |
3260 | This specifies the maximum size for an HTTP request body. | |
3261 | In other words, the maximum size of a PUT/POST request. | |
3262 | A user who attempts to send a request with a body larger | |
3263 | than this limit receives an "Invalid Request" error message. | |
3264 | If you set this parameter to a zero (the default), there will | |
3265 | be no limit imposed. | |
3266 | DOC_END | |
3267 | ||
41bd17a4 | 3268 | NAME: broken_posts |
aa49962c | 3269 | IFDEF: HTTP_VIOLATIONS |
cccac0a2 | 3270 | TYPE: acl_access |
cccac0a2 | 3271 | DEFAULT: none |
41bd17a4 | 3272 | LOC: Config.accessList.brokenPosts |
cccac0a2 | 3273 | DOC_START |
41bd17a4 | 3274 | A list of ACL elements which, if matched, causes Squid to send |
3275 | an extra CRLF pair after the body of a PUT/POST request. | |
cccac0a2 | 3276 | |
41bd17a4 | 3277 | Some HTTP servers has broken implementations of PUT/POST, |
3278 | and rely on an extra CRLF pair sent by some WWW clients. | |
cccac0a2 | 3279 | |
41bd17a4 | 3280 | Quote from RFC2616 section 4.1 on this matter: |
cccac0a2 | 3281 | |
41bd17a4 | 3282 | Note: certain buggy HTTP/1.0 client implementations generate an |
3283 | extra CRLF's after a POST request. To restate what is explicitly | |
3284 | forbidden by the BNF, an HTTP/1.1 client must not preface or follow | |
3285 | a request with an extra CRLF. | |
cccac0a2 | 3286 | |
41bd17a4 | 3287 | Example: |
3288 | acl buggy_server url_regex ^http://.... | |
3289 | broken_posts allow buggy_server | |
3290 | DOC_END | |
cccac0a2 | 3291 | |
41bd17a4 | 3292 | NAME: via |
3293 | IFDEF: HTTP_VIOLATIONS | |
3294 | COMMENT: on|off | |
3295 | TYPE: onoff | |
3296 | DEFAULT: on | |
3297 | LOC: Config.onoff.via | |
3298 | DOC_START | |
3299 | If set (default), Squid will include a Via header in requests and | |
3300 | replies as required by RFC2616. | |
3301 | DOC_END | |
4cc6eb12 | 3302 | |
41bd17a4 | 3303 | NAME: ie_refresh |
3304 | COMMENT: on|off | |
3305 | TYPE: onoff | |
3306 | LOC: Config.onoff.ie_refresh | |
3307 | DEFAULT: off | |
3308 | DOC_START | |
3309 | Microsoft Internet Explorer up until version 5.5 Service | |
3310 | Pack 1 has an issue with transparent proxies, wherein it | |
3311 | is impossible to force a refresh. Turning this on provides | |
3312 | a partial fix to the problem, by causing all IMS-REFRESH | |
3313 | requests from older IE versions to check the origin server | |
3314 | for fresh content. This reduces hit ratio by some amount | |
3315 | (~10% in my experience), but allows users to actually get | |
3316 | fresh content when they want it. Note because Squid | |
3317 | cannot tell if the user is using 5.5 or 5.5SP1, the behavior | |
3318 | of 5.5 is unchanged from old versions of Squid (i.e. a | |
3319 | forced refresh is impossible). Newer versions of IE will, | |
3320 | hopefully, continue to have the new behavior and will be | |
3321 | handled based on that assumption. This option defaults to | |
3322 | the old Squid behavior, which is better for hit ratios but | |
3323 | worse for clients using IE, if they need to be able to | |
3324 | force fresh content. | |
3325 | DOC_END | |
b9d7fe3e | 3326 | |
41bd17a4 | 3327 | NAME: vary_ignore_expire |
3328 | COMMENT: on|off | |
3329 | TYPE: onoff | |
3330 | LOC: Config.onoff.vary_ignore_expire | |
3331 | DEFAULT: off | |
3332 | DOC_START | |
3333 | Many HTTP servers supporting Vary gives such objects | |
3334 | immediate expiry time with no cache-control header | |
3335 | when requested by a HTTP/1.0 client. This option | |
3336 | enables Squid to ignore such expiry times until | |
3337 | HTTP/1.1 is fully implemented. | |
7e73cd78 AJ |
3338 | |
3339 | WARNING: If turned on this may eventually cause some | |
3340 | varying objects not intended for caching to get cached. | |
cccac0a2 | 3341 | DOC_END |
c4ab8329 | 3342 | |
41bd17a4 | 3343 | NAME: request_entities |
3344 | TYPE: onoff | |
3345 | LOC: Config.onoff.request_entities | |
3346 | DEFAULT: off | |
3347 | DOC_START | |
3348 | Squid defaults to deny GET and HEAD requests with request entities, | |
3349 | as the meaning of such requests are undefined in the HTTP standard | |
3350 | even if not explicitly forbidden. | |
0976f8db | 3351 | |
41bd17a4 | 3352 | Set this directive to on if you have clients which insists |
3353 | on sending request entities in GET or HEAD requests. But be warned | |
3354 | that there is server software (both proxies and web servers) which | |
3355 | can fail to properly process this kind of request which may make you | |
3356 | vulnerable to cache pollution attacks if enabled. | |
cccac0a2 | 3357 | DOC_END |
6b53c392 | 3358 | |
41bd17a4 | 3359 | NAME: request_header_access |
3360 | IFDEF: HTTP_VIOLATIONS | |
3361 | TYPE: http_header_access[] | |
3362 | LOC: Config.request_header_access | |
cccac0a2 | 3363 | DEFAULT: none |
cccac0a2 | 3364 | DOC_START |
41bd17a4 | 3365 | Usage: request_header_access header_name allow|deny [!]aclname ... |
0976f8db | 3366 | |
41bd17a4 | 3367 | WARNING: Doing this VIOLATES the HTTP standard. Enabling |
3368 | this feature could make you liable for problems which it | |
3369 | causes. | |
0976f8db | 3370 | |
41bd17a4 | 3371 | This option replaces the old 'anonymize_headers' and the |
3372 | older 'http_anonymizer' option with something that is much | |
3373 | more configurable. This new method creates a list of ACLs | |
3374 | for each header, allowing you very fine-tuned header | |
3375 | mangling. | |
934b03fc | 3376 | |
41bd17a4 | 3377 | This option only applies to request headers, i.e., from the |
3378 | client to the server. | |
5401aa8d | 3379 | |
41bd17a4 | 3380 | You can only specify known headers for the header name. |
3381 | Other headers are reclassified as 'Other'. You can also | |
3382 | refer to all the headers with 'All'. | |
5401aa8d | 3383 | |
41bd17a4 | 3384 | For example, to achieve the same behavior as the old |
3385 | 'http_anonymizer standard' option, you should use: | |
5401aa8d | 3386 | |
41bd17a4 | 3387 | request_header_access From deny all |
3388 | request_header_access Referer deny all | |
3389 | request_header_access Server deny all | |
3390 | request_header_access User-Agent deny all | |
3391 | request_header_access WWW-Authenticate deny all | |
3392 | request_header_access Link deny all | |
5401aa8d | 3393 | |
41bd17a4 | 3394 | Or, to reproduce the old 'http_anonymizer paranoid' feature |
3395 | you should use: | |
5401aa8d | 3396 | |
41bd17a4 | 3397 | request_header_access Allow allow all |
3398 | request_header_access Authorization allow all | |
3399 | request_header_access WWW-Authenticate allow all | |
3400 | request_header_access Proxy-Authorization allow all | |
3401 | request_header_access Proxy-Authenticate allow all | |
3402 | request_header_access Cache-Control allow all | |
3403 | request_header_access Content-Encoding allow all | |
3404 | request_header_access Content-Length allow all | |
3405 | request_header_access Content-Type allow all | |
3406 | request_header_access Date allow all | |
3407 | request_header_access Expires allow all | |
3408 | request_header_access Host allow all | |
3409 | request_header_access If-Modified-Since allow all | |
3410 | request_header_access Last-Modified allow all | |
3411 | request_header_access Location allow all | |
3412 | request_header_access Pragma allow all | |
3413 | request_header_access Accept allow all | |
3414 | request_header_access Accept-Charset allow all | |
3415 | request_header_access Accept-Encoding allow all | |
3416 | request_header_access Accept-Language allow all | |
3417 | request_header_access Content-Language allow all | |
3418 | request_header_access Mime-Version allow all | |
3419 | request_header_access Retry-After allow all | |
3420 | request_header_access Title allow all | |
3421 | request_header_access Connection allow all | |
3422 | request_header_access Proxy-Connection allow all | |
3423 | request_header_access All deny all | |
5401aa8d | 3424 | |
41bd17a4 | 3425 | although many of those are HTTP reply headers, and so should be |
3426 | controlled with the reply_header_access directive. | |
5401aa8d | 3427 | |
41bd17a4 | 3428 | By default, all headers are allowed (no anonymizing is |
3429 | performed). | |
5401aa8d | 3430 | DOC_END |
3431 | ||
41bd17a4 | 3432 | NAME: reply_header_access |
3433 | IFDEF: HTTP_VIOLATIONS | |
3434 | TYPE: http_header_access[] | |
3435 | LOC: Config.reply_header_access | |
cccac0a2 | 3436 | DEFAULT: none |
3437 | DOC_START | |
41bd17a4 | 3438 | Usage: reply_header_access header_name allow|deny [!]aclname ... |
934b03fc | 3439 | |
41bd17a4 | 3440 | WARNING: Doing this VIOLATES the HTTP standard. Enabling |
3441 | this feature could make you liable for problems which it | |
3442 | causes. | |
934b03fc | 3443 | |
41bd17a4 | 3444 | This option only applies to reply headers, i.e., from the |
3445 | server to the client. | |
934b03fc | 3446 | |
41bd17a4 | 3447 | This is the same as request_header_access, but in the other |
3448 | direction. | |
6b53c392 | 3449 | |
41bd17a4 | 3450 | This option replaces the old 'anonymize_headers' and the |
3451 | older 'http_anonymizer' option with something that is much | |
3452 | more configurable. This new method creates a list of ACLs | |
3453 | for each header, allowing you very fine-tuned header | |
3454 | mangling. | |
cccac0a2 | 3455 | |
41bd17a4 | 3456 | You can only specify known headers for the header name. |
3457 | Other headers are reclassified as 'Other'. You can also | |
3458 | refer to all the headers with 'All'. | |
cccac0a2 | 3459 | |
41bd17a4 | 3460 | For example, to achieve the same behavior as the old |
3461 | 'http_anonymizer standard' option, you should use: | |
cccac0a2 | 3462 | |
41bd17a4 | 3463 | reply_header_access From deny all |
3464 | reply_header_access Referer deny all | |
3465 | reply_header_access Server deny all | |
3466 | reply_header_access User-Agent deny all | |
3467 | reply_header_access WWW-Authenticate deny all | |
3468 | reply_header_access Link deny all | |
cccac0a2 | 3469 | |
41bd17a4 | 3470 | Or, to reproduce the old 'http_anonymizer paranoid' feature |
3471 | you should use: | |
cccac0a2 | 3472 | |
41bd17a4 | 3473 | reply_header_access Allow allow all |
3474 | reply_header_access Authorization allow all | |
3475 | reply_header_access WWW-Authenticate allow all | |
3476 | reply_header_access Proxy-Authorization allow all | |
3477 | reply_header_access Proxy-Authenticate allow all | |
3478 | reply_header_access Cache-Control allow all | |
3479 | reply_header_access Content-Encoding allow all | |
3480 | reply_header_access Content-Length allow all | |
3481 | reply_header_access Content-Type allow all | |
3482 | reply_header_access Date allow all | |
3483 | reply_header_access Expires allow all | |
3484 | reply_header_access Host allow all | |
3485 | reply_header_access If-Modified-Since allow all | |
3486 | reply_header_access Last-Modified allow all | |
3487 | reply_header_access Location allow all | |
3488 | reply_header_access Pragma allow all | |
3489 | reply_header_access Accept allow all | |
3490 | reply_header_access Accept-Charset allow all | |
3491 | reply_header_access Accept-Encoding allow all | |
3492 | reply_header_access Accept-Language allow all | |
3493 | reply_header_access Content-Language allow all | |
3494 | reply_header_access Mime-Version allow all | |
3495 | reply_header_access Retry-After allow all | |
3496 | reply_header_access Title allow all | |
3497 | reply_header_access Connection allow all | |
3498 | reply_header_access Proxy-Connection allow all | |
3499 | reply_header_access All deny all | |
cccac0a2 | 3500 | |
41bd17a4 | 3501 | although the HTTP request headers won't be usefully controlled |
3502 | by this directive -- see request_header_access for details. | |
cccac0a2 | 3503 | |
41bd17a4 | 3504 | By default, all headers are allowed (no anonymizing is |
3505 | performed). | |
cccac0a2 | 3506 | DOC_END |
3507 | ||
41bd17a4 | 3508 | NAME: header_replace |
3509 | IFDEF: HTTP_VIOLATIONS | |
3510 | TYPE: http_header_replace[] | |
3511 | LOC: Config.request_header_access | |
cccac0a2 | 3512 | DEFAULT: none |
41bd17a4 | 3513 | DOC_START |
3514 | Usage: header_replace header_name message | |
3515 | Example: header_replace User-Agent Nutscrape/1.0 (CP/M; 8-bit) | |
cccac0a2 | 3516 | |
41bd17a4 | 3517 | This option allows you to change the contents of headers |
3518 | denied with header_access above, by replacing them with | |
3519 | some fixed string. This replaces the old fake_user_agent | |
3520 | option. | |
cccac0a2 | 3521 | |
41bd17a4 | 3522 | This only applies to request headers, not reply headers. |
cccac0a2 | 3523 | |
41bd17a4 | 3524 | By default, headers are removed if denied. |
3525 | DOC_END | |
cccac0a2 | 3526 | |
41bd17a4 | 3527 | NAME: relaxed_header_parser |
3528 | COMMENT: on|off|warn | |
3529 | TYPE: tristate | |
3530 | LOC: Config.onoff.relaxed_header_parser | |
3531 | DEFAULT: on | |
3532 | DOC_START | |
3533 | In the default "on" setting Squid accepts certain forms | |
3534 | of non-compliant HTTP messages where it is unambiguous | |
3535 | what the sending application intended even if the message | |
3536 | is not correctly formatted. The messages is then normalized | |
3537 | to the correct form when forwarded by Squid. | |
cccac0a2 | 3538 | |
41bd17a4 | 3539 | If set to "warn" then a warning will be emitted in cache.log |
3540 | each time such HTTP error is encountered. | |
cccac0a2 | 3541 | |
41bd17a4 | 3542 | If set to "off" then such HTTP errors will cause the request |
3543 | or response to be rejected. | |
3544 | DOC_END | |
7d90757b | 3545 | |
41bd17a4 | 3546 | COMMENT_START |
3547 | TIMEOUTS | |
3548 | ----------------------------------------------------------------------------- | |
3549 | COMMENT_END | |
3550 | ||
3551 | NAME: forward_timeout | |
3552 | COMMENT: time-units | |
3553 | TYPE: time_t | |
3554 | LOC: Config.Timeout.forward | |
3555 | DEFAULT: 4 minutes | |
3556 | DOC_START | |
3557 | This parameter specifies how long Squid should at most attempt in | |
3558 | finding a forwarding path for the request before giving up. | |
cccac0a2 | 3559 | DOC_END |
3560 | ||
41bd17a4 | 3561 | NAME: connect_timeout |
3562 | COMMENT: time-units | |
3563 | TYPE: time_t | |
3564 | LOC: Config.Timeout.connect | |
3565 | DEFAULT: 1 minute | |
057f5854 | 3566 | DOC_START |
41bd17a4 | 3567 | This parameter specifies how long to wait for the TCP connect to |
3568 | the requested server or peer to complete before Squid should | |
3569 | attempt to find another path where to forward the request. | |
057f5854 | 3570 | DOC_END |
3571 | ||
41bd17a4 | 3572 | NAME: peer_connect_timeout |
3573 | COMMENT: time-units | |
3574 | TYPE: time_t | |
3575 | LOC: Config.Timeout.peer_connect | |
3576 | DEFAULT: 30 seconds | |
cccac0a2 | 3577 | DOC_START |
41bd17a4 | 3578 | This parameter specifies how long to wait for a pending TCP |
3579 | connection to a peer cache. The default is 30 seconds. You | |
3580 | may also set different timeout values for individual neighbors | |
3581 | with the 'connect-timeout' option on a 'cache_peer' line. | |
3582 | DOC_END | |
7f7db318 | 3583 | |
41bd17a4 | 3584 | NAME: read_timeout |
3585 | COMMENT: time-units | |
3586 | TYPE: time_t | |
3587 | LOC: Config.Timeout.read | |
3588 | DEFAULT: 15 minutes | |
3589 | DOC_START | |
3590 | The read_timeout is applied on server-side connections. After | |
3591 | each successful read(), the timeout will be extended by this | |
3592 | amount. If no data is read again after this amount of time, | |
3593 | the request is aborted and logged with ERR_READ_TIMEOUT. The | |
3594 | default is 15 minutes. | |
3595 | DOC_END | |
cccac0a2 | 3596 | |
41bd17a4 | 3597 | NAME: request_timeout |
3598 | TYPE: time_t | |
3599 | LOC: Config.Timeout.request | |
3600 | DEFAULT: 5 minutes | |
3601 | DOC_START | |
3602 | How long to wait for an HTTP request after initial | |
3603 | connection establishment. | |
3604 | DOC_END | |
cccac0a2 | 3605 | |
41bd17a4 | 3606 | NAME: persistent_request_timeout |
3607 | TYPE: time_t | |
3608 | LOC: Config.Timeout.persistent_request | |
3609 | DEFAULT: 2 minutes | |
3610 | DOC_START | |
3611 | How long to wait for the next HTTP request on a persistent | |
3612 | connection after the previous request completes. | |
3613 | DOC_END | |
cccac0a2 | 3614 | |
41bd17a4 | 3615 | NAME: client_lifetime |
3616 | COMMENT: time-units | |
3617 | TYPE: time_t | |
3618 | LOC: Config.Timeout.lifetime | |
3619 | DEFAULT: 1 day | |
3620 | DOC_START | |
3621 | The maximum amount of time a client (browser) is allowed to | |
3622 | remain connected to the cache process. This protects the Cache | |
3623 | from having a lot of sockets (and hence file descriptors) tied up | |
3624 | in a CLOSE_WAIT state from remote clients that go away without | |
3625 | properly shutting down (either because of a network failure or | |
3626 | because of a poor client implementation). The default is one | |
3627 | day, 1440 minutes. | |
7d90757b | 3628 | |
41bd17a4 | 3629 | NOTE: The default value is intended to be much larger than any |
3630 | client would ever need to be connected to your cache. You | |
3631 | should probably change client_lifetime only as a last resort. | |
3632 | If you seem to have many client connections tying up | |
3633 | filedescriptors, we recommend first tuning the read_timeout, | |
3634 | request_timeout, persistent_request_timeout and quick_abort values. | |
cccac0a2 | 3635 | DOC_END |
3636 | ||
41bd17a4 | 3637 | NAME: half_closed_clients |
3638 | TYPE: onoff | |
3639 | LOC: Config.onoff.half_closed_clients | |
0c2f5c4f | 3640 | DEFAULT: off |
4eb368f9 | 3641 | DOC_START |
41bd17a4 | 3642 | Some clients may shutdown the sending side of their TCP |
3643 | connections, while leaving their receiving sides open. Sometimes, | |
3644 | Squid can not tell the difference between a half-closed and a | |
0c2f5c4f AJ |
3645 | fully-closed TCP connection. |
3646 | ||
3647 | By default, Squid will immediately close client connections when | |
3648 | read(2) returns "no more data to read." | |
3649 | ||
abdf1651 | 3650 | Change this option to 'on' and Squid will keep open connections |
0c2f5c4f AJ |
3651 | until a read(2) or write(2) on the socket returns an error. |
3652 | This may show some benefits for reverse proxies. But if not | |
3653 | it is recommended to leave OFF. | |
4eb368f9 | 3654 | DOC_END |
3655 | ||
41bd17a4 | 3656 | NAME: pconn_timeout |
3657 | TYPE: time_t | |
3658 | LOC: Config.Timeout.pconn | |
3659 | DEFAULT: 1 minute | |
cccac0a2 | 3660 | DOC_START |
41bd17a4 | 3661 | Timeout for idle persistent connections to servers and other |
3662 | proxies. | |
3663 | DOC_END | |
cccac0a2 | 3664 | |
41bd17a4 | 3665 | NAME: ident_timeout |
3666 | TYPE: time_t | |
3667 | IFDEF: USE_IDENT | |
4daaf3cb | 3668 | LOC: Ident::TheConfig.timeout |
41bd17a4 | 3669 | DEFAULT: 10 seconds |
3670 | DOC_START | |
3671 | Maximum time to wait for IDENT lookups to complete. | |
cccac0a2 | 3672 | |
41bd17a4 | 3673 | If this is too high, and you enabled IDENT lookups from untrusted |
3674 | users, you might be susceptible to denial-of-service by having | |
3675 | many ident requests going at once. | |
cccac0a2 | 3676 | DOC_END |
3677 | ||
41bd17a4 | 3678 | NAME: shutdown_lifetime |
3679 | COMMENT: time-units | |
3680 | TYPE: time_t | |
3681 | LOC: Config.shutdownLifetime | |
3682 | DEFAULT: 30 seconds | |
cccac0a2 | 3683 | DOC_START |
41bd17a4 | 3684 | When SIGTERM or SIGHUP is received, the cache is put into |
3685 | "shutdown pending" mode until all active sockets are closed. | |
3686 | This value is the lifetime to set for all open descriptors | |
3687 | during shutdown mode. Any active clients after this many | |
3688 | seconds will receive a 'timeout' message. | |
cccac0a2 | 3689 | DOC_END |
0976f8db | 3690 | |
cccac0a2 | 3691 | COMMENT_START |
3692 | ADMINISTRATIVE PARAMETERS | |
3693 | ----------------------------------------------------------------------------- | |
3694 | COMMENT_END | |
3695 | ||
3696 | NAME: cache_mgr | |
3697 | TYPE: string | |
3698 | DEFAULT: webmaster | |
3699 | LOC: Config.adminEmail | |
3700 | DOC_START | |
3701 | Email-address of local cache manager who will receive | |
3702 | mail if the cache dies. The default is "webmaster." | |
3703 | DOC_END | |
3704 | ||
abacf776 | 3705 | NAME: mail_from |
3706 | TYPE: string | |
3707 | DEFAULT: none | |
3708 | LOC: Config.EmailFrom | |
3709 | DOC_START | |
3710 | From: email-address for mail sent when the cache dies. | |
3711 | The default is to use 'appname@unique_hostname'. | |
b8c0c06d | 3712 | Default appname value is "squid", can be changed into |
abacf776 | 3713 | src/globals.h before building squid. |
3714 | DOC_END | |
3715 | ||
d084bf20 | 3716 | NAME: mail_program |
3717 | TYPE: eol | |
3718 | DEFAULT: mail | |
3719 | LOC: Config.EmailProgram | |
3720 | DOC_START | |
3721 | Email program used to send mail if the cache dies. | |
846a5e31 | 3722 | The default is "mail". The specified program must comply |
d084bf20 | 3723 | with the standard Unix mail syntax: |
846a5e31 | 3724 | mail-program recipient < mailfile |
3725 | ||
d084bf20 | 3726 | Optional command line options can be specified. |
3727 | DOC_END | |
3728 | ||
cccac0a2 | 3729 | NAME: cache_effective_user |
3730 | TYPE: string | |
5483d916 | 3731 | DEFAULT: @DEFAULT_CACHE_EFFECTIVE_USER@ |
cccac0a2 | 3732 | LOC: Config.effectiveUser |
e3d74828 | 3733 | DOC_START |
3734 | If you start Squid as root, it will change its effective/real | |
3735 | UID/GID to the user specified below. The default is to change | |
5483d916 | 3736 | to UID of @DEFAULT_CACHE_EFFECTIVE_USER@. |
64e288bd | 3737 | see also; cache_effective_group |
e3d74828 | 3738 | DOC_END |
3739 | ||
cccac0a2 | 3740 | NAME: cache_effective_group |
3741 | TYPE: string | |
3742 | DEFAULT: none | |
3743 | LOC: Config.effectiveGroup | |
3744 | DOC_START | |
64e288bd | 3745 | Squid sets the GID to the effective user's default group ID |
3746 | (taken from the password file) and supplementary group list | |
3747 | from the groups membership. | |
3748 | ||
e3d74828 | 3749 | If you want Squid to run with a specific GID regardless of |
3750 | the group memberships of the effective user then set this | |
3751 | to the group (or GID) you want Squid to run as. When set | |
64e288bd | 3752 | all other group privileges of the effective user are ignored |
e3d74828 | 3753 | and only this GID is effective. If Squid is not started as |
64e288bd | 3754 | root the user starting Squid MUST be member of the specified |
e3d74828 | 3755 | group. |
64e288bd | 3756 | |
3757 | This option is not recommended by the Squid Team. | |
3758 | Our preference is for administrators to configure a secure | |
3759 | user account for squid with UID/GID matching system policies. | |
cccac0a2 | 3760 | DOC_END |
3761 | ||
d3caee79 | 3762 | NAME: httpd_suppress_version_string |
3763 | COMMENT: on|off | |
3764 | TYPE: onoff | |
3765 | DEFAULT: off | |
3766 | LOC: Config.onoff.httpd_suppress_version_string | |
3767 | DOC_START | |
3768 | Suppress Squid version string info in HTTP headers and HTML error pages. | |
3769 | DOC_END | |
3770 | ||
cccac0a2 | 3771 | NAME: visible_hostname |
3772 | TYPE: string | |
3773 | LOC: Config.visibleHostname | |
3774 | DEFAULT: none | |
3775 | DOC_START | |
3776 | If you want to present a special hostname in error messages, etc, | |
7f7db318 | 3777 | define this. Otherwise, the return value of gethostname() |
cccac0a2 | 3778 | will be used. If you have multiple caches in a cluster and |
3779 | get errors about IP-forwarding you must set them to have individual | |
3780 | names with this setting. | |
3781 | DOC_END | |
3782 | ||
cccac0a2 | 3783 | NAME: unique_hostname |
3784 | TYPE: string | |
3785 | LOC: Config.uniqueHostname | |
3786 | DEFAULT: none | |
3787 | DOC_START | |
3788 | If you want to have multiple machines with the same | |
7f7db318 | 3789 | 'visible_hostname' you must give each machine a different |
3790 | 'unique_hostname' so forwarding loops can be detected. | |
cccac0a2 | 3791 | DOC_END |
3792 | ||
cccac0a2 | 3793 | NAME: hostname_aliases |
3794 | TYPE: wordlist | |
3795 | LOC: Config.hostnameAliases | |
3796 | DEFAULT: none | |
3797 | DOC_START | |
7f7db318 | 3798 | A list of other DNS names your cache has. |
cccac0a2 | 3799 | DOC_END |
0976f8db | 3800 | |
c642c141 AJ |
3801 | NAME: umask |
3802 | TYPE: int | |
3803 | LOC: Config.umask | |
3804 | DEFAULT: 027 | |
3805 | DOC_START | |
3806 | Minimum umask which should be enforced while the proxy | |
3807 | is running, in addition to the umask set at startup. | |
3808 | ||
3809 | For a traditional octal representation of umasks, start | |
3810 | your value with 0. | |
3811 | DOC_END | |
3812 | ||
cccac0a2 | 3813 | COMMENT_START |
3814 | OPTIONS FOR THE CACHE REGISTRATION SERVICE | |
3815 | ----------------------------------------------------------------------------- | |
3816 | ||
3817 | This section contains parameters for the (optional) cache | |
3818 | announcement service. This service is provided to help | |
3819 | cache administrators locate one another in order to join or | |
3820 | create cache hierarchies. | |
3821 | ||
3822 | An 'announcement' message is sent (via UDP) to the registration | |
3823 | service by Squid. By default, the announcement message is NOT | |
3824 | SENT unless you enable it with 'announce_period' below. | |
3825 | ||
3826 | The announcement message includes your hostname, plus the | |
3827 | following information from this configuration file: | |
3828 | ||
3829 | http_port | |
3830 | icp_port | |
3831 | cache_mgr | |
3832 | ||
3833 | All current information is processed regularly and made | |
3834 | available on the Web at http://www.ircache.net/Cache/Tracker/. | |
3835 | COMMENT_END | |
3836 | ||
3837 | NAME: announce_period | |
3838 | TYPE: time_t | |
3839 | LOC: Config.Announce.period | |
3840 | DEFAULT: 0 | |
3841 | DOC_START | |
3842 | This is how frequently to send cache announcements. The | |
3843 | default is `0' which disables sending the announcement | |
3844 | messages. | |
3845 | ||
3846 | To enable announcing your cache, just uncomment the line | |
3847 | below. | |
3848 | ||
3849 | NOCOMMENT_START | |
9e7dbc51 | 3850 | #To enable announcing your cache, just uncomment the line below. |
3851 | #announce_period 1 day | |
cccac0a2 | 3852 | NOCOMMENT_END |
3853 | DOC_END | |
3854 | ||
cccac0a2 | 3855 | NAME: announce_host |
3856 | TYPE: string | |
3857 | DEFAULT: tracker.ircache.net | |
3858 | LOC: Config.Announce.host | |
3859 | DOC_NONE | |
3860 | ||
3861 | NAME: announce_file | |
3862 | TYPE: string | |
3863 | DEFAULT: none | |
3864 | LOC: Config.Announce.file | |
3865 | DOC_NONE | |
3866 | ||
3867 | NAME: announce_port | |
3868 | TYPE: ushort | |
3869 | DEFAULT: 3131 | |
3870 | LOC: Config.Announce.port | |
3871 | DOC_START | |
3872 | announce_host and announce_port set the hostname and port | |
3873 | number where the registration message will be sent. | |
3874 | ||
3875 | Hostname will default to 'tracker.ircache.net' and port will | |
3876 | default default to 3131. If the 'filename' argument is given, | |
3877 | the contents of that file will be included in the announce | |
3878 | message. | |
3879 | DOC_END | |
3880 | ||
8d6275c0 | 3881 | COMMENT_START |
3882 | HTTPD-ACCELERATOR OPTIONS | |
3883 | ----------------------------------------------------------------------------- | |
3884 | COMMENT_END | |
3885 | ||
cccac0a2 | 3886 | NAME: httpd_accel_surrogate_id |
f41735ea | 3887 | IFDEF: USE_SQUID_ESI |
cccac0a2 | 3888 | TYPE: string |
3889 | LOC: Config.Accel.surrogate_id | |
3890 | DEFAULT: unset-id | |
3891 | DOC_START | |
3892 | Surrogates (http://www.esi.org/architecture_spec_1.0.html) | |
3893 | need an identification token to allow control targeting. Because | |
3894 | a farm of surrogates may all perform the same tasks, they may share | |
3895 | an identification token. | |
3896 | DOC_END | |
3897 | ||
3898 | NAME: http_accel_surrogate_remote | |
f41735ea | 3899 | IFDEF: USE_SQUID_ESI |
cccac0a2 | 3900 | COMMENT: on|off |
3901 | TYPE: onoff | |
3902 | DEFAULT: off | |
3903 | LOC: Config.onoff.surrogate_is_remote | |
3904 | DOC_START | |
3905 | Remote surrogates (such as those in a CDN) honour Surrogate-Control: no-store-remote. | |
3906 | Set this to on to have squid behave as a remote surrogate. | |
3907 | DOC_END | |
3908 | ||
3909 | NAME: esi_parser | |
f41735ea | 3910 | IFDEF: USE_SQUID_ESI |
964b44c3 | 3911 | COMMENT: libxml2|expat|custom |
cccac0a2 | 3912 | TYPE: string |
3913 | LOC: ESIParser::Type | |
3914 | DEFAULT: custom | |
3915 | DOC_START | |
3916 | ESI markup is not strictly XML compatible. The custom ESI parser | |
3917 | will give higher performance, but cannot handle non ASCII character | |
3918 | encodings. | |
3919 | DOC_END | |
0976f8db | 3920 | |
9edd9041 | 3921 | COMMENT_START |
8d6275c0 | 3922 | DELAY POOL PARAMETERS |
9edd9041 | 3923 | ----------------------------------------------------------------------------- |
3924 | COMMENT_END | |
3925 | ||
3926 | NAME: delay_pools | |
3927 | TYPE: delay_pool_count | |
3928 | DEFAULT: 0 | |
3929 | IFDEF: DELAY_POOLS | |
3930 | LOC: Config.Delay | |
3931 | DOC_START | |
3932 | This represents the number of delay pools to be used. For example, | |
3933 | if you have one class 2 delay pool and one class 3 delays pool, you | |
3934 | have a total of 2 delay pools. | |
3935 | DOC_END | |
3936 | ||
3937 | NAME: delay_class | |
3938 | TYPE: delay_pool_class | |
3939 | DEFAULT: none | |
3940 | IFDEF: DELAY_POOLS | |
3941 | LOC: Config.Delay | |
3942 | DOC_START | |
3943 | This defines the class of each delay pool. There must be exactly one | |
3944 | delay_class line for each delay pool. For example, to define two | |
3945 | delay pools, one of class 2 and one of class 3, the settings above | |
3946 | and here would be: | |
3947 | ||
b1fb3348 AJ |
3948 | Example: |
3949 | delay_pools 4 # 4 delay pools | |
3950 | delay_class 1 2 # pool 1 is a class 2 pool | |
3951 | delay_class 2 3 # pool 2 is a class 3 pool | |
3952 | delay_class 3 4 # pool 3 is a class 4 pool | |
3953 | delay_class 4 5 # pool 4 is a class 5 pool | |
9edd9041 | 3954 | |
3955 | The delay pool classes are: | |
3956 | ||
3957 | class 1 Everything is limited by a single aggregate | |
3958 | bucket. | |
3959 | ||
3960 | class 2 Everything is limited by a single aggregate | |
3961 | bucket as well as an "individual" bucket chosen | |
b1fb3348 | 3962 | from bits 25 through 32 of the IPv4 address. |
9edd9041 | 3963 | |
3964 | class 3 Everything is limited by a single aggregate | |
3965 | bucket as well as a "network" bucket chosen | |
3966 | from bits 17 through 24 of the IP address and a | |
3967 | "individual" bucket chosen from bits 17 through | |
b1fb3348 | 3968 | 32 of the IPv4 address. |
9edd9041 | 3969 | |
3970 | class 4 Everything in a class 3 delay pool, with an | |
3971 | additional limit on a per user basis. This | |
3972 | only takes effect if the username is established | |
3973 | in advance - by forcing authentication in your | |
3974 | http_access rules. | |
3975 | ||
3976 | class 5 Requests are grouped according their tag (see | |
3977 | external_acl's tag= reply). | |
3978 | ||
3979 | NOTE: If an IP address is a.b.c.d | |
3980 | -> bits 25 through 32 are "d" | |
3981 | -> bits 17 through 24 are "c" | |
3982 | -> bits 17 through 32 are "c * 256 + d" | |
b1fb3348 AJ |
3983 | |
3984 | NOTE-2: Due to the use of bitmasks in class 2,3,4 pools they only apply to | |
3985 | IPv4 traffic. Class 1 and 5 pools may be used with IPv6 traffic. | |
9edd9041 | 3986 | DOC_END |
3987 | ||
3988 | NAME: delay_access | |
3989 | TYPE: delay_pool_access | |
3990 | DEFAULT: none | |
3991 | IFDEF: DELAY_POOLS | |
3992 | LOC: Config.Delay | |
3993 | DOC_START | |
3994 | This is used to determine which delay pool a request falls into. | |
3995 | ||
3996 | delay_access is sorted per pool and the matching starts with pool 1, | |
3997 | then pool 2, ..., and finally pool N. The first delay pool where the | |
3998 | request is allowed is selected for the request. If it does not allow | |
3999 | the request to any pool then the request is not delayed (default). | |
4000 | ||
4001 | For example, if you want some_big_clients in delay | |
4002 | pool 1 and lotsa_little_clients in delay pool 2: | |
4003 | ||
4004 | Example: | |
4005 | delay_access 1 allow some_big_clients | |
4006 | delay_access 1 deny all | |
4007 | delay_access 2 allow lotsa_little_clients | |
4008 | delay_access 2 deny all | |
4009 | delay_access 3 allow authenticated_clients | |
4010 | DOC_END | |
4011 | ||
4012 | NAME: delay_parameters | |
4013 | TYPE: delay_pool_rates | |
4014 | DEFAULT: none | |
4015 | IFDEF: DELAY_POOLS | |
4016 | LOC: Config.Delay | |
4017 | DOC_START | |
4018 | This defines the parameters for a delay pool. Each delay pool has | |
4019 | a number of "buckets" associated with it, as explained in the | |
4020 | description of delay_class. For a class 1 delay pool, the syntax is: | |
4021 | ||
4022 | delay_parameters pool aggregate | |
4023 | ||
4024 | For a class 2 delay pool: | |
4025 | ||
4026 | delay_parameters pool aggregate individual | |
4027 | ||
4028 | For a class 3 delay pool: | |
4029 | ||
4030 | delay_parameters pool aggregate network individual | |
4031 | ||
4032 | For a class 4 delay pool: | |
4033 | ||
4034 | delay_parameters pool aggregate network individual user | |
4035 | ||
4036 | For a class 5 delay pool: | |
4037 | ||
4038 | delay_parameters pool tag | |
4039 | ||
4040 | The variables here are: | |
4041 | ||
4042 | pool a pool number - ie, a number between 1 and the | |
4043 | number specified in delay_pools as used in | |
4044 | delay_class lines. | |
4045 | ||
4046 | aggregate the "delay parameters" for the aggregate bucket | |
4047 | (class 1, 2, 3). | |
4048 | ||
4049 | individual the "delay parameters" for the individual | |
4050 | buckets (class 2, 3). | |
4051 | ||
4052 | network the "delay parameters" for the network buckets | |
4053 | (class 3). | |
4054 | ||
4055 | user the delay parameters for the user buckets | |
4056 | (class 4). | |
4057 | ||
4058 | tag the delay parameters for the tag buckets | |
4059 | (class 5). | |
4060 | ||
4061 | A pair of delay parameters is written restore/maximum, where restore is | |
4062 | the number of bytes (not bits - modem and network speeds are usually | |
4063 | quoted in bits) per second placed into the bucket, and maximum is the | |
4064 | maximum number of bytes which can be in the bucket at any time. | |
4065 | ||
4066 | For example, if delay pool number 1 is a class 2 delay pool as in the | |
4067 | above example, and is being used to strictly limit each host to 64kbps | |
4068 | (plus overheads), with no overall limit, the line is: | |
4069 | ||
4070 | delay_parameters 1 -1/-1 8000/8000 | |
4071 | ||
4072 | Note that the figure -1 is used to represent "unlimited". | |
4073 | ||
4074 | And, if delay pool number 2 is a class 3 delay pool as in the above | |
4075 | example, and you want to limit it to a total of 256kbps (strict limit) | |
4076 | with each 8-bit network permitted 64kbps (strict limit) and each | |
4077 | individual host permitted 4800bps with a bucket maximum size of 64kb | |
4078 | to permit a decent web page to be downloaded at a decent speed | |
4079 | (if the network is not being limited due to overuse) but slow down | |
4080 | large downloads more significantly: | |
4081 | ||
4082 | delay_parameters 2 32000/32000 8000/8000 600/8000 | |
4083 | ||
4084 | There must be one delay_parameters line for each delay pool. | |
4085 | ||
4086 | Finally, for a class 4 delay pool as in the example - each user will | |
4087 | be limited to 128Kb no matter how many workstations they are logged into.: | |
4088 | ||
4089 | delay_parameters 4 32000/32000 8000/8000 600/64000 16000/16000 | |
4090 | DOC_END | |
4091 | ||
4092 | NAME: delay_initial_bucket_level | |
4093 | COMMENT: (percent, 0-100) | |
4094 | TYPE: ushort | |
4095 | DEFAULT: 50 | |
4096 | IFDEF: DELAY_POOLS | |
4097 | LOC: Config.Delay.initial | |
4098 | DOC_START | |
4099 | The initial bucket percentage is used to determine how much is put | |
4100 | in each bucket when squid starts, is reconfigured, or first notices | |
4101 | a host accessing it (in class 2 and class 3, individual hosts and | |
4102 | networks only have buckets associated with them once they have been | |
4103 | "seen" by squid). | |
4104 | DOC_END | |
4105 | ||
cccac0a2 | 4106 | COMMENT_START |
8d6275c0 | 4107 | WCCPv1 AND WCCPv2 CONFIGURATION OPTIONS |
cccac0a2 | 4108 | ----------------------------------------------------------------------------- |
4109 | COMMENT_END | |
4110 | ||
8d6275c0 | 4111 | NAME: wccp_router |
4112 | TYPE: address | |
4113 | LOC: Config.Wccp.router | |
4114 | DEFAULT: 0.0.0.0 | |
4115 | IFDEF: USE_WCCP | |
e313ab0a AJ |
4116 | DOC_START |
4117 | Use this option to define your WCCP ``home'' router for | |
4118 | Squid. | |
4119 | ||
4120 | wccp_router supports a single WCCP(v1) router | |
4121 | ||
4122 | wccp2_router supports multiple WCCPv2 routers | |
4123 | ||
4124 | only one of the two may be used at the same time and defines | |
4125 | which version of WCCP to use. | |
4126 | DOC_END | |
df2eec10 | 4127 | |
8d6275c0 | 4128 | NAME: wccp2_router |
9fb4efad | 4129 | TYPE: IpAddress_list |
8d6275c0 | 4130 | LOC: Config.Wccp2.router |
cccac0a2 | 4131 | DEFAULT: none |
8d6275c0 | 4132 | IFDEF: USE_WCCPv2 |
cccac0a2 | 4133 | DOC_START |
8d6275c0 | 4134 | Use this option to define your WCCP ``home'' router for |
4135 | Squid. | |
cccac0a2 | 4136 | |
8d6275c0 | 4137 | wccp_router supports a single WCCP(v1) router |
cccac0a2 | 4138 | |
8d6275c0 | 4139 | wccp2_router supports multiple WCCPv2 routers |
cccac0a2 | 4140 | |
8d6275c0 | 4141 | only one of the two may be used at the same time and defines |
4142 | which version of WCCP to use. | |
4143 | DOC_END | |
4144 | ||
4145 | NAME: wccp_version | |
cccac0a2 | 4146 | TYPE: int |
8d6275c0 | 4147 | LOC: Config.Wccp.version |
4148 | DEFAULT: 4 | |
4149 | IFDEF: USE_WCCP | |
cccac0a2 | 4150 | DOC_START |
8d6275c0 | 4151 | This directive is only relevant if you need to set up WCCP(v1) |
4152 | to some very old and end-of-life Cisco routers. In all other | |
4153 | setups it must be left unset or at the default setting. | |
4154 | It defines an internal version in the WCCP(v1) protocol, | |
4155 | with version 4 being the officially documented protocol. | |
cccac0a2 | 4156 | |
8d6275c0 | 4157 | According to some users, Cisco IOS 11.2 and earlier only |
4158 | support WCCP version 3. If you're using that or an earlier | |
4159 | version of IOS, you may need to change this value to 3, otherwise | |
4160 | do not specify this parameter. | |
cccac0a2 | 4161 | DOC_END |
4162 | ||
8d6275c0 | 4163 | NAME: wccp2_rebuild_wait |
4164 | TYPE: onoff | |
4165 | LOC: Config.Wccp2.rebuildwait | |
4166 | DEFAULT: on | |
4167 | IFDEF: USE_WCCPv2 | |
4168 | DOC_START | |
4169 | If this is enabled Squid will wait for the cache dir rebuild to finish | |
4170 | before sending the first wccp2 HereIAm packet | |
4171 | DOC_END | |
cccac0a2 | 4172 | |
8d6275c0 | 4173 | NAME: wccp2_forwarding_method |
e313ab0a | 4174 | TYPE: wccp2_method |
8d6275c0 | 4175 | LOC: Config.Wccp2.forwarding_method |
451c4786 | 4176 | DEFAULT: gre |
8d6275c0 | 4177 | IFDEF: USE_WCCPv2 |
cccac0a2 | 4178 | DOC_START |
699acd19 | 4179 | WCCP2 allows the setting of forwarding methods between the |
8d6275c0 | 4180 | router/switch and the cache. Valid values are as follows: |
cccac0a2 | 4181 | |
451c4786 AJ |
4182 | gre - GRE encapsulation (forward the packet in a GRE/WCCP tunnel) |
4183 | l2 - L2 redirect (forward the packet using Layer 2/MAC rewriting) | |
cccac0a2 | 4184 | |
8d6275c0 | 4185 | Currently (as of IOS 12.4) cisco routers only support GRE. |
4186 | Cisco switches only support the L2 redirect assignment method. | |
cccac0a2 | 4187 | DOC_END |
4188 | ||
8d6275c0 | 4189 | NAME: wccp2_return_method |
e313ab0a | 4190 | TYPE: wccp2_method |
8d6275c0 | 4191 | LOC: Config.Wccp2.return_method |
451c4786 | 4192 | DEFAULT: gre |
8d6275c0 | 4193 | IFDEF: USE_WCCPv2 |
cccac0a2 | 4194 | DOC_START |
699acd19 | 4195 | WCCP2 allows the setting of return methods between the |
8d6275c0 | 4196 | router/switch and the cache for packets that the cache |
4197 | decides not to handle. Valid values are as follows: | |
cccac0a2 | 4198 | |
451c4786 AJ |
4199 | gre - GRE encapsulation (forward the packet in a GRE/WCCP tunnel) |
4200 | l2 - L2 redirect (forward the packet using Layer 2/MAC rewriting) | |
cccac0a2 | 4201 | |
8d6275c0 | 4202 | Currently (as of IOS 12.4) cisco routers only support GRE. |
4203 | Cisco switches only support the L2 redirect assignment. | |
cccac0a2 | 4204 | |
699acd19 | 4205 | If the "ip wccp redirect exclude in" command has been |
8d6275c0 | 4206 | enabled on the cache interface, then it is still safe for |
4207 | the proxy server to use a l2 redirect method even if this | |
4208 | option is set to GRE. | |
cccac0a2 | 4209 | DOC_END |
4210 | ||
8d6275c0 | 4211 | NAME: wccp2_assignment_method |
451c4786 | 4212 | TYPE: wccp2_amethod |
8d6275c0 | 4213 | LOC: Config.Wccp2.assignment_method |
451c4786 | 4214 | DEFAULT: hash |
8d6275c0 | 4215 | IFDEF: USE_WCCPv2 |
cccac0a2 | 4216 | DOC_START |
8d6275c0 | 4217 | WCCP2 allows the setting of methods to assign the WCCP hash |
4218 | Valid values are as follows: | |
cccac0a2 | 4219 | |
451c4786 AJ |
4220 | hash - Hash assignment |
4221 | mask - Mask assignment | |
cccac0a2 | 4222 | |
8d6275c0 | 4223 | As a general rule, cisco routers support the hash assignment method |
4224 | and cisco switches support the mask assignment method. | |
4225 | DOC_END | |
cccac0a2 | 4226 | |
8d6275c0 | 4227 | NAME: wccp2_service |
4228 | TYPE: wccp2_service | |
4229 | LOC: Config.Wccp2.info | |
4230 | DEFAULT: none | |
4231 | DEFAULT_IF_NONE: standard 0 | |
4232 | IFDEF: USE_WCCPv2 | |
4233 | DOC_START | |
4234 | WCCP2 allows for multiple traffic services. There are two | |
4235 | types: "standard" and "dynamic". The standard type defines | |
4236 | one service id - http (id 0). The dynamic service ids can be from | |
4237 | 51 to 255 inclusive. In order to use a dynamic service id | |
4238 | one must define the type of traffic to be redirected; this is done | |
4239 | using the wccp2_service_info option. | |
4240 | ||
4241 | The "standard" type does not require a wccp2_service_info option, | |
4242 | just specifying the service id will suffice. | |
4243 | ||
4244 | MD5 service authentication can be enabled by adding | |
4245 | "password=<password>" to the end of this service declaration. | |
4246 | ||
4247 | Examples: | |
4248 | ||
4249 | wccp2_service standard 0 # for the 'web-cache' standard service | |
4250 | wccp2_service dynamic 80 # a dynamic service type which will be | |
4251 | # fleshed out with subsequent options. | |
4252 | wccp2_service standard 0 password=foo | |
8d6275c0 | 4253 | DOC_END |
4254 | ||
4255 | NAME: wccp2_service_info | |
4256 | TYPE: wccp2_service_info | |
4257 | LOC: Config.Wccp2.info | |
4258 | DEFAULT: none | |
4259 | IFDEF: USE_WCCPv2 | |
4260 | DOC_START | |
4261 | Dynamic WCCPv2 services require further information to define the | |
4262 | traffic you wish to have diverted. | |
4263 | ||
4264 | The format is: | |
4265 | ||
4266 | wccp2_service_info <id> protocol=<protocol> flags=<flag>,<flag>.. | |
4267 | priority=<priority> ports=<port>,<port>.. | |
4268 | ||
4269 | The relevant WCCPv2 flags: | |
4270 | + src_ip_hash, dst_ip_hash | |
005fe566 | 4271 | + source_port_hash, dst_port_hash |
8d6275c0 | 4272 | + src_ip_alt_hash, dst_ip_alt_hash |
4273 | + src_port_alt_hash, dst_port_alt_hash | |
4274 | + ports_source | |
4275 | ||
4276 | The port list can be one to eight entries. | |
4277 | ||
4278 | Example: | |
4279 | ||
4280 | wccp2_service_info 80 protocol=tcp flags=src_ip_hash,ports_source | |
4281 | priority=240 ports=80 | |
4282 | ||
4283 | Note: the service id must have been defined by a previous | |
4284 | 'wccp2_service dynamic <id>' entry. | |
4285 | DOC_END | |
4286 | ||
4287 | NAME: wccp2_weight | |
4288 | TYPE: int | |
4289 | LOC: Config.Wccp2.weight | |
4290 | DEFAULT: 10000 | |
4291 | IFDEF: USE_WCCPv2 | |
4292 | DOC_START | |
4293 | Each cache server gets assigned a set of the destination | |
4294 | hash proportional to their weight. | |
4295 | DOC_END | |
4296 | ||
4297 | NAME: wccp_address | |
4298 | TYPE: address | |
4299 | LOC: Config.Wccp.address | |
4300 | DEFAULT: 0.0.0.0 | |
4301 | IFDEF: USE_WCCP | |
4302 | DOC_NONE | |
df2eec10 | 4303 | |
8d6275c0 | 4304 | NAME: wccp2_address |
4305 | TYPE: address | |
4306 | LOC: Config.Wccp2.address | |
4307 | DEFAULT: 0.0.0.0 | |
4308 | IFDEF: USE_WCCPv2 | |
4309 | DOC_START | |
4310 | Use this option if you require WCCP to use a specific | |
4311 | interface address. | |
4312 | ||
4313 | The default behavior is to not bind to any specific address. | |
4314 | DOC_END | |
4315 | ||
4316 | COMMENT_START | |
4317 | PERSISTENT CONNECTION HANDLING | |
4318 | ----------------------------------------------------------------------------- | |
4319 | ||
4320 | Also see "pconn_timeout" in the TIMEOUTS section | |
4321 | COMMENT_END | |
4322 | ||
4323 | NAME: client_persistent_connections | |
4324 | TYPE: onoff | |
4325 | LOC: Config.onoff.client_pconns | |
4326 | DEFAULT: on | |
4327 | DOC_NONE | |
4328 | ||
4329 | NAME: server_persistent_connections | |
4330 | TYPE: onoff | |
4331 | LOC: Config.onoff.server_pconns | |
4332 | DEFAULT: on | |
4333 | DOC_START | |
4334 | Persistent connection support for clients and servers. By | |
4335 | default, Squid uses persistent connections (when allowed) | |
4336 | with its clients and servers. You can use these options to | |
4337 | disable persistent connections with clients and/or servers. | |
4338 | DOC_END | |
4339 | ||
4340 | NAME: persistent_connection_after_error | |
4341 | TYPE: onoff | |
4342 | LOC: Config.onoff.error_pconns | |
4343 | DEFAULT: off | |
4344 | DOC_START | |
4345 | With this directive the use of persistent connections after | |
4346 | HTTP errors can be disabled. Useful if you have clients | |
4347 | who fail to handle errors on persistent connections proper. | |
4348 | DOC_END | |
4349 | ||
4350 | NAME: detect_broken_pconn | |
4351 | TYPE: onoff | |
4352 | LOC: Config.onoff.detect_broken_server_pconns | |
4353 | DEFAULT: off | |
4354 | DOC_START | |
4355 | Some servers have been found to incorrectly signal the use | |
4356 | of HTTP/1.0 persistent connections even on replies not | |
4357 | compatible, causing significant delays. This server problem | |
4358 | has mostly been seen on redirects. | |
4359 | ||
4360 | By enabling this directive Squid attempts to detect such | |
4361 | broken replies and automatically assume the reply is finished | |
4362 | after 10 seconds timeout. | |
4363 | DOC_END | |
4364 | ||
4365 | COMMENT_START | |
4366 | CACHE DIGEST OPTIONS | |
4367 | ----------------------------------------------------------------------------- | |
4368 | COMMENT_END | |
4369 | ||
4370 | NAME: digest_generation | |
4371 | IFDEF: USE_CACHE_DIGESTS | |
4372 | TYPE: onoff | |
4373 | LOC: Config.onoff.digest_generation | |
4374 | DEFAULT: on | |
4375 | DOC_START | |
4376 | This controls whether the server will generate a Cache Digest | |
4377 | of its contents. By default, Cache Digest generation is | |
13e917b5 | 4378 | enabled if Squid is compiled with --enable-cache-digests defined. |
8d6275c0 | 4379 | DOC_END |
4380 | ||
4381 | NAME: digest_bits_per_entry | |
4382 | IFDEF: USE_CACHE_DIGESTS | |
4383 | TYPE: int | |
4384 | LOC: Config.digest.bits_per_entry | |
4385 | DEFAULT: 5 | |
4386 | DOC_START | |
4387 | This is the number of bits of the server's Cache Digest which | |
4388 | will be associated with the Digest entry for a given HTTP | |
4389 | Method and URL (public key) combination. The default is 5. | |
4390 | DOC_END | |
4391 | ||
4392 | NAME: digest_rebuild_period | |
4393 | IFDEF: USE_CACHE_DIGESTS | |
4394 | COMMENT: (seconds) | |
4395 | TYPE: time_t | |
4396 | LOC: Config.digest.rebuild_period | |
4397 | DEFAULT: 1 hour | |
4398 | DOC_START | |
749ceff8 | 4399 | This is the wait time between Cache Digest rebuilds. |
8d6275c0 | 4400 | DOC_END |
4401 | ||
4402 | NAME: digest_rewrite_period | |
4403 | COMMENT: (seconds) | |
4404 | IFDEF: USE_CACHE_DIGESTS | |
4405 | TYPE: time_t | |
4406 | LOC: Config.digest.rewrite_period | |
4407 | DEFAULT: 1 hour | |
4408 | DOC_START | |
749ceff8 | 4409 | This is the wait time between Cache Digest writes to |
8d6275c0 | 4410 | disk. |
4411 | DOC_END | |
4412 | ||
4413 | NAME: digest_swapout_chunk_size | |
4414 | COMMENT: (bytes) | |
4415 | TYPE: b_size_t | |
4416 | IFDEF: USE_CACHE_DIGESTS | |
4417 | LOC: Config.digest.swapout_chunk_size | |
4418 | DEFAULT: 4096 bytes | |
4419 | DOC_START | |
4420 | This is the number of bytes of the Cache Digest to write to | |
4421 | disk at a time. It defaults to 4096 bytes (4KB), the Squid | |
4422 | default swap page. | |
4423 | DOC_END | |
4424 | ||
4425 | NAME: digest_rebuild_chunk_percentage | |
4426 | COMMENT: (percent, 0-100) | |
4427 | IFDEF: USE_CACHE_DIGESTS | |
4428 | TYPE: int | |
4429 | LOC: Config.digest.rebuild_chunk_percentage | |
4430 | DEFAULT: 10 | |
4431 | DOC_START | |
4432 | This is the percentage of the Cache Digest to be scanned at a | |
4433 | time. By default it is set to 10% of the Cache Digest. | |
4434 | DOC_END | |
4435 | ||
1db9eacd | 4436 | COMMENT_START |
5473c134 | 4437 | SNMP OPTIONS |
1db9eacd | 4438 | ----------------------------------------------------------------------------- |
4439 | COMMENT_END | |
4440 | ||
5473c134 | 4441 | NAME: snmp_port |
4442 | TYPE: ushort | |
4443 | LOC: Config.Port.snmp | |
87630341 | 4444 | DEFAULT: 0 |
5473c134 | 4445 | IFDEF: SQUID_SNMP |
8d6275c0 | 4446 | DOC_START |
87630341 | 4447 | The port number where Squid listens for SNMP requests. To enable |
4448 | SNMP support set this to a suitable port number. Port number | |
4449 | 3401 is often used for the Squid SNMP agent. By default it's | |
4450 | set to "0" (disabled) | |
4451 | NOCOMMENT_START | |
4452 | #snmp_port 3401 | |
4453 | NOCOMMENT_END | |
8d6275c0 | 4454 | DOC_END |
4455 | ||
5473c134 | 4456 | NAME: snmp_access |
4457 | TYPE: acl_access | |
4458 | LOC: Config.accessList.snmp | |
8d6275c0 | 4459 | DEFAULT: none |
5473c134 | 4460 | DEFAULT_IF_NONE: deny all |
4461 | IFDEF: SQUID_SNMP | |
8d6275c0 | 4462 | DOC_START |
5473c134 | 4463 | Allowing or denying access to the SNMP port. |
8d6275c0 | 4464 | |
5473c134 | 4465 | All access to the agent is denied by default. |
4466 | usage: | |
8d6275c0 | 4467 | |
5473c134 | 4468 | snmp_access allow|deny [!]aclname ... |
8d6275c0 | 4469 | |
5473c134 | 4470 | Example: |
4471 | snmp_access allow snmppublic localhost | |
4472 | snmp_access deny all | |
cccac0a2 | 4473 | DOC_END |
4474 | ||
5473c134 | 4475 | NAME: snmp_incoming_address |
4476 | TYPE: address | |
4477 | LOC: Config.Addrs.snmp_incoming | |
4478 | DEFAULT: 0.0.0.0 | |
4479 | IFDEF: SQUID_SNMP | |
4480 | DOC_NONE | |
df2eec10 | 4481 | |
5473c134 | 4482 | NAME: snmp_outgoing_address |
4483 | TYPE: address | |
4484 | LOC: Config.Addrs.snmp_outgoing | |
4485 | DEFAULT: 255.255.255.255 | |
4486 | IFDEF: SQUID_SNMP | |
cccac0a2 | 4487 | DOC_START |
df2eec10 | 4488 | Just like 'udp_incoming_address', but for the SNMP port. |
cccac0a2 | 4489 | |
5473c134 | 4490 | snmp_incoming_address is used for the SNMP socket receiving |
4491 | messages from SNMP agents. | |
4492 | snmp_outgoing_address is used for SNMP packets returned to SNMP | |
4493 | agents. | |
cccac0a2 | 4494 | |
5473c134 | 4495 | The default snmp_incoming_address (0.0.0.0) is to listen on all |
4496 | available network interfaces. | |
cccac0a2 | 4497 | |
5473c134 | 4498 | If snmp_outgoing_address is set to 255.255.255.255 (the default) |
4499 | it will use the same socket as snmp_incoming_address. Only | |
4500 | change this if you want to have SNMP replies sent using another | |
4501 | address than where this Squid listens for SNMP queries. | |
cccac0a2 | 4502 | |
5473c134 | 4503 | NOTE, snmp_incoming_address and snmp_outgoing_address can not have |
4504 | the same value since they both use port 3401. | |
cccac0a2 | 4505 | DOC_END |
4506 | ||
5473c134 | 4507 | COMMENT_START |
4508 | ICP OPTIONS | |
4509 | ----------------------------------------------------------------------------- | |
4510 | COMMENT_END | |
4511 | ||
4512 | NAME: icp_port udp_port | |
4513 | TYPE: ushort | |
4514 | DEFAULT: 0 | |
4515 | LOC: Config.Port.icp | |
cccac0a2 | 4516 | DOC_START |
5473c134 | 4517 | The port number where Squid sends and receives ICP queries to |
4518 | and from neighbor caches. The standard UDP port for ICP is 3130. | |
4519 | Default is disabled (0). | |
4520 | NOCOMMENT_START | |
df2eec10 | 4521 | #icp_port @DEFAULT_ICP_PORT@ |
5473c134 | 4522 | NOCOMMENT_END |
cccac0a2 | 4523 | DOC_END |
4524 | ||
5473c134 | 4525 | NAME: htcp_port |
4526 | IFDEF: USE_HTCP | |
4527 | TYPE: ushort | |
87630341 | 4528 | DEFAULT: 0 |
5473c134 | 4529 | LOC: Config.Port.htcp |
cccac0a2 | 4530 | DOC_START |
5473c134 | 4531 | The port number where Squid sends and receives HTCP queries to |
87630341 | 4532 | and from neighbor caches. To turn it on you want to set it to |
4533 | 4827. By default it is set to "0" (disabled). | |
4534 | NOCOMMENT_START | |
4535 | #htcp_port 4827 | |
4536 | NOCOMMENT_END | |
cccac0a2 | 4537 | DOC_END |
4538 | ||
4539 | NAME: log_icp_queries | |
4540 | COMMENT: on|off | |
4541 | TYPE: onoff | |
4542 | DEFAULT: on | |
4543 | LOC: Config.onoff.log_udp | |
4544 | DOC_START | |
4545 | If set, ICP queries are logged to access.log. You may wish | |
4546 | do disable this if your ICP load is VERY high to speed things | |
4547 | up or to simplify log analysis. | |
4548 | DOC_END | |
4549 | ||
5473c134 | 4550 | NAME: udp_incoming_address |
4551 | TYPE: address | |
4552 | LOC:Config.Addrs.udp_incoming | |
4553 | DEFAULT: 0.0.0.0 | |
8524d4b2 | 4554 | DOC_START |
4555 | udp_incoming_address is used for UDP packets received from other | |
4556 | caches. | |
4557 | ||
4558 | The default behavior is to not bind to any specific address. | |
4559 | ||
4560 | Only change this if you want to have all UDP queries received on | |
4561 | a specific interface/address. | |
4562 | ||
4563 | NOTE: udp_incoming_address is used by the ICP, HTCP, and DNS | |
4564 | modules. Altering it will affect all of them in the same manner. | |
4565 | ||
4566 | see also; udp_outgoing_address | |
4567 | ||
4568 | NOTE, udp_incoming_address and udp_outgoing_address can not | |
4569 | have the same value since they both use the same port. | |
4570 | DOC_END | |
cccac0a2 | 4571 | |
5473c134 | 4572 | NAME: udp_outgoing_address |
4573 | TYPE: address | |
4574 | LOC: Config.Addrs.udp_outgoing | |
4575 | DEFAULT: 255.255.255.255 | |
cccac0a2 | 4576 | DOC_START |
8524d4b2 | 4577 | udp_outgoing_address is used for UDP packets sent out to other |
5473c134 | 4578 | caches. |
cccac0a2 | 4579 | |
5473c134 | 4580 | The default behavior is to not bind to any specific address. |
cccac0a2 | 4581 | |
8524d4b2 | 4582 | Instead it will use the same socket as udp_incoming_address. |
4583 | Only change this if you want to have UDP queries sent using another | |
4584 | address than where this Squid listens for UDP queries from other | |
5473c134 | 4585 | caches. |
4586 | ||
8524d4b2 | 4587 | NOTE: udp_outgoing_address is used by the ICP, HTCP, and DNS |
4588 | modules. Altering it will affect all of them in the same manner. | |
4589 | ||
4590 | see also; udp_incoming_address | |
4591 | ||
5473c134 | 4592 | NOTE, udp_incoming_address and udp_outgoing_address can not |
8524d4b2 | 4593 | have the same value since they both use the same port. |
cccac0a2 | 4594 | DOC_END |
4595 | ||
3d1e3e43 | 4596 | NAME: icp_hit_stale |
4597 | COMMENT: on|off | |
4598 | TYPE: onoff | |
4599 | DEFAULT: off | |
4600 | LOC: Config.onoff.icp_hit_stale | |
4601 | DOC_START | |
4602 | If you want to return ICP_HIT for stale cache objects, set this | |
4603 | option to 'on'. If you have sibling relationships with caches | |
4604 | in other administrative domains, this should be 'off'. If you only | |
4605 | have sibling relationships with caches under your control, | |
4606 | it is probably okay to set this to 'on'. | |
4607 | If set to 'on', your siblings should use the option "allow-miss" | |
4608 | on their cache_peer lines for connecting to you. | |
4609 | DOC_END | |
4610 | ||
5473c134 | 4611 | NAME: minimum_direct_hops |
cccac0a2 | 4612 | TYPE: int |
5473c134 | 4613 | DEFAULT: 4 |
4614 | LOC: Config.minDirectHops | |
cccac0a2 | 4615 | DOC_START |
5473c134 | 4616 | If using the ICMP pinging stuff, do direct fetches for sites |
4617 | which are no more than this many hops away. | |
cccac0a2 | 4618 | DOC_END |
4619 | ||
5473c134 | 4620 | NAME: minimum_direct_rtt |
4621 | TYPE: int | |
4622 | DEFAULT: 400 | |
4623 | LOC: Config.minDirectRtt | |
cccac0a2 | 4624 | DOC_START |
5473c134 | 4625 | If using the ICMP pinging stuff, do direct fetches for sites |
4626 | which are no more than this many rtt milliseconds away. | |
cccac0a2 | 4627 | DOC_END |
4628 | ||
cccac0a2 | 4629 | NAME: netdb_low |
4630 | TYPE: int | |
4631 | DEFAULT: 900 | |
4632 | LOC: Config.Netdb.low | |
4633 | DOC_NONE | |
4634 | ||
4635 | NAME: netdb_high | |
4636 | TYPE: int | |
4637 | DEFAULT: 1000 | |
4638 | LOC: Config.Netdb.high | |
4639 | DOC_START | |
4640 | The low and high water marks for the ICMP measurement | |
4641 | database. These are counts, not percents. The defaults are | |
4642 | 900 and 1000. When the high water mark is reached, database | |
4643 | entries will be deleted until the low mark is reached. | |
4644 | DOC_END | |
4645 | ||
cccac0a2 | 4646 | NAME: netdb_ping_period |
4647 | TYPE: time_t | |
4648 | LOC: Config.Netdb.period | |
4649 | DEFAULT: 5 minutes | |
4650 | DOC_START | |
4651 | The minimum period for measuring a site. There will be at | |
4652 | least this much delay between successive pings to the same | |
4653 | network. The default is five minutes. | |
4654 | DOC_END | |
4655 | ||
cccac0a2 | 4656 | NAME: query_icmp |
4657 | COMMENT: on|off | |
4658 | TYPE: onoff | |
4659 | DEFAULT: off | |
4660 | LOC: Config.onoff.query_icmp | |
4661 | DOC_START | |
4662 | If you want to ask your peers to include ICMP data in their ICP | |
4663 | replies, enable this option. | |
4664 | ||
4665 | If your peer has configured Squid (during compilation) with | |
7f7db318 | 4666 | '--enable-icmp' that peer will send ICMP pings to origin server |
4667 | sites of the URLs it receives. If you enable this option the | |
cccac0a2 | 4668 | ICP replies from that peer will include the ICMP data (if available). |
4669 | Then, when choosing a parent cache, Squid will choose the parent with | |
4670 | the minimal RTT to the origin server. When this happens, the | |
4671 | hierarchy field of the access.log will be | |
4672 | "CLOSEST_PARENT_MISS". This option is off by default. | |
4673 | DOC_END | |
4674 | ||
4675 | NAME: test_reachability | |
4676 | COMMENT: on|off | |
4677 | TYPE: onoff | |
4678 | DEFAULT: off | |
4679 | LOC: Config.onoff.test_reachability | |
4680 | DOC_START | |
4681 | When this is 'on', ICP MISS replies will be ICP_MISS_NOFETCH | |
4682 | instead of ICP_MISS if the target host is NOT in the ICMP | |
4683 | database, or has a zero RTT. | |
4684 | DOC_END | |
4685 | ||
5473c134 | 4686 | NAME: icp_query_timeout |
4687 | COMMENT: (msec) | |
4688 | DEFAULT: 0 | |
4689 | TYPE: int | |
4690 | LOC: Config.Timeout.icp_query | |
4c3ef9b2 | 4691 | DOC_START |
5473c134 | 4692 | Normally Squid will automatically determine an optimal ICP |
4693 | query timeout value based on the round-trip-time of recent ICP | |
4694 | queries. If you want to override the value determined by | |
4695 | Squid, set this 'icp_query_timeout' to a non-zero value. This | |
4696 | value is specified in MILLISECONDS, so, to use a 2-second | |
4697 | timeout (the old default), you would write: | |
4c3ef9b2 | 4698 | |
5473c134 | 4699 | icp_query_timeout 2000 |
4c3ef9b2 | 4700 | DOC_END |
4701 | ||
5473c134 | 4702 | NAME: maximum_icp_query_timeout |
4703 | COMMENT: (msec) | |
4704 | DEFAULT: 2000 | |
4705 | TYPE: int | |
4706 | LOC: Config.Timeout.icp_query_max | |
cccac0a2 | 4707 | DOC_START |
5473c134 | 4708 | Normally the ICP query timeout is determined dynamically. But |
4709 | sometimes it can lead to very large values (say 5 seconds). | |
4710 | Use this option to put an upper limit on the dynamic timeout | |
4711 | value. Do NOT use this option to always use a fixed (instead | |
4712 | of a dynamic) timeout value. To set a fixed timeout see the | |
4713 | 'icp_query_timeout' directive. | |
cccac0a2 | 4714 | DOC_END |
4715 | ||
5473c134 | 4716 | NAME: minimum_icp_query_timeout |
4717 | COMMENT: (msec) | |
4718 | DEFAULT: 5 | |
4719 | TYPE: int | |
4720 | LOC: Config.Timeout.icp_query_min | |
cccac0a2 | 4721 | DOC_START |
5473c134 | 4722 | Normally the ICP query timeout is determined dynamically. But |
4723 | sometimes it can lead to very small timeouts, even lower than | |
4724 | the normal latency variance on your link due to traffic. | |
4725 | Use this option to put an lower limit on the dynamic timeout | |
4726 | value. Do NOT use this option to always use a fixed (instead | |
4727 | of a dynamic) timeout value. To set a fixed timeout see the | |
4728 | 'icp_query_timeout' directive. | |
cccac0a2 | 4729 | DOC_END |
4730 | ||
5473c134 | 4731 | NAME: background_ping_rate |
4732 | COMMENT: time-units | |
4733 | TYPE: time_t | |
4734 | DEFAULT: 10 seconds | |
4735 | LOC: Config.backgroundPingRate | |
cccac0a2 | 4736 | DOC_START |
5473c134 | 4737 | Controls how often the ICP pings are sent to siblings that |
4738 | have background-ping set. | |
cccac0a2 | 4739 | DOC_END |
4740 | ||
5473c134 | 4741 | COMMENT_START |
4742 | MULTICAST ICP OPTIONS | |
4743 | ----------------------------------------------------------------------------- | |
4744 | COMMENT_END | |
4745 | ||
4746 | NAME: mcast_groups | |
4747 | TYPE: wordlist | |
4748 | LOC: Config.mcast_group_list | |
8c01ada0 | 4749 | DEFAULT: none |
4750 | DOC_START | |
5473c134 | 4751 | This tag specifies a list of multicast groups which your server |
4752 | should join to receive multicasted ICP queries. | |
8c01ada0 | 4753 | |
5473c134 | 4754 | NOTE! Be very careful what you put here! Be sure you |
4755 | understand the difference between an ICP _query_ and an ICP | |
4756 | _reply_. This option is to be set only if you want to RECEIVE | |
4757 | multicast queries. Do NOT set this option to SEND multicast | |
4758 | ICP (use cache_peer for that). ICP replies are always sent via | |
4759 | unicast, so this option does not affect whether or not you will | |
4760 | receive replies from multicast group members. | |
8c01ada0 | 4761 | |
5473c134 | 4762 | You must be very careful to NOT use a multicast address which |
4763 | is already in use by another group of caches. | |
8c01ada0 | 4764 | |
5473c134 | 4765 | If you are unsure about multicast, please read the Multicast |
4766 | chapter in the Squid FAQ (http://www.squid-cache.org/FAQ/). | |
8c01ada0 | 4767 | |
5473c134 | 4768 | Usage: mcast_groups 239.128.16.128 224.0.1.20 |
8c01ada0 | 4769 | |
5473c134 | 4770 | By default, Squid doesn't listen on any multicast groups. |
4771 | DOC_END | |
8c01ada0 | 4772 | |
5473c134 | 4773 | NAME: mcast_miss_addr |
4774 | IFDEF: MULTICAST_MISS_STREAM | |
4775 | TYPE: address | |
4776 | LOC: Config.mcast_miss.addr | |
4777 | DEFAULT: 255.255.255.255 | |
4778 | DOC_START | |
4779 | If you enable this option, every "cache miss" URL will | |
4780 | be sent out on the specified multicast address. | |
cccac0a2 | 4781 | |
5473c134 | 4782 | Do not enable this option unless you are are absolutely |
4783 | certain you understand what you are doing. | |
cccac0a2 | 4784 | DOC_END |
4785 | ||
5473c134 | 4786 | NAME: mcast_miss_ttl |
4787 | IFDEF: MULTICAST_MISS_STREAM | |
4788 | TYPE: ushort | |
4789 | LOC: Config.mcast_miss.ttl | |
4790 | DEFAULT: 16 | |
cccac0a2 | 4791 | DOC_START |
5473c134 | 4792 | This is the time-to-live value for packets multicasted |
4793 | when multicasting off cache miss URLs is enabled. By | |
4794 | default this is set to 'site scope', i.e. 16. | |
4795 | DOC_END | |
cccac0a2 | 4796 | |
5473c134 | 4797 | NAME: mcast_miss_port |
4798 | IFDEF: MULTICAST_MISS_STREAM | |
4799 | TYPE: ushort | |
4800 | LOC: Config.mcast_miss.port | |
4801 | DEFAULT: 3135 | |
4802 | DOC_START | |
4803 | This is the port number to be used in conjunction with | |
4804 | 'mcast_miss_addr'. | |
4805 | DOC_END | |
cccac0a2 | 4806 | |
5473c134 | 4807 | NAME: mcast_miss_encode_key |
4808 | IFDEF: MULTICAST_MISS_STREAM | |
4809 | TYPE: string | |
4810 | LOC: Config.mcast_miss.encode_key | |
4811 | DEFAULT: XXXXXXXXXXXXXXXX | |
4812 | DOC_START | |
4813 | The URLs that are sent in the multicast miss stream are | |
4814 | encrypted. This is the encryption key. | |
4815 | DOC_END | |
8c01ada0 | 4816 | |
5473c134 | 4817 | NAME: mcast_icp_query_timeout |
4818 | COMMENT: (msec) | |
4819 | DEFAULT: 2000 | |
4820 | TYPE: int | |
4821 | LOC: Config.Timeout.mcast_icp_query | |
4822 | DOC_START | |
4823 | For multicast peers, Squid regularly sends out ICP "probes" to | |
4824 | count how many other peers are listening on the given multicast | |
4825 | address. This value specifies how long Squid should wait to | |
4826 | count all the replies. The default is 2000 msec, or 2 | |
4827 | seconds. | |
cccac0a2 | 4828 | DOC_END |
4829 | ||
5473c134 | 4830 | COMMENT_START |
4831 | INTERNAL ICON OPTIONS | |
4832 | ----------------------------------------------------------------------------- | |
4833 | COMMENT_END | |
4834 | ||
cccac0a2 | 4835 | NAME: icon_directory |
4836 | TYPE: string | |
4837 | LOC: Config.icons.directory | |
4838 | DEFAULT: @DEFAULT_ICON_DIR@ | |
4839 | DOC_START | |
4840 | Where the icons are stored. These are normally kept in | |
4841 | @DEFAULT_ICON_DIR@ | |
4842 | DOC_END | |
4843 | ||
f024c970 | 4844 | NAME: global_internal_static |
4845 | TYPE: onoff | |
4846 | LOC: Config.onoff.global_internal_static | |
4847 | DEFAULT: on | |
4848 | DOC_START | |
4849 | This directive controls is Squid should intercept all requests for | |
4850 | /squid-internal-static/ no matter which host the URL is requesting | |
4851 | (default on setting), or if nothing special should be done for | |
4852 | such URLs (off setting). The purpose of this directive is to make | |
4853 | icons etc work better in complex cache hierarchies where it may | |
4854 | not always be possible for all corners in the cache mesh to reach | |
4855 | the server generating a directory listing. | |
4856 | DOC_END | |
4857 | ||
5473c134 | 4858 | NAME: short_icon_urls |
4859 | TYPE: onoff | |
4860 | LOC: Config.icons.use_short_names | |
4861 | DEFAULT: on | |
4862 | DOC_START | |
4863 | If this is enabled Squid will use short URLs for icons. | |
4864 | If disabled it will revert to the old behavior of including | |
4865 | it's own name and port in the URL. | |
4866 | ||
4867 | If you run a complex cache hierarchy with a mix of Squid and | |
4868 | other proxies you may need to disable this directive. | |
4869 | DOC_END | |
4870 | ||
4871 | COMMENT_START | |
4872 | ERROR PAGE OPTIONS | |
4873 | ----------------------------------------------------------------------------- | |
4874 | COMMENT_END | |
4875 | ||
4876 | NAME: error_directory | |
4877 | TYPE: string | |
4878 | LOC: Config.errorDirectory | |
43000484 | 4879 | DEFAULT: none |
5473c134 | 4880 | DOC_START |
4881 | If you wish to create your own versions of the default | |
43000484 AJ |
4882 | error files to customize them to suit your company copy |
4883 | the error/template files to another directory and point | |
4884 | this tag at them. | |
4885 | ||
4886 | WARNING: This option will disable multi-language support | |
4887 | on error pages if used. | |
5473c134 | 4888 | |
4889 | The squid developers are interested in making squid available in | |
4890 | a wide variety of languages. If you are making translations for a | |
43000484 | 4891 | language that Squid does not currently provide please consider |
5473c134 | 4892 | contributing your translation back to the project. |
43000484 AJ |
4893 | http://wiki.squid-cache.org/Translations |
4894 | ||
4895 | The squid developers working on translations are happy to supply drop-in | |
4896 | translated error files in exchange for any new language contributions. | |
4897 | DOC_END | |
4898 | ||
4899 | NAME: error_default_language | |
4900 | IFDEF: USE_ERR_LOCALES | |
4901 | TYPE: string | |
4902 | LOC: Config.errorDefaultLanguage | |
4903 | DEFAULT: none | |
4904 | DOC_START | |
4905 | Set the default language which squid will send error pages in | |
4906 | if no existing translation matches the clients language | |
4907 | preferences. | |
4908 | ||
4909 | If unset (default) generic English will be used. | |
4910 | ||
4911 | The squid developers are interested in making squid available in | |
4912 | a wide variety of languages. If you are interested in making | |
4913 | translations for any language see the squid wiki for details. | |
4914 | http://wiki.squid-cache.org/Translations | |
5473c134 | 4915 | DOC_END |
4916 | ||
c411820c AJ |
4917 | NAME: error_log_languages |
4918 | IFDEF: USE_ERR_LOCALES | |
4919 | TYPE: onoff | |
4920 | LOC: Config.errorLogMissingLanguages | |
4921 | DEFAULT: on | |
4922 | DOC_START | |
4923 | Log to cache.log what languages users are attempting to | |
4924 | auto-negotiate for translations. | |
4925 | ||
4926 | Successful negotiations are not logged. Only failures | |
4927 | have meaning to indicate that Squid may need an upgrade | |
0c49f10e | 4928 | of its error page translations. |
c411820c AJ |
4929 | DOC_END |
4930 | ||
5b52cb6c AJ |
4931 | NAME: err_page_stylesheet |
4932 | TYPE: string | |
4933 | LOC: Config.errorStylesheet | |
4934 | DEFAULT: @DEFAULT_CONFIG_DIR@/errorpage.css | |
4935 | DOC_START | |
4936 | CSS Stylesheet to pattern the display of Squid default error pages. | |
4937 | ||
4938 | For information on CSS see http://www.w3.org/Style/CSS/ | |
4939 | DOC_END | |
4940 | ||
5473c134 | 4941 | NAME: err_html_text |
4942 | TYPE: eol | |
4943 | LOC: Config.errHtmlText | |
4944 | DEFAULT: none | |
4945 | DOC_START | |
4946 | HTML text to include in error messages. Make this a "mailto" | |
4947 | URL to your admin address, or maybe just a link to your | |
4948 | organizations Web page. | |
4949 | ||
4950 | To include this in your error messages, you must rewrite | |
4951 | the error template files (found in the "errors" directory). | |
4952 | Wherever you want the 'err_html_text' line to appear, | |
4953 | insert a %L tag in the error template file. | |
4954 | DOC_END | |
4955 | ||
4956 | NAME: email_err_data | |
4957 | COMMENT: on|off | |
4958 | TYPE: onoff | |
4959 | LOC: Config.onoff.emailErrData | |
4960 | DEFAULT: on | |
4961 | DOC_START | |
4962 | If enabled, information about the occurred error will be | |
4963 | included in the mailto links of the ERR pages (if %W is set) | |
4964 | so that the email body contains the data. | |
4965 | Syntax is <A HREF="mailto:%w%W">%w</A> | |
4966 | DOC_END | |
4967 | ||
4968 | NAME: deny_info | |
4969 | TYPE: denyinfo | |
4970 | LOC: Config.denyInfoList | |
4971 | DEFAULT: none | |
4972 | DOC_START | |
4973 | Usage: deny_info err_page_name acl | |
4974 | or deny_info http://... acl | |
43000484 | 4975 | or deny_info TCP_RESET acl |
5473c134 | 4976 | |
4977 | This can be used to return a ERR_ page for requests which | |
4978 | do not pass the 'http_access' rules. Squid remembers the last | |
4979 | acl it evaluated in http_access, and if a 'deny_info' line exists | |
4980 | for that ACL Squid returns a corresponding error page. | |
4981 | ||
4982 | The acl is typically the last acl on the http_access deny line which | |
4983 | denied access. The exceptions to this rule are: | |
4984 | - When Squid needs to request authentication credentials. It's then | |
4985 | the first authentication related acl encountered | |
4986 | - When none of the http_access lines matches. It's then the last | |
4987 | acl processed on the last http_access line. | |
4988 | ||
43000484 AJ |
4989 | NP: If providing your own custom error pages with error_directory |
4990 | you may also specify them by your custom file name: | |
4991 | Example: deny_info ERR_CUSTOM_ACCESS_DENIED bad_guys | |
5473c134 | 4992 | |
4993 | Alternatively you can specify an error URL. The browsers will | |
4994 | get redirected (302) to the specified URL. %s in the redirection | |
4995 | URL will be replaced by the requested URL. | |
4996 | ||
4997 | Alternatively you can tell Squid to reset the TCP connection | |
4998 | by specifying TCP_RESET. | |
4999 | DOC_END | |
5000 | ||
5001 | COMMENT_START | |
5002 | OPTIONS INFLUENCING REQUEST FORWARDING | |
5003 | ----------------------------------------------------------------------------- | |
5004 | COMMENT_END | |
5005 | ||
5006 | NAME: nonhierarchical_direct | |
e72a0ec0 | 5007 | TYPE: onoff |
5473c134 | 5008 | LOC: Config.onoff.nonhierarchical_direct |
e72a0ec0 | 5009 | DEFAULT: on |
5010 | DOC_START | |
5473c134 | 5011 | By default, Squid will send any non-hierarchical requests |
5012 | (matching hierarchy_stoplist or not cacheable request type) direct | |
5013 | to origin servers. | |
e72a0ec0 | 5014 | |
5473c134 | 5015 | If you set this to off, Squid will prefer to send these |
5016 | requests to parents. | |
0b0cfcf2 | 5017 | |
5473c134 | 5018 | Note that in most configurations, by turning this off you will only |
5019 | add latency to these request without any improvement in global hit | |
5020 | ratio. | |
0b0cfcf2 | 5021 | |
5473c134 | 5022 | If you are inside an firewall see never_direct instead of |
5023 | this directive. | |
8d6275c0 | 5024 | DOC_END |
0b0cfcf2 | 5025 | |
5473c134 | 5026 | NAME: prefer_direct |
8d6275c0 | 5027 | TYPE: onoff |
5473c134 | 5028 | LOC: Config.onoff.prefer_direct |
8d6275c0 | 5029 | DEFAULT: off |
5030 | DOC_START | |
5473c134 | 5031 | Normally Squid tries to use parents for most requests. If you for some |
5032 | reason like it to first try going direct and only use a parent if | |
5033 | going direct fails set this to on. | |
0b0cfcf2 | 5034 | |
5473c134 | 5035 | By combining nonhierarchical_direct off and prefer_direct on you |
5036 | can set up Squid to use a parent as a backup path if going direct | |
5037 | fails. | |
5038 | ||
5039 | Note: If you want Squid to use parents for all requests see | |
5040 | the never_direct directive. prefer_direct only modifies how Squid | |
5041 | acts on cacheable requests. | |
cccac0a2 | 5042 | DOC_END |
5043 | ||
5473c134 | 5044 | NAME: always_direct |
8d6275c0 | 5045 | TYPE: acl_access |
5473c134 | 5046 | LOC: Config.accessList.AlwaysDirect |
0b0cfcf2 | 5047 | DEFAULT: none |
0b0cfcf2 | 5048 | DOC_START |
5473c134 | 5049 | Usage: always_direct allow|deny [!]aclname ... |
0b0cfcf2 | 5050 | |
5473c134 | 5051 | Here you can use ACL elements to specify requests which should |
5052 | ALWAYS be forwarded by Squid to the origin servers without using | |
5053 | any peers. For example, to always directly forward requests for | |
5054 | local servers ignoring any parents or siblings you may have use | |
5055 | something like: | |
0b0cfcf2 | 5056 | |
5473c134 | 5057 | acl local-servers dstdomain my.domain.net |
5058 | always_direct allow local-servers | |
0b0cfcf2 | 5059 | |
5473c134 | 5060 | To always forward FTP requests directly, use |
f16fbc82 | 5061 | |
5473c134 | 5062 | acl FTP proto FTP |
5063 | always_direct allow FTP | |
cccac0a2 | 5064 | |
5473c134 | 5065 | NOTE: There is a similar, but opposite option named |
5066 | 'never_direct'. You need to be aware that "always_direct deny | |
5067 | foo" is NOT the same thing as "never_direct allow foo". You | |
5068 | may need to use a deny rule to exclude a more-specific case of | |
5069 | some other rule. Example: | |
8d6275c0 | 5070 | |
5473c134 | 5071 | acl local-external dstdomain external.foo.net |
5072 | acl local-servers dstdomain .foo.net | |
5073 | always_direct deny local-external | |
5074 | always_direct allow local-servers | |
8d6275c0 | 5075 | |
5473c134 | 5076 | NOTE: If your goal is to make the client forward the request |
5077 | directly to the origin server bypassing Squid then this needs | |
5078 | to be done in the client configuration. Squid configuration | |
5079 | can only tell Squid how Squid should fetch the object. | |
8d6275c0 | 5080 | |
5473c134 | 5081 | NOTE: This directive is not related to caching. The replies |
5082 | is cached as usual even if you use always_direct. To not cache | |
5083 | the replies see no_cache. | |
5084 | ||
5085 | This option replaces some v1.1 options such as local_domain | |
5086 | and local_ip. | |
cccac0a2 | 5087 | DOC_END |
0976f8db | 5088 | |
5473c134 | 5089 | NAME: never_direct |
5090 | TYPE: acl_access | |
5091 | LOC: Config.accessList.NeverDirect | |
5092 | DEFAULT: none | |
8d6275c0 | 5093 | DOC_START |
5473c134 | 5094 | Usage: never_direct allow|deny [!]aclname ... |
5095 | ||
5096 | never_direct is the opposite of always_direct. Please read | |
5097 | the description for always_direct if you have not already. | |
5098 | ||
5099 | With 'never_direct' you can use ACL elements to specify | |
5100 | requests which should NEVER be forwarded directly to origin | |
5101 | servers. For example, to force the use of a proxy for all | |
5102 | requests, except those in your local domain use something like: | |
5103 | ||
5104 | acl local-servers dstdomain .foo.net | |
5473c134 | 5105 | never_direct deny local-servers |
5106 | never_direct allow all | |
5107 | ||
5108 | or if Squid is inside a firewall and there are local intranet | |
5109 | servers inside the firewall use something like: | |
5110 | ||
5111 | acl local-intranet dstdomain .foo.net | |
5112 | acl local-external dstdomain external.foo.net | |
5113 | always_direct deny local-external | |
5114 | always_direct allow local-intranet | |
5115 | never_direct allow all | |
5116 | ||
5117 | This option replaces some v1.1 options such as inside_firewall | |
5118 | and firewall_ip. | |
8d6275c0 | 5119 | DOC_END |
0976f8db | 5120 | |
5473c134 | 5121 | COMMENT_START |
5122 | ADVANCED NETWORKING OPTIONS | |
5123 | ----------------------------------------------------------------------------- | |
5124 | COMMENT_END | |
5125 | ||
cccac0a2 | 5126 | NAME: incoming_icp_average |
5127 | TYPE: int | |
5128 | DEFAULT: 6 | |
5129 | LOC: Config.comm_incoming.icp_average | |
5130 | DOC_NONE | |
5131 | ||
5132 | NAME: incoming_http_average | |
5133 | TYPE: int | |
5134 | DEFAULT: 4 | |
5135 | LOC: Config.comm_incoming.http_average | |
5136 | DOC_NONE | |
5137 | ||
5138 | NAME: incoming_dns_average | |
5139 | TYPE: int | |
5140 | DEFAULT: 4 | |
5141 | LOC: Config.comm_incoming.dns_average | |
5142 | DOC_NONE | |
5143 | ||
5144 | NAME: min_icp_poll_cnt | |
5145 | TYPE: int | |
5146 | DEFAULT: 8 | |
5147 | LOC: Config.comm_incoming.icp_min_poll | |
5148 | DOC_NONE | |
5149 | ||
5150 | NAME: min_dns_poll_cnt | |
5151 | TYPE: int | |
5152 | DEFAULT: 8 | |
5153 | LOC: Config.comm_incoming.dns_min_poll | |
5154 | DOC_NONE | |
5155 | ||
5156 | NAME: min_http_poll_cnt | |
5157 | TYPE: int | |
5158 | DEFAULT: 8 | |
5159 | LOC: Config.comm_incoming.http_min_poll | |
5160 | DOC_START | |
5473c134 | 5161 | Heavy voodoo here. I can't even believe you are reading this. |
5162 | Are you crazy? Don't even think about adjusting these unless | |
5163 | you understand the algorithms in comm_select.c first! | |
5164 | DOC_END | |
5165 | ||
5166 | NAME: accept_filter | |
5473c134 | 5167 | TYPE: string |
5168 | DEFAULT: none | |
5169 | LOC: Config.accept_filter | |
5170 | DOC_START | |
0b4d4be5 | 5171 | FreeBSD: |
5172 | ||
5473c134 | 5173 | The name of an accept(2) filter to install on Squid's |
5174 | listen socket(s). This feature is perhaps specific to | |
5175 | FreeBSD and requires support in the kernel. | |
5176 | ||
5177 | The 'httpready' filter delays delivering new connections | |
2324cda2 | 5178 | to Squid until a full HTTP request has been received. |
0b4d4be5 | 5179 | See the accf_http(9) man page for details. |
5180 | ||
5181 | The 'dataready' filter delays delivering new connections | |
5182 | to Squid until there is some data to process. | |
5183 | See the accf_dataready(9) man page for details. | |
5184 | ||
5185 | Linux: | |
5186 | ||
5187 | The 'data' filter delays delivering of new connections | |
5188 | to Squid until there is some data to process by TCP_ACCEPT_DEFER. | |
5189 | You may optionally specify a number of seconds to wait by | |
5190 | 'data=N' where N is the number of seconds. Defaults to 30 | |
5191 | if not specified. See the tcp(7) man page for details. | |
5473c134 | 5192 | EXAMPLE: |
0b4d4be5 | 5193 | # FreeBSD |
5473c134 | 5194 | accept_filter httpready |
0b4d4be5 | 5195 | # Linux |
5196 | accept_filter data | |
5473c134 | 5197 | DOC_END |
5198 | ||
5199 | NAME: tcp_recv_bufsize | |
5200 | COMMENT: (bytes) | |
5201 | TYPE: b_size_t | |
5202 | DEFAULT: 0 bytes | |
5203 | LOC: Config.tcpRcvBufsz | |
5204 | DOC_START | |
5205 | Size of receive buffer to set for TCP sockets. Probably just | |
5206 | as easy to change your kernel's default. Set to zero to use | |
5207 | the default buffer size. | |
5208 | DOC_END | |
5209 | ||
5210 | COMMENT_START | |
5211 | ICAP OPTIONS | |
5212 | ----------------------------------------------------------------------------- | |
5213 | COMMENT_END | |
5214 | ||
5215 | NAME: icap_enable | |
5216 | TYPE: onoff | |
5217 | IFDEF: ICAP_CLIENT | |
5218 | COMMENT: on|off | |
26cc52cb | 5219 | LOC: Adaptation::Icap::TheConfig.onoff |
5473c134 | 5220 | DEFAULT: off |
5221 | DOC_START | |
53e738c6 | 5222 | If you want to enable the ICAP module support, set this to on. |
5473c134 | 5223 | DOC_END |
5224 | ||
5225 | NAME: icap_connect_timeout | |
5226 | TYPE: time_t | |
5227 | DEFAULT: none | |
26cc52cb | 5228 | LOC: Adaptation::Icap::TheConfig.connect_timeout_raw |
5473c134 | 5229 | IFDEF: ICAP_CLIENT |
5230 | DOC_START | |
5231 | This parameter specifies how long to wait for the TCP connect to | |
5232 | the requested ICAP server to complete before giving up and either | |
5233 | terminating the HTTP transaction or bypassing the failure. | |
5234 | ||
5235 | The default for optional services is peer_connect_timeout. | |
5236 | The default for essential services is connect_timeout. | |
5237 | If this option is explicitly set, its value applies to all services. | |
5238 | DOC_END | |
5239 | ||
5240 | NAME: icap_io_timeout | |
5241 | COMMENT: time-units | |
5242 | TYPE: time_t | |
5243 | DEFAULT: none | |
26cc52cb | 5244 | LOC: Adaptation::Icap::TheConfig.io_timeout_raw |
5473c134 | 5245 | IFDEF: ICAP_CLIENT |
5246 | DOC_START | |
5247 | This parameter specifies how long to wait for an I/O activity on | |
5248 | an established, active ICAP connection before giving up and | |
5249 | either terminating the HTTP transaction or bypassing the | |
5250 | failure. | |
5251 | ||
5252 | The default is read_timeout. | |
5253 | DOC_END | |
5254 | ||
5255 | NAME: icap_service_failure_limit | |
5256 | TYPE: int | |
5257 | IFDEF: ICAP_CLIENT | |
26cc52cb | 5258 | LOC: Adaptation::Icap::TheConfig.service_failure_limit |
5473c134 | 5259 | DEFAULT: 10 |
5260 | DOC_START | |
5261 | The limit specifies the number of failures that Squid tolerates | |
5262 | when establishing a new TCP connection with an ICAP service. If | |
5263 | the number of failures exceeds the limit, the ICAP service is | |
5264 | not used for new ICAP requests until it is time to refresh its | |
5265 | OPTIONS. The per-service failure counter is reset to zero each | |
5266 | time Squid fetches new service OPTIONS. | |
5267 | ||
5268 | A negative value disables the limit. Without the limit, an ICAP | |
5269 | service will not be considered down due to connectivity failures | |
5270 | between ICAP OPTIONS requests. | |
cccac0a2 | 5271 | DOC_END |
5272 | ||
5473c134 | 5273 | NAME: icap_service_revival_delay |
cccac0a2 | 5274 | TYPE: int |
5473c134 | 5275 | IFDEF: ICAP_CLIENT |
26cc52cb | 5276 | LOC: Adaptation::Icap::TheConfig.service_revival_delay |
5473c134 | 5277 | DEFAULT: 180 |
cccac0a2 | 5278 | DOC_START |
5473c134 | 5279 | The delay specifies the number of seconds to wait after an ICAP |
5280 | OPTIONS request failure before requesting the options again. The | |
5281 | failed ICAP service is considered "down" until fresh OPTIONS are | |
5282 | fetched. | |
cccac0a2 | 5283 | |
5473c134 | 5284 | The actual delay cannot be smaller than the hardcoded minimum |
5285 | delay of 30 seconds. | |
cccac0a2 | 5286 | DOC_END |
5287 | ||
5473c134 | 5288 | NAME: icap_preview_enable |
cccac0a2 | 5289 | TYPE: onoff |
5473c134 | 5290 | IFDEF: ICAP_CLIENT |
5291 | COMMENT: on|off | |
26cc52cb | 5292 | LOC: Adaptation::Icap::TheConfig.preview_enable |
ac7a62f9 | 5293 | DEFAULT: on |
cccac0a2 | 5294 | DOC_START |
ac7a62f9 | 5295 | The ICAP Preview feature allows the ICAP server to handle the |
5296 | HTTP message by looking only at the beginning of the message body | |
5297 | or even without receiving the body at all. In some environments, | |
5298 | previews greatly speedup ICAP processing. | |
5299 | ||
5300 | During an ICAP OPTIONS transaction, the server may tell Squid what | |
5301 | HTTP messages should be previewed and how big the preview should be. | |
5302 | Squid will not use Preview if the server did not request one. | |
5303 | ||
5304 | To disable ICAP Preview for all ICAP services, regardless of | |
5305 | individual ICAP server OPTIONS responses, set this option to "off". | |
5306 | Example: | |
5307 | icap_preview_enable off | |
cccac0a2 | 5308 | DOC_END |
5309 | ||
5473c134 | 5310 | NAME: icap_preview_size |
5311 | TYPE: int | |
5312 | IFDEF: ICAP_CLIENT | |
26cc52cb | 5313 | LOC: Adaptation::Icap::TheConfig.preview_size |
5473c134 | 5314 | DEFAULT: -1 |
cccac0a2 | 5315 | DOC_START |
53e738c6 | 5316 | The default size of preview data to be sent to the ICAP server. |
5317 | -1 means no preview. This value might be overwritten on a per server | |
5318 | basis by OPTIONS requests. | |
cccac0a2 | 5319 | DOC_END |
5320 | ||
5473c134 | 5321 | NAME: icap_default_options_ttl |
5322 | TYPE: int | |
5323 | IFDEF: ICAP_CLIENT | |
26cc52cb | 5324 | LOC: Adaptation::Icap::TheConfig.default_options_ttl |
5473c134 | 5325 | DEFAULT: 60 |
cccac0a2 | 5326 | DOC_START |
53e738c6 | 5327 | The default TTL value for ICAP OPTIONS responses that don't have |
5473c134 | 5328 | an Options-TTL header. |
cccac0a2 | 5329 | DOC_END |
5330 | ||
5473c134 | 5331 | NAME: icap_persistent_connections |
5332 | TYPE: onoff | |
5333 | IFDEF: ICAP_CLIENT | |
5334 | COMMENT: on|off | |
26cc52cb | 5335 | LOC: Adaptation::Icap::TheConfig.reuse_connections |
5473c134 | 5336 | DEFAULT: on |
cccac0a2 | 5337 | DOC_START |
5473c134 | 5338 | Whether or not Squid should use persistent connections to |
5339 | an ICAP server. | |
cccac0a2 | 5340 | DOC_END |
5341 | ||
5473c134 | 5342 | NAME: icap_send_client_ip |
5343 | TYPE: onoff | |
5344 | IFDEF: ICAP_CLIENT | |
5345 | COMMENT: on|off | |
26cc52cb | 5346 | LOC: Adaptation::Icap::TheConfig.send_client_ip |
5473c134 | 5347 | DEFAULT: off |
cccac0a2 | 5348 | DOC_START |
53e738c6 | 5349 | This adds the header "X-Client-IP" to ICAP requests. |
cccac0a2 | 5350 | DOC_END |
5351 | ||
5473c134 | 5352 | NAME: icap_send_client_username |
5353 | TYPE: onoff | |
5354 | IFDEF: ICAP_CLIENT | |
5355 | COMMENT: on|off | |
26cc52cb | 5356 | LOC: Adaptation::Icap::TheConfig.send_client_username |
5473c134 | 5357 | DEFAULT: off |
cccac0a2 | 5358 | DOC_START |
5473c134 | 5359 | This sends authenticated HTTP client username (if available) to |
5360 | the ICAP service. The username value is encoded based on the | |
5361 | icap_client_username_encode option and is sent using the header | |
5362 | specified by the icap_client_username_header option. | |
cccac0a2 | 5363 | DOC_END |
5364 | ||
5473c134 | 5365 | NAME: icap_client_username_header |
cccac0a2 | 5366 | TYPE: string |
5473c134 | 5367 | IFDEF: ICAP_CLIENT |
26cc52cb | 5368 | LOC: Adaptation::Icap::TheConfig.client_username_header |
5473c134 | 5369 | DEFAULT: X-Client-Username |
cccac0a2 | 5370 | DOC_START |
5473c134 | 5371 | ICAP request header name to use for send_client_username. |
cccac0a2 | 5372 | DOC_END |
5373 | ||
5473c134 | 5374 | NAME: icap_client_username_encode |
cccac0a2 | 5375 | TYPE: onoff |
5473c134 | 5376 | IFDEF: ICAP_CLIENT |
5377 | COMMENT: on|off | |
26cc52cb | 5378 | LOC: Adaptation::Icap::TheConfig.client_username_encode |
5473c134 | 5379 | DEFAULT: off |
cccac0a2 | 5380 | DOC_START |
5473c134 | 5381 | Whether to base64 encode the authenticated client username. |
cccac0a2 | 5382 | DOC_END |
5383 | ||
5473c134 | 5384 | NAME: icap_service |
5385 | TYPE: icap_service_type | |
5386 | IFDEF: ICAP_CLIENT | |
26cc52cb | 5387 | LOC: Adaptation::Icap::TheConfig |
5473c134 | 5388 | DEFAULT: none |
cccac0a2 | 5389 | DOC_START |
53e738c6 | 5390 | Defines a single ICAP service |
cccac0a2 | 5391 | |
53e738c6 | 5392 | icap_service servicename vectoring_point bypass service_url |
7d90757b | 5393 | |
53e738c6 | 5394 | vectoring_point = reqmod_precache|reqmod_postcache|respmod_precache|respmod_postcache |
f3db09e2 | 5395 | This specifies at which point of transaction processing the |
5396 | ICAP service should be activated. *_postcache vectoring points | |
5397 | are not yet supported. | |
53e738c6 | 5398 | bypass = 1|0 |
f3db09e2 | 5399 | If set to 1, the ICAP service is treated as optional. If the |
5400 | service cannot be reached or malfunctions, Squid will try to | |
5401 | ignore any errors and process the message as if the service | |
5402 | was not enabled. No all ICAP errors can be bypassed. | |
5403 | If set to 0, the ICAP service is treated as essential and all | |
5404 | ICAP errors will result in an error page returned to the | |
5405 | HTTP client. | |
53e738c6 | 5406 | service_url = icap://servername:port/service |
5473c134 | 5407 | |
5473c134 | 5408 | Example: |
5409 | icap_service service_1 reqmod_precache 0 icap://icap1.mydomain.net:1344/reqmod | |
5410 | icap_service service_2 respmod_precache 0 icap://icap2.mydomain.net:1344/respmod | |
cccac0a2 | 5411 | DOC_END |
5412 | ||
5473c134 | 5413 | NAME: icap_class |
5414 | TYPE: icap_class_type | |
5415 | IFDEF: ICAP_CLIENT | |
21a26d31 | 5416 | LOC: none |
5473c134 | 5417 | DEFAULT: none |
cccac0a2 | 5418 | DOC_START |
62c7f90e AR |
5419 | This depricated option was documented to define an ICAP service |
5420 | chain, even though it actually defined a set of similar, redundant | |
5421 | services, and the chains were not supported. | |
5473c134 | 5422 | |
62c7f90e AR |
5423 | To define a set of redundant services, please use the |
5424 | adaptation_service_set directive. | |
5473c134 | 5425 | |
62c7f90e AR |
5426 | If you need adaptation service chains, patches or sponsorship |
5427 | is welcome. | |
cccac0a2 | 5428 | DOC_END |
5429 | ||
5473c134 | 5430 | NAME: icap_access |
5431 | TYPE: icap_access_type | |
5432 | IFDEF: ICAP_CLIENT | |
21a26d31 | 5433 | LOC: none |
cccac0a2 | 5434 | DEFAULT: none |
cccac0a2 | 5435 | DOC_START |
62c7f90e AR |
5436 | This option is depricated. Please use adaptation_access, which |
5437 | has the same ICAP functionality, but comes with better | |
5438 | documentation, and eCAP support. | |
cccac0a2 | 5439 | DOC_END |
5440 | ||
57afc994 AR |
5441 | COMMENT_START |
5442 | eCAP OPTIONS | |
5443 | ----------------------------------------------------------------------------- | |
5444 | COMMENT_END | |
5445 | ||
21a26d31 AR |
5446 | NAME: ecap_enable |
5447 | TYPE: onoff | |
5448 | IFDEF: USE_ECAP | |
5449 | COMMENT: on|off | |
574b508c | 5450 | LOC: Adaptation::Ecap::TheConfig.onoff |
21a26d31 AR |
5451 | DEFAULT: off |
5452 | DOC_START | |
5453 | Controls whether eCAP support is enabled. | |
5454 | DOC_END | |
5455 | ||
5456 | NAME: ecap_service | |
5457 | TYPE: ecap_service_type | |
5458 | IFDEF: USE_ECAP | |
574b508c | 5459 | LOC: Adaptation::Ecap::TheConfig |
21a26d31 AR |
5460 | DEFAULT: none |
5461 | DOC_START | |
5462 | Defines a single eCAP service | |
5463 | ||
5464 | ecap_service servicename vectoring_point bypass service_url | |
5465 | ||
5466 | vectoring_point = reqmod_precache|reqmod_postcache|respmod_precache|respmod_postcache | |
5467 | This specifies at which point of transaction processing the | |
5468 | eCAP service should be activated. *_postcache vectoring points | |
5469 | are not yet supported. | |
5470 | bypass = 1|0 | |
5471 | If set to 1, the eCAP service is treated as optional. If the | |
5472 | service cannot be reached or malfunctions, Squid will try to | |
5473 | ignore any errors and process the message as if the service | |
5474 | was not enabled. No all eCAP errors can be bypassed. | |
5475 | If set to 0, the eCAP service is treated as essential and all | |
5476 | eCAP errors will result in an error page returned to the | |
5477 | HTTP client. | |
5478 | service_url = ecap://vendor/service_name?custom&cgi=style¶meters=optional | |
5479 | ||
5480 | Example: | |
5481 | ecap_service service_1 reqmod_precache 0 ecap://filters-R-us/leakDetector?on_error=block | |
5482 | ecap_service service_2 respmod_precache 1 icap://filters-R-us/virusFilter?config=/etc/vf.cfg | |
5483 | DOC_END | |
5484 | ||
57afc994 AR |
5485 | NAME: loadable_modules |
5486 | TYPE: wordlist | |
5487 | IFDEF: USE_LOADABLE_MODULES | |
5488 | LOC: Config.loadable_module_names | |
5489 | DEFAULT: none | |
5490 | DOC_START | |
5491 | Instructs Squid to load the specified dynamic module(s) or activate | |
5492 | preloaded module(s). | |
5493 | Example: | |
5494 | loadable_modules @DEFAULT_PREFIX@/lib/MinimalAdapter.so | |
5495 | DOC_END | |
5496 | ||
62c7f90e AR |
5497 | COMMENT_START |
5498 | MESSAGE ADAPTATION OPTIONS | |
5499 | ----------------------------------------------------------------------------- | |
5500 | COMMENT_END | |
5501 | ||
5502 | NAME: adaptation_service_set | |
5503 | TYPE: adaptation_service_set_type | |
5504 | IFDEF: USE_ADAPTATION | |
5505 | LOC: none | |
5506 | DEFAULT: none | |
5507 | DOC_START | |
5508 | ||
5509 | Defines a named adaptation service set. The set is populated in | |
5510 | the order of adaptation_service_set directives in this file. | |
5511 | When adaptation ACLs are processed, the first and only the first | |
5512 | applicable adaptation service from the set will be used. Thus, | |
5513 | the set should group similar, redundant services, rather than a | |
5514 | chain of complementary services. | |
5515 | ||
5516 | If you have a single adaptation service, you do not need to | |
5517 | define a set containing it because adaptation_access accepts | |
5518 | service names. | |
5519 | ||
5520 | See also: adaptation_access | |
5521 | ||
5522 | Example: | |
5523 | adaptation_service_set svcBlocker urlFilterPrimary urlFilterBackup | |
5524 | adaptation service_set svcLogger loggerLocal loggerRemote | |
5525 | DOC_END | |
5526 | ||
5527 | NAME: adaptation_access | |
5528 | TYPE: adaptation_access_type | |
5529 | IFDEF: USE_ADAPTATION | |
5530 | LOC: none | |
5531 | DEFAULT: none | |
5532 | DOC_START | |
5533 | Sends an HTTP transaction to an ICAP or eCAP adaptation service. | |
5534 | ||
5535 | adaptation_access service_name allow|deny [!]aclname... | |
5536 | adaptation_access set_name allow|deny [!]aclname... | |
5537 | ||
5538 | At each supported vectoring point, the adaptation_access | |
5539 | statements are processed in the order they appear in this | |
5540 | configuration file. Statements pointing to the following services | |
5541 | are ignored (i.e., skipped without checking their ACL): | |
5542 | ||
5543 | - services serving different vectoring points | |
5544 | - "broken-but-bypassable" services | |
5545 | - "up" services configured to ignore such transactions | |
5546 | (e.g., based on the ICAP Transfer-Ignore header). | |
5547 | ||
5548 | When a set_name is used, all services in the set are checked | |
5549 | using the same rules, to find the first applicable one. See | |
5550 | adaptation_service_set for details. | |
5551 | ||
5552 | If an access list is checked and there is a match, the | |
5553 | processing stops: For an "allow" rule, the corresponding | |
5554 | adaptation service is used for the transaction. For a "deny" | |
5555 | rule, no adaptation service is activated. | |
5556 | ||
5557 | It is currently not possible to apply more than one adaptation | |
5558 | service at the same vectoring point to the same HTTP transaction. | |
5559 | ||
5560 | See also: icap_service and ecap_service | |
5561 | ||
5562 | Example: | |
5563 | adaptation_access service_1 allow all | |
5564 | DOC_END | |
5565 | ||
5473c134 | 5566 | COMMENT_START |
5567 | DNS OPTIONS | |
5568 | ----------------------------------------------------------------------------- | |
5569 | COMMENT_END | |
5570 | ||
5571 | NAME: check_hostnames | |
cccac0a2 | 5572 | TYPE: onoff |
cccac0a2 | 5573 | DEFAULT: off |
5473c134 | 5574 | LOC: Config.onoff.check_hostnames |
cccac0a2 | 5575 | DOC_START |
5473c134 | 5576 | For security and stability reasons Squid can check |
5577 | hostnames for Internet standard RFC compliance. If you want | |
5578 | Squid to perform these checks turn this directive on. | |
cccac0a2 | 5579 | DOC_END |
5580 | ||
5473c134 | 5581 | NAME: allow_underscore |
cccac0a2 | 5582 | TYPE: onoff |
cccac0a2 | 5583 | DEFAULT: on |
5473c134 | 5584 | LOC: Config.onoff.allow_underscore |
cccac0a2 | 5585 | DOC_START |
5473c134 | 5586 | Underscore characters is not strictly allowed in Internet hostnames |
5587 | but nevertheless used by many sites. Set this to off if you want | |
5588 | Squid to be strict about the standard. | |
5589 | This check is performed only when check_hostnames is set to on. | |
cccac0a2 | 5590 | DOC_END |
5591 | ||
5473c134 | 5592 | NAME: cache_dns_program |
cccac0a2 | 5593 | TYPE: string |
5473c134 | 5594 | IFDEF: USE_DNSSERVERS |
5595 | DEFAULT: @DEFAULT_DNSSERVER@ | |
5596 | LOC: Config.Program.dnsserver | |
cccac0a2 | 5597 | DOC_START |
5473c134 | 5598 | Specify the location of the executable for dnslookup process. |
cccac0a2 | 5599 | DOC_END |
5600 | ||
5473c134 | 5601 | NAME: dns_children |
5602 | TYPE: int | |
5603 | IFDEF: USE_DNSSERVERS | |
5604 | DEFAULT: 5 | |
5605 | LOC: Config.dnsChildren | |
58850d15 | 5606 | DOC_START |
5473c134 | 5607 | The number of processes spawn to service DNS name lookups. |
5608 | For heavily loaded caches on large servers, you should | |
5609 | probably increase this value to at least 10. The maximum | |
5610 | is 32. The default is 5. | |
58850d15 | 5611 | |
5473c134 | 5612 | You must have at least one dnsserver process. |
58850d15 | 5613 | DOC_END |
5614 | ||
5473c134 | 5615 | NAME: dns_retransmit_interval |
5616 | TYPE: time_t | |
5617 | DEFAULT: 5 seconds | |
5618 | LOC: Config.Timeout.idns_retransmit | |
5619 | IFDEF: !USE_DNSSERVERS | |
cccac0a2 | 5620 | DOC_START |
5473c134 | 5621 | Initial retransmit interval for DNS queries. The interval is |
5622 | doubled each time all configured DNS servers have been tried. | |
cccac0a2 | 5623 | |
cccac0a2 | 5624 | DOC_END |
5625 | ||
5473c134 | 5626 | NAME: dns_timeout |
5627 | TYPE: time_t | |
5628 | DEFAULT: 2 minutes | |
5629 | LOC: Config.Timeout.idns_query | |
5630 | IFDEF: !USE_DNSSERVERS | |
cccac0a2 | 5631 | DOC_START |
5473c134 | 5632 | DNS Query timeout. If no response is received to a DNS query |
5633 | within this time all DNS servers for the queried domain | |
5634 | are assumed to be unavailable. | |
cccac0a2 | 5635 | DOC_END |
5636 | ||
5473c134 | 5637 | NAME: dns_defnames |
5638 | COMMENT: on|off | |
cccac0a2 | 5639 | TYPE: onoff |
cccac0a2 | 5640 | DEFAULT: off |
5473c134 | 5641 | LOC: Config.onoff.res_defnames |
cccac0a2 | 5642 | DOC_START |
5473c134 | 5643 | Normally the RES_DEFNAMES resolver option is disabled |
5644 | (see res_init(3)). This prevents caches in a hierarchy | |
5645 | from interpreting single-component hostnames locally. To allow | |
5646 | Squid to handle single-component names, enable this option. | |
cccac0a2 | 5647 | DOC_END |
5648 | ||
5473c134 | 5649 | NAME: dns_nameservers |
5650 | TYPE: wordlist | |
5651 | DEFAULT: none | |
5652 | LOC: Config.dns_nameservers | |
cccac0a2 | 5653 | DOC_START |
5473c134 | 5654 | Use this if you want to specify a list of DNS name servers |
5655 | (IP addresses) to use instead of those given in your | |
5656 | /etc/resolv.conf file. | |
5657 | On Windows platforms, if no value is specified here or in | |
5658 | the /etc/resolv.conf file, the list of DNS name servers are | |
5659 | taken from the Windows registry, both static and dynamic DHCP | |
5660 | configurations are supported. | |
cccac0a2 | 5661 | |
5473c134 | 5662 | Example: dns_nameservers 10.0.0.1 192.172.0.4 |
cccac0a2 | 5663 | DOC_END |
5664 | ||
5473c134 | 5665 | NAME: hosts_file |
cccac0a2 | 5666 | TYPE: string |
5473c134 | 5667 | DEFAULT: @DEFAULT_HOSTS@ |
5668 | LOC: Config.etcHostsPath | |
cccac0a2 | 5669 | DOC_START |
5473c134 | 5670 | Location of the host-local IP name-address associations |
5671 | database. Most Operating Systems have such a file on different | |
5672 | default locations: | |
5673 | - Un*X & Linux: /etc/hosts | |
5674 | - Windows NT/2000: %SystemRoot%\system32\drivers\etc\hosts | |
5675 | (%SystemRoot% value install default is c:\winnt) | |
5676 | - Windows XP/2003: %SystemRoot%\system32\drivers\etc\hosts | |
5677 | (%SystemRoot% value install default is c:\windows) | |
5678 | - Windows 9x/Me: %windir%\hosts | |
5679 | (%windir% value is usually c:\windows) | |
5680 | - Cygwin: /etc/hosts | |
cccac0a2 | 5681 | |
5473c134 | 5682 | The file contains newline-separated definitions, in the |
5683 | form ip_address_in_dotted_form name [name ...] names are | |
5684 | whitespace-separated. Lines beginning with an hash (#) | |
5685 | character are comments. | |
cccac0a2 | 5686 | |
5473c134 | 5687 | The file is checked at startup and upon configuration. |
5688 | If set to 'none', it won't be checked. | |
5689 | If append_domain is used, that domain will be added to | |
5690 | domain-local (i.e. not containing any dot character) host | |
5691 | definitions. | |
cccac0a2 | 5692 | DOC_END |
5693 | ||
5473c134 | 5694 | NAME: append_domain |
5695 | TYPE: string | |
5696 | LOC: Config.appendDomain | |
5697 | DEFAULT: none | |
6a2f3fcf | 5698 | DOC_START |
5473c134 | 5699 | Appends local domain name to hostnames without any dots in |
5700 | them. append_domain must begin with a period. | |
5701 | ||
5702 | Be warned there are now Internet names with no dots in | |
5703 | them using only top-domain names, so setting this may | |
5704 | cause some Internet sites to become unavailable. | |
5705 | ||
5706 | Example: | |
5707 | append_domain .yourdomain.com | |
6a2f3fcf | 5708 | DOC_END |
5709 | ||
5473c134 | 5710 | NAME: ignore_unknown_nameservers |
5711 | TYPE: onoff | |
5712 | LOC: Config.onoff.ignore_unknown_nameservers | |
df6fd596 | 5713 | DEFAULT: on |
5714 | DOC_START | |
5473c134 | 5715 | By default Squid checks that DNS responses are received |
5716 | from the same IP addresses they are sent to. If they | |
5717 | don't match, Squid ignores the response and writes a warning | |
5718 | message to cache.log. You can allow responses from unknown | |
5719 | nameservers by setting this option to 'off'. | |
df6fd596 | 5720 | DOC_END |
5721 | ||
cc192b50 | 5722 | NAME: dns_v4_fallback |
5723 | TYPE: onoff | |
5724 | DEFAULT: on | |
5725 | LOC: Config.onoff.dns_require_A | |
5726 | DOC_START | |
5727 | Standard practice with DNS is to lookup either A or AAAA records | |
5728 | and use the results if it succeeds. Only looking up the other if | |
5729 | the first attempt fails or otherwise produces no results. | |
5730 | ||
5731 | That policy however will cause squid to produce error pages for some | |
5732 | servers that advertise AAAA but are unreachable over IPv6. | |
5733 | ||
5734 | If this is ON squid will always lookup both AAAA and A, using both. | |
5735 | If this is OFF squid will lookup AAAA and only try A if none found. | |
5736 | ||
5737 | WARNING: There are some possibly unwanted side-effects with this on: | |
5738 | *) Doubles the load placed by squid on the DNS network. | |
5739 | *) May negatively impact connection delay times. | |
5740 | DOC_END | |
5741 | ||
6bc15a4f | 5742 | NAME: ipcache_size |
5743 | COMMENT: (number of entries) | |
5744 | TYPE: int | |
5745 | DEFAULT: 1024 | |
5746 | LOC: Config.ipcache.size | |
5747 | DOC_NONE | |
5748 | ||
5749 | NAME: ipcache_low | |
5750 | COMMENT: (percent) | |
5751 | TYPE: int | |
5752 | DEFAULT: 90 | |
5753 | LOC: Config.ipcache.low | |
5754 | DOC_NONE | |
5755 | ||
5756 | NAME: ipcache_high | |
5757 | COMMENT: (percent) | |
5758 | TYPE: int | |
5759 | DEFAULT: 95 | |
5760 | LOC: Config.ipcache.high | |
5761 | DOC_START | |
5762 | The size, low-, and high-water marks for the IP cache. | |
5763 | DOC_END | |
5764 | ||
5765 | NAME: fqdncache_size | |
5766 | COMMENT: (number of entries) | |
5767 | TYPE: int | |
5768 | DEFAULT: 1024 | |
5769 | LOC: Config.fqdncache.size | |
5770 | DOC_START | |
5771 | Maximum number of FQDN cache entries. | |
5772 | DOC_END | |
5773 | ||
a58ff010 | 5774 | COMMENT_START |
5473c134 | 5775 | MISCELLANEOUS |
a58ff010 | 5776 | ----------------------------------------------------------------------------- |
5777 | COMMENT_END | |
5778 | ||
5473c134 | 5779 | NAME: memory_pools |
a58ff010 | 5780 | COMMENT: on|off |
5473c134 | 5781 | TYPE: onoff |
5782 | DEFAULT: on | |
5783 | LOC: Config.onoff.mem_pools | |
a58ff010 | 5784 | DOC_START |
5473c134 | 5785 | If set, Squid will keep pools of allocated (but unused) memory |
5786 | available for future use. If memory is a premium on your | |
5787 | system and you believe your malloc library outperforms Squid | |
5788 | routines, disable this. | |
a58ff010 | 5789 | DOC_END |
5790 | ||
5473c134 | 5791 | NAME: memory_pools_limit |
5792 | COMMENT: (bytes) | |
5793 | TYPE: b_size_t | |
5794 | DEFAULT: 5 MB | |
5795 | LOC: Config.MemPools.limit | |
ec1245f8 | 5796 | DOC_START |
5473c134 | 5797 | Used only with memory_pools on: |
5798 | memory_pools_limit 50 MB | |
ec1245f8 | 5799 | |
5473c134 | 5800 | If set to a non-zero value, Squid will keep at most the specified |
5801 | limit of allocated (but unused) memory in memory pools. All free() | |
5802 | requests that exceed this limit will be handled by your malloc | |
5803 | library. Squid does not pre-allocate any memory, just safe-keeps | |
5804 | objects that otherwise would be free()d. Thus, it is safe to set | |
5805 | memory_pools_limit to a reasonably high value even if your | |
5806 | configuration will use less memory. | |
ec1245f8 | 5807 | |
5473c134 | 5808 | If set to zero, Squid will keep all memory it can. That is, there |
5809 | will be no limit on the total amount of memory used for safe-keeping. | |
ec1245f8 | 5810 | |
5473c134 | 5811 | To disable memory allocation optimization, do not set |
5812 | memory_pools_limit to 0. Set memory_pools to "off" instead. | |
5813 | ||
5814 | An overhead for maintaining memory pools is not taken into account | |
5815 | when the limit is checked. This overhead is close to four bytes per | |
5816 | object kept. However, pools may actually _save_ memory because of | |
5817 | reduced memory thrashing in your malloc library. | |
ec1245f8 | 5818 | DOC_END |
5819 | ||
5473c134 | 5820 | NAME: forwarded_for |
67c06f0d AJ |
5821 | COMMENT: on|off|transparent|truncate|delete |
5822 | TYPE: string | |
5473c134 | 5823 | DEFAULT: on |
5824 | LOC: opt_forwarded_for | |
5f8252d2 | 5825 | DOC_START |
67c06f0d AJ |
5826 | If set to "on", Squid will append your client's IP address |
5827 | in the HTTP requests it forwards. By default it looks like: | |
5f8252d2 | 5828 | |
5473c134 | 5829 | X-Forwarded-For: 192.1.2.3 |
5830 | ||
67c06f0d | 5831 | If set to "off", it will appear as |
5473c134 | 5832 | |
5833 | X-Forwarded-For: unknown | |
67c06f0d AJ |
5834 | |
5835 | If set to "transparent", Squid will not alter the | |
5836 | X-Forwarded-For header in any way. | |
5837 | ||
5838 | If set to "delete", Squid will delete the entire | |
5839 | X-Forwarded-For header. | |
5840 | ||
5841 | If set to "truncate", Squid will remove all existing | |
5842 | X-Forwarded-For entries, and place itself as the sole entry. | |
5f8252d2 | 5843 | DOC_END |
5844 | ||
5473c134 | 5845 | NAME: cachemgr_passwd |
5846 | TYPE: cachemgrpasswd | |
5847 | DEFAULT: none | |
5848 | LOC: Config.passwd_list | |
5f8252d2 | 5849 | DOC_START |
5473c134 | 5850 | Specify passwords for cachemgr operations. |
5f8252d2 | 5851 | |
5473c134 | 5852 | Usage: cachemgr_passwd password action action ... |
5853 | ||
5854 | Some valid actions are (see cache manager menu for a full list): | |
5855 | 5min | |
5856 | 60min | |
5857 | asndb | |
5858 | authenticator | |
5859 | cbdata | |
5860 | client_list | |
5861 | comm_incoming | |
5862 | config * | |
5863 | counters | |
5864 | delay | |
5865 | digest_stats | |
5866 | dns | |
5867 | events | |
5868 | filedescriptors | |
5869 | fqdncache | |
5870 | histograms | |
5871 | http_headers | |
5872 | info | |
5873 | io | |
5874 | ipcache | |
5875 | mem | |
5876 | menu | |
5877 | netdb | |
5878 | non_peers | |
5879 | objects | |
5880 | offline_toggle * | |
5881 | pconn | |
5882 | peer_select | |
b360c477 | 5883 | reconfigure * |
5473c134 | 5884 | redirector |
5885 | refresh | |
5886 | server_list | |
5887 | shutdown * | |
5888 | store_digest | |
5889 | storedir | |
5890 | utilization | |
5891 | via_headers | |
5892 | vm_objects | |
5893 | ||
5894 | * Indicates actions which will not be performed without a | |
5895 | valid password, others can be performed if not listed here. | |
5896 | ||
5897 | To disable an action, set the password to "disable". | |
5898 | To allow performing an action without a password, set the | |
5899 | password to "none". | |
5900 | ||
5901 | Use the keyword "all" to set the same password for all actions. | |
5902 | ||
5903 | Example: | |
5904 | cachemgr_passwd secret shutdown | |
5905 | cachemgr_passwd lesssssssecret info stats/objects | |
5906 | cachemgr_passwd disable all | |
5f8252d2 | 5907 | DOC_END |
5908 | ||
5473c134 | 5909 | NAME: client_db |
a58ff010 | 5910 | COMMENT: on|off |
5473c134 | 5911 | TYPE: onoff |
5912 | DEFAULT: on | |
5913 | LOC: Config.onoff.client_db | |
a58ff010 | 5914 | DOC_START |
5473c134 | 5915 | If you want to disable collecting per-client statistics, |
5916 | turn off client_db here. | |
a58ff010 | 5917 | DOC_END |
5918 | ||
5473c134 | 5919 | NAME: refresh_all_ims |
5920 | COMMENT: on|off | |
5921 | TYPE: onoff | |
5922 | DEFAULT: off | |
5923 | LOC: Config.onoff.refresh_all_ims | |
a58ff010 | 5924 | DOC_START |
5473c134 | 5925 | When you enable this option, squid will always check |
5926 | the origin server for an update when a client sends an | |
5927 | If-Modified-Since request. Many browsers use IMS | |
5928 | requests when the user requests a reload, and this | |
5929 | ensures those clients receive the latest version. | |
a58ff010 | 5930 | |
5473c134 | 5931 | By default (off), squid may return a Not Modified response |
5932 | based on the age of the cached version. | |
78e8cfc4 | 5933 | DOC_END |
5934 | ||
5473c134 | 5935 | NAME: reload_into_ims |
5936 | IFDEF: HTTP_VIOLATIONS | |
12b91c99 | 5937 | COMMENT: on|off |
5473c134 | 5938 | TYPE: onoff |
5939 | DEFAULT: off | |
5940 | LOC: Config.onoff.reload_into_ims | |
12b91c99 | 5941 | DOC_START |
5473c134 | 5942 | When you enable this option, client no-cache or ``reload'' |
5943 | requests will be changed to If-Modified-Since requests. | |
5944 | Doing this VIOLATES the HTTP standard. Enabling this | |
5945 | feature could make you liable for problems which it | |
5946 | causes. | |
5947 | ||
5948 | see also refresh_pattern for a more selective approach. | |
12b91c99 | 5949 | DOC_END |
5950 | ||
5473c134 | 5951 | NAME: maximum_single_addr_tries |
5952 | TYPE: int | |
5953 | LOC: Config.retry.maxtries | |
5954 | DEFAULT: 1 | |
a58ff010 | 5955 | DOC_START |
5473c134 | 5956 | This sets the maximum number of connection attempts for a |
5957 | host that only has one address (for multiple-address hosts, | |
5958 | each address is tried once). | |
5959 | ||
5960 | The default value is one attempt, the (not recommended) | |
5961 | maximum is 255 tries. A warning message will be generated | |
5962 | if it is set to a value greater than ten. | |
5963 | ||
5964 | Note: This is in addition to the request re-forwarding which | |
5965 | takes place if Squid fails to get a satisfying response. | |
a58ff010 | 5966 | DOC_END |
5967 | ||
5473c134 | 5968 | NAME: retry_on_error |
a58ff010 | 5969 | TYPE: onoff |
5473c134 | 5970 | LOC: Config.retry.onerror |
a58ff010 | 5971 | DEFAULT: off |
5972 | DOC_START | |
5473c134 | 5973 | If set to on Squid will automatically retry requests when |
5974 | receiving an error response. This is mainly useful if you | |
5975 | are in a complex cache hierarchy to work around access | |
5976 | control errors. | |
5f8252d2 | 5977 | DOC_END |
5978 | ||
5473c134 | 5979 | NAME: as_whois_server |
5f8252d2 | 5980 | TYPE: string |
5473c134 | 5981 | LOC: Config.as_whois_server |
5982 | DEFAULT: whois.ra.net | |
5983 | DEFAULT_IF_NONE: whois.ra.net | |
5f8252d2 | 5984 | DOC_START |
5473c134 | 5985 | WHOIS server to query for AS numbers. NOTE: AS numbers are |
5986 | queried only when Squid starts up, not for every request. | |
5f8252d2 | 5987 | DOC_END |
5988 | ||
5473c134 | 5989 | NAME: offline_mode |
5f8252d2 | 5990 | TYPE: onoff |
5473c134 | 5991 | LOC: Config.onoff.offline |
5f8252d2 | 5992 | DEFAULT: off |
5993 | DOC_START | |
5473c134 | 5994 | Enable this option and Squid will never try to validate cached |
5995 | objects. | |
a58ff010 | 5996 | DOC_END |
5997 | ||
5473c134 | 5998 | NAME: uri_whitespace |
5999 | TYPE: uri_whitespace | |
6000 | LOC: Config.uri_whitespace | |
6001 | DEFAULT: strip | |
a58ff010 | 6002 | DOC_START |
5473c134 | 6003 | What to do with requests that have whitespace characters in the |
6004 | URI. Options: | |
a58ff010 | 6005 | |
5473c134 | 6006 | strip: The whitespace characters are stripped out of the URL. |
6007 | This is the behavior recommended by RFC2396. | |
6008 | deny: The request is denied. The user receives an "Invalid | |
6009 | Request" message. | |
6010 | allow: The request is allowed and the URI is not changed. The | |
6011 | whitespace characters remain in the URI. Note the | |
6012 | whitespace is passed to redirector processes if they | |
6013 | are in use. | |
6014 | encode: The request is allowed and the whitespace characters are | |
6015 | encoded according to RFC1738. This could be considered | |
6016 | a violation of the HTTP/1.1 | |
6017 | RFC because proxies are not allowed to rewrite URI's. | |
6018 | chop: The request is allowed and the URI is chopped at the | |
6019 | first whitespace. This might also be considered a | |
6020 | violation. | |
6021 | DOC_END | |
a58ff010 | 6022 | |
5473c134 | 6023 | NAME: chroot |
6024 | TYPE: string | |
6025 | LOC: Config.chroot_dir | |
a58ff010 | 6026 | DEFAULT: none |
6027 | DOC_START | |
5473c134 | 6028 | Use this to have Squid do a chroot() while initializing. This |
6029 | also causes Squid to fully drop root privileges after | |
6030 | initializing. This means, for example, if you use a HTTP | |
6031 | port less than 1024 and try to reconfigure, you will may get an | |
6032 | error saying that Squid can not open the port. | |
6033 | DOC_END | |
a58ff010 | 6034 | |
5473c134 | 6035 | NAME: balance_on_multiple_ip |
6036 | TYPE: onoff | |
6037 | LOC: Config.onoff.balance_on_multiple_ip | |
cc192b50 | 6038 | DEFAULT: off |
5473c134 | 6039 | DOC_START |
cc192b50 | 6040 | Modern IP resolvers in squid sort lookup results by preferred access. |
6041 | By default squid will use these IP in order and only rotates to | |
6042 | the next listed when the most preffered fails. | |
6043 | ||
5473c134 | 6044 | Some load balancing servers based on round robin DNS have been |
6045 | found not to preserve user session state across requests | |
6046 | to different IP addresses. | |
a58ff010 | 6047 | |
cc192b50 | 6048 | Enabling this directive Squid rotates IP's per request. |
a58ff010 | 6049 | DOC_END |
6050 | ||
5473c134 | 6051 | NAME: pipeline_prefetch |
6052 | TYPE: onoff | |
6053 | LOC: Config.onoff.pipeline_prefetch | |
6054 | DEFAULT: off | |
a58ff010 | 6055 | DOC_START |
5473c134 | 6056 | To boost the performance of pipelined requests to closer |
6057 | match that of a non-proxied environment Squid can try to fetch | |
6058 | up to two requests in parallel from a pipeline. | |
a58ff010 | 6059 | |
5473c134 | 6060 | Defaults to off for bandwidth management and access logging |
6061 | reasons. | |
6062 | DOC_END | |
a58ff010 | 6063 | |
5473c134 | 6064 | NAME: high_response_time_warning |
6065 | TYPE: int | |
6066 | COMMENT: (msec) | |
6067 | LOC: Config.warnings.high_rptm | |
6068 | DEFAULT: 0 | |
6069 | DOC_START | |
6070 | If the one-minute median response time exceeds this value, | |
6071 | Squid prints a WARNING with debug level 0 to get the | |
6072 | administrators attention. The value is in milliseconds. | |
a58ff010 | 6073 | DOC_END |
6074 | ||
5473c134 | 6075 | NAME: high_page_fault_warning |
6076 | TYPE: int | |
6077 | LOC: Config.warnings.high_pf | |
6078 | DEFAULT: 0 | |
cc9f92d4 | 6079 | DOC_START |
5473c134 | 6080 | If the one-minute average page fault rate exceeds this |
6081 | value, Squid prints a WARNING with debug level 0 to get | |
6082 | the administrators attention. The value is in page faults | |
6083 | per second. | |
6084 | DOC_END | |
cc9f92d4 | 6085 | |
5473c134 | 6086 | NAME: high_memory_warning |
6087 | TYPE: b_size_t | |
6088 | LOC: Config.warnings.high_memory | |
904971da | 6089 | DEFAULT: 0 KB |
5473c134 | 6090 | DOC_START |
6091 | If the memory usage (as determined by mallinfo) exceeds | |
904971da | 6092 | this amount, Squid prints a WARNING with debug level 0 to get |
5473c134 | 6093 | the administrators attention. |
6094 | DOC_END | |
cc9f92d4 | 6095 | |
5473c134 | 6096 | NAME: sleep_after_fork |
6097 | COMMENT: (microseconds) | |
6098 | TYPE: int | |
6099 | LOC: Config.sleep_after_fork | |
6100 | DEFAULT: 0 | |
6101 | DOC_START | |
6102 | When this is set to a non-zero value, the main Squid process | |
6103 | sleeps the specified number of microseconds after a fork() | |
6104 | system call. This sleep may help the situation where your | |
6105 | system reports fork() failures due to lack of (virtual) | |
6106 | memory. Note, however, if you have a lot of child | |
6107 | processes, these sleep delays will add up and your | |
6108 | Squid will not service requests for some amount of time | |
6109 | until all the child processes have been started. | |
6110 | On Windows value less then 1000 (1 milliseconds) are | |
6111 | rounded to 1000. | |
cc9f92d4 | 6112 | DOC_END |
6113 | ||
b6696974 | 6114 | NAME: windows_ipaddrchangemonitor |
6b0516c6 | 6115 | IFDEF: _SQUID_MSWIN_ |
b6696974 GS |
6116 | COMMENT: on|off |
6117 | TYPE: onoff | |
6118 | DEFAULT: on | |
6119 | LOC: Config.onoff.WIN32_IpAddrChangeMonitor | |
6120 | DOC_START | |
6121 | On Windows Squid by default will monitor IP address changes and will | |
6122 | reconfigure itself after any detected event. This is very useful for | |
6123 | proxies connected to internet with dial-up interfaces. | |
6124 | In some cases (a Proxy server acting as VPN gateway is one) it could be | |
6125 | desiderable to disable this behaviour setting this to 'off'. | |
6126 | Note: after changing this, Squid service must be restarted. | |
6127 | DOC_END | |
6128 | ||
cccac0a2 | 6129 | EOF |