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