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