]> git.ipfire.org Git - thirdparty/squid.git/blob - src/cf.data.pre
751d47cf9d5fc131536aa171a48870fe3be9e8ca
[thirdparty/squid.git] / src / cf.data.pre
1 ## Copyright (C) 1996-2022 The Squid Software Foundation and contributors
2 ##
3 ## Squid software is distributed under GPLv2+ license and includes
4 ## contributions from numerous individuals and organizations.
5 ## Please see the COPYING and CONTRIBUTORS files for details.
6 ##
7
8 COMMENT_START
9 WELCOME TO @SQUID@
10 ----------------------------
11
12 This is the documentation for the Squid configuration file.
13 This documentation can also be found online at:
14 http://www.squid-cache.org/Doc/config/
15
16 You may wish to look at the Squid home page and wiki for the
17 FAQ and other documentation:
18 http://www.squid-cache.org/
19 http://wiki.squid-cache.org/SquidFaq
20 http://wiki.squid-cache.org/ConfigExamples
21
22 This documentation shows what the defaults for various directives
23 happen to be. If you don't need to change the default, you should
24 leave the line out of your squid.conf in most cases.
25
26 In some cases "none" refers to no default setting at all,
27 while in other cases it refers to the value of the option
28 - the comments for that keyword indicate if this is the case.
29
30 COMMENT_END
31
32 COMMENT_START
33 Configuration options can be included using the "include" directive.
34 Include takes a list of files to include. Quoting and wildcards are
35 supported.
36
37 For example,
38
39 include /path/to/included/file/squid.acl.config
40
41 Includes can be nested up to a hard-coded depth of 16 levels.
42 This arbitrary restriction is to prevent recursive include references
43 from causing Squid entering an infinite loop whilst trying to load
44 configuration files.
45
46 Values with byte units
47
48 Squid accepts size units on some size related directives. All
49 such directives are documented with a default value displaying
50 a unit.
51
52 Units accepted by Squid are:
53 bytes - byte
54 KB - Kilobyte (1024 bytes)
55 MB - Megabyte
56 GB - Gigabyte
57
58 Values with time units
59
60 Time-related directives marked with either "time-units" or
61 "time-units-small" accept a time unit. The supported time units are:
62
63 nanosecond (time-units-small only)
64 microsecond (time-units-small only)
65 millisecond
66 second
67 minute
68 hour
69 day
70 week
71 fortnight
72 month - 30 days
73 year - 31557790080 milliseconds (just over 365 days)
74 decade
75
76 Values with spaces, quotes, and other special characters
77
78 Squid supports directive parameters with spaces, quotes, and other
79 special characters. Surround such parameters with "double quotes". Use
80 the configuration_includes_quoted_values directive to enable or
81 disable that support.
82
83 Squid supports reading configuration option parameters from external
84 files using the syntax:
85 parameters("/path/filename")
86 For example:
87 acl allowlist dstdomain parameters("/etc/squid/allowlist.txt")
88
89 Conditional configuration
90
91 If-statements can be used to make configuration directives
92 depend on conditions:
93
94 if <CONDITION>
95 ... regular configuration directives ...
96 [else
97 ... regular configuration directives ...]
98 endif
99
100 The else part is optional. The keywords "if", "else", and "endif"
101 must be typed on their own lines, as if they were regular
102 configuration directives.
103
104 NOTE: An else-if condition is not supported.
105
106 These individual conditions types are supported:
107
108 true
109 Always evaluates to true.
110 false
111 Always evaluates to false.
112 <integer> = <integer>
113 Equality comparison of two integer numbers.
114
115
116 SMP-Related Macros
117
118 The following SMP-related preprocessor macros can be used.
119
120 ${process_name} expands to the current Squid process "name"
121 (e.g., squid1, squid2, or cache1).
122
123 ${process_number} expands to the current Squid process
124 identifier, which is an integer number (e.g., 1, 2, 3) unique
125 across all Squid processes of the current service instance.
126
127 ${service_name} expands into the current Squid service instance
128 name identifier which is provided by -n on the command line.
129
130 Logformat Macros
131
132 Logformat macros can be used in many places outside of the logformat
133 directive. In theory, all of the logformat codes can be used as %macros,
134 where they are supported. In practice, a %macro expands as a dash (-) when
135 the transaction does not yet have enough information and a value is needed.
136
137 There is no definitive list of what tokens are available at the various
138 stages of the transaction.
139
140 And some information may already be available to Squid but not yet
141 committed where the macro expansion code can access it (report
142 such instances!). The macro will be expanded into a single dash
143 ('-') in such cases. Not all macros have been tested.
144
145 COMMENT_END
146
147 # options still not yet ported from 2.7 to 3.x
148 NAME: broken_vary_encoding
149 TYPE: obsolete
150 DOC_START
151 This option is not yet supported by Squid-3.
152 DOC_END
153
154 NAME: cache_vary
155 TYPE: obsolete
156 DOC_START
157 This option is not yet supported by Squid-3.
158 DOC_END
159
160 NAME: error_map
161 TYPE: obsolete
162 DOC_START
163 This option is not yet supported by Squid-3.
164 DOC_END
165
166 NAME: external_refresh_check
167 TYPE: obsolete
168 DOC_START
169 This option is not yet supported by Squid-3.
170 DOC_END
171
172 NAME: location_rewrite_program location_rewrite_access location_rewrite_children location_rewrite_concurrency
173 TYPE: obsolete
174 DOC_START
175 This option is not yet supported by Squid-3.
176 DOC_END
177
178 NAME: refresh_stale_hit
179 TYPE: obsolete
180 DOC_START
181 This option is not yet supported by Squid-3.
182 DOC_END
183
184 # Options removed in 6.x
185 NAME: announce_file
186 TYPE: obsolete
187 DOC_START
188 Remove this line. Squid no longer supports this feature.
189 DOC_END
190
191 NAME: announce_host
192 TYPE: obsolete
193 DOC_START
194 Remove this line. Squid no longer supports this feature.
195 DOC_END
196
197 NAME: announce_period
198 TYPE: obsolete
199 DOC_START
200 Remove this line. Squid no longer supports this feature.
201 DOC_END
202
203 NAME: announce_port
204 TYPE: obsolete
205 DOC_START
206 Remove this line. Squid no longer supports this feature.
207 DOC_END
208
209 NAME: request_entities
210 TYPE: obsolete
211 DOC_START
212 Remove this line. Squid now accepts HTTP/1.1 requests with bodies.
213 To simplify UI and code, Squid rejects certain HTTP/1.0 requests with bodies.
214 DOC_END
215
216 # Options removed in 5.x
217 NAME: dns_v4_first
218 TYPE: obsolete
219 DOC_START
220 Remove this line. Squid no longer supports preferential treatment of DNS A records.
221 DOC_END
222
223 # Options removed in 4.x
224 NAME: cache_peer_domain cache_host_domain
225 TYPE: obsolete
226 DOC_START
227 Replace with dstdomain ACLs and cache_peer_access.
228 DOC_END
229
230 NAME: ie_refresh
231 TYPE: obsolete
232 DOC_START
233 Remove this line. The behaviour enabled by this is no longer needed.
234 DOC_END
235
236 NAME: sslproxy_cafile
237 TYPE: obsolete
238 DOC_START
239 Remove this line. Use tls_outgoing_options cafile= instead.
240 DOC_END
241
242 NAME: sslproxy_capath
243 TYPE: obsolete
244 DOC_START
245 Remove this line. Use tls_outgoing_options capath= instead.
246 DOC_END
247
248 NAME: sslproxy_cipher
249 TYPE: obsolete
250 DOC_START
251 Remove this line. Use tls_outgoing_options cipher= instead.
252 DOC_END
253
254 NAME: sslproxy_client_certificate
255 TYPE: obsolete
256 DOC_START
257 Remove this line. Use tls_outgoing_options cert= instead.
258 DOC_END
259
260 NAME: sslproxy_client_key
261 TYPE: obsolete
262 DOC_START
263 Remove this line. Use tls_outgoing_options key= instead.
264 DOC_END
265
266 NAME: sslproxy_flags
267 TYPE: obsolete
268 DOC_START
269 Remove this line. Use tls_outgoing_options flags= instead.
270 DOC_END
271
272 NAME: sslproxy_options
273 TYPE: obsolete
274 DOC_START
275 Remove this line. Use tls_outgoing_options options= instead.
276 DOC_END
277
278 NAME: sslproxy_version
279 TYPE: obsolete
280 DOC_START
281 Remove this line. Use tls_outgoing_options options= instead.
282 DOC_END
283
284 # Options removed in 3.5
285 NAME: hierarchy_stoplist
286 TYPE: obsolete
287 DOC_START
288 Remove this line. Use always_direct or cache_peer_access ACLs instead if you need to prevent cache_peer use.
289 DOC_END
290
291 # Options removed in 3.4
292 NAME: log_access
293 TYPE: obsolete
294 DOC_START
295 Remove this line. Use acls with access_log directives to control access logging
296 DOC_END
297
298 NAME: log_icap
299 TYPE: obsolete
300 DOC_START
301 Remove this line. Use acls with icap_log directives to control icap logging
302 DOC_END
303
304 # Options Removed in 3.3
305 NAME: ignore_ims_on_miss
306 TYPE: obsolete
307 DOC_START
308 Remove this line. The HTTP/1.1 feature is now configured by 'cache_miss_revalidate'.
309 DOC_END
310
311 # Options Removed in 3.2
312 NAME: balance_on_multiple_ip
313 TYPE: obsolete
314 DOC_START
315 Remove this line. Squid performs a 'Happy Eyeballs' algorithm, this multiple-IP algorithm is not longer relevant.
316 DOC_END
317
318 NAME: chunked_request_body_max_size
319 TYPE: obsolete
320 DOC_START
321 Remove this line. Squid is now HTTP/1.1 compliant.
322 DOC_END
323
324 NAME: dns_v4_fallback
325 TYPE: obsolete
326 DOC_START
327 Remove this line. Squid performs a 'Happy Eyeballs' algorithm, the 'fallback' algorithm is no longer relevant.
328 DOC_END
329
330 NAME: emulate_httpd_log
331 TYPE: obsolete
332 DOC_START
333 Replace this with an access_log directive using the format 'common' or 'combined'.
334 DOC_END
335
336 NAME: forward_log
337 TYPE: obsolete
338 DOC_START
339 Use a regular access.log with ACL limiting it to MISS events.
340 DOC_END
341
342 NAME: ftp_list_width
343 TYPE: obsolete
344 DOC_START
345 Remove this line. Configure FTP page display using the CSS controls in errorpages.css instead.
346 DOC_END
347
348 NAME: ignore_expect_100
349 TYPE: obsolete
350 DOC_START
351 Remove this line. The HTTP/1.1 feature is now fully supported by default.
352 DOC_END
353
354 NAME: log_fqdn
355 TYPE: obsolete
356 DOC_START
357 Remove this option from your config. To log FQDN use %>A in the log format.
358 DOC_END
359
360 NAME: log_ip_on_direct
361 TYPE: obsolete
362 DOC_START
363 Remove this option from your config. To log server or peer names use %<A in the log format.
364 DOC_END
365
366 NAME: maximum_single_addr_tries
367 TYPE: obsolete
368 DOC_START
369 Replaced by connect_retries. The behaviour has changed, please read the documentation before altering.
370 DOC_END
371
372 NAME: referer_log referrer_log
373 TYPE: obsolete
374 DOC_START
375 Replace this with an access_log directive using the format 'referrer'.
376 DOC_END
377
378 NAME: update_headers
379 TYPE: obsolete
380 DOC_START
381 Remove this line. The feature is supported by default in storage types where update is implemented.
382 DOC_END
383
384 NAME: url_rewrite_concurrency
385 TYPE: obsolete
386 DOC_START
387 Remove this line. Set the 'concurrency=' option of url_rewrite_children instead.
388 DOC_END
389
390 NAME: useragent_log
391 TYPE: obsolete
392 DOC_START
393 Replace this with an access_log directive using the format 'useragent'.
394 DOC_END
395
396 # Options Removed in 3.1
397 NAME: dns_testnames
398 TYPE: obsolete
399 DOC_START
400 Remove this line. DNS is no longer tested on startup.
401 DOC_END
402
403 NAME: extension_methods
404 TYPE: obsolete
405 DOC_START
406 Remove this line. All valid methods for HTTP are accepted by default.
407 DOC_END
408
409 # 2.7 Options Removed/Replaced in 3.2
410 NAME: zero_buffers
411 TYPE: obsolete
412 DOC_NONE
413
414 # 2.7 Options Removed/Replaced in 3.1
415 NAME: incoming_rate
416 TYPE: obsolete
417 DOC_NONE
418
419 NAME: server_http11
420 TYPE: obsolete
421 DOC_START
422 Remove this line. HTTP/1.1 is supported by default.
423 DOC_END
424
425 NAME: upgrade_http0.9
426 TYPE: obsolete
427 DOC_START
428 Remove this line. ICY/1.0 streaming protocol is supported by default.
429 DOC_END
430
431 NAME: zph_local zph_mode zph_option zph_parent zph_sibling
432 TYPE: obsolete
433 DOC_START
434 Alter these entries. Use the qos_flows directive instead.
435 DOC_END
436
437 # Options Removed in 3.0
438 NAME: header_access
439 TYPE: obsolete
440 DOC_START
441 Since squid-3.0 replace with request_header_access or reply_header_access
442 depending on whether you wish to match client requests or server replies.
443 DOC_END
444
445 NAME: httpd_accel_no_pmtu_disc
446 TYPE: obsolete
447 DOC_START
448 Since squid-3.0 use the 'disable-pmtu-discovery' flag on http_port instead.
449 DOC_END
450
451 NAME: wais_relay_host
452 TYPE: obsolete
453 DOC_START
454 Replace this line with 'cache_peer' configuration.
455 DOC_END
456
457 NAME: wais_relay_port
458 TYPE: obsolete
459 DOC_START
460 Replace this line with 'cache_peer' configuration.
461 DOC_END
462
463 COMMENT_START
464 OPTIONS FOR SMP
465 -----------------------------------------------------------------------------
466 COMMENT_END
467
468 NAME: workers
469 TYPE: int
470 LOC: Config.workers
471 DEFAULT: 1
472 DEFAULT_DOC: SMP support disabled.
473 DOC_START
474 Number of main Squid processes or "workers" to fork and maintain.
475 0: "no daemon" mode, like running "squid -N ..."
476 1: "no SMP" mode, start one main Squid process daemon (default)
477 N: start N main Squid process daemons (i.e., SMP mode)
478
479 In SMP mode, each worker does nearly all what a single Squid daemon
480 does (e.g., listen on http_port and forward HTTP requests).
481 DOC_END
482
483 NAME: cpu_affinity_map
484 TYPE: CpuAffinityMap
485 LOC: Config.cpuAffinityMap
486 DEFAULT: none
487 DEFAULT_DOC: Let operating system decide.
488 DOC_START
489 Usage: cpu_affinity_map process_numbers=P1,P2,... cores=C1,C2,...
490
491 Sets 1:1 mapping between Squid processes and CPU cores. For example,
492
493 cpu_affinity_map process_numbers=1,2,3,4 cores=1,3,5,7
494
495 affects processes 1 through 4 only and places them on the first
496 four even cores, starting with core #1.
497
498 CPU cores are numbered starting from 1. Requires support for
499 sched_getaffinity(2) and sched_setaffinity(2) system calls.
500
501 Multiple cpu_affinity_map options are merged.
502
503 See also: workers
504 DOC_END
505
506 NAME: shared_memory_locking
507 TYPE: YesNoNone
508 COMMENT: on|off
509 LOC: Config.shmLocking
510 DEFAULT: off
511 DOC_START
512 Whether to ensure that all required shared memory is available by
513 "locking" that shared memory into RAM when Squid starts. The
514 alternative is faster startup time followed by slightly slower
515 performance and, if not enough RAM is actually available during
516 runtime, mysterious crashes.
517
518 SMP Squid uses many shared memory segments. These segments are
519 brought into Squid memory space using an mmap(2) system call. During
520 Squid startup, the mmap() call often succeeds regardless of whether
521 the system has enough RAM. In general, Squid cannot tell whether the
522 kernel applies this "optimistic" memory allocation policy (but
523 popular modern kernels usually use it).
524
525 Later, if Squid attempts to actually access the mapped memory
526 regions beyond what the kernel is willing to allocate, the
527 "optimistic" kernel simply kills Squid kid with a SIGBUS signal.
528 Some of the memory limits enforced by the kernel are currently
529 poorly understood: We do not know how to detect and check them. This
530 option ensures that the mapped memory will be available.
531
532 This option may have a positive performance side-effect: Locking
533 memory at start avoids runtime paging I/O. Paging slows Squid down.
534
535 Locking memory may require a large enough RLIMIT_MEMLOCK OS limit,
536 CAP_IPC_LOCK capability, or equivalent.
537 DOC_END
538
539 NAME: hopeless_kid_revival_delay
540 COMMENT: time-units
541 TYPE: time_t
542 LOC: Config.hopelessKidRevivalDelay
543 DEFAULT: 1 hour
544 DOC_START
545 Normally, when a kid process dies, Squid immediately restarts the
546 kid. A kid experiencing frequent deaths is marked as "hopeless" for
547 the duration specified by this directive. Hopeless kids are not
548 automatically restarted.
549
550 Currently, zero values are not supported because they result in
551 misconfigured SMP Squid instances running forever, endlessly
552 restarting each dying kid. To effectively disable hopeless kids
553 revival, set the delay to a huge value (e.g., 1 year).
554
555 Reconfiguration also clears all hopeless kids designations, allowing
556 for manual revival of hopeless kids.
557 DOC_END
558
559 COMMENT_START
560 OPTIONS FOR AUTHENTICATION
561 -----------------------------------------------------------------------------
562 COMMENT_END
563
564 NAME: auth_param
565 TYPE: authparam
566 IFDEF: USE_AUTH
567 LOC: Auth::TheConfig.schemes
568 DEFAULT: none
569 DOC_START
570 This is used to define parameters for the various authentication
571 schemes supported by Squid.
572
573 format: auth_param scheme parameter [setting]
574
575 The order in which authentication schemes are presented to the client is
576 dependent on the order the scheme first appears in config file. IE
577 has a bug (it's not RFC 2617 compliant) in that it will use the basic
578 scheme if basic is the first entry presented, even if more secure
579 schemes are presented. For now use the order in the recommended
580 settings section below. If other browsers have difficulties (don't
581 recognize the schemes offered even if you are using basic) either
582 put basic first, or disable the other schemes (by commenting out their
583 program entry).
584
585 Once an authentication scheme is fully configured, it can only be
586 shutdown by shutting squid down and restarting. Changes can be made on
587 the fly and activated with a reconfigure. I.E. You can change to a
588 different helper, but not unconfigure the helper completely.
589
590 Please note that while this directive defines how Squid processes
591 authentication it does not automatically activate authentication.
592 To use authentication you must in addition make use of ACLs based
593 on login name in http_access (proxy_auth, proxy_auth_regex or
594 external with %LOGIN used in the format tag). The browser will be
595 challenged for authentication on the first such acl encountered
596 in http_access processing and will also be re-challenged for new
597 login credentials if the request is being denied by a proxy_auth
598 type acl.
599
600 WARNING: authentication can't be used in a transparently intercepting
601 proxy as the client then thinks it is talking to an origin server and
602 not the proxy. This is a limitation of bending the TCP/IP protocol to
603 transparently intercepting port 80, not a limitation in Squid.
604 Ports flagged 'transparent', 'intercept', or 'tproxy' have
605 authentication disabled.
606
607 === Parameters common to all schemes. ===
608
609 "program" cmdline
610 Specifies the command for the external authenticator.
611
612 By default, each authentication scheme is not used unless a
613 program is specified.
614
615 See http://wiki.squid-cache.org/Features/AddonHelpers for
616 more details on helper operations and creating your own.
617
618 "key_extras" format
619 Specifies a string to be append to request line format for
620 the authentication helper. "Quoted" format values may contain
621 spaces and logformat %macros. In theory, any logformat %macro
622 can be used. In practice, a %macro expands as a dash (-) if
623 the helper request is sent before the required macro
624 information is available to Squid.
625
626 By default, Squid uses request formats provided in
627 scheme-specific examples below (search for %credentials).
628
629 The expanded key_extras value is added to the Squid credentials
630 cache and, hence, will affect authentication. It can be used to
631 authenticate different users with identical user names (e.g.,
632 when user authentication depends on http_port).
633
634 Avoid adding frequently changing information to key_extras. For
635 example, if you add user source IP, and it changes frequently
636 in your environment, then max_user_ip ACL is going to treat
637 every user+IP combination as a unique "user", breaking the ACL
638 and wasting a lot of memory on those user records. It will also
639 force users to authenticate from scratch whenever their IP
640 changes.
641
642 "realm" string
643 Specifies the protection scope (aka realm name) which is to be
644 reported to the client for the authentication scheme. It is
645 commonly part of the text the user will see when prompted for
646 their username and password.
647
648 For Basic the default is "Squid proxy-caching web server".
649 For Digest there is no default, this parameter is mandatory.
650 For NTLM and Negotiate this parameter is ignored.
651
652 "children" numberofchildren [startup=N] [idle=N] [concurrency=N]
653 [queue-size=N] [on-persistent-overload=action]
654 [reservation-timeout=seconds]
655
656 The maximum number of authenticator processes to spawn. If
657 you start too few Squid will have to wait for them to process
658 a backlog of credential verifications, slowing it down. When
659 password verifications are done via a (slow) network you are
660 likely to need lots of authenticator processes.
661
662 The startup= and idle= options permit some skew in the exact
663 amount run. A minimum of startup=N will begin during startup
664 and reconfigure. Squid will start more in groups of up to
665 idle=N in an attempt to meet traffic needs and to keep idle=N
666 free above those traffic needs up to the maximum.
667
668 The concurrency= option sets the number of concurrent requests
669 the helper can process. The default of 0 is used for helpers
670 who only supports one request at a time. Setting this to a
671 number greater than 0 changes the protocol used to include a
672 channel ID field first on the request/response line, allowing
673 multiple requests to be sent to the same helper in parallel
674 without waiting for the response.
675
676 Concurrency must not be set unless it's known the helper
677 supports the input format with channel-ID fields.
678
679 The queue-size option sets the maximum number of queued
680 requests. A request is queued when no existing child can
681 accept it due to concurrency limit and no new child can be
682 started due to numberofchildren limit. The default maximum is
683 2*numberofchildren. Squid is allowed to temporarily exceed the
684 configured maximum, marking the affected helper as
685 "overloaded". If the helper overload lasts more than 3
686 minutes, the action prescribed by the on-persistent-overload
687 option applies.
688
689 The on-persistent-overload=action option specifies Squid
690 reaction to a new helper request arriving when the helper
691 has been overloaded for more that 3 minutes already. The number
692 of queued requests determines whether the helper is overloaded
693 (see the queue-size option).
694
695 Two actions are supported:
696
697 die Squid worker quits. This is the default behavior.
698
699 ERR Squid treats the helper request as if it was
700 immediately submitted, and the helper immediately
701 replied with an ERR response. This action has no effect
702 on the already queued and in-progress helper requests.
703
704 NOTE: NTLM and Negotiate schemes do not support concurrency
705 in the Squid code module even though some helpers can.
706
707 The reservation-timeout=seconds option allows NTLM and Negotiate
708 helpers to forget about clients that abandon their in-progress
709 connection authentication without closing the connection. The
710 timeout is measured since the last helper response received by
711 Squid for the client. Fractional seconds are not supported.
712
713 After the timeout, the helper will be used for other clients if
714 there are no unreserved helpers available. In the latter case,
715 the old client attempt to resume authentication will not be
716 forwarded to the helper (and the client should open a new HTTP
717 connection and retry authentication from scratch).
718
719 By default, reservations do not expire and clients that keep
720 their connections open without completing authentication may
721 exhaust all NTLM and Negotiate helpers.
722
723 "keep_alive" on|off
724 If you experience problems with PUT/POST requests when using
725 the NTLM or Negotiate schemes then you can try setting this
726 to off. This will cause Squid to forcibly close the connection
727 on the initial request where the browser asks which schemes
728 are supported by the proxy.
729
730 For Basic and Digest this parameter is ignored.
731
732 "utf8" on|off
733 Useful for sending credentials to authentication backends that
734 expect UTF-8 encoding (e.g., LDAP).
735
736 When this option is enabled, Squid uses HTTP Accept-Language
737 request header to guess the received credentials encoding
738 (ISO-Latin-1, CP1251, or UTF-8) and then converts the first
739 two encodings into UTF-8.
740
741 When this option is disabled and by default, Squid sends
742 credentials in their original (i.e. received) encoding.
743
744 This parameter is only honored for Basic and Digest schemes.
745 For Basic, the entire username:password credentials are
746 checked and, if necessary, re-encoded. For Digest -- just the
747 username component. For NTLM and Negotiate schemes, this
748 parameter is ignored.
749
750 IF HAVE_AUTH_MODULE_BASIC
751 === Basic authentication parameters ===
752
753 "credentialsttl" timetolive
754 Specifies how long squid assumes an externally validated
755 username:password pair is valid for - in other words how
756 often the helper program is called for that user. Set this
757 low to force revalidation with short lived passwords.
758
759 NOTE: setting this high does not impact your susceptibility
760 to replay attacks unless you are using an one-time password
761 system (such as SecureID). If you are using such a system,
762 you will be vulnerable to replay attacks unless you also
763 use the max_user_ip ACL in an http_access rule.
764
765 "casesensitive" on|off
766 Specifies if usernames are case sensitive. Most user databases
767 are case insensitive allowing the same username to be spelled
768 using both lower and upper case letters, but some are case
769 sensitive. This makes a big difference for user_max_ip ACL
770 processing and similar.
771
772 ENDIF
773 IF HAVE_AUTH_MODULE_DIGEST
774 === Digest authentication parameters ===
775
776 "nonce_garbage_interval" timeinterval
777 Specifies the interval that nonces that have been issued
778 to client_agent's are checked for validity.
779
780 "nonce_max_duration" timeinterval
781 Specifies the maximum length of time a given nonce will be
782 valid for.
783
784 "nonce_max_count" number
785 Specifies the maximum number of times a given nonce can be
786 used.
787
788 "nonce_strictness" on|off
789 Determines if squid requires strict increment-by-1 behavior
790 for nonce counts, or just incrementing (off - for use when
791 user agents generate nonce counts that occasionally miss 1
792 (ie, 1,2,4,6)). Default off.
793
794 "check_nonce_count" on|off
795 This directive if set to off can disable the nonce count check
796 completely to work around buggy digest qop implementations in
797 certain mainstream browser versions. Default on to check the
798 nonce count to protect from authentication replay attacks.
799
800 "post_workaround" on|off
801 This is a workaround to certain buggy browsers who send an
802 incorrect request digest in POST requests when reusing the
803 same nonce as acquired earlier on a GET request.
804
805 ENDIF
806
807 === Example Configuration ===
808
809 This configuration displays the recommended authentication scheme
810 order from most to least secure with recommended minimum configuration
811 settings for each scheme:
812
813 #auth_param negotiate program <uncomment and complete this line to activate>
814 #auth_param negotiate children 20 startup=0 idle=1
815 #
816 #auth_param digest program <uncomment and complete this line to activate>
817 #auth_param digest children 20 startup=0 idle=1
818 #auth_param digest realm Squid proxy-caching web server
819 #auth_param digest nonce_garbage_interval 5 minutes
820 #auth_param digest nonce_max_duration 30 minutes
821 #auth_param digest nonce_max_count 50
822 #
823 #auth_param ntlm program <uncomment and complete this line to activate>
824 #auth_param ntlm children 20 startup=0 idle=1
825 #
826 #auth_param basic program <uncomment and complete this line>
827 #auth_param basic children 5 startup=5 idle=1
828 #auth_param basic credentialsttl 2 hours
829 DOC_END
830
831 NAME: authenticate_cache_garbage_interval
832 IFDEF: USE_AUTH
833 TYPE: time_t
834 DEFAULT: 1 hour
835 LOC: Auth::TheConfig.garbageCollectInterval
836 DOC_START
837 The time period between garbage collection across the username cache.
838 This is a trade-off between memory utilization (long intervals - say
839 2 days) and CPU (short intervals - say 1 minute). Only change if you
840 have good reason to.
841 DOC_END
842
843 NAME: authenticate_ttl
844 IFDEF: USE_AUTH
845 TYPE: time_t
846 DEFAULT: 1 hour
847 LOC: Auth::TheConfig.credentialsTtl
848 DOC_START
849 The time a user & their credentials stay in the logged in
850 user cache since their last request. When the garbage
851 interval passes, all user credentials that have passed their
852 TTL are removed from memory.
853 DOC_END
854
855 NAME: authenticate_ip_ttl
856 IFDEF: USE_AUTH
857 TYPE: time_t
858 LOC: Auth::TheConfig.ipTtl
859 DEFAULT: 1 second
860 DOC_START
861 If you use proxy authentication and the 'max_user_ip' ACL,
862 this directive controls how long Squid remembers the IP
863 addresses associated with each user. Use a small value
864 (e.g., 60 seconds) if your users might change addresses
865 quickly, as is the case with dialup. You might be safe
866 using a larger value (e.g., 2 hours) in a corporate LAN
867 environment with relatively static address assignments.
868 DOC_END
869
870 COMMENT_START
871 ACCESS CONTROLS
872 -----------------------------------------------------------------------------
873 COMMENT_END
874
875 NAME: external_acl_type
876 TYPE: externalAclHelper
877 LOC: Config.externalAclHelperList
878 DEFAULT: none
879 DOC_START
880 This option defines external acl classes using a helper program
881 to look up the status
882
883 external_acl_type name [options] FORMAT /path/to/helper [helper arguments]
884
885 Options:
886
887 ttl=n TTL in seconds for cached results (defaults to 3600
888 for 1 hour)
889
890 negative_ttl=n
891 TTL for cached negative lookups (default same
892 as ttl)
893
894 grace=n Percentage remaining of TTL where a refresh of a
895 cached entry should be initiated without needing to
896 wait for a new reply. (default is for no grace period)
897
898 cache=n The maximum number of entries in the result cache. The
899 default limit is 262144 entries. Each cache entry usually
900 consumes at least 256 bytes. Squid currently does not remove
901 expired cache entries until the limit is reached, so a proxy
902 will sooner or later reach the limit. The expanded FORMAT
903 value is used as the cache key, so if the details in FORMAT
904 are highly variable, a larger cache may be needed to produce
905 reduction in helper load.
906
907 children-max=n
908 Maximum number of acl helper processes spawned to service
909 external acl lookups of this type. (default 5)
910
911 children-startup=n
912 Minimum number of acl helper processes to spawn during
913 startup and reconfigure to service external acl lookups
914 of this type. (default 0)
915
916 children-idle=n
917 Number of acl helper processes to keep ahead of traffic
918 loads. Squid will spawn this many at once whenever load
919 rises above the capabilities of existing processes.
920 Up to the value of children-max. (default 1)
921
922 concurrency=n concurrency level per process. Only used with helpers
923 capable of processing more than one query at a time.
924
925 queue-size=N The queue-size option sets the maximum number of
926 queued requests. A request is queued when no existing
927 helper can accept it due to concurrency limit and no
928 new helper can be started due to children-max limit.
929 If the queued requests exceed queue size, the acl is
930 ignored. The default value is set to 2*children-max.
931
932 protocol=2.5 Compatibility mode for Squid-2.5 external acl helpers.
933
934 ipv4 / ipv6 IP protocol used to communicate with this helper.
935 The default is to auto-detect IPv6 and use it when available.
936
937
938 FORMAT is a series of %macro codes. See logformat directive for a full list
939 of the accepted codes. Although note that at the time of any external ACL
940 being tested data may not be available and thus some %macro expand to '-'.
941
942 In addition to the logformat codes; when processing external ACLs these
943 additional macros are made available:
944
945 %ACL The name of the ACL being tested.
946
947 %DATA The ACL arguments specified in the referencing config
948 'acl ... external' line, separated by spaces (an
949 "argument string"). see acl external.
950
951 If there are no ACL arguments %DATA expands to '-'.
952
953 If you do not specify a DATA macro inside FORMAT,
954 Squid automatically appends %DATA to your FORMAT.
955 Note that Squid-3.x may expand %DATA to whitespace
956 or nothing in this case.
957
958 By default, Squid applies URL-encoding to each ACL
959 argument inside the argument string. If an explicit
960 encoding modifier is used (e.g., %#DATA), then Squid
961 encodes the whole argument string as a single token
962 (e.g., with %#DATA, spaces between arguments become
963 %20).
964
965 If SSL is enabled, the following formatting codes become available:
966
967 %USER_CERT SSL User certificate in PEM format
968 %USER_CERTCHAIN SSL User certificate chain in PEM format
969 %USER_CERT_xx SSL User certificate subject attribute xx
970 %USER_CA_CERT_xx SSL User certificate issuer attribute xx
971
972
973 NOTE: all other format codes accepted by older Squid versions
974 are deprecated.
975
976
977 General request syntax:
978
979 [channel-ID] FORMAT-values
980
981
982 FORMAT-values consists of transaction details expanded with
983 whitespace separation per the config file FORMAT specification
984 using the FORMAT macros listed above.
985
986 Request values sent to the helper are URL escaped to protect
987 each value in requests against whitespaces.
988
989 If using protocol=2.5 then the request sent to the helper is not
990 URL escaped to protect against whitespace.
991
992 NOTE: protocol=3.0 is deprecated as no longer necessary.
993
994 When using the concurrency= option the protocol is changed by
995 introducing a query channel tag in front of the request/response.
996 The query channel tag is a number between 0 and concurrency-1.
997 This value must be echoed back unchanged to Squid as the first part
998 of the response relating to its request.
999
1000
1001 The helper receives lines expanded per the above format specification
1002 and for each input line returns 1 line starting with OK/ERR/BH result
1003 code and optionally followed by additional keywords with more details.
1004
1005
1006 General result syntax:
1007
1008 [channel-ID] result keyword=value ...
1009
1010 Result consists of one of the codes:
1011
1012 OK
1013 the ACL test produced a match.
1014
1015 ERR
1016 the ACL test does not produce a match.
1017
1018 BH
1019 An internal error occurred in the helper, preventing
1020 a result being identified.
1021
1022 The meaning of 'a match' is determined by your squid.conf
1023 access control configuration. See the Squid wiki for details.
1024
1025 Defined keywords:
1026
1027 user= The users name (login)
1028
1029 password= The users password (for login= cache_peer option)
1030
1031 message= Message describing the reason for this response.
1032 Available as %o in error pages.
1033 Useful on (ERR and BH results).
1034
1035 tag= Apply a tag to a request. Only sets a tag once,
1036 does not alter existing tags.
1037
1038 log= String to be logged in access.log. Available as
1039 %ea in logformat specifications.
1040
1041 clt_conn_tag= Associates a TAG with the client TCP connection.
1042 Please see url_rewrite_program related documentation
1043 for this kv-pair.
1044
1045 Any keywords may be sent on any response whether OK, ERR or BH.
1046
1047 All response keyword values need to be a single token with URL
1048 escaping, or enclosed in double quotes (") and escaped using \ on
1049 any double quotes or \ characters within the value. The wrapping
1050 double quotes are removed before the value is interpreted by Squid.
1051 \r and \n are also replace by CR and LF.
1052
1053 Some example key values:
1054
1055 user=John%20Smith
1056 user="John Smith"
1057 user="J. \"Bob\" Smith"
1058 DOC_END
1059
1060 NAME: acl
1061 TYPE: acl
1062 LOC: Config.aclList
1063 IF USE_OPENSSL
1064 DEFAULT: ssl::certHasExpired ssl_error X509_V_ERR_CERT_HAS_EXPIRED
1065 DEFAULT: ssl::certNotYetValid ssl_error X509_V_ERR_CERT_NOT_YET_VALID
1066 DEFAULT: ssl::certDomainMismatch ssl_error SQUID_X509_V_ERR_DOMAIN_MISMATCH
1067 DEFAULT: ssl::certUntrusted ssl_error X509_V_ERR_INVALID_CA X509_V_ERR_SELF_SIGNED_CERT_IN_CHAIN X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY X509_V_ERR_CERT_UNTRUSTED
1068 DEFAULT: ssl::certSelfSigned ssl_error X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT
1069 ENDIF
1070 DEFAULT: all src all
1071 DEFAULT: manager url_regex -i ^cache_object:// +i ^[^:]+://[^/]+/squid-internal-mgr/
1072 DEFAULT: localhost src 127.0.0.1/32 ::1
1073 DEFAULT: to_localhost dst 127.0.0.0/8 0.0.0.0/32 ::1/128 ::/128
1074 DEFAULT: to_linklocal dst 169.254.0.0/16 fe80::/10
1075 DEFAULT: CONNECT method CONNECT
1076 DEFAULT_DOC: ACLs all, manager, localhost, to_localhost, to_linklocal, and CONNECT are predefined.
1077 DOC_START
1078 Defining an Access List
1079
1080 Every access list definition must begin with an aclname and acltype,
1081 followed by either type-specific arguments or a quoted filename that
1082 they are read from.
1083
1084 acl aclname acltype argument ...
1085 acl aclname acltype "file" ...
1086
1087 When using "file", the file should contain one item per line.
1088
1089
1090 ACL Options
1091
1092 Some acl types supports options which changes their default behaviour:
1093
1094 -i,+i By default, regular expressions are CASE-SENSITIVE. To make them
1095 case-insensitive, use the -i option. To return case-sensitive
1096 use the +i option between patterns, or make a new ACL line
1097 without -i.
1098
1099 -n Disable lookups and address type conversions. If lookup or
1100 conversion is required because the parameter type (IP or
1101 domain name) does not match the message address type (domain
1102 name or IP), then the ACL would immediately declare a mismatch
1103 without any warnings or lookups.
1104
1105 -m[=delimiters]
1106 Perform a list membership test, interpreting values as
1107 comma-separated token lists and matching against individual
1108 tokens instead of whole values.
1109 The optional "delimiters" parameter specifies one or more
1110 alternative non-alphanumeric delimiter characters.
1111 non-alphanumeric delimiter characters.
1112
1113 -- Used to stop processing all options, in the case the first acl
1114 value has '-' character as first character (for example the '-'
1115 is a valid domain name)
1116
1117 Some acl types require suspending the current request in order
1118 to access some external data source.
1119 Those which do are marked with the tag [slow], those which
1120 don't are marked as [fast].
1121 See http://wiki.squid-cache.org/SquidFaq/SquidAcl
1122 for further information
1123
1124 ***** ACL TYPES AVAILABLE *****
1125
1126 acl aclname src ip-address/mask ... # clients IP address [fast]
1127 acl aclname src addr1-addr2/mask ... # range of addresses [fast]
1128 acl aclname dst [-n] ip-address/mask ... # URL host's IP address [slow]
1129 acl aclname localip ip-address/mask ... # IP address the client connected to [fast]
1130
1131 if USE_SQUID_EUI
1132 acl aclname arp mac-address ...
1133 acl aclname eui64 eui64-address ...
1134 # [fast]
1135 # MAC (EUI-48) and EUI-64 addresses use xx:xx:xx:xx:xx:xx notation.
1136 #
1137 # The 'arp' ACL code is not portable to all operating systems.
1138 # It works on Linux, Solaris, Windows, FreeBSD, and some other
1139 # BSD variants.
1140 #
1141 # The eui_lookup directive is required to be 'on' (the default)
1142 # and Squid built with --enable-eui for MAC/EUI addresses to be
1143 # available for this ACL.
1144 #
1145 # Squid can only determine the MAC/EUI address for IPv4
1146 # clients that are on the same subnet. If the client is on a
1147 # different subnet, then Squid cannot find out its address.
1148 #
1149 # IPv6 protocol does not contain ARP. MAC/EUI is either
1150 # encoded directly in the IPv6 address or not available.
1151 endif
1152 acl aclname clientside_mark mark[/mask] ...
1153 # matches CONNMARK of an accepted connection [fast]
1154 # DEPRECATED. Use the 'client_connection_mark' instead.
1155
1156 acl aclname client_connection_mark mark[/mask] ...
1157 # matches CONNMARK of an accepted connection [fast]
1158 #
1159 # mark and mask are unsigned integers (hex, octal, or decimal).
1160 # If multiple marks are given, then the ACL matches if at least
1161 # one mark matches.
1162 #
1163 # Uses netfilter-conntrack library.
1164 # Requires building Squid with --enable-linux-netfilter.
1165 #
1166 # The client, various intermediaries, and Squid itself may set
1167 # CONNMARK at various times. The last CONNMARK set wins. This ACL
1168 # checks the mark present on an accepted connection or set by
1169 # Squid afterwards, depending on the ACL check timing. This ACL
1170 # effectively ignores any mark set by other agents after Squid has
1171 # accepted the connection.
1172
1173 acl aclname srcdomain .foo.com ...
1174 # reverse lookup, from client IP [slow]
1175 acl aclname dstdomain [-n] .foo.com ...
1176 # Destination server from URL [fast]
1177 acl aclname srcdom_regex [-i] \.foo\.com ...
1178 # regex matching client name [slow]
1179 acl aclname dstdom_regex [-n] [-i] \.foo\.com ...
1180 # regex matching server [fast]
1181 #
1182 # For dstdomain and dstdom_regex a reverse lookup is tried if a IP
1183 # based URL is used and no match is found. The name "none" is used
1184 # if the reverse lookup fails.
1185
1186 acl aclname src_as number ...
1187 acl aclname dst_as number ...
1188 # [fast]
1189 # Except for access control, AS numbers can be used for
1190 # routing of requests to specific caches. Here's an
1191 # example for routing all requests for AS#1241 and only
1192 # those to mycache.mydomain.net:
1193 # acl asexample dst_as 1241
1194 # cache_peer_access mycache.mydomain.net allow asexample
1195 # cache_peer_access mycache_mydomain.net deny all
1196
1197 acl aclname peername myPeer ...
1198 acl aclname peername_regex [-i] regex-pattern ...
1199 # [fast]
1200 # match against a named cache_peer entry
1201 # set unique name= on cache_peer lines for reliable use.
1202
1203 acl aclname time [day-abbrevs] [h1:m1-h2:m2]
1204 # [fast]
1205 # day-abbrevs:
1206 # S - Sunday
1207 # M - Monday
1208 # T - Tuesday
1209 # W - Wednesday
1210 # H - Thursday
1211 # F - Friday
1212 # A - Saturday
1213 # h1:m1 must be less than h2:m2
1214
1215 acl aclname url_regex [-i] ^http:// ...
1216 # regex matching on whole URL [fast]
1217 acl aclname urllogin [-i] [^a-zA-Z0-9] ...
1218 # regex matching on URL login field
1219 acl aclname urlpath_regex [-i] \.gif$ ...
1220 # regex matching on URL path [fast]
1221
1222 acl aclname port 80 70 21 0-1024... # destination TCP port [fast]
1223 # ranges are allowed
1224 acl aclname localport 3128 ... # TCP port the client connected to [fast]
1225 # NP: for interception mode this is usually '80'
1226
1227 acl aclname myportname 3128 ... # *_port name [fast]
1228
1229 acl aclname proto HTTP FTP ... # request protocol [fast]
1230
1231 acl aclname method GET POST ... # HTTP request method [fast]
1232
1233 acl aclname http_status 200 301 500- 400-403 ...
1234 # status code in reply [fast]
1235
1236 acl aclname browser [-i] regexp ...
1237 # pattern match on User-Agent header (see also req_header below) [fast]
1238
1239 acl aclname referer_regex [-i] regexp ...
1240 # pattern match on Referer header [fast]
1241 # Referer is highly unreliable, so use with care
1242
1243 acl aclname ident [-i] username ...
1244 acl aclname ident_regex [-i] pattern ...
1245 # string match on ident output [slow]
1246 # use REQUIRED to accept any non-null ident.
1247
1248 acl aclname proxy_auth [-i] username ...
1249 acl aclname proxy_auth_regex [-i] pattern ...
1250 # perform http authentication challenge to the client and match against
1251 # supplied credentials [slow]
1252 #
1253 # takes a list of allowed usernames.
1254 # use REQUIRED to accept any valid username.
1255 #
1256 # Will use proxy authentication in forward-proxy scenarios, and plain
1257 # http authentication in reverse-proxy scenarios
1258 #
1259 # NOTE: when a Proxy-Authentication header is sent but it is not
1260 # needed during ACL checking the username is NOT logged
1261 # in access.log.
1262 #
1263 # NOTE: proxy_auth requires a EXTERNAL authentication program
1264 # to check username/password combinations (see
1265 # auth_param directive).
1266 #
1267 # NOTE: proxy_auth can't be used in a transparent/intercepting proxy
1268 # as the browser needs to be configured for using a proxy in order
1269 # to respond to proxy authentication.
1270
1271 acl aclname snmp_community string ...
1272 # A community string to limit access to your SNMP Agent [fast]
1273 # Example:
1274 #
1275 # acl snmppublic snmp_community public
1276
1277 acl aclname maxconn number
1278 # This will be matched when the client's IP address has
1279 # more than <number> TCP connections established. [fast]
1280 # NOTE: This only measures direct TCP links so X-Forwarded-For
1281 # indirect clients are not counted.
1282
1283 acl aclname max_user_ip [-s] number
1284 # This will be matched when the user attempts to log in from more
1285 # than <number> different ip addresses. The authenticate_ip_ttl
1286 # parameter controls the timeout on the ip entries. [fast]
1287 # If -s is specified the limit is strict, denying browsing
1288 # from any further IP addresses until the ttl has expired. Without
1289 # -s Squid will just annoy the user by "randomly" denying requests.
1290 # (the counter is reset each time the limit is reached and a
1291 # request is denied)
1292 # NOTE: in acceleration mode or where there is mesh of child proxies,
1293 # clients may appear to come from multiple addresses if they are
1294 # going through proxy farms, so a limit of 1 may cause user problems.
1295
1296 acl aclname random probability
1297 # Pseudo-randomly match requests. Based on the probability given.
1298 # Probability may be written as a decimal (0.333), fraction (1/3)
1299 # or ratio of matches:non-matches (3:5).
1300
1301 acl aclname req_mime_type [-i] mime-type ...
1302 # regex match against the mime type of the request generated
1303 # by the client. Can be used to detect file upload or some
1304 # types HTTP tunneling requests [fast]
1305 # NOTE: This does NOT match the reply. You cannot use this
1306 # to match the returned file type.
1307
1308 acl aclname req_header header-name [-i] any\.regex\.here
1309 # regex match against any of the known request headers. May be
1310 # thought of as a superset of "browser", "referer" and "mime-type"
1311 # ACL [fast]
1312
1313 acl aclname rep_mime_type [-i] mime-type ...
1314 # regex match against the mime type of the reply received by
1315 # squid. Can be used to detect file download or some
1316 # types HTTP tunneling requests. [fast]
1317 # NOTE: This has no effect in http_access rules. It only has
1318 # effect in rules that affect the reply data stream such as
1319 # http_reply_access.
1320
1321 acl aclname rep_header header-name [-i] any\.regex\.here
1322 # regex match against any of the known reply headers. May be
1323 # thought of as a superset of "browser", "referer" and "mime-type"
1324 # ACLs [fast]
1325
1326 acl aclname external class_name [arguments...]
1327 # external ACL lookup via a helper class defined by the
1328 # external_acl_type directive [slow]
1329
1330 acl aclname user_cert attribute values...
1331 # match against attributes in a user SSL certificate
1332 # attribute is one of DN/C/O/CN/L/ST or a numerical OID [fast]
1333
1334 acl aclname ca_cert attribute values...
1335 # match against attributes a users issuing CA SSL certificate
1336 # attribute is one of DN/C/O/CN/L/ST or a numerical OID [fast]
1337
1338 acl aclname ext_user [-i] username ...
1339 acl aclname ext_user_regex [-i] pattern ...
1340 # string match on username returned by external acl helper [slow]
1341 # use REQUIRED to accept any non-null user name.
1342
1343 acl aclname tag tagvalue ...
1344 # string match on tag returned by external acl helper [fast]
1345 # DEPRECATED. Only the first tag will match with this ACL.
1346 # Use the 'note' ACL instead for handling multiple tag values.
1347
1348 acl aclname hier_code codename ...
1349 # string match against squid hierarchy code(s); [fast]
1350 # e.g., DIRECT, PARENT_HIT, NONE, etc.
1351 #
1352 # NOTE: This has no effect in http_access rules. It only has
1353 # effect in rules that affect the reply data stream such as
1354 # http_reply_access.
1355
1356 acl aclname note [-m[=delimiters]] name [value ...]
1357 # match transaction annotation [fast]
1358 # Without values, matches any annotation with a given name.
1359 # With value(s), matches any annotation with a given name that
1360 # also has one of the given values.
1361 # If the -m flag is used, then the value of the named
1362 # annotation is interpreted as a list of tokens, and the ACL
1363 # matches individual name=token pairs rather than whole
1364 # name=value pairs. See "ACL Options" above for more info.
1365 # Annotation sources include note and adaptation_meta directives
1366 # as well as helper and eCAP responses.
1367
1368 acl aclname annotate_transaction [-m[=delimiters]] key=value ...
1369 acl aclname annotate_transaction [-m[=delimiters]] key+=value ...
1370 # Always matches. [fast]
1371 # Used for its side effect: This ACL immediately adds a
1372 # key=value annotation to the current master transaction.
1373 # The added annotation can then be tested using note ACL and
1374 # logged (or sent to helpers) using %note format code.
1375 #
1376 # Annotations can be specified using replacement and addition
1377 # formats. The key=value form replaces old same-key annotation
1378 # value(s). The key+=value form appends a new value to the old
1379 # same-key annotation. Both forms create a new key=value
1380 # annotation if no same-key annotation exists already. If
1381 # -m flag is used, then the value is interpreted as a list
1382 # and the annotation will contain key=token pair(s) instead of the
1383 # whole key=value pair.
1384 #
1385 # This ACL is especially useful for recording complex multi-step
1386 # ACL-driven decisions. For example, the following configuration
1387 # avoids logging transactions accepted after aclX matched:
1388 #
1389 # # First, mark transactions accepted after aclX matched
1390 # acl markSpecial annotate_transaction special=true
1391 # http_access allow acl001
1392 # ...
1393 # http_access deny acl100
1394 # http_access allow aclX markSpecial
1395 #
1396 # # Second, do not log marked transactions:
1397 # acl markedSpecial note special true
1398 # access_log ... deny markedSpecial
1399 #
1400 # # Note that the following would not have worked because aclX
1401 # # alone does not determine whether the transaction was allowed:
1402 # access_log ... deny aclX # Wrong!
1403 #
1404 # Warning: This ACL annotates the transaction even when negated
1405 # and even if subsequent ACLs fail to match. For example, the
1406 # following three rules will have exactly the same effect as far
1407 # as annotations set by the "mark" ACL are concerned:
1408 #
1409 # some_directive acl1 ... mark # rule matches if mark is reached
1410 # some_directive acl1 ... !mark # rule never matches
1411 # some_directive acl1 ... mark !all # rule never matches
1412
1413 acl aclname annotate_client [-m[=delimiters]] key=value ...
1414 acl aclname annotate_client [-m[=delimiters]] key+=value ...
1415 #
1416 # Always matches. [fast]
1417 # Used for its side effect: This ACL immediately adds a
1418 # key=value annotation to the current client-to-Squid
1419 # connection. Connection annotations are propagated to the current
1420 # and all future master transactions on the annotated connection.
1421 # See the annotate_transaction ACL for details.
1422 #
1423 # For example, the following configuration avoids rewriting URLs
1424 # of transactions bumped by SslBump:
1425 #
1426 # # First, mark bumped connections:
1427 # acl markBumped annotate_client bumped=true
1428 # ssl_bump peek acl1
1429 # ssl_bump stare acl2
1430 # ssl_bump bump acl3 markBumped
1431 # ssl_bump splice all
1432 #
1433 # # Second, do not send marked transactions to the redirector:
1434 # acl markedBumped note bumped true
1435 # url_rewrite_access deny markedBumped
1436 #
1437 # # Note that the following would not have worked because acl3 alone
1438 # # does not determine whether the connection is going to be bumped:
1439 # url_rewrite_access deny acl3 # Wrong!
1440
1441 acl aclname adaptation_service service ...
1442 # Matches the name of any icap_service, ecap_service,
1443 # adaptation_service_set, or adaptation_service_chain that Squid
1444 # has used (or attempted to use) for the master transaction.
1445 # This ACL must be defined after the corresponding adaptation
1446 # service is named in squid.conf. This ACL is usable with
1447 # adaptation_meta because it starts matching immediately after
1448 # the service has been selected for adaptation.
1449
1450 acl aclname transaction_initiator initiator ...
1451 # Matches transaction's initiator [fast]
1452 #
1453 # Supported initiators are:
1454 # esi: matches transactions fetching ESI resources
1455 # certificate-fetching: matches transactions fetching
1456 # a missing intermediate TLS certificate
1457 # cache-digest: matches transactions fetching Cache Digests
1458 # from a cache_peer
1459 # htcp: matches HTCP requests from peers
1460 # icp: matches ICP requests to peers
1461 # icmp: matches ICMP RTT database (NetDB) requests to peers
1462 # asn: matches asns db requests
1463 # internal: matches any of the above
1464 # client: matches transactions containing an HTTP or FTP
1465 # client request received at a Squid *_port
1466 # all: matches any transaction, including internal transactions
1467 # without a configurable initiator and hopefully rare
1468 # transactions without a known-to-Squid initiator
1469 #
1470 # Multiple initiators are ORed.
1471
1472 acl aclname has component
1473 # matches a transaction "component" [fast]
1474 #
1475 # Supported transaction components are:
1476 # request: transaction has a request header (at least)
1477 # response: transaction has a response header (at least)
1478 # ALE: transaction has an internally-generated Access Log Entry
1479 # structure; bugs notwithstanding, all transaction have it
1480 #
1481 # For example, the following configuration helps when dealing with HTTP
1482 # clients that close connections without sending a request header:
1483 #
1484 # acl hasRequest has request
1485 # acl logMe note important_transaction
1486 # # avoid "logMe ACL is used in context without an HTTP request" warnings
1487 # access_log ... logformat=detailed hasRequest logMe
1488 # # log request-less transactions, instead of ignoring them
1489 # access_log ... logformat=brief !hasRequest
1490 #
1491 # Multiple components are not supported for one "acl" rule, but
1492 # can be specified (and are ORed) using multiple same-name rules:
1493 #
1494 # # OK, this strange logging daemon needs request or response,
1495 # # but can work without either a request or a response:
1496 # acl hasWhatMyLoggingDaemonNeeds has request
1497 # acl hasWhatMyLoggingDaemonNeeds has response
1498
1499 acl aclname at_step step
1500 # match against the current request processing step [fast]
1501 # Valid steps are:
1502 # GeneratingCONNECT: Generating HTTP CONNECT request headers
1503 IF USE_OPENSSL
1504 # The following ssl_bump processing steps are recognized:
1505 # SslBump1: After getting TCP-level and HTTP CONNECT info.
1506 # SslBump2: After getting SSL Client Hello info.
1507 # SslBump3: After getting SSL Server Hello info.
1508 ENDIF
1509
1510 IF USE_OPENSSL
1511 acl aclname ssl_error errorname
1512 # match against SSL certificate validation error [fast]
1513 #
1514 # When used with sslproxy_cert_error, this ACL tests a single
1515 # certificate validation error currently being evaluated by that
1516 # directive. When used with slproxy_cert_sign or sslproxy_cert_adapt,
1517 # the ACL tests all past certificate validation errors associated with
1518 # the current Squid-to-server connection (attempt). This ACL is not yet
1519 # supported for use with other directives.
1520 #
1521 # For valid error names see in @DEFAULT_ERROR_DIR@/templates/error-details.txt
1522 # template file.
1523 #
1524 # The following can be used as shortcuts for certificate properties:
1525 # [ssl::]certHasExpired: the "not after" field is in the past
1526 # [ssl::]certNotYetValid: the "not before" field is in the future
1527 # [ssl::]certUntrusted: The certificate issuer is not to be trusted.
1528 # [ssl::]certSelfSigned: The certificate is self signed.
1529 # [ssl::]certDomainMismatch: The certificate CN domain does not
1530 # match the name the name of the host we are connecting to.
1531 #
1532 # The ssl::certHasExpired, ssl::certNotYetValid, ssl::certDomainMismatch,
1533 # ssl::certUntrusted, and ssl::certSelfSigned can also be used as
1534 # predefined ACLs, just like the 'all' ACL.
1535
1536 acl aclname server_cert_fingerprint [-sha1] fingerprint
1537 # match against server SSL certificate fingerprint [fast]
1538 #
1539 # The fingerprint is the digest of the DER encoded version
1540 # of the whole certificate. The user should use the form: XX:XX:...
1541 # Optional argument specifies the digest algorithm to use.
1542 # The SHA1 digest algorithm is the default and is currently
1543 # the only algorithm supported (-sha1).
1544
1545 acl aclname ssl::server_name [option] .foo.com ...
1546 # matches server name obtained from various sources [fast]
1547 #
1548 # The ACL computes server name(s) using such information sources as
1549 # CONNECT request URI, TLS client SNI, and TLS server certificate
1550 # subject (CN and SubjectAltName). The computed server name(s) usually
1551 # change with each SslBump step, as more info becomes available:
1552 # * SNI is used as the server name instead of the request URI,
1553 # * subject name(s) from the server certificate (CN and
1554 # SubjectAltName) are used as the server names instead of SNI.
1555 #
1556 # When the ACL computes multiple server names, matching any single
1557 # computed name is sufficient for the ACL to match.
1558 #
1559 # The "none" name can be used to match transactions where the ACL
1560 # could not compute the server name using any information source
1561 # that was both available and allowed to be used by the ACL options at
1562 # the ACL evaluation time.
1563 #
1564 # Unlike dstdomain, this ACL does not perform DNS lookups.
1565 #
1566 # An ACL option below may be used to restrict what information
1567 # sources are used to extract the server names from:
1568 #
1569 # --client-requested
1570 # The server name is SNI regardless of what the server says.
1571 # --server-provided
1572 # The server name(s) are the certificate subject name(s), regardless
1573 # of what the client has requested. If the server certificate is
1574 # unavailable, then the name is "none".
1575 # --consensus
1576 # The server name is either SNI (if SNI matches at least one of the
1577 # certificate subject names) or "none" (otherwise). When the server
1578 # certificate is unavailable, the consensus server name is SNI.
1579 #
1580 # Combining multiple options in one ACL is a fatal configuration
1581 # error.
1582 #
1583 # For all options: If no SNI is available, then the CONNECT request
1584 # target (a.k.a. URI) is used instead of SNI (for an intercepted
1585 # connection, this target is the destination IP address).
1586
1587 acl aclname ssl::server_name_regex [-i] \.foo\.com ...
1588 # regex matches server name obtained from various sources [fast]
1589
1590 acl aclname connections_encrypted
1591 # matches transactions with all HTTP messages received over TLS
1592 # transport connections. [fast]
1593 #
1594 # The master transaction deals with HTTP messages received from
1595 # various sources. All sources used by the master transaction in the
1596 # past are considered by the ACL. The following rules define whether
1597 # a given message source taints the entire master transaction,
1598 # resulting in ACL mismatches:
1599 #
1600 # * The HTTP client transport connection is not TLS.
1601 # * An adaptation service connection-encryption flag is off.
1602 # * The peer or origin server transport connection is not TLS.
1603 #
1604 # Caching currently does not affect these rules. This cache ignorance
1605 # implies that only the current HTTP client transport and REQMOD
1606 # services status determine whether this ACL matches a from-cache
1607 # transaction. The source of the cached response does not have any
1608 # effect on future transaction that use the cached response without
1609 # revalidation. This may change.
1610 #
1611 # DNS, ICP, and HTCP exchanges during the master transaction do not
1612 # affect these rules.
1613 ENDIF
1614 acl aclname any-of acl1 acl2 ...
1615 # match any one of the acls [fast or slow]
1616 # The first matching ACL stops further ACL evaluation.
1617 #
1618 # ACLs from multiple any-of lines with the same name are ORed.
1619 # For example, A = (a1 or a2) or (a3 or a4) can be written as
1620 # acl A any-of a1 a2
1621 # acl A any-of a3 a4
1622 #
1623 # This group ACL is fast if all evaluated ACLs in the group are fast
1624 # and slow otherwise.
1625
1626 acl aclname all-of acl1 acl2 ...
1627 # match all of the acls [fast or slow]
1628 # The first mismatching ACL stops further ACL evaluation.
1629 #
1630 # ACLs from multiple all-of lines with the same name are ORed.
1631 # For example, B = (b1 and b2) or (b3 and b4) can be written as
1632 # acl B all-of b1 b2
1633 # acl B all-of b3 b4
1634 #
1635 # This group ACL is fast if all evaluated ACLs in the group are fast
1636 # and slow otherwise.
1637
1638 Examples:
1639 acl macaddress arp 09:00:2b:23:45:67
1640 acl myexample dst_as 1241
1641 acl password proxy_auth REQUIRED
1642 acl fileupload req_mime_type -i ^multipart/form-data$
1643 acl javascript rep_mime_type -i ^application/x-javascript$
1644
1645 CONFIG_START
1646 #
1647 # Recommended minimum configuration:
1648 #
1649
1650 # Example rule allowing access from your local networks.
1651 # Adapt to list your (internal) IP networks from where browsing
1652 # should be allowed
1653 acl localnet src 0.0.0.1-0.255.255.255 # RFC 1122 "this" network (LAN)
1654 acl localnet src 10.0.0.0/8 # RFC 1918 local private network (LAN)
1655 acl localnet src 100.64.0.0/10 # RFC 6598 shared address space (CGN)
1656 acl localnet src 169.254.0.0/16 # RFC 3927 link-local (directly plugged) machines
1657 acl localnet src 172.16.0.0/12 # RFC 1918 local private network (LAN)
1658 acl localnet src 192.168.0.0/16 # RFC 1918 local private network (LAN)
1659 acl localnet src fc00::/7 # RFC 4193 local private network range
1660 acl localnet src fe80::/10 # RFC 4291 link-local (directly plugged) machines
1661
1662 acl SSL_ports port 443
1663 acl Safe_ports port 80 # http
1664 acl Safe_ports port 21 # ftp
1665 acl Safe_ports port 443 # https
1666 acl Safe_ports port 70 # gopher
1667 acl Safe_ports port 210 # wais
1668 acl Safe_ports port 1025-65535 # unregistered ports
1669 acl Safe_ports port 280 # http-mgmt
1670 acl Safe_ports port 488 # gss-http
1671 acl Safe_ports port 591 # filemaker
1672 acl Safe_ports port 777 # multiling http
1673 CONFIG_END
1674 DOC_END
1675
1676 NAME: proxy_protocol_access
1677 TYPE: acl_access
1678 LOC: Config.accessList.proxyProtocol
1679 DEFAULT: none
1680 DEFAULT_DOC: all TCP connections to ports with require-proxy-header will be denied
1681 DOC_START
1682 Determine which client proxies can be trusted to provide correct
1683 information regarding real client IP address using PROXY protocol.
1684
1685 Requests may pass through a chain of several other proxies
1686 before reaching us. The original source details may by sent in:
1687 * HTTP message Forwarded header, or
1688 * HTTP message X-Forwarded-For header, or
1689 * PROXY protocol connection header.
1690
1691 This directive is solely for validating new PROXY protocol
1692 connections received from a port flagged with require-proxy-header.
1693 It is checked only once after TCP connection setup.
1694
1695 A deny match results in TCP connection closure.
1696
1697 An allow match is required for Squid to permit the corresponding
1698 TCP connection, before Squid even looks for HTTP request headers.
1699 If there is an allow match, Squid starts using PROXY header information
1700 to determine the source address of the connection for all future ACL
1701 checks, logging, etc.
1702
1703 SECURITY CONSIDERATIONS:
1704
1705 Any host from which we accept client IP details can place
1706 incorrect information in the relevant header, and Squid
1707 will use the incorrect information as if it were the
1708 source address of the request. This may enable remote
1709 hosts to bypass any access control restrictions that are
1710 based on the client's source addresses.
1711
1712 This clause only supports fast acl types.
1713 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
1714 DOC_END
1715
1716 NAME: follow_x_forwarded_for
1717 TYPE: acl_access
1718 IFDEF: FOLLOW_X_FORWARDED_FOR
1719 LOC: Config.accessList.followXFF
1720 DEFAULT_IF_NONE: deny all
1721 DEFAULT_DOC: X-Forwarded-For header will be ignored.
1722 DOC_START
1723 Determine which client proxies can be trusted to provide correct
1724 information regarding real client IP address.
1725
1726 Requests may pass through a chain of several other proxies
1727 before reaching us. The original source details may by sent in:
1728 * HTTP message Forwarded header, or
1729 * HTTP message X-Forwarded-For header, or
1730 * PROXY protocol connection header.
1731
1732 PROXY protocol connections are controlled by the proxy_protocol_access
1733 directive which is checked before this.
1734
1735 If a request reaches us from a source that is allowed by this
1736 directive, then we trust the information it provides regarding
1737 the IP of the client it received from (if any).
1738
1739 For the purpose of ACLs used in this directive the src ACL type always
1740 matches the address we are testing and srcdomain matches its rDNS.
1741
1742 On each HTTP request Squid checks for X-Forwarded-For header fields.
1743 If found the header values are iterated in reverse order and an allow
1744 match is required for Squid to continue on to the next value.
1745 The verification ends when a value receives a deny match, cannot be
1746 tested, or there are no more values to test.
1747 NOTE: Squid does not yet follow the Forwarded HTTP header.
1748
1749 The end result of this process is an IP address that we will
1750 refer to as the indirect client address. This address may
1751 be treated as the client address for access control, ICAP, delay
1752 pools and logging, depending on the acl_uses_indirect_client,
1753 icap_uses_indirect_client, delay_pool_uses_indirect_client,
1754 log_uses_indirect_client and tproxy_uses_indirect_client options.
1755
1756 This clause only supports fast acl types.
1757 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
1758
1759 SECURITY CONSIDERATIONS:
1760
1761 Any host from which we accept client IP details can place
1762 incorrect information in the relevant header, and Squid
1763 will use the incorrect information as if it were the
1764 source address of the request. This may enable remote
1765 hosts to bypass any access control restrictions that are
1766 based on the client's source addresses.
1767
1768 For example:
1769
1770 acl localhost src 127.0.0.1
1771 acl my_other_proxy srcdomain .proxy.example.com
1772 follow_x_forwarded_for allow localhost
1773 follow_x_forwarded_for allow my_other_proxy
1774 DOC_END
1775
1776 NAME: acl_uses_indirect_client
1777 COMMENT: on|off
1778 TYPE: onoff
1779 IFDEF: FOLLOW_X_FORWARDED_FOR
1780 DEFAULT: on
1781 LOC: Config.onoff.acl_uses_indirect_client
1782 DOC_START
1783 Controls whether the indirect client address
1784 (see follow_x_forwarded_for) is used instead of the
1785 direct client address in acl matching.
1786
1787 NOTE: maxconn ACL considers direct TCP links and indirect
1788 clients will always have zero. So no match.
1789 DOC_END
1790
1791 NAME: delay_pool_uses_indirect_client
1792 COMMENT: on|off
1793 TYPE: onoff
1794 IFDEF: FOLLOW_X_FORWARDED_FOR&&USE_DELAY_POOLS
1795 DEFAULT: on
1796 LOC: Config.onoff.delay_pool_uses_indirect_client
1797 DOC_START
1798 Controls whether the indirect client address
1799 (see follow_x_forwarded_for) is used instead of the
1800 direct client address in delay pools.
1801 DOC_END
1802
1803 NAME: log_uses_indirect_client
1804 COMMENT: on|off
1805 TYPE: onoff
1806 IFDEF: FOLLOW_X_FORWARDED_FOR
1807 DEFAULT: on
1808 LOC: Config.onoff.log_uses_indirect_client
1809 DOC_START
1810 Controls whether the indirect client address
1811 (see follow_x_forwarded_for) is used instead of the
1812 direct client address in the access log.
1813 DOC_END
1814
1815 NAME: tproxy_uses_indirect_client
1816 COMMENT: on|off
1817 TYPE: onoff
1818 IFDEF: FOLLOW_X_FORWARDED_FOR&&LINUX_NETFILTER
1819 DEFAULT: off
1820 LOC: Config.onoff.tproxy_uses_indirect_client
1821 DOC_START
1822 Controls whether the indirect client address
1823 (see follow_x_forwarded_for) is used instead of the
1824 direct client address when spoofing the outgoing client.
1825
1826 This has no effect on requests arriving in non-tproxy
1827 mode ports.
1828
1829 SECURITY WARNING: Usage of this option is dangerous
1830 and should not be used trivially. Correct configuration
1831 of follow_x_forwarded_for with a limited set of trusted
1832 sources is required to prevent abuse of your proxy.
1833 DOC_END
1834
1835 NAME: spoof_client_ip
1836 TYPE: acl_access
1837 LOC: Config.accessList.spoof_client_ip
1838 DEFAULT: none
1839 DEFAULT_DOC: Allow spoofing on all TPROXY traffic.
1840 DOC_START
1841 Control client IP address spoofing of TPROXY traffic based on
1842 defined access lists.
1843
1844 spoof_client_ip allow|deny [!]aclname ...
1845
1846 If there are no "spoof_client_ip" lines present, the default
1847 is to "allow" spoofing of any suitable request.
1848
1849 Note that the cache_peer "no-tproxy" option overrides this ACL.
1850
1851 This clause supports fast acl types.
1852 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
1853 DOC_END
1854
1855 NAME: http_access
1856 TYPE: acl_access
1857 LOC: Config.accessList.http
1858 DEFAULT_IF_NONE: deny all
1859 DEFAULT_DOC: Deny, unless rules exist in squid.conf.
1860 DOC_START
1861 Allowing or Denying access based on defined access lists
1862
1863 To allow or deny a message received on an HTTP, HTTPS, or FTP port:
1864 http_access allow|deny [!]aclname ...
1865
1866 NOTE on default values:
1867
1868 If there are no "access" lines present, the default is to deny
1869 the request.
1870
1871 If none of the "access" lines cause a match, the default is the
1872 opposite of the last line in the list. If the last line was
1873 deny, the default is allow. Conversely, if the last line
1874 is allow, the default will be deny. For these reasons, it is a
1875 good idea to have an "deny all" entry at the end of your access
1876 lists to avoid potential confusion.
1877
1878 This clause supports both fast and slow acl types.
1879 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
1880
1881 CONFIG_START
1882
1883 #
1884 # Recommended minimum Access Permission configuration:
1885 #
1886 # Deny requests to certain unsafe ports
1887 http_access deny !Safe_ports
1888
1889 # Deny CONNECT to other than secure SSL ports
1890 http_access deny CONNECT !SSL_ports
1891
1892 # Only allow cachemgr access from localhost
1893 http_access allow localhost manager
1894 http_access deny manager
1895
1896 # This default configuration only allows localhost requests because a more
1897 # permissive Squid installation could introduce new attack vectors into the
1898 # network by proxying external TCP connections to unprotected services.
1899 http_access allow localhost
1900
1901 # The two deny rules below are unnecessary in this default configuration
1902 # because they are followed by a "deny all" rule. However, they may become
1903 # critically important when you start allowing external requests below them.
1904
1905 # Protect web applications running on the same server as Squid. They often
1906 # assume that only local users can access them at "localhost" ports.
1907 http_access deny to_localhost
1908
1909 # Protect cloud servers that provide local users with sensitive info about
1910 # their server via certain well-known link-local (a.k.a. APIPA) addresses.
1911 http_access deny to_linklocal
1912
1913 #
1914 # INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
1915 #
1916
1917 # For example, to allow access from your local networks, you may uncomment the
1918 # following rule (and/or add rules that match your definition of "local"):
1919 # http_access allow localnet
1920
1921 # And finally deny all other access to this proxy
1922 http_access deny all
1923 CONFIG_END
1924 DOC_END
1925
1926 NAME: adapted_http_access http_access2
1927 TYPE: acl_access
1928 LOC: Config.accessList.adapted_http
1929 DEFAULT: none
1930 DEFAULT_DOC: Allow, unless rules exist in squid.conf.
1931 DOC_START
1932 Allowing or Denying access based on defined access lists
1933
1934 Essentially identical to http_access, but runs after redirectors
1935 and ICAP/eCAP adaptation. Allowing access control based on their
1936 output.
1937
1938 If not set then only http_access is used.
1939 DOC_END
1940
1941 NAME: http_reply_access
1942 TYPE: acl_access
1943 LOC: Config.accessList.reply
1944 DEFAULT: none
1945 DEFAULT_DOC: Allow, unless rules exist in squid.conf.
1946 DOC_START
1947 Allow replies to client requests. This is complementary to http_access.
1948
1949 http_reply_access allow|deny [!] aclname ...
1950
1951 NOTE: if there are no access lines present, the default is to allow
1952 all replies.
1953
1954 If none of the access lines cause a match the opposite of the
1955 last line will apply. Thus it is good practice to end the rules
1956 with an "allow all" or "deny all" entry.
1957
1958 This clause supports both fast and slow acl types.
1959 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
1960 DOC_END
1961
1962 NAME: icp_access
1963 TYPE: acl_access
1964 LOC: Config.accessList.icp
1965 DEFAULT: none
1966 DEFAULT_DOC: Deny, unless rules exist in squid.conf.
1967 DOC_START
1968 Allowing or Denying access to the ICP port based on defined
1969 access lists
1970
1971 icp_access allow|deny [!]aclname ...
1972
1973 NOTE: The default if no icp_access lines are present is to
1974 deny all traffic. This default may cause problems with peers
1975 using ICP.
1976
1977 This clause only supports fast acl types.
1978 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
1979
1980 # Allow ICP queries from local networks only
1981 #icp_access allow localnet
1982 #icp_access deny all
1983 DOC_END
1984
1985 NAME: htcp_access
1986 IFDEF: USE_HTCP
1987 TYPE: acl_access
1988 LOC: Config.accessList.htcp
1989 DEFAULT: none
1990 DEFAULT_DOC: Deny, unless rules exist in squid.conf.
1991 DOC_START
1992 Allowing or Denying access to the HTCP port based on defined
1993 access lists
1994
1995 htcp_access allow|deny [!]aclname ...
1996
1997 See also htcp_clr_access for details on access control for
1998 cache purge (CLR) HTCP messages.
1999
2000 NOTE: The default if no htcp_access lines are present is to
2001 deny all traffic. This default may cause problems with peers
2002 using the htcp option.
2003
2004 This clause only supports fast acl types.
2005 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2006
2007 # Allow HTCP queries from local networks only
2008 #htcp_access allow localnet
2009 #htcp_access deny all
2010 DOC_END
2011
2012 NAME: htcp_clr_access
2013 IFDEF: USE_HTCP
2014 TYPE: acl_access
2015 LOC: Config.accessList.htcp_clr
2016 DEFAULT: none
2017 DEFAULT_DOC: Deny, unless rules exist in squid.conf.
2018 DOC_START
2019 Allowing or Denying access to purge content using HTCP based
2020 on defined access lists.
2021 See htcp_access for details on general HTCP access control.
2022
2023 htcp_clr_access allow|deny [!]aclname ...
2024
2025 This clause only supports fast acl types.
2026 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2027
2028 # Allow HTCP CLR requests from trusted peers
2029 acl htcp_clr_peer src 192.0.2.2 2001:DB8::2
2030 htcp_clr_access allow htcp_clr_peer
2031 htcp_clr_access deny all
2032 DOC_END
2033
2034 NAME: miss_access
2035 TYPE: acl_access
2036 LOC: Config.accessList.miss
2037 DEFAULT: none
2038 DEFAULT_DOC: Allow, unless rules exist in squid.conf.
2039 DOC_START
2040 Determines whether network access is permitted when satisfying a request.
2041
2042 For example;
2043 to force your neighbors to use you as a sibling instead of
2044 a parent.
2045
2046 acl localclients src 192.0.2.0/24 2001:DB8::a:0/64
2047 miss_access deny !localclients
2048 miss_access allow all
2049
2050 This means only your local clients are allowed to fetch relayed/MISS
2051 replies from the network and all other clients can only fetch cached
2052 objects (HITs).
2053
2054 The default for this setting allows all clients who passed the
2055 http_access rules to relay via this proxy.
2056
2057 This clause only supports fast acl types.
2058 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2059 DOC_END
2060
2061 NAME: ident_lookup_access
2062 TYPE: acl_access
2063 IFDEF: USE_IDENT
2064 DEFAULT: none
2065 DEFAULT_DOC: Unless rules exist in squid.conf, IDENT is not fetched.
2066 LOC: Ident::TheConfig.identLookup
2067 DOC_START
2068 A list of ACL elements which, if matched, cause an ident
2069 (RFC 931) lookup to be performed for this request. For
2070 example, you might choose to always perform ident lookups
2071 for your main multi-user Unix boxes, but not for your Macs
2072 and PCs. By default, ident lookups are not performed for
2073 any requests.
2074
2075 To enable ident lookups for specific client addresses, you
2076 can follow this example:
2077
2078 acl ident_aware_hosts src 198.168.1.0/24
2079 ident_lookup_access allow ident_aware_hosts
2080 ident_lookup_access deny all
2081
2082 Only src type ACL checks are fully supported. A srcdomain
2083 ACL might work at times, but it will not always provide
2084 the correct result.
2085
2086 This clause only supports fast acl types.
2087 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2088 DOC_END
2089
2090 NAME: reply_body_max_size
2091 COMMENT: size [acl acl...]
2092 TYPE: acl_b_size_t
2093 DEFAULT: none
2094 DEFAULT_DOC: No limit is applied.
2095 LOC: Config.ReplyBodySize
2096 DOC_START
2097 This option specifies the maximum size of a reply body. It can be
2098 used to prevent users from downloading very large files, such as
2099 MP3's and movies. When the reply headers are received, the
2100 reply_body_max_size lines are processed, and the first line where
2101 all (if any) listed ACLs are true is used as the maximum body size
2102 for this reply.
2103
2104 This size is checked twice. First when we get the reply headers,
2105 we check the content-length value. If the content length value exists
2106 and is larger than the allowed size, the request is denied and the
2107 user receives an error message that says "the request or reply
2108 is too large." If there is no content-length, and the reply
2109 size exceeds this limit, the client's connection is just closed
2110 and they will receive a partial reply.
2111
2112 WARNING: downstream caches probably can not detect a partial reply
2113 if there is no content-length header, so they will cache
2114 partial responses and give them out as hits. You should NOT
2115 use this option if you have downstream caches.
2116
2117 WARNING: A maximum size smaller than the size of squid's error messages
2118 will cause an infinite loop and crash squid. Ensure that the smallest
2119 non-zero value you use is greater that the maximum header size plus
2120 the size of your largest error page.
2121
2122 If you set this parameter none (the default), there will be
2123 no limit imposed.
2124
2125 Configuration Format is:
2126 reply_body_max_size SIZE UNITS [acl ...]
2127 ie.
2128 reply_body_max_size 10 MB
2129
2130 DOC_END
2131
2132 NAME: on_unsupported_protocol
2133 TYPE: on_unsupported_protocol
2134 LOC: Config.accessList.on_unsupported_protocol
2135 DEFAULT: none
2136 DEFAULT_DOC: Respond with an error message to unidentifiable traffic
2137 DOC_START
2138 Determines Squid behavior when encountering strange requests at the
2139 beginning of an accepted TCP connection or the beginning of a bumped
2140 CONNECT tunnel. Controlling Squid reaction to unexpected traffic is
2141 especially useful in interception environments where Squid is likely
2142 to see connections for unsupported protocols that Squid should either
2143 terminate or tunnel at TCP level.
2144
2145 on_unsupported_protocol <action> [!]acl ...
2146
2147 The first matching action wins. Only fast ACLs are supported.
2148
2149 Supported actions are:
2150
2151 tunnel: Establish a TCP connection with the intended server and
2152 blindly shovel TCP packets between the client and server.
2153
2154 respond: Respond with an error message, using the transfer protocol
2155 for the Squid port that received the request (e.g., HTTP
2156 for connections intercepted at the http_port). This is the
2157 default.
2158
2159 Squid expects the following traffic patterns:
2160
2161 http_port: a plain HTTP request
2162 https_port: SSL/TLS handshake followed by an [encrypted] HTTP request
2163 ftp_port: a plain FTP command (no on_unsupported_protocol support yet!)
2164 CONNECT tunnel on http_port: same as https_port
2165 CONNECT tunnel on https_port: same as https_port
2166
2167 Currently, this directive has effect on intercepted connections and
2168 bumped tunnels only. Other cases are not supported because Squid
2169 cannot know the intended destination of other traffic.
2170
2171 For example:
2172 # define what Squid errors indicate receiving non-HTTP traffic:
2173 acl foreignProtocol squid_error ERR_PROTOCOL_UNKNOWN ERR_TOO_BIG
2174 # define what Squid errors indicate receiving nothing:
2175 acl serverTalksFirstProtocol squid_error ERR_REQUEST_START_TIMEOUT
2176 # tunnel everything that does not look like HTTP:
2177 on_unsupported_protocol tunnel foreignProtocol
2178 # tunnel if we think the client waits for the server to talk first:
2179 on_unsupported_protocol tunnel serverTalksFirstProtocol
2180 # in all other error cases, just send an HTTP "error page" response:
2181 on_unsupported_protocol respond all
2182
2183 See also: squid_error ACL
2184 DOC_END
2185
2186 NAME: auth_schemes
2187 TYPE: AuthSchemes
2188 IFDEF: USE_AUTH
2189 LOC: Auth::TheConfig.schemeAccess
2190 DEFAULT: none
2191 DEFAULT_DOC: use all auth_param schemes in their configuration order
2192 DOC_START
2193 Use this directive to customize authentication schemes presence and
2194 order in Squid's Unauthorized and Authentication Required responses.
2195
2196 auth_schemes scheme1,scheme2,... [!]aclname ...
2197
2198 where schemeN is the name of one of the authentication schemes
2199 configured using auth_param directives. At least one scheme name is
2200 required. Multiple scheme names are separated by commas. Either
2201 avoid whitespace or quote the entire schemes list.
2202
2203 A special "ALL" scheme name expands to all auth_param-configured
2204 schemes in their configuration order. This directive cannot be used
2205 to configure Squid to offer no authentication schemes at all.
2206
2207 The first matching auth_schemes rule determines the schemes order
2208 for the current Authentication Required transaction. Note that the
2209 future response is not yet available during auth_schemes evaluation.
2210
2211 If this directive is not used or none of its rules match, then Squid
2212 responds with all configured authentication schemes in the order of
2213 auth_param directives in the configuration file.
2214
2215 This directive does not determine when authentication is used or
2216 how each authentication scheme authenticates clients.
2217
2218 The following example sends basic and negotiate authentication
2219 schemes, in that order, when requesting authentication of HTTP
2220 requests matching the isIE ACL (not shown) while sending all
2221 auth_param schemes in their configuration order to other clients:
2222
2223 auth_schemes basic,negotiate isIE
2224 auth_schemes ALL all # explicit default
2225
2226 This directive supports fast ACLs only.
2227
2228 See also: auth_param.
2229 DOC_END
2230
2231 COMMENT_START
2232 NETWORK OPTIONS
2233 -----------------------------------------------------------------------------
2234 COMMENT_END
2235
2236 NAME: http_port ascii_port
2237 TYPE: PortCfg
2238 DEFAULT: none
2239 LOC: HttpPortList
2240 DOC_START
2241 Usage: port [mode] [options]
2242 hostname:port [mode] [options]
2243 1.2.3.4:port [mode] [options]
2244
2245 The socket addresses where Squid will listen for HTTP client
2246 requests. You may specify multiple socket addresses.
2247 There are three forms: port alone, hostname with port, and
2248 IP address with port. If you specify a hostname or IP
2249 address, Squid binds the socket to that specific
2250 address. Most likely, you do not need to bind to a specific
2251 address, so you can use the port number alone.
2252
2253 If you are running Squid in accelerator mode, you
2254 probably want to listen on port 80 also, or instead.
2255
2256 The -a command line option may be used to specify additional
2257 port(s) where Squid listens for proxy request. Such ports will
2258 be plain proxy ports with no options.
2259
2260 You may specify multiple socket addresses on multiple lines.
2261
2262 Modes:
2263
2264 intercept Support for IP-Layer NAT interception delivering
2265 traffic to this Squid port.
2266 NP: disables authentication on the port.
2267
2268 tproxy Support Linux TPROXY (or BSD divert-to) with spoofing
2269 of outgoing connections using the client IP address.
2270 NP: disables authentication on the port.
2271
2272 accel Accelerator / reverse proxy mode
2273
2274 ssl-bump For each CONNECT request allowed by ssl_bump ACLs,
2275 establish secure connection with the client and with
2276 the server, decrypt HTTPS messages as they pass through
2277 Squid, and treat them as unencrypted HTTP messages,
2278 becoming the man-in-the-middle.
2279
2280 The ssl_bump option is required to fully enable
2281 bumping of CONNECT requests.
2282
2283 Omitting the mode flag causes default forward proxy mode to be used.
2284
2285
2286 Accelerator Mode Options:
2287
2288 defaultsite=domainname
2289 What to use for the Host: header if it is not present
2290 in a request. Determines what site (not origin server)
2291 accelerators should consider the default.
2292
2293 no-vhost Disable using HTTP/1.1 Host header for virtual domain support.
2294
2295 protocol= Protocol to reconstruct accelerated and intercepted
2296 requests with. Defaults to HTTP/1.1 for http_port and
2297 HTTPS/1.1 for https_port.
2298 When an unsupported value is configured Squid will
2299 produce a FATAL error.
2300 Values: HTTP or HTTP/1.1, HTTPS or HTTPS/1.1
2301
2302 vport Virtual host port support. Using the http_port number
2303 instead of the port passed on Host: headers.
2304
2305 vport=NN Virtual host port support. Using the specified port
2306 number instead of the port passed on Host: headers.
2307
2308 act-as-origin
2309 Act as if this Squid is the origin server.
2310 This currently means generate new Date: and Expires:
2311 headers on HIT instead of adding Age:.
2312
2313 ignore-cc Ignore request Cache-Control headers.
2314
2315 WARNING: This option violates HTTP specifications if
2316 used in non-accelerator setups.
2317
2318 allow-direct Allow direct forwarding in accelerator mode. Normally
2319 accelerated requests are denied direct forwarding as if
2320 never_direct was used.
2321
2322 WARNING: this option opens accelerator mode to security
2323 vulnerabilities usually only affecting in interception
2324 mode. Make sure to protect forwarding with suitable
2325 http_access rules when using this.
2326
2327
2328 SSL Bump Mode Options:
2329 In addition to these options ssl-bump requires TLS/SSL options.
2330
2331 generate-host-certificates[=<on|off>]
2332 Dynamically create SSL server certificates for the
2333 destination hosts of bumped CONNECT requests.When
2334 enabled, the cert and key options are used to sign
2335 generated certificates. Otherwise generated
2336 certificate will be selfsigned.
2337 If there is a CA certificate lifetime of the generated
2338 certificate equals lifetime of the CA certificate. If
2339 generated certificate is selfsigned lifetime is three
2340 years.
2341 This option is enabled by default when ssl-bump is used.
2342 See the ssl-bump option above for more information.
2343
2344 dynamic_cert_mem_cache_size=SIZE
2345 Approximate total RAM size spent on cached generated
2346 certificates. If set to zero, caching is disabled. The
2347 default value is 4MB.
2348
2349 TLS / SSL Options:
2350
2351 tls-cert= Path to file containing an X.509 certificate (PEM format)
2352 to be used in the TLS handshake ServerHello.
2353
2354 If this certificate is constrained by KeyUsage TLS
2355 feature it must allow HTTP server usage, along with
2356 any additional restrictions imposed by your choice
2357 of options= settings.
2358
2359 When OpenSSL is used this file may also contain a
2360 chain of intermediate CA certificates to send in the
2361 TLS handshake.
2362
2363 When GnuTLS is used this option (and any paired
2364 tls-key= option) may be repeated to load multiple
2365 certificates for different domains.
2366
2367 Also, when generate-host-certificates=on is configured
2368 the first tls-cert= option must be a CA certificate
2369 capable of signing the automatically generated
2370 certificates.
2371
2372 tls-key= Path to a file containing private key file (PEM format)
2373 for the previous tls-cert= option.
2374
2375 If tls-key= is not specified tls-cert= is assumed to
2376 reference a PEM file containing both the certificate
2377 and private key.
2378
2379 cipher= Colon separated list of supported ciphers.
2380 NOTE: some ciphers such as EDH ciphers depend on
2381 additional settings. If those settings are
2382 omitted the ciphers may be silently ignored
2383 by the OpenSSL library.
2384
2385 options= Various SSL implementation options. The most important
2386 being:
2387
2388 NO_SSLv3 Disallow the use of SSLv3
2389
2390 NO_TLSv1 Disallow the use of TLSv1.0
2391
2392 NO_TLSv1_1 Disallow the use of TLSv1.1
2393
2394 NO_TLSv1_2 Disallow the use of TLSv1.2
2395
2396 SINGLE_DH_USE
2397 Always create a new key when using
2398 temporary/ephemeral DH key exchanges
2399
2400 SINGLE_ECDH_USE
2401 Enable ephemeral ECDH key exchange.
2402 The adopted curve should be specified
2403 using the tls-dh option.
2404
2405 NO_TICKET
2406 Disable use of RFC5077 session tickets.
2407 Some servers may have problems
2408 understanding the TLS extension due
2409 to ambiguous specification in RFC4507.
2410
2411 ALL Enable various bug workarounds
2412 suggested as "harmless" by OpenSSL
2413 Be warned that this reduces SSL/TLS
2414 strength to some attacks.
2415
2416 See the OpenSSL SSL_CTX_set_options documentation for a
2417 more complete list.
2418
2419 clientca= File containing the list of CAs to use when
2420 requesting a client certificate.
2421
2422 tls-cafile= PEM file containing CA certificates to use when verifying
2423 client certificates. If not configured clientca will be
2424 used. May be repeated to load multiple files.
2425
2426 capath= Directory containing additional CA certificates
2427 and CRL lists to use when verifying client certificates.
2428 Requires OpenSSL or LibreSSL.
2429
2430 crlfile= File of additional CRL lists to use when verifying
2431 the client certificate, in addition to CRLs stored in
2432 the capath. Implies VERIFY_CRL flag below.
2433
2434 tls-dh=[curve:]file
2435 File containing DH parameters for temporary/ephemeral DH key
2436 exchanges, optionally prefixed by a curve for ephemeral ECDH
2437 key exchanges.
2438 See OpenSSL documentation for details on how to create the
2439 DH parameter file. Supported curves for ECDH can be listed
2440 using the "openssl ecparam -list_curves" command.
2441 WARNING: EDH and EECDH ciphers will be silently disabled if
2442 this option is not set.
2443
2444 sslflags= Various flags modifying the use of SSL:
2445 DELAYED_AUTH
2446 Don't request client certificates
2447 immediately, but wait until acl processing
2448 requires a certificate (not yet implemented).
2449 CONDITIONAL_AUTH
2450 Request a client certificate during the TLS
2451 handshake, but ignore certificate absence in
2452 the TLS client Hello. If the client does
2453 supply a certificate, it is validated.
2454 NO_SESSION_REUSE
2455 Don't allow for session reuse. Each connection
2456 will result in a new SSL session.
2457 VERIFY_CRL
2458 Verify CRL lists when accepting client
2459 certificates.
2460 VERIFY_CRL_ALL
2461 Verify CRL lists for all certificates in the
2462 client certificate chain.
2463
2464 tls-default-ca[=off]
2465 Whether to use the system Trusted CAs. Default is OFF.
2466
2467 tls-no-npn Do not use the TLS NPN extension to advertise HTTP/1.1.
2468
2469 sslcontext= SSL session ID context identifier.
2470
2471 Other Options:
2472
2473 connection-auth[=on|off]
2474 use connection-auth=off to tell Squid to prevent
2475 forwarding Microsoft connection oriented authentication
2476 (NTLM, Negotiate and Kerberos)
2477
2478 disable-pmtu-discovery=
2479 Control Path-MTU discovery usage:
2480 off lets OS decide on what to do (default).
2481 transparent disable PMTU discovery when transparent
2482 support is enabled.
2483 always disable always PMTU discovery.
2484
2485 In many setups of transparently intercepting proxies
2486 Path-MTU discovery can not work on traffic towards the
2487 clients. This is the case when the intercepting device
2488 does not fully track connections and fails to forward
2489 ICMP must fragment messages to the cache server. If you
2490 have such setup and experience that certain clients
2491 sporadically hang or never complete requests set
2492 disable-pmtu-discovery option to 'transparent'.
2493
2494 name= Specifies a internal name for the port. Defaults to
2495 the port specification (port or addr:port)
2496
2497 tcpkeepalive[=idle,interval,timeout]
2498 Enable TCP keepalive probes of idle connections.
2499 In seconds; idle is the initial time before TCP starts
2500 probing the connection, interval how often to probe, and
2501 timeout the time before giving up.
2502
2503 require-proxy-header
2504 Require PROXY protocol version 1 or 2 connections.
2505 The proxy_protocol_access is required to permit
2506 downstream proxies which can be trusted.
2507
2508 worker-queues
2509 Ask TCP stack to maintain a dedicated listening queue
2510 for each worker accepting requests at this port.
2511 Requires TCP stack that supports the SO_REUSEPORT socket
2512 option.
2513
2514 SECURITY WARNING: Enabling worker-specific queues
2515 allows any process running as Squid's effective user to
2516 easily accept requests destined to this port.
2517
2518 If you run Squid on a dual-homed machine with an internal
2519 and an external interface we recommend you to specify the
2520 internal address:port in http_port. This way Squid will only be
2521 visible on the internal address.
2522
2523 CONFIG_START
2524
2525 # Squid normally listens to port 3128
2526 http_port @DEFAULT_HTTP_PORT@
2527 CONFIG_END
2528 DOC_END
2529
2530 NAME: https_port
2531 IFDEF: USE_GNUTLS||USE_OPENSSL
2532 TYPE: PortCfg
2533 DEFAULT: none
2534 LOC: HttpPortList
2535 DOC_START
2536 Usage: [ip:]port [mode] tls-cert=certificate.pem [options]
2537
2538 The socket address where Squid will listen for client requests made
2539 over TLS or SSL connections. Commonly referred to as HTTPS.
2540
2541 This is most useful for situations where you are running squid in
2542 accelerator mode and you want to do the TLS work at the accelerator
2543 level.
2544
2545 You may specify multiple socket addresses on multiple lines,
2546 each with their own certificate and/or options.
2547
2548 The tls-cert= option is mandatory on HTTPS ports.
2549
2550 See http_port for a list of modes and options.
2551 DOC_END
2552
2553 NAME: ftp_port
2554 TYPE: PortCfg
2555 DEFAULT: none
2556 LOC: FtpPortList
2557 DOC_START
2558 Enables Native FTP proxy by specifying the socket address where Squid
2559 listens for FTP client requests. See http_port directive for various
2560 ways to specify the listening address and mode.
2561
2562 Usage: ftp_port address [mode] [options]
2563
2564 WARNING: This is a new, experimental, complex feature that has seen
2565 limited production exposure. Some Squid modules (e.g., caching) do not
2566 currently work with native FTP proxying, and many features have not
2567 even been tested for compatibility. Test well before deploying!
2568
2569 Native FTP proxying differs substantially from proxying HTTP requests
2570 with ftp:// URIs because Squid works as an FTP server and receives
2571 actual FTP commands (rather than HTTP requests with FTP URLs).
2572
2573 Native FTP commands accepted at ftp_port are internally converted or
2574 wrapped into HTTP-like messages. The same happens to Native FTP
2575 responses received from FTP origin servers. Those HTTP-like messages
2576 are shoveled through regular access control and adaptation layers
2577 between the FTP client and the FTP origin server. This allows Squid to
2578 examine, adapt, block, and log FTP exchanges. Squid reuses most HTTP
2579 mechanisms when shoveling wrapped FTP messages. For example,
2580 http_access and adaptation_access directives are used.
2581
2582 Modes:
2583
2584 intercept Same as http_port intercept. The FTP origin address is
2585 determined based on the intended destination of the
2586 intercepted connection.
2587
2588 tproxy Support Linux TPROXY for spoofing outgoing
2589 connections using the client IP address.
2590 NP: disables authentication and maybe IPv6 on the port.
2591
2592 By default (i.e., without an explicit mode option), Squid extracts the
2593 FTP origin address from the login@origin parameter of the FTP USER
2594 command. Many popular FTP clients support such native FTP proxying.
2595
2596 Options:
2597
2598 name=token Specifies an internal name for the port. Defaults to
2599 the port address. Usable with myportname ACL.
2600
2601 ftp-track-dirs
2602 Enables tracking of FTP directories by injecting extra
2603 PWD commands and adjusting Request-URI (in wrapping
2604 HTTP requests) to reflect the current FTP server
2605 directory. Tracking is disabled by default.
2606
2607 protocol=FTP Protocol to reconstruct accelerated and intercepted
2608 requests with. Defaults to FTP. No other accepted
2609 values have been tested with. An unsupported value
2610 results in a FATAL error. Accepted values are FTP,
2611 HTTP (or HTTP/1.1), and HTTPS (or HTTPS/1.1).
2612
2613 Other http_port modes and options that are not specific to HTTP and
2614 HTTPS may also work.
2615 DOC_END
2616
2617 NAME: tcp_outgoing_tos tcp_outgoing_ds tcp_outgoing_dscp
2618 TYPE: acl_tos
2619 DEFAULT: none
2620 LOC: Ip::Qos::TheConfig.tosToServer
2621 DOC_START
2622 Allows you to select a TOS/Diffserv value for packets outgoing
2623 on the server side, based on an ACL.
2624
2625 tcp_outgoing_tos ds-field [!]aclname ...
2626
2627 Example where normal_service_net uses the TOS value 0x00
2628 and good_service_net uses 0x20
2629
2630 acl normal_service_net src 10.0.0.0/24
2631 acl good_service_net src 10.0.1.0/24
2632 tcp_outgoing_tos 0x00 normal_service_net
2633 tcp_outgoing_tos 0x20 good_service_net
2634
2635 TOS/DSCP values really only have local significance - so you should
2636 know what you're specifying. For more information, see RFC2474,
2637 RFC2475, and RFC3260.
2638
2639 The TOS/DSCP byte must be exactly that - a octet value 0 - 255, or
2640 "default" to use whatever default your host has.
2641 Note that only multiples of 4 are usable as the two rightmost bits have
2642 been redefined for use by ECN (RFC 3168 section 23.1).
2643 The squid parser will enforce this by masking away the ECN bits.
2644
2645 Processing proceeds in the order specified, and stops at first fully
2646 matching line.
2647
2648 Only fast ACLs are supported.
2649 DOC_END
2650
2651 NAME: clientside_tos
2652 TYPE: acl_tos
2653 DEFAULT: none
2654 LOC: Ip::Qos::TheConfig.tosToClient
2655 DOC_START
2656 Allows you to select a TOS/DSCP value for packets being transmitted
2657 on the client-side, based on an ACL.
2658
2659 clientside_tos ds-field [!]aclname ...
2660
2661 Example where normal_service_net uses the TOS value 0x00
2662 and good_service_net uses 0x20
2663
2664 acl normal_service_net src 10.0.0.0/24
2665 acl good_service_net src 10.0.1.0/24
2666 clientside_tos 0x00 normal_service_net
2667 clientside_tos 0x20 good_service_net
2668
2669 Note: This feature is incompatible with qos_flows. Any TOS values set here
2670 will be overwritten by TOS values in qos_flows.
2671
2672 The TOS/DSCP byte must be exactly that - a octet value 0 - 255, or
2673 "default" to use whatever default your host has.
2674 Note that only multiples of 4 are usable as the two rightmost bits have
2675 been redefined for use by ECN (RFC 3168 section 23.1).
2676 The squid parser will enforce this by masking away the ECN bits.
2677
2678 This clause only supports fast acl types.
2679 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2680 DOC_END
2681
2682 NAME: tcp_outgoing_mark
2683 TYPE: acl_nfmark
2684 IFDEF: SO_MARK&&USE_LIBCAP
2685 DEFAULT: none
2686 LOC: Ip::Qos::TheConfig.nfmarkToServer
2687 DOC_START
2688 Allows you to apply a Netfilter mark value to outgoing packets
2689 on the server side, based on an ACL.
2690
2691 tcp_outgoing_mark mark-value [!]aclname ...
2692
2693 Example where normal_service_net uses the mark value 0x00
2694 and good_service_net uses 0x20
2695
2696 acl normal_service_net src 10.0.0.0/24
2697 acl good_service_net src 10.0.1.0/24
2698 tcp_outgoing_mark 0x00 normal_service_net
2699 tcp_outgoing_mark 0x20 good_service_net
2700
2701 Only fast ACLs are supported.
2702 DOC_END
2703
2704 NAME: mark_client_packet clientside_mark
2705 TYPE: acl_nfmark
2706 IFDEF: SO_MARK&&USE_LIBCAP
2707 DEFAULT: none
2708 LOC: Ip::Qos::TheConfig.nfmarkToClient
2709 DOC_START
2710 Allows you to apply a Netfilter MARK value to packets being transmitted
2711 on the client-side, based on an ACL.
2712
2713 mark_client_packet mark-value [!]aclname ...
2714
2715 Example where normal_service_net uses the MARK value 0x00
2716 and good_service_net uses 0x20
2717
2718 acl normal_service_net src 10.0.0.0/24
2719 acl good_service_net src 10.0.1.0/24
2720 mark_client_packet 0x00 normal_service_net
2721 mark_client_packet 0x20 good_service_net
2722
2723 Note: This feature is incompatible with qos_flows. Any mark values set here
2724 will be overwritten by mark values in qos_flows.
2725
2726 This clause only supports fast acl types.
2727 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2728 DOC_END
2729
2730 NAME: mark_client_connection
2731 TYPE: acl_nfmark
2732 IFDEF: SO_MARK&&USE_LIBCAP
2733 DEFAULT: none
2734 LOC: Ip::Qos::TheConfig.nfConnmarkToClient
2735 DOC_START
2736 Allows you to apply a Netfilter CONNMARK value to a connection
2737 on the client-side, based on an ACL.
2738
2739 mark_client_connection mark-value[/mask] [!]aclname ...
2740
2741 The mark-value and mask are unsigned integers (hex, octal, or decimal).
2742 The mask may be used to preserve marking previously set by other agents
2743 (e.g., iptables).
2744
2745 A matching rule replaces the CONNMARK value. If a mask is also
2746 specified, then the masked bits of the original value are zeroed, and
2747 the configured mark-value is ORed with that adjusted value.
2748 For example, applying a mark-value 0xAB/0xF to 0x5F CONNMARK, results
2749 in a 0xFB marking (rather than a 0xAB or 0x5B).
2750
2751 This directive semantics is similar to iptables --set-mark rather than
2752 --set-xmark functionality.
2753
2754 The directive does not interfere with qos_flows (which uses packet MARKs,
2755 not CONNMARKs).
2756
2757 Example where squid marks intercepted FTP connections:
2758
2759 acl proto_ftp proto FTP
2760 mark_client_connection 0x200/0xff00 proto_ftp
2761
2762 This clause only supports fast acl types.
2763 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2764 DOC_END
2765
2766 NAME: qos_flows
2767 TYPE: QosConfig
2768 IFDEF: USE_QOS_TOS
2769 DEFAULT: none
2770 LOC: Ip::Qos::TheConfig
2771 DOC_START
2772 Allows you to select a TOS/DSCP value to mark outgoing
2773 connections to the client, based on where the reply was sourced.
2774 For platforms using netfilter, allows you to set a netfilter mark
2775 value instead of, or in addition to, a TOS value.
2776
2777 By default this functionality is disabled. To enable it with the default
2778 settings simply use "qos_flows mark" or "qos_flows tos". Default
2779 settings will result in the netfilter mark or TOS value being copied
2780 from the upstream connection to the client. Note that it is the connection
2781 CONNMARK value not the packet MARK value that is copied.
2782
2783 It is not currently possible to copy the mark or TOS value from the
2784 client to the upstream connection request.
2785
2786 TOS values really only have local significance - so you should
2787 know what you're specifying. For more information, see RFC2474,
2788 RFC2475, and RFC3260.
2789
2790 The TOS/DSCP byte must be exactly that - a octet value 0 - 255.
2791 Note that only multiples of 4 are usable as the two rightmost bits have
2792 been redefined for use by ECN (RFC 3168 section 23.1).
2793 The squid parser will enforce this by masking away the ECN bits.
2794
2795 Mark values can be any unsigned 32-bit integer value.
2796
2797 This setting is configured by setting the following values:
2798
2799 tos|mark Whether to set TOS or netfilter mark values
2800
2801 local-hit=0xFF Value to mark local cache hits.
2802
2803 sibling-hit=0xFF Value to mark hits from sibling peers.
2804
2805 parent-hit=0xFF Value to mark hits from parent peers.
2806
2807 miss=0xFF[/mask] Value to mark cache misses. Takes precedence
2808 over the preserve-miss feature (see below), unless
2809 mask is specified, in which case only the bits
2810 specified in the mask are written.
2811
2812 The TOS variant of the following features are only possible on Linux
2813 and require your kernel to be patched with the TOS preserving ZPH
2814 patch, available from http://zph.bratcheda.org
2815 No patch is needed to preserve the netfilter mark, which will work
2816 with all variants of netfilter.
2817
2818 disable-preserve-miss
2819 This option disables the preservation of the TOS or netfilter
2820 mark. By default, the existing TOS or netfilter mark value of
2821 the response coming from the remote server will be retained
2822 and masked with miss-mark.
2823 NOTE: in the case of a netfilter mark, the mark must be set on
2824 the connection (using the CONNMARK target) not on the packet
2825 (MARK target).
2826
2827 miss-mask=0xFF
2828 Allows you to mask certain bits in the TOS or mark value
2829 received from the remote server, before copying the value to
2830 the TOS sent towards clients.
2831 Default for tos: 0xFF (TOS from server is not changed).
2832 Default for mark: 0xFFFFFFFF (mark from server is not changed).
2833
2834 All of these features require the --enable-zph-qos compilation flag
2835 (enabled by default). Netfilter marking also requires the
2836 libnetfilter_conntrack libraries (--with-netfilter-conntrack) and
2837 libcap 2.09+ (--with-libcap).
2838
2839 DOC_END
2840
2841 NAME: tcp_outgoing_address
2842 TYPE: acl_address
2843 DEFAULT: none
2844 DEFAULT_DOC: Address selection is performed by the operating system.
2845 LOC: Config.accessList.outgoing_address
2846 DOC_START
2847 Allows you to map requests to different outgoing IP addresses
2848 based on the username or source address of the user making
2849 the request.
2850
2851 tcp_outgoing_address ipaddr [[!]aclname] ...
2852
2853 For example;
2854 Forwarding clients with dedicated IPs for certain subnets.
2855
2856 acl normal_service_net src 10.0.0.0/24
2857 acl good_service_net src 10.0.2.0/24
2858
2859 tcp_outgoing_address 2001:db8::c001 good_service_net
2860 tcp_outgoing_address 10.1.0.2 good_service_net
2861
2862 tcp_outgoing_address 2001:db8::beef normal_service_net
2863 tcp_outgoing_address 10.1.0.1 normal_service_net
2864
2865 tcp_outgoing_address 2001:db8::1
2866 tcp_outgoing_address 10.1.0.3
2867
2868 Processing proceeds in the order specified, and stops at first fully
2869 matching line.
2870
2871 Squid will add an implicit IP version test to each line.
2872 Requests going to IPv4 websites will use the outgoing 10.1.0.* addresses.
2873 Requests going to IPv6 websites will use the outgoing 2001:db8:* addresses.
2874
2875
2876 NOTE: The use of this directive using client dependent ACLs is
2877 incompatible with the use of server side persistent connections. To
2878 ensure correct results it is best to set server_persistent_connections
2879 to off when using this directive in such configurations.
2880
2881 NOTE: The use of this directive to set a local IP on outgoing TCP links
2882 is incompatible with using TPROXY to set client IP out outbound TCP links.
2883 When needing to contact peers use the no-tproxy cache_peer option and the
2884 client_dst_passthru directive re-enable normal forwarding such as this.
2885
2886 This clause only supports fast acl types.
2887 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
2888 DOC_END
2889
2890 NAME: host_verify_strict
2891 TYPE: onoff
2892 DEFAULT: off
2893 LOC: Config.onoff.hostStrictVerify
2894 DOC_START
2895 Regardless of this option setting, when dealing with intercepted
2896 traffic, Squid always verifies that the destination IP address matches
2897 the Host header domain or IP (called 'authority form URL').
2898
2899 This enforcement is performed to satisfy a MUST-level requirement in
2900 RFC 2616 section 14.23: "The Host field value MUST represent the naming
2901 authority of the origin server or gateway given by the original URL".
2902
2903 When set to ON:
2904 Squid always responds with an HTTP 409 (Conflict) error
2905 page and logs a security warning if there is no match.
2906
2907 Squid verifies that the destination IP address matches
2908 the Host header for forward-proxy and reverse-proxy traffic
2909 as well. For those traffic types, Squid also enables the
2910 following checks, comparing the corresponding Host header
2911 and Request-URI components:
2912
2913 * The host names (domain or IP) must be identical,
2914 but valueless or missing Host header disables all checks.
2915 For the two host names to match, both must be either IP
2916 or FQDN.
2917
2918 * Port numbers must be identical, but if a port is missing
2919 the scheme-default port is assumed.
2920
2921
2922 When set to OFF (the default):
2923 Squid allows suspicious requests to continue but logs a
2924 security warning and blocks caching of the response.
2925
2926 * Forward-proxy traffic is not checked at all.
2927
2928 * Reverse-proxy traffic is not checked at all.
2929
2930 * Intercepted traffic which passes verification is handled
2931 according to client_dst_passthru.
2932
2933 * Intercepted requests which fail verification are sent
2934 to the client original destination instead of DIRECT.
2935 This overrides 'client_dst_passthru off'.
2936
2937 For now suspicious intercepted CONNECT requests are always
2938 responded to with an HTTP 409 (Conflict) error page.
2939
2940
2941 SECURITY NOTE:
2942
2943 As described in CVE-2009-0801 when the Host: header alone is used
2944 to determine the destination of a request it becomes trivial for
2945 malicious scripts on remote websites to bypass browser same-origin
2946 security policy and sandboxing protections.
2947
2948 The cause of this is that such applets are allowed to perform their
2949 own HTTP stack, in which case the same-origin policy of the browser
2950 sandbox only verifies that the applet tries to contact the same IP
2951 as from where it was loaded at the IP level. The Host: header may
2952 be different from the connected IP and approved origin.
2953
2954 DOC_END
2955
2956 NAME: client_dst_passthru
2957 TYPE: onoff
2958 DEFAULT: on
2959 LOC: Config.onoff.client_dst_passthru
2960 DOC_START
2961 With NAT or TPROXY intercepted traffic Squid may pass the request
2962 directly to the original client destination IP or seek a faster
2963 source using the HTTP Host header.
2964
2965 Using Host to locate alternative servers can provide faster
2966 connectivity with a range of failure recovery options.
2967 But can also lead to connectivity trouble when the client and
2968 server are attempting stateful interactions unaware of the proxy.
2969
2970 This option (on by default) prevents alternative DNS entries being
2971 located to send intercepted traffic DIRECT to an origin server.
2972 The clients original destination IP and port will be used instead.
2973
2974 Regardless of this option setting, when dealing with intercepted
2975 traffic Squid will verify the Host: header and any traffic which
2976 fails Host verification will be treated as if this option were ON.
2977
2978 see host_verify_strict for details on the verification process.
2979 DOC_END
2980
2981 COMMENT_START
2982 TLS OPTIONS
2983 -----------------------------------------------------------------------------
2984 COMMENT_END
2985
2986 NAME: tls_outgoing_options
2987 IFDEF: USE_GNUTLS||USE_OPENSSL
2988 TYPE: securePeerOptions
2989 DEFAULT: min-version=1.0
2990 LOC: Security::ProxyOutgoingConfig
2991 DOC_START
2992 disable Do not support https:// URLs.
2993
2994 cert=/path/to/client/certificate
2995 A client X.509 certificate to use when connecting.
2996
2997 key=/path/to/client/private_key
2998 The private key corresponding to the cert= above.
2999
3000 If key= is not specified cert= is assumed to
3001 reference a PEM file containing both the certificate
3002 and private key.
3003
3004 cipher=... The list of valid TLS ciphers to use.
3005
3006 min-version=1.N
3007 The minimum TLS protocol version to permit.
3008 To control SSLv3 use the options= parameter.
3009 Supported Values: 1.0 (default), 1.1, 1.2, 1.3
3010
3011 options=... Specify various TLS/SSL implementation options.
3012
3013 OpenSSL options most important are:
3014
3015 NO_SSLv3 Disallow the use of SSLv3
3016
3017 SINGLE_DH_USE
3018 Always create a new key when using
3019 temporary/ephemeral DH key exchanges
3020
3021 NO_TICKET
3022 Disable use of RFC5077 session tickets.
3023 Some servers may have problems
3024 understanding the TLS extension due
3025 to ambiguous specification in RFC4507.
3026
3027 ALL Enable various bug workarounds
3028 suggested as "harmless" by OpenSSL
3029 Be warned that this reduces SSL/TLS
3030 strength to some attacks.
3031
3032 See the OpenSSL SSL_CTX_set_options documentation
3033 for a more complete list.
3034
3035 GnuTLS options most important are:
3036
3037 %NO_TICKETS
3038 Disable use of RFC5077 session tickets.
3039 Some servers may have problems
3040 understanding the TLS extension due
3041 to ambiguous specification in RFC4507.
3042
3043 See the GnuTLS Priority Strings documentation
3044 for a more complete list.
3045 http://www.gnutls.org/manual/gnutls.html#Priority-Strings
3046
3047
3048 cafile= PEM file containing CA certificates to use when verifying
3049 the peer certificate. May be repeated to load multiple files.
3050
3051 capath= A directory containing additional CA certificates to
3052 use when verifying the peer certificate.
3053 Requires OpenSSL or LibreSSL.
3054
3055 crlfile=... A certificate revocation list file to use when
3056 verifying the peer certificate.
3057
3058 flags=... Specify various flags modifying the TLS implementation:
3059
3060 DONT_VERIFY_PEER
3061 Accept certificates even if they fail to
3062 verify.
3063 DONT_VERIFY_DOMAIN
3064 Don't verify the peer certificate
3065 matches the server name
3066
3067 default-ca[=off]
3068 Whether to use the system Trusted CAs. Default is ON.
3069
3070 domain= The peer name as advertised in its certificate.
3071 Used for verifying the correctness of the received peer
3072 certificate. If not specified the peer hostname will be
3073 used.
3074 DOC_END
3075
3076 COMMENT_START
3077 SSL OPTIONS
3078 -----------------------------------------------------------------------------
3079 COMMENT_END
3080
3081 NAME: ssl_unclean_shutdown
3082 IFDEF: USE_OPENSSL
3083 TYPE: onoff
3084 DEFAULT: off
3085 LOC: Config.SSL.unclean_shutdown
3086 DOC_START
3087 Some browsers (especially MSIE) bugs out on SSL shutdown
3088 messages.
3089 DOC_END
3090
3091 NAME: ssl_engine
3092 IFDEF: USE_OPENSSL
3093 TYPE: string
3094 LOC: Config.SSL.ssl_engine
3095 DEFAULT: none
3096 DOC_START
3097 The OpenSSL engine to use. You will need to set this if you
3098 would like to use hardware SSL acceleration for example.
3099
3100 Not supported in builds with OpenSSL 3.0 or newer.
3101 DOC_END
3102
3103 NAME: sslproxy_session_ttl
3104 IFDEF: USE_OPENSSL
3105 DEFAULT: 300
3106 LOC: Config.SSL.session_ttl
3107 TYPE: int
3108 DOC_START
3109 Sets the timeout value for SSL sessions
3110 DOC_END
3111
3112 NAME: sslproxy_session_cache_size
3113 IFDEF: USE_OPENSSL
3114 DEFAULT: 2 MB
3115 LOC: Config.SSL.sessionCacheSize
3116 TYPE: b_size_t
3117 DOC_START
3118 Sets the cache size to use for ssl session
3119 DOC_END
3120
3121 NAME: sslproxy_foreign_intermediate_certs
3122 IFDEF: USE_OPENSSL
3123 DEFAULT: none
3124 LOC: Config.ssl_client.foreignIntermediateCertsPath
3125 TYPE: string
3126 DOC_START
3127 Many origin servers fail to send their full server certificate
3128 chain for verification, assuming the client already has or can
3129 easily locate any missing intermediate certificates.
3130
3131 Squid uses the certificates from the specified file to fill in
3132 these missing chains when trying to validate origin server
3133 certificate chains.
3134
3135 The file is expected to contain zero or more PEM-encoded
3136 intermediate certificates. These certificates are not treated
3137 as trusted root certificates, and any self-signed certificate in
3138 this file will be ignored.
3139 DOC_END
3140
3141 NAME: sslproxy_cert_sign_hash
3142 IFDEF: USE_OPENSSL
3143 DEFAULT: none
3144 LOC: Config.SSL.certSignHash
3145 TYPE: string
3146 DOC_START
3147 Sets the hashing algorithm to use when signing generated certificates.
3148 Valid algorithm names depend on the OpenSSL library used. The following
3149 names are usually available: sha1, sha256, sha512, and md5. Please see
3150 your OpenSSL library manual for the available hashes. By default, Squids
3151 that support this option use sha256 hashes.
3152
3153 Squid does not forcefully purge cached certificates that were generated
3154 with an algorithm other than the currently configured one. They remain
3155 in the cache, subject to the regular cache eviction policy, and become
3156 useful if the algorithm changes again.
3157 DOC_END
3158
3159 NAME: ssl_bump
3160 IFDEF: USE_OPENSSL
3161 TYPE: sslproxy_ssl_bump
3162 LOC: Config.accessList.ssl_bump
3163 DEFAULT_DOC: Become a TCP tunnel without decrypting proxied traffic.
3164 DEFAULT: none
3165 DOC_START
3166 This option is consulted when a CONNECT request is received on
3167 an http_port (or a new connection is intercepted at an
3168 https_port), provided that port was configured with an ssl-bump
3169 flag. The subsequent data on the connection is either treated as
3170 HTTPS and decrypted OR tunneled at TCP level without decryption,
3171 depending on the first matching bumping "action".
3172
3173 ssl_bump <action> [!]acl ...
3174
3175 The following bumping actions are currently supported:
3176
3177 splice
3178 Become a TCP tunnel without decrypting proxied traffic.
3179 This is the default action.
3180
3181 bump
3182 When used on step SslBump1, establishes a secure connection
3183 with the client first, then connect to the server.
3184 When used on step SslBump2 or SslBump3, establishes a secure
3185 connection with the server and, using a mimicked server
3186 certificate, with the client.
3187
3188 peek
3189 Receive client (step SslBump1) or server (step SslBump2)
3190 certificate while preserving the possibility of splicing the
3191 connection. Peeking at the server certificate (during step 2)
3192 usually precludes bumping of the connection at step 3.
3193
3194 stare
3195 Receive client (step SslBump1) or server (step SslBump2)
3196 certificate while preserving the possibility of bumping the
3197 connection. Staring at the server certificate (during step 2)
3198 usually precludes splicing of the connection at step 3.
3199
3200 terminate
3201 Close client and server connections.
3202
3203 Backward compatibility actions available at step SslBump1:
3204
3205 client-first
3206 Bump the connection. Establish a secure connection with the
3207 client first, then connect to the server. This old mode does
3208 not allow Squid to mimic server SSL certificate and does not
3209 work with intercepted SSL connections.
3210
3211 server-first
3212 Bump the connection. Establish a secure connection with the
3213 server first, then establish a secure connection with the
3214 client, using a mimicked server certificate. Works with both
3215 CONNECT requests and intercepted SSL connections, but does
3216 not allow to make decisions based on SSL handshake info.
3217
3218 peek-and-splice
3219 Decide whether to bump or splice the connection based on
3220 client-to-squid and server-to-squid SSL hello messages.
3221 XXX: Remove.
3222
3223 none
3224 Same as the "splice" action.
3225
3226 All ssl_bump rules are evaluated at each of the supported bumping
3227 steps. Rules with actions that are impossible at the current step are
3228 ignored. The first matching ssl_bump action wins and is applied at the
3229 end of the current step. If no rules match, the splice action is used.
3230 See the at_step ACL for a list of the supported SslBump steps.
3231
3232 This clause supports both fast and slow acl types.
3233 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
3234
3235 See also: http_port ssl-bump, https_port ssl-bump, and acl at_step.
3236
3237
3238 # Example: Bump all TLS connections except those originating from
3239 # localhost or those going to example.com.
3240
3241 acl broken_sites ssl::server_name .example.com
3242 ssl_bump splice localhost
3243 ssl_bump splice broken_sites
3244 ssl_bump bump all
3245 DOC_END
3246
3247 NAME: sslproxy_cert_error
3248 IFDEF: USE_OPENSSL
3249 DEFAULT: none
3250 DEFAULT_DOC: Server certificate errors terminate the transaction.
3251 LOC: Config.ssl_client.cert_error
3252 TYPE: acl_access
3253 DOC_START
3254 Use this ACL to bypass server certificate validation errors.
3255
3256 For example, the following lines will bypass all validation errors
3257 when talking to servers for example.com. All other
3258 validation errors will result in ERR_SECURE_CONNECT_FAIL error.
3259
3260 acl BrokenButTrustedServers dstdomain example.com
3261 sslproxy_cert_error allow BrokenButTrustedServers
3262 sslproxy_cert_error deny all
3263
3264 This clause only supports fast acl types.
3265 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
3266 Using slow acl types may result in server crashes
3267
3268 Without this option, all server certificate validation errors
3269 terminate the transaction to protect Squid and the client.
3270
3271 SQUID_X509_V_ERR_INFINITE_VALIDATION error cannot be bypassed
3272 but should not happen unless your OpenSSL library is buggy.
3273
3274 SECURITY WARNING:
3275 Bypassing validation errors is dangerous because an
3276 error usually implies that the server cannot be trusted
3277 and the connection may be insecure.
3278
3279 See also: sslproxy_flags and DONT_VERIFY_PEER.
3280 DOC_END
3281
3282 NAME: sslproxy_cert_sign
3283 IFDEF: USE_OPENSSL
3284 DEFAULT: none
3285 POSTSCRIPTUM: signUntrusted ssl::certUntrusted
3286 POSTSCRIPTUM: signSelf ssl::certSelfSigned
3287 POSTSCRIPTUM: signTrusted all
3288 TYPE: sslproxy_cert_sign
3289 LOC: Config.ssl_client.cert_sign
3290 DOC_START
3291
3292 sslproxy_cert_sign <signing algorithm> acl ...
3293
3294 The following certificate signing algorithms are supported:
3295
3296 signTrusted
3297 Sign using the configured CA certificate which is usually
3298 placed in and trusted by end-user browsers. This is the
3299 default for trusted origin server certificates.
3300
3301 signUntrusted
3302 Sign to guarantee an X509_V_ERR_CERT_UNTRUSTED browser error.
3303 This is the default for untrusted origin server certificates
3304 that are not self-signed (see ssl::certUntrusted).
3305
3306 signSelf
3307 Sign using a self-signed certificate with the right CN to
3308 generate a X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT error in the
3309 browser. This is the default for self-signed origin server
3310 certificates (see ssl::certSelfSigned).
3311
3312 This clause only supports fast acl types.
3313
3314 When sslproxy_cert_sign acl(s) match, Squid uses the corresponding
3315 signing algorithm to generate the certificate and ignores all
3316 subsequent sslproxy_cert_sign options (the first match wins). If no
3317 acl(s) match, the default signing algorithm is determined by errors
3318 detected when obtaining and validating the origin server certificate.
3319
3320 WARNING: SQUID_X509_V_ERR_DOMAIN_MISMATCH and ssl:certDomainMismatch can
3321 be used with sslproxy_cert_adapt, but if and only if Squid is bumping a
3322 CONNECT request that carries a domain name. In all other cases (CONNECT
3323 to an IP address or an intercepted SSL connection), Squid cannot detect
3324 the domain mismatch at certificate generation time when
3325 bump-server-first is used.
3326 DOC_END
3327
3328 NAME: sslproxy_cert_adapt
3329 IFDEF: USE_OPENSSL
3330 DEFAULT: none
3331 TYPE: sslproxy_cert_adapt
3332 LOC: Config.ssl_client.cert_adapt
3333 DOC_START
3334
3335 sslproxy_cert_adapt <adaptation algorithm> acl ...
3336
3337 The following certificate adaptation algorithms are supported:
3338
3339 setValidAfter
3340 Sets the "Not After" property to the "Not After" property of
3341 the CA certificate used to sign generated certificates.
3342
3343 setValidBefore
3344 Sets the "Not Before" property to the "Not Before" property of
3345 the CA certificate used to sign generated certificates.
3346
3347 setCommonName or setCommonName{CN}
3348 Sets Subject.CN property to the host name specified as a
3349 CN parameter or, if no explicit CN parameter was specified,
3350 extracted from the CONNECT request. It is a misconfiguration
3351 to use setCommonName without an explicit parameter for
3352 intercepted or tproxied SSL connections.
3353
3354 This clause only supports fast acl types.
3355
3356 Squid first groups sslproxy_cert_adapt options by adaptation algorithm.
3357 Within a group, when sslproxy_cert_adapt acl(s) match, Squid uses the
3358 corresponding adaptation algorithm to generate the certificate and
3359 ignores all subsequent sslproxy_cert_adapt options in that algorithm's
3360 group (i.e., the first match wins within each algorithm group). If no
3361 acl(s) match, the default mimicking action takes place.
3362
3363 WARNING: SQUID_X509_V_ERR_DOMAIN_MISMATCH and ssl:certDomainMismatch can
3364 be used with sslproxy_cert_adapt, but if and only if Squid is bumping a
3365 CONNECT request that carries a domain name. In all other cases (CONNECT
3366 to an IP address or an intercepted SSL connection), Squid cannot detect
3367 the domain mismatch at certificate generation time when
3368 bump-server-first is used.
3369 DOC_END
3370
3371 NAME: sslpassword_program
3372 IFDEF: USE_OPENSSL
3373 DEFAULT: none
3374 LOC: Config.Program.ssl_password
3375 TYPE: string
3376 DOC_START
3377 Specify a program used for entering SSL key passphrases
3378 when using encrypted SSL certificate keys. If not specified
3379 keys must either be unencrypted, or Squid started with the -N
3380 option to allow it to query interactively for the passphrase.
3381
3382 The key file name is given as argument to the program allowing
3383 selection of the right password if you have multiple encrypted
3384 keys.
3385 DOC_END
3386
3387 COMMENT_START
3388 OPTIONS RELATING TO EXTERNAL SSL_CRTD
3389 -----------------------------------------------------------------------------
3390 COMMENT_END
3391
3392 NAME: sslcrtd_program
3393 TYPE: eol
3394 IFDEF: USE_SSL_CRTD
3395 DEFAULT: @DEFAULT_SSL_CRTD@ -s @DEFAULT_SSL_DB_DIR@ -M 4MB
3396 LOC: Ssl::TheConfig.ssl_crtd
3397 DOC_START
3398 Specify the location and options of the executable for certificate
3399 generator.
3400
3401 @DEFAULT_SSL_CRTD@ program can use a disk cache to improve response
3402 times on repeated requests. To enable caching, specify -s and -M
3403 parameters. If those parameters are not given, the program generates
3404 a new certificate on every request.
3405
3406 For more information use:
3407 @DEFAULT_SSL_CRTD@ -h
3408 DOC_END
3409
3410 NAME: sslcrtd_children
3411 TYPE: HelperChildConfig
3412 IFDEF: USE_SSL_CRTD
3413 DEFAULT: 32 startup=5 idle=1
3414 LOC: Ssl::TheConfig.ssl_crtdChildren
3415 DOC_START
3416 Specifies the maximum number of certificate generation processes that
3417 Squid may spawn (numberofchildren) and several related options. Using
3418 too few of these helper processes (a.k.a. "helpers") creates request
3419 queues. Using too many helpers wastes your system resources. Squid
3420 does not support spawning more than 32 helpers.
3421
3422 Usage: numberofchildren [option]...
3423
3424 The startup= and idle= options allow some measure of skew in your
3425 tuning.
3426
3427 startup=N
3428
3429 Sets the minimum number of processes to spawn when Squid
3430 starts or reconfigures. When set to zero the first request will
3431 cause spawning of the first child process to handle it.
3432
3433 Starting too few children temporary slows Squid under load while it
3434 tries to spawn enough additional processes to cope with traffic.
3435
3436 idle=N
3437
3438 Sets a minimum of how many processes Squid is to try and keep available
3439 at all times. When traffic begins to rise above what the existing
3440 processes can handle this many more will be spawned up to the maximum
3441 configured. A minimum setting of 1 is required.
3442
3443 queue-size=N
3444
3445 Sets the maximum number of queued requests. A request is queued when
3446 no existing child is idle and no new child can be started due to
3447 numberofchildren limit. If the queued requests exceed queue size for
3448 more than 3 minutes squid aborts its operation. The default value is
3449 set to 2*numberofchildren.
3450
3451 You must have at least one ssl_crtd process.
3452 DOC_END
3453
3454 NAME: sslcrtvalidator_program
3455 TYPE: eol
3456 IFDEF: USE_OPENSSL
3457 DEFAULT: none
3458 LOC: Ssl::TheConfig.ssl_crt_validator
3459 DOC_START
3460 Specify the location and options of the executable for ssl_crt_validator
3461 process.
3462
3463 Usage: sslcrtvalidator_program [ttl=...] [cache=n] path ...
3464
3465 Options:
3466
3467 cache=bytes
3468 Limits how much memory Squid can use for caching validator
3469 responses. The default is 67108864 (i.e. 64 MB).
3470 Reconfiguration purges any excess entries. To disable caching,
3471 use cache=0. Currently, cache entry sizes are seriously
3472 underestimated. Even with that bug, a typical estimate for a
3473 single cache entry size would be at least a few kilobytes (the
3474 size of the PEM certificates sent to the validator).
3475
3476 ttl=<seconds|"infinity">
3477 Approximately how long Squid may reuse the validator results
3478 for. The default is 3600 (i.e. 1 hour). Using ttl=infinity
3479 disables TTL checks. Reconfiguration does not affect TTLs of
3480 the already cached entries. To disable caching, use zero cache
3481 size, not zero TTL -- zero TTL allows reuse for the remainder
3482 of the second when the result was cached.
3483 DOC_END
3484
3485 NAME: sslcrtvalidator_children
3486 TYPE: HelperChildConfig
3487 IFDEF: USE_OPENSSL
3488 DEFAULT: 32 startup=5 idle=1 concurrency=1
3489 LOC: Ssl::TheConfig.ssl_crt_validator_Children
3490 DOC_START
3491 Specifies the maximum number of certificate validation processes that
3492 Squid may spawn (numberofchildren) and several related options. Using
3493 too few of these helper processes (a.k.a. "helpers") creates request
3494 queues. Using too many helpers wastes your system resources. Squid
3495 does not support spawning more than 32 helpers.
3496
3497 Usage: numberofchildren [option]...
3498
3499 The startup= and idle= options allow some measure of skew in your
3500 tuning.
3501
3502 startup=N
3503
3504 Sets the minimum number of processes to spawn when Squid
3505 starts or reconfigures. When set to zero the first request will
3506 cause spawning of the first child process to handle it.
3507
3508 Starting too few children temporary slows Squid under load while it
3509 tries to spawn enough additional processes to cope with traffic.
3510
3511 idle=N
3512
3513 Sets a minimum of how many processes Squid is to try and keep available
3514 at all times. When traffic begins to rise above what the existing
3515 processes can handle this many more will be spawned up to the maximum
3516 configured. A minimum setting of 1 is required.
3517
3518 concurrency=
3519
3520 The number of requests each certificate validator helper can handle in
3521 parallel. A value of 0 indicates the certificate validator does not
3522 support concurrency. Defaults to 1.
3523
3524 When this directive is set to a value >= 1 then the protocol
3525 used to communicate with the helper is modified to include
3526 a request ID in front of the request/response. The request
3527 ID from the request must be echoed back with the response
3528 to that request.
3529
3530 queue-size=N
3531
3532 Sets the maximum number of queued requests. A request is queued when
3533 no existing child can accept it due to concurrency limit and no new
3534 child can be started due to numberofchildren limit. If the queued
3535 requests exceed queue size for more than 3 minutes squid aborts its
3536 operation. The default value is set to 2*numberofchildren.
3537
3538 You must have at least one ssl_crt_validator process.
3539 DOC_END
3540
3541 COMMENT_START
3542 OPTIONS WHICH AFFECT THE NEIGHBOR SELECTION ALGORITHM
3543 -----------------------------------------------------------------------------
3544 COMMENT_END
3545
3546 NAME: cache_peer
3547 TYPE: peer
3548 DEFAULT: none
3549 LOC: Config.peers
3550 DOC_START
3551 To specify other caches in a hierarchy, use the format:
3552
3553 cache_peer hostname type http-port icp-port [options]
3554
3555 For example,
3556
3557 # proxy icp
3558 # hostname type port port options
3559 # -------------------- -------- ----- ----- -----------
3560 cache_peer parent.foo.net parent 3128 3130 default
3561 cache_peer sib1.foo.net sibling 3128 3130 proxy-only
3562 cache_peer sib2.foo.net sibling 3128 3130 proxy-only
3563 cache_peer example.com parent 80 0 default
3564 cache_peer cdn.example.com sibling 3128 0
3565
3566 type: either 'parent', 'sibling', or 'multicast'.
3567
3568 proxy-port: The port number where the peer accept HTTP requests.
3569 For other Squid proxies this is usually 3128
3570 For web servers this is usually 80
3571
3572 icp-port: Used for querying neighbor caches about objects.
3573 Set to 0 if the peer does not support ICP or HTCP.
3574 See ICP and HTCP options below for additional details.
3575
3576
3577 ==== ICP OPTIONS ====
3578
3579 You MUST also set icp_port and icp_access explicitly when using these options.
3580 The defaults will prevent peer traffic using ICP.
3581
3582
3583 no-query Disable ICP queries to this neighbor.
3584
3585 multicast-responder
3586 Indicates the named peer is a member of a multicast group.
3587 ICP queries will not be sent directly to the peer, but ICP
3588 replies will be accepted from it.
3589
3590 closest-only Indicates that, for ICP_OP_MISS replies, we'll only forward
3591 CLOSEST_PARENT_MISSes and never FIRST_PARENT_MISSes.
3592
3593 background-ping
3594 To only send ICP queries to this neighbor infrequently.
3595 This is used to keep the neighbor round trip time updated
3596 and is usually used in conjunction with weighted-round-robin.
3597
3598
3599 ==== HTCP OPTIONS ====
3600
3601 You MUST also set htcp_port and htcp_access explicitly when using these options.
3602 The defaults will prevent peer traffic using HTCP.
3603
3604
3605 htcp Send HTCP, instead of ICP, queries to the neighbor.
3606 You probably also want to set the "icp-port" to 4827
3607 instead of 3130. This directive accepts a comma separated
3608 list of options described below.
3609
3610 htcp=oldsquid Send HTCP to old Squid versions (2.5 or earlier).
3611
3612 htcp=no-clr Send HTCP to the neighbor but without
3613 sending any CLR requests. This cannot be used with
3614 only-clr.
3615
3616 htcp=only-clr Send HTCP to the neighbor but ONLY CLR requests.
3617 This cannot be used with no-clr.
3618
3619 htcp=no-purge-clr
3620 Send HTCP to the neighbor including CLRs but only when
3621 they do not result from PURGE requests.
3622
3623 htcp=forward-clr
3624 Forward any HTCP CLR requests this proxy receives to the peer.
3625
3626
3627 ==== PEER SELECTION METHODS ====
3628
3629 The default peer selection method is ICP, with the first responding peer
3630 being used as source. These options can be used for better load balancing.
3631
3632
3633 default This is a parent cache which can be used as a "last-resort"
3634 if a peer cannot be located by any of the peer-selection methods.
3635 If specified more than once, only the first is used.
3636
3637 round-robin Load-Balance parents which should be used in a round-robin
3638 fashion in the absence of any ICP queries.
3639 weight=N can be used to add bias.
3640
3641 weighted-round-robin
3642 Load-Balance parents which should be used in a round-robin
3643 fashion with the frequency of each parent being based on the
3644 round trip time. Closer parents are used more often.
3645 Usually used for background-ping parents.
3646 weight=N can be used to add bias.
3647
3648 carp Load-Balance parents which should be used as a CARP array.
3649 The requests will be distributed among the parents based on the
3650 CARP load balancing hash function based on their weight.
3651
3652 userhash Load-balance parents based on the client proxy_auth or ident username.
3653
3654 sourcehash Load-balance parents based on the client source IP.
3655
3656 multicast-siblings
3657 To be used only for cache peers of type "multicast".
3658 ALL members of this multicast group have "sibling"
3659 relationship with it, not "parent". This is to a multicast
3660 group when the requested object would be fetched only from
3661 a "parent" cache, anyway. It's useful, e.g., when
3662 configuring a pool of redundant Squid proxies, being
3663 members of the same multicast group.
3664
3665
3666 ==== PEER SELECTION OPTIONS ====
3667
3668 weight=N use to affect the selection of a peer during any weighted
3669 peer-selection mechanisms.
3670 The weight must be an integer; default is 1,
3671 larger weights are favored more.
3672 This option does not affect parent selection if a peering
3673 protocol is not in use.
3674
3675 basetime=N Specify a base amount to be subtracted from round trip
3676 times of parents.
3677 It is subtracted before division by weight in calculating
3678 which parent to fectch from. If the rtt is less than the
3679 base time the rtt is set to a minimal value.
3680
3681 ttl=N Specify a TTL to use when sending multicast ICP queries
3682 to this address.
3683 Only useful when sending to a multicast group.
3684 Because we don't accept ICP replies from random
3685 hosts, you must configure other group members as
3686 peers with the 'multicast-responder' option.
3687
3688 no-delay To prevent access to this neighbor from influencing the
3689 delay pools.
3690
3691 digest-url=URL Tell Squid to fetch the cache digest (if digests are
3692 enabled) for this host from the specified URL rather
3693 than the Squid default location.
3694
3695
3696 ==== CARP OPTIONS ====
3697
3698 carp-key=key-specification
3699 use a different key than the full URL to hash against the peer.
3700 the key-specification is a comma-separated list of the keywords
3701 scheme, host, port, path, params
3702 Order is not important.
3703
3704 ==== ACCELERATOR / REVERSE-PROXY OPTIONS ====
3705
3706 originserver Causes this parent to be contacted as an origin server.
3707 Meant to be used in accelerator setups when the peer
3708 is a web server.
3709
3710 forceddomain=name
3711 Set the Host header of requests forwarded to this peer.
3712 Useful in accelerator setups where the server (peer)
3713 expects a certain domain name but clients may request
3714 others. ie example.com or www.example.com
3715
3716 no-digest Disable request of cache digests.
3717
3718 no-netdb-exchange
3719 Disables requesting ICMP RTT database (NetDB).
3720
3721
3722 ==== AUTHENTICATION OPTIONS ====
3723
3724 login=user:password
3725 If this is a personal/workgroup proxy and your parent
3726 requires proxy authentication.
3727
3728 Note: The string can include URL escapes (i.e. %20 for
3729 spaces). This also means % must be written as %%.
3730
3731 login=PASSTHRU
3732 Send login details received from client to this peer.
3733 Both Proxy- and WWW-Authorization headers are passed
3734 without alteration to the peer.
3735 Authentication is not required by Squid for this to work.
3736
3737 Note: This will pass any form of authentication but
3738 only Basic auth will work through a proxy unless the
3739 connection-auth options are also used.
3740
3741 login=PASS Send login details received from client to this peer.
3742 Authentication is not required by this option.
3743
3744 If there are no client-provided authentication headers
3745 to pass on, but username and password are available
3746 from an external ACL user= and password= result tags
3747 they may be sent instead.
3748
3749 Note: To combine this with proxy_auth both proxies must
3750 share the same user database as HTTP only allows for
3751 a single login (one for proxy, one for origin server).
3752 Also be warned this will expose your users proxy
3753 password to the peer. USE WITH CAUTION
3754
3755 login=*:password
3756 Send the username to the upstream cache, but with a
3757 fixed password. This is meant to be used when the peer
3758 is in another administrative domain, but it is still
3759 needed to identify each user.
3760 The star can optionally be followed by some extra
3761 information which is added to the username. This can
3762 be used to identify this proxy to the peer, similar to
3763 the login=username:password option above.
3764
3765 login=NEGOTIATE
3766 If this is a personal/workgroup proxy and your parent
3767 requires a secure proxy authentication.
3768 The first principal from the default keytab or defined by
3769 the environment variable KRB5_KTNAME will be used.
3770
3771 WARNING: The connection may transmit requests from multiple
3772 clients. Negotiate often assumes end-to-end authentication
3773 and a single-client. Which is not strictly true here.
3774
3775 login=NEGOTIATE:principal_name
3776 If this is a personal/workgroup proxy and your parent
3777 requires a secure proxy authentication.
3778 The principal principal_name from the default keytab or
3779 defined by the environment variable KRB5_KTNAME will be
3780 used.
3781
3782 WARNING: The connection may transmit requests from multiple
3783 clients. Negotiate often assumes end-to-end authentication
3784 and a single-client. Which is not strictly true here.
3785
3786 connection-auth=on|off
3787 Tell Squid that this peer does or not support Microsoft
3788 connection oriented authentication, and any such
3789 challenges received from there should be ignored.
3790 Default is auto to automatically determine the status
3791 of the peer.
3792
3793 auth-no-keytab
3794 Do not use a keytab to authenticate to a peer when
3795 login=NEGOTIATE is specified. Let the GSSAPI
3796 implementation determine which already existing
3797 credentials cache to use instead.
3798
3799
3800 ==== SSL / HTTPS / TLS OPTIONS ====
3801
3802 tls Encrypt connections to this peer with TLS.
3803
3804 sslcert=/path/to/ssl/certificate
3805 A client X.509 certificate to use when connecting to
3806 this peer.
3807
3808 sslkey=/path/to/ssl/key
3809 The private key corresponding to sslcert above.
3810
3811 If sslkey= is not specified sslcert= is assumed to
3812 reference a PEM file containing both the certificate
3813 and private key.
3814
3815 sslcipher=... The list of valid SSL ciphers to use when connecting
3816 to this peer.
3817
3818 tls-min-version=1.N
3819 The minimum TLS protocol version to permit. To control
3820 SSLv3 use the tls-options= parameter.
3821 Supported Values: 1.0 (default), 1.1, 1.2
3822
3823 tls-options=... Specify various TLS implementation options.
3824
3825 OpenSSL options most important are:
3826
3827 NO_SSLv3 Disallow the use of SSLv3
3828
3829 SINGLE_DH_USE
3830 Always create a new key when using
3831 temporary/ephemeral DH key exchanges
3832
3833 NO_TICKET
3834 Disable use of RFC5077 session tickets.
3835 Some servers may have problems
3836 understanding the TLS extension due
3837 to ambiguous specification in RFC4507.
3838
3839 ALL Enable various bug workarounds
3840 suggested as "harmless" by OpenSSL
3841 Be warned that this reduces SSL/TLS
3842 strength to some attacks.
3843
3844 See the OpenSSL SSL_CTX_set_options documentation for a
3845 more complete list.
3846
3847 GnuTLS options most important are:
3848
3849 %NO_TICKETS
3850 Disable use of RFC5077 session tickets.
3851 Some servers may have problems
3852 understanding the TLS extension due
3853 to ambiguous specification in RFC4507.
3854
3855 See the GnuTLS Priority Strings documentation
3856 for a more complete list.
3857 http://www.gnutls.org/manual/gnutls.html#Priority-Strings
3858
3859 tls-cafile= PEM file containing CA certificates to use when verifying
3860 the peer certificate. May be repeated to load multiple files.
3861
3862 sslcapath=... A directory containing additional CA certificates to
3863 use when verifying the peer certificate.
3864 Requires OpenSSL or LibreSSL.
3865
3866 sslcrlfile=... A certificate revocation list file to use when
3867 verifying the peer certificate.
3868
3869 sslflags=... Specify various flags modifying the SSL implementation:
3870
3871 DONT_VERIFY_PEER
3872 Accept certificates even if they fail to
3873 verify.
3874
3875 DONT_VERIFY_DOMAIN
3876 Don't verify the peer certificate
3877 matches the server name
3878
3879 ssldomain= The peer name as advertised in it's certificate.
3880 Used for verifying the correctness of the received peer
3881 certificate. If not specified the peer hostname will be
3882 used.
3883
3884 front-end-https[=off|on|auto]
3885 Enable the "Front-End-Https: On" header needed when
3886 using Squid as a SSL frontend in front of Microsoft OWA.
3887 See MS KB document Q307347 for details on this header.
3888 If set to auto the header will only be added if the
3889 request is forwarded as a https:// URL.
3890
3891 tls-default-ca[=off]
3892 Whether to use the system Trusted CAs. Default is ON.
3893
3894 tls-no-npn Do not use the TLS NPN extension to advertise HTTP/1.1.
3895
3896 ==== GENERAL OPTIONS ====
3897
3898 connect-timeout=N
3899 A peer-specific connect timeout.
3900 Also see the peer_connect_timeout directive.
3901
3902 connect-fail-limit=N
3903 How many times connecting to a peer must fail before
3904 it is marked as down. Standby connection failures
3905 count towards this limit. Default is 10.
3906
3907 allow-miss Disable Squid's use of only-if-cached when forwarding
3908 requests to siblings. This is primarily useful when
3909 icp_hit_stale is used by the sibling. Excessive use
3910 of this option may result in forwarding loops. One way
3911 to prevent peering loops when using this option, is to
3912 deny cache peer usage on requests from a peer:
3913 acl fromPeer ...
3914 cache_peer_access peerName deny fromPeer
3915
3916 max-conn=N Limit the number of concurrent connections the Squid
3917 may open to this peer, including already opened idle
3918 and standby connections. There is no peer-specific
3919 connection limit by default.
3920
3921 A peer exceeding the limit is not used for new
3922 requests unless a standby connection is available.
3923
3924 max-conn currently works poorly with idle persistent
3925 connections: When a peer reaches its max-conn limit,
3926 and there are idle persistent connections to the peer,
3927 the peer may not be selected because the limiting code
3928 does not know whether Squid can reuse those idle
3929 connections.
3930
3931 standby=N Maintain a pool of N "hot standby" connections to an
3932 UP peer, available for requests when no idle
3933 persistent connection is available (or safe) to use.
3934 By default and with zero N, no such pool is maintained.
3935 N must not exceed the max-conn limit (if any).
3936
3937 At start or after reconfiguration, Squid opens new TCP
3938 standby connections until there are N connections
3939 available and then replenishes the standby pool as
3940 opened connections are used up for requests. A used
3941 connection never goes back to the standby pool, but
3942 may go to the regular idle persistent connection pool
3943 shared by all peers and origin servers.
3944
3945 Squid never opens multiple new standby connections
3946 concurrently. This one-at-a-time approach minimizes
3947 flooding-like effect on peers. Furthermore, just a few
3948 standby connections should be sufficient in most cases
3949 to supply most new requests with a ready-to-use
3950 connection.
3951
3952 Standby connections obey server_idle_pconn_timeout.
3953 For the feature to work as intended, the peer must be
3954 configured to accept and keep them open longer than
3955 the idle timeout at the connecting Squid, to minimize
3956 race conditions typical to idle used persistent
3957 connections. Default request_timeout and
3958 server_idle_pconn_timeout values ensure such a
3959 configuration.
3960
3961 name=xxx Unique name for the peer.
3962 Required if you have multiple cache_peers with the same hostname.
3963 Defaults to cache_peer hostname when not explicitly specified.
3964
3965 Other directives (e.g., cache_peer_access), cache manager reports,
3966 and cache.log messages use this name to refer to this cache_peer.
3967
3968 The cache_peer name value affects hashing-based peer selection
3969 methods (e.g., carp and sourcehash).
3970
3971 Can be used by outgoing access controls through the
3972 peername ACL type.
3973
3974 The name value preserves configured spelling, but name uniqueness
3975 checks and name-based search are case-insensitive.
3976
3977 no-tproxy Do not use the client-spoof TPROXY support when forwarding
3978 requests to this peer. Use normal address selection instead.
3979 This overrides the spoof_client_ip ACL.
3980
3981 proxy-only objects fetched from the peer will not be stored locally.
3982
3983 DOC_END
3984
3985 NAME: cache_peer_access
3986 TYPE: peer_access
3987 DEFAULT: none
3988 DEFAULT_DOC: No peer usage restrictions.
3989 LOC: none
3990 DOC_START
3991 Restricts usage of cache_peer proxies.
3992
3993 Usage:
3994 cache_peer_access peer-name allow|deny [!]aclname ...
3995
3996 For the required peer-name parameter, use either the value of the
3997 cache_peer name=value parameter or, if name=value is missing, the
3998 cache_peer hostname parameter.
3999
4000 This directive narrows down the selection of peering candidates, but
4001 does not determine the order in which the selected candidates are
4002 contacted. That order is determined by the peer selection algorithms
4003 (see PEER SELECTION sections in the cache_peer documentation).
4004
4005 If a deny rule matches, the corresponding peer will not be contacted
4006 for the current transaction -- Squid will not send ICP queries and
4007 will not forward HTTP requests to that peer. An allow match leaves
4008 the corresponding peer in the selection. The first match for a given
4009 peer wins for that peer.
4010
4011 The relative order of cache_peer_access directives for the same peer
4012 matters. The relative order of any two cache_peer_access directives
4013 for different peers does not matter. To ease interpretation, it is a
4014 good idea to group cache_peer_access directives for the same peer
4015 together.
4016
4017 A single cache_peer_access directive may be evaluated multiple times
4018 for a given transaction because individual peer selection algorithms
4019 may check it independently from each other. These redundant checks
4020 may be optimized away in future Squid versions.
4021
4022 This clause only supports fast acl types.
4023 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
4024
4025 DOC_END
4026
4027 NAME: neighbor_type_domain
4028 TYPE: hostdomaintype
4029 DEFAULT: none
4030 DEFAULT_DOC: The peer type from cache_peer directive is used for all requests to that peer.
4031 LOC: none
4032 DOC_START
4033 Modify the cache_peer neighbor type when passing requests
4034 about specific domains to the peer.
4035
4036 Usage:
4037 neighbor_type_domain peer-name parent|sibling domain...
4038
4039 For the required peer-name parameter, use either the value of the
4040 cache_peer name=value parameter or, if name=value is missing, the
4041 cache_peer hostname parameter.
4042
4043 For example:
4044 cache_peer foo.example.com parent 3128 3130
4045 neighbor_type_domain foo.example.com sibling .au .de
4046
4047 The above configuration treats all requests to foo.example.com as a
4048 parent proxy unless the request is for a .au or .de ccTLD domain name.
4049 DOC_END
4050
4051 NAME: dead_peer_timeout
4052 COMMENT: (seconds)
4053 DEFAULT: 10 seconds
4054 TYPE: time_t
4055 LOC: Config.Timeout.deadPeer
4056 DOC_START
4057 This controls how long Squid waits to declare a peer cache
4058 as "dead." If there are no ICP replies received in this
4059 amount of time, Squid will declare the peer dead and not
4060 expect to receive any further ICP replies. However, it
4061 continues to send ICP queries, and will mark the peer as
4062 alive upon receipt of the first subsequent ICP reply.
4063
4064 This timeout also affects when Squid expects to receive ICP
4065 replies from peers. If more than 'dead_peer' seconds have
4066 passed since the last ICP reply was received, Squid will not
4067 expect to receive an ICP reply on the next query. Thus, if
4068 your time between requests is greater than this timeout, you
4069 will see a lot of requests sent DIRECT to origin servers
4070 instead of to your parents.
4071 DOC_END
4072
4073 NAME: forward_max_tries
4074 DEFAULT: 25
4075 TYPE: int
4076 LOC: Config.forward_max_tries
4077 DOC_START
4078 Limits the number of attempts to forward the request.
4079
4080 For the purpose of this limit, Squid counts all high-level request
4081 forwarding attempts, including any same-destination retries after
4082 certain persistent connection failures and any attempts to use a
4083 different peer. However, these low-level attempts are not counted:
4084 * connection reopening attempts (enabled using connect_retries)
4085 * unfinished Happy Eyeballs connection attempts (prevented by setting
4086 happy_eyeballs_connect_limit to 0)
4087
4088 See also: forward_timeout and connect_retries.
4089 DOC_END
4090
4091 COMMENT_START
4092 MEMORY CACHE OPTIONS
4093 -----------------------------------------------------------------------------
4094 COMMENT_END
4095
4096 NAME: cache_mem
4097 COMMENT: (bytes)
4098 TYPE: b_size_t
4099 DEFAULT: 256 MB
4100 LOC: Config.memMaxSize
4101 DOC_START
4102 NOTE: THIS PARAMETER DOES NOT SPECIFY THE MAXIMUM PROCESS SIZE.
4103 IT ONLY PLACES A LIMIT ON HOW MUCH ADDITIONAL MEMORY SQUID WILL
4104 USE AS A MEMORY CACHE OF OBJECTS. SQUID USES MEMORY FOR OTHER
4105 THINGS AS WELL. SEE THE SQUID FAQ SECTION 8 FOR DETAILS.
4106
4107 'cache_mem' specifies the ideal amount of memory to be used
4108 for:
4109 * In-Transit objects
4110 * Hot Objects
4111 * Negative-Cached objects
4112
4113 Data for these objects are stored in 4 KB blocks. This
4114 parameter specifies the ideal upper limit on the total size of
4115 4 KB blocks allocated. In-Transit objects take the highest
4116 priority.
4117
4118 In-transit objects have priority over the others. When
4119 additional space is needed for incoming data, negative-cached
4120 and hot objects will be released. In other words, the
4121 negative-cached and hot objects will fill up any unused space
4122 not needed for in-transit objects.
4123
4124 If circumstances require, this limit will be exceeded.
4125 Specifically, if your incoming request rate requires more than
4126 'cache_mem' of memory to hold in-transit objects, Squid will
4127 exceed this limit to satisfy the new requests. When the load
4128 decreases, blocks will be freed until the high-water mark is
4129 reached. Thereafter, blocks will be used to store hot
4130 objects.
4131
4132 If shared memory caching is enabled, Squid does not use the shared
4133 cache space for in-transit objects, but they still consume as much
4134 local memory as they need. For more details about the shared memory
4135 cache, see memory_cache_shared.
4136 DOC_END
4137
4138 NAME: maximum_object_size_in_memory
4139 COMMENT: (bytes)
4140 TYPE: b_size_t
4141 DEFAULT: 512 KB
4142 LOC: Config.Store.maxInMemObjSize
4143 DOC_START
4144 Objects greater than this size will not be attempted to kept in
4145 the memory cache. This should be set high enough to keep objects
4146 accessed frequently in memory to improve performance whilst low
4147 enough to keep larger objects from hoarding cache_mem.
4148 DOC_END
4149
4150 NAME: memory_cache_shared
4151 COMMENT: on|off
4152 TYPE: YesNoNone
4153 LOC: Config.memShared
4154 DEFAULT: none
4155 DEFAULT_DOC: "on" where supported if doing memory caching with multiple SMP workers.
4156 DOC_START
4157 Controls whether the memory cache is shared among SMP workers.
4158
4159 The shared memory cache is meant to occupy cache_mem bytes and replace
4160 the non-shared memory cache, although some entities may still be
4161 cached locally by workers for now (e.g., internal and in-transit
4162 objects may be served from a local memory cache even if shared memory
4163 caching is enabled).
4164
4165 By default, the memory cache is shared if and only if all of the
4166 following conditions are satisfied: Squid runs in SMP mode with
4167 multiple workers, cache_mem is positive, and Squid environment
4168 supports required IPC primitives (e.g., POSIX shared memory segments
4169 and GCC-style atomic operations).
4170
4171 To avoid blocking locks, shared memory uses opportunistic algorithms
4172 that do not guarantee that every cachable entity that could have been
4173 shared among SMP workers will actually be shared.
4174 DOC_END
4175
4176 NAME: memory_cache_mode
4177 TYPE: memcachemode
4178 LOC: Config
4179 DEFAULT: always
4180 DEFAULT_DOC: Keep the most recently fetched objects in memory
4181 DOC_START
4182 Controls which objects to keep in the memory cache (cache_mem)
4183
4184 always Keep most recently fetched objects in memory (default)
4185
4186 disk Only disk cache hits are kept in memory, which means
4187 an object must first be cached on disk and then hit
4188 a second time before cached in memory.
4189
4190 network Only objects fetched from network is kept in memory
4191 DOC_END
4192
4193 NAME: memory_replacement_policy
4194 TYPE: removalpolicy
4195 LOC: Config.memPolicy
4196 DEFAULT: lru
4197 DOC_START
4198 The memory replacement policy parameter determines which
4199 objects are purged from memory when memory space is needed.
4200
4201 See cache_replacement_policy for details on algorithms.
4202 DOC_END
4203
4204 COMMENT_START
4205 DISK CACHE OPTIONS
4206 -----------------------------------------------------------------------------
4207 COMMENT_END
4208
4209 NAME: cache_replacement_policy
4210 TYPE: removalpolicy
4211 LOC: Config.replPolicy
4212 DEFAULT: lru
4213 DOC_START
4214 The cache replacement policy parameter determines which
4215 objects are evicted (replaced) when disk space is needed.
4216
4217 lru : Squid's original list based LRU policy
4218 heap GDSF : Greedy-Dual Size Frequency
4219 heap LFUDA: Least Frequently Used with Dynamic Aging
4220 heap LRU : LRU policy implemented using a heap
4221
4222 Applies to any cache_dir lines listed below this directive.
4223
4224 The LRU policies keeps recently referenced objects.
4225
4226 The heap GDSF policy optimizes object hit rate by keeping smaller
4227 popular objects in cache so it has a better chance of getting a
4228 hit. It achieves a lower byte hit rate than LFUDA though since
4229 it evicts larger (possibly popular) objects.
4230
4231 The heap LFUDA policy keeps popular objects in cache regardless of
4232 their size and thus optimizes byte hit rate at the expense of
4233 hit rate since one large, popular object will prevent many
4234 smaller, slightly less popular objects from being cached.
4235
4236 Both policies utilize a dynamic aging mechanism that prevents
4237 cache pollution that can otherwise occur with frequency-based
4238 replacement policies.
4239
4240 NOTE: if using the LFUDA replacement policy you should increase
4241 the value of maximum_object_size above its default of 4 MB to
4242 to maximize the potential byte hit rate improvement of LFUDA.
4243
4244 For more information about the GDSF and LFUDA cache replacement
4245 policies see http://www.hpl.hp.com/techreports/1999/HPL-1999-69.html
4246 and http://fog.hpl.external.hp.com/techreports/98/HPL-98-173.html.
4247 DOC_END
4248
4249 NAME: minimum_object_size
4250 COMMENT: (bytes)
4251 TYPE: b_int64_t
4252 DEFAULT: 0 KB
4253 DEFAULT_DOC: no limit
4254 LOC: Config.Store.minObjectSize
4255 DOC_START
4256 Objects smaller than this size will NOT be saved on disk. The
4257 value is specified in bytes, and the default is 0 KB, which
4258 means all responses can be stored.
4259 DOC_END
4260
4261 NAME: maximum_object_size
4262 COMMENT: (bytes)
4263 TYPE: b_int64_t
4264 DEFAULT: 4 MB
4265 LOC: Config.Store.maxObjectSize
4266 DOC_START
4267 Set the default value for max-size parameter on any cache_dir.
4268 The value is specified in bytes, and the default is 4 MB.
4269
4270 If you wish to get a high BYTES hit ratio, you should probably
4271 increase this (one 32 MB object hit counts for 3200 10KB
4272 hits).
4273
4274 If you wish to increase hit ratio more than you want to
4275 save bandwidth you should leave this low.
4276
4277 NOTE: if using the LFUDA replacement policy you should increase
4278 this value to maximize the byte hit rate improvement of LFUDA!
4279 See cache_replacement_policy for a discussion of this policy.
4280 DOC_END
4281
4282 NAME: cache_dir
4283 TYPE: cachedir
4284 DEFAULT: none
4285 DEFAULT_DOC: No disk cache. Store cache objects only in memory.
4286 LOC: Config.cacheSwap
4287 DOC_START
4288 Format:
4289 cache_dir Type Directory-Name Fs-specific-data [options]
4290
4291 You can specify multiple cache_dir lines to spread the
4292 cache among different disk partitions.
4293
4294 Type specifies the kind of storage system to use. Only "ufs"
4295 is built by default. To enable any of the other storage systems
4296 see the --enable-storeio configure option.
4297
4298 'Directory' is a top-level directory where cache swap
4299 files will be stored. If you want to use an entire disk
4300 for caching, this can be the mount-point directory.
4301 The directory must exist and be writable by the Squid
4302 process. Squid will NOT create this directory for you.
4303
4304 In SMP configurations, cache_dir must not precede the workers option
4305 and should use configuration macros or conditionals to give each
4306 worker interested in disk caching a dedicated cache directory.
4307
4308
4309 ==== The ufs store type ====
4310
4311 "ufs" is the old well-known Squid storage format that has always
4312 been there.
4313
4314 Usage:
4315 cache_dir ufs Directory-Name Mbytes L1 L2 [options]
4316
4317 'Mbytes' is the amount of disk space (MB) to use under this
4318 directory. The default is 100 MB. Change this to suit your
4319 configuration. Do NOT put the size of your disk drive here.
4320 Instead, if you want Squid to use the entire disk drive,
4321 subtract 20% and use that value.
4322
4323 'L1' is the number of first-level subdirectories which
4324 will be created under the 'Directory'. The default is 16.
4325
4326 'L2' is the number of second-level subdirectories which
4327 will be created under each first-level directory. The default
4328 is 256.
4329
4330
4331 ==== The aufs store type ====
4332
4333 "aufs" uses the same storage format as "ufs", utilizing
4334 POSIX-threads to avoid blocking the main Squid process on
4335 disk-I/O. This was formerly known in Squid as async-io.
4336
4337 Usage:
4338 cache_dir aufs Directory-Name Mbytes L1 L2 [options]
4339
4340 see argument descriptions under ufs above
4341
4342
4343 ==== The diskd store type ====
4344
4345 "diskd" uses the same storage format as "ufs", utilizing a
4346 separate process to avoid blocking the main Squid process on
4347 disk-I/O.
4348
4349 Usage:
4350 cache_dir diskd Directory-Name Mbytes L1 L2 [options] [Q1=n] [Q2=n]
4351
4352 see argument descriptions under ufs above
4353
4354 Q1 specifies the number of unacknowledged I/O requests when Squid
4355 stops opening new files. If this many messages are in the queues,
4356 Squid won't open new files. Default is 64
4357
4358 Q2 specifies the number of unacknowledged messages when Squid
4359 starts blocking. If this many messages are in the queues,
4360 Squid blocks until it receives some replies. Default is 72
4361
4362 When Q1 < Q2 (the default), the cache directory is optimized
4363 for lower response time at the expense of a decrease in hit
4364 ratio. If Q1 > Q2, the cache directory is optimized for
4365 higher hit ratio at the expense of an increase in response
4366 time.
4367
4368
4369 ==== The rock store type ====
4370
4371 Usage:
4372 cache_dir rock Directory-Name Mbytes [options]
4373
4374 The Rock Store type is a database-style storage. All cached
4375 entries are stored in a "database" file, using fixed-size slots.
4376 A single entry occupies one or more slots.
4377
4378 If possible, Squid using Rock Store creates a dedicated kid
4379 process called "disker" to avoid blocking Squid worker(s) on disk
4380 I/O. One disker kid is created for each rock cache_dir. Diskers
4381 are created only when Squid, running in daemon mode, has support
4382 for the IpcIo disk I/O module.
4383
4384 swap-timeout=msec: Squid will not start writing a miss to or
4385 reading a hit from disk if it estimates that the swap operation
4386 will take more than the specified number of milliseconds. By
4387 default and when set to zero, disables the disk I/O time limit
4388 enforcement. Ignored when using blocking I/O module because
4389 blocking synchronous I/O does not allow Squid to estimate the
4390 expected swap wait time.
4391
4392 max-swap-rate=swaps/sec: Artificially limits disk access using
4393 the specified I/O rate limit. Swap out requests that
4394 would cause the average I/O rate to exceed the limit are
4395 delayed. Individual swap in requests (i.e., hits or reads) are
4396 not delayed, but they do contribute to measured swap rate and
4397 since they are placed in the same FIFO queue as swap out
4398 requests, they may wait longer if max-swap-rate is smaller.
4399 This is necessary on file systems that buffer "too
4400 many" writes and then start blocking Squid and other processes
4401 while committing those writes to disk. Usually used together
4402 with swap-timeout to avoid excessive delays and queue overflows
4403 when disk demand exceeds available disk "bandwidth". By default
4404 and when set to zero, disables the disk I/O rate limit
4405 enforcement. Currently supported by IpcIo module only.
4406
4407 slot-size=bytes: The size of a database "record" used for
4408 storing cached responses. A cached response occupies at least
4409 one slot and all database I/O is done using individual slots so
4410 increasing this parameter leads to more disk space waste while
4411 decreasing it leads to more disk I/O overheads. Should be a
4412 multiple of your operating system I/O page size. Defaults to
4413 16KBytes. A housekeeping header is stored with each slot and
4414 smaller slot-sizes will be rejected. The header is smaller than
4415 100 bytes.
4416
4417
4418 ==== COMMON OPTIONS ====
4419
4420 no-store no new objects should be stored to this cache_dir.
4421
4422 min-size=n the minimum object size in bytes this cache_dir
4423 will accept. It's used to restrict a cache_dir
4424 to only store large objects (e.g. AUFS) while
4425 other stores are optimized for smaller objects
4426 (e.g. Rock).
4427 Defaults to 0.
4428
4429 max-size=n the maximum object size in bytes this cache_dir
4430 supports.
4431 The value in maximum_object_size directive sets
4432 the default unless more specific details are
4433 available (ie a small store capacity).
4434
4435 Note: To make optimal use of the max-size limits you should order
4436 the cache_dir lines with the smallest max-size value first.
4437
4438 CONFIG_START
4439
4440 # Uncomment and adjust the following to add a disk cache directory.
4441 #cache_dir ufs @DEFAULT_SWAP_DIR@ 100 16 256
4442 CONFIG_END
4443 DOC_END
4444
4445 NAME: store_dir_select_algorithm
4446 TYPE: string
4447 LOC: Config.store_dir_select_algorithm
4448 DEFAULT: least-load
4449 DOC_START
4450 How Squid selects which cache_dir to use when the response
4451 object will fit into more than one.
4452
4453 Regardless of which algorithm is used the cache_dir min-size
4454 and max-size parameters are obeyed. As such they can affect
4455 the selection algorithm by limiting the set of considered
4456 cache_dir.
4457
4458 Algorithms:
4459
4460 least-load
4461
4462 This algorithm is suited to caches with similar cache_dir
4463 sizes and disk speeds.
4464
4465 The disk with the least I/O pending is selected.
4466 When there are multiple disks with the same I/O load ranking
4467 the cache_dir with most available capacity is selected.
4468
4469 When a mix of cache_dir sizes are configured the faster disks
4470 have a naturally lower I/O loading and larger disks have more
4471 capacity. So space used to store objects and data throughput
4472 may be very unbalanced towards larger disks.
4473
4474
4475 round-robin
4476
4477 This algorithm is suited to caches with unequal cache_dir
4478 disk sizes.
4479
4480 Each cache_dir is selected in a rotation. The next suitable
4481 cache_dir is used.
4482
4483 Available cache_dir capacity is only considered in relation
4484 to whether the object will fit and meets the min-size and
4485 max-size parameters.
4486
4487 Disk I/O loading is only considered to prevent overload on slow
4488 disks. This algorithm does not spread objects by size, so any
4489 I/O loading per-disk may appear very unbalanced and volatile.
4490
4491 If several cache_dirs use similar min-size, max-size, or other
4492 limits to to reject certain responses, then do not group such
4493 cache_dir lines together, to avoid round-robin selection bias
4494 towards the first cache_dir after the group. Instead, interleave
4495 cache_dir lines from different groups. For example:
4496
4497 store_dir_select_algorithm round-robin
4498 cache_dir rock /hdd1 ... min-size=100000
4499 cache_dir rock /ssd1 ... max-size=99999
4500 cache_dir rock /hdd2 ... min-size=100000
4501 cache_dir rock /ssd2 ... max-size=99999
4502 cache_dir rock /hdd3 ... min-size=100000
4503 cache_dir rock /ssd3 ... max-size=99999
4504 DOC_END
4505
4506 NAME: paranoid_hit_validation
4507 COMMENT: time-units-small
4508 TYPE: time_nanoseconds
4509 DEFAULT: 0
4510 DEFAULT_DOC: validation disabled
4511 LOC: Config.paranoid_hit_validation
4512 DOC_START
4513 Controls whether Squid should perform paranoid validation of cache entry
4514 metadata integrity every time a cache entry is hit. This low-level
4515 validation should always succeed. Each failed validation results in a
4516 cache miss, a BUG line reported to cache.log, and the invalid entry
4517 marked as unusable (and eventually purged from the cache).
4518
4519 Squid can only validate shared cache memory and rock cache_dir entries.
4520
4521 * Zero (default) value means that the validation is disabled.
4522
4523 * Positive values enable validation:
4524 - values less than 1 day approximate the maximum time that Squid is allowed
4525 to spend validating a single cache hit.
4526 - values greater or equal to 1 day are considered as no limitation:
4527 in this case all checks will be performed, regardless of how much time
4528 they take.
4529
4530 Hits are usually stored using 16KB slots (for rock, the size is
4531 configurable via cache_dir slot-size). Larger hits require scanning more
4532 slots and, hence, take more time. When validation is enabled, at least one
4533 slot is always validated, regardless of the configured time limit.
4534
4535 A worker process validating an entry cannot do anything else (i.e. the
4536 validation is blocking). The validation overhead is environment dependent,
4537 but developers have observed Squid spending 3-10 microseconds to check each
4538 slot of a Rock or shared memory hit entry. If Squid cuts validation short
4539 because it runs out of configured time, it treats the entry as valid.
4540
4541 When hit validation is enabled, its statistics is included in Cache
4542 Manager mgr:counters, mgr:5min, and mgr:60min reports.
4543 DOC_END
4544
4545 NAME: max_open_disk_fds
4546 TYPE: int
4547 LOC: Config.max_open_disk_fds
4548 DEFAULT: 0
4549 DEFAULT_DOC: no limit
4550 DOC_START
4551 To avoid having disk as the I/O bottleneck Squid can optionally
4552 bypass the on-disk cache if more than this amount of disk file
4553 descriptors are open.
4554
4555 A value of 0 indicates no limit.
4556 DOC_END
4557
4558 NAME: cache_swap_low
4559 COMMENT: (percent, 0-100)
4560 TYPE: int
4561 DEFAULT: 90
4562 LOC: Config.Swap.lowWaterMark
4563 DOC_START
4564 The low-water mark for AUFS/UFS/diskd cache object eviction by
4565 the cache_replacement_policy algorithm.
4566
4567 Removal begins when the swap (disk) usage of a cache_dir is
4568 above this low-water mark and attempts to maintain utilization
4569 near the low-water mark.
4570
4571 As swap utilization increases towards the high-water mark set
4572 by cache_swap_high object eviction becomes more aggressive.
4573
4574 The value difference in percentages between low- and high-water
4575 marks represent an eviction rate of 300 objects per second and
4576 the rate continues to scale in aggressiveness by multiples of
4577 this above the high-water mark.
4578
4579 Defaults are 90% and 95%. If you have a large cache, 5% could be
4580 hundreds of MB. If this is the case you may wish to set these
4581 numbers closer together.
4582
4583 See also cache_swap_high and cache_replacement_policy
4584 DOC_END
4585
4586 NAME: cache_swap_high
4587 COMMENT: (percent, 0-100)
4588 TYPE: int
4589 DEFAULT: 95
4590 LOC: Config.Swap.highWaterMark
4591 DOC_START
4592 The high-water mark for AUFS/UFS/diskd cache object eviction by
4593 the cache_replacement_policy algorithm.
4594
4595 Removal begins when the swap (disk) usage of a cache_dir is
4596 above the low-water mark set by cache_swap_low and attempts to
4597 maintain utilization near the low-water mark.
4598
4599 As swap utilization increases towards this high-water mark object
4600 eviction becomes more aggressive.
4601
4602 The value difference in percentages between low- and high-water
4603 marks represent an eviction rate of 300 objects per second and
4604 the rate continues to scale in aggressiveness by multiples of
4605 this above the high-water mark.
4606
4607 Defaults are 90% and 95%. If you have a large cache, 5% could be
4608 hundreds of MB. If this is the case you may wish to set these
4609 numbers closer together.
4610
4611 See also cache_swap_low and cache_replacement_policy
4612 DOC_END
4613
4614 COMMENT_START
4615 LOGFILE OPTIONS
4616 -----------------------------------------------------------------------------
4617 COMMENT_END
4618
4619 NAME: logformat
4620 TYPE: logformat
4621 LOC: Log::TheConfig
4622 DEFAULT: none
4623 DEFAULT_DOC: The format definitions squid, common, combined, referrer, useragent are built in.
4624 DOC_START
4625 Usage:
4626
4627 logformat <name> <format specification>
4628
4629 Defines an access log format.
4630
4631 The <format specification> is a string with embedded % format codes
4632
4633 % format codes all follow the same basic structure where all
4634 components but the formatcode are optional and usually unnecessary,
4635 especially when dealing with common codes.
4636
4637 % [encoding] [-] [[0]width] [{arg}] formatcode [{arg}]
4638
4639 encoding escapes or otherwise protects "special" characters:
4640
4641 " Quoted string encoding where quote(") and
4642 backslash(\) characters are \-escaped while
4643 CR, LF, and TAB characters are encoded as \r,
4644 \n, and \t two-character sequences.
4645
4646 [ Custom Squid encoding where percent(%), square
4647 brackets([]), backslash(\) and characters with
4648 codes outside of [32,126] range are %-encoded.
4649 SP is not encoded. Used by log_mime_hdrs.
4650
4651 # URL encoding (a.k.a. percent-encoding) where
4652 all URL unsafe and control characters (per RFC
4653 1738) are %-encoded.
4654
4655 / Shell-like encoding where quote(") and
4656 backslash(\) characters are \-escaped while CR
4657 and LF characters are encoded as \r and \n
4658 two-character sequences. Values containing SP
4659 character(s) are surrounded by quotes(").
4660
4661 ' Raw/as-is encoding with no escaping/quoting.
4662
4663 Default encoding: When no explicit encoding is
4664 specified, each %code determines its own encoding.
4665 Most %codes use raw/as-is encoding, but some codes use
4666 a so called "pass-through URL encoding" where all URL
4667 unsafe and control characters (per RFC 1738) are
4668 %-encoded, but the percent character(%) is left as is.
4669
4670 - left aligned
4671
4672 width minimum and/or maximum field width:
4673 [width_min][.width_max]
4674 When minimum starts with 0, the field is zero-padded.
4675 String values exceeding maximum width are truncated.
4676
4677 {arg} argument such as header name etc. This field may be
4678 placed before or after the token, but not both at once.
4679
4680 Format codes:
4681
4682 % a literal % character
4683 sn Unique sequence number per log line entry
4684 err_code The ID of an error response served by Squid or
4685 a similar internal error identifier.
4686 err_detail Additional err_code-dependent error information.
4687 note The annotation specified by the argument. Also
4688 logs the adaptation meta headers set by the
4689 adaptation_meta configuration parameter.
4690 If no argument given all annotations logged.
4691 The argument may include a separator to use with
4692 annotation values:
4693 name[:separator]
4694 By default, multiple note values are separated with ","
4695 and multiple notes are separated with "\r\n".
4696 When logging named notes with %{name}note, the
4697 explicitly configured separator is used between note
4698 values. When logging all notes with %note, the
4699 explicitly configured separator is used between
4700 individual notes. There is currently no way to
4701 specify both value and notes separators when logging
4702 all notes with %note.
4703 master_xaction The master transaction identifier is an unsigned
4704 integer. These IDs are guaranteed to monotonically
4705 increase within a single worker process lifetime, with
4706 higher values corresponding to transactions that were
4707 accepted or initiated later. Due to current implementation
4708 deficiencies, some IDs are skipped (i.e. never logged).
4709 Concurrent workers and restarted workers use similar,
4710 overlapping sequences of master transaction IDs.
4711
4712 Connection related format codes:
4713
4714 >a Client source IP address
4715 >A Client FQDN
4716 >p Client source port
4717 >eui Client source EUI (MAC address, EUI-48 or EUI-64 identifier)
4718 >la Local IP address the client connected to
4719 >lp Local port number the client connected to
4720 >qos Client connection TOS/DSCP value set by Squid
4721 >nfmark Client connection netfilter packet MARK set by Squid
4722
4723 transport::>connection_id Identifies a transport connection
4724 accepted by Squid (e.g., a connection carrying the
4725 logged HTTP request). Currently, Squid only supports
4726 TCP transport connections.
4727
4728 The logged identifier is an unsigned integer. These
4729 IDs are guaranteed to monotonically increase within a
4730 single worker process lifetime, with higher values
4731 corresponding to connections that were accepted later.
4732 Many IDs are skipped (i.e. never logged). Concurrent
4733 workers and restarted workers use similar, partially
4734 overlapping sequences of IDs.
4735
4736 la Local listening IP address the client connection was connected to.
4737 lp Local listening port number the client connection was connected to.
4738
4739 <a Server IP address of the last server or peer connection
4740 <A Server FQDN or peer name
4741 <p Server port number of the last server or peer connection
4742 <la Local IP address of the last server or peer connection
4743 <lp Local port number of the last server or peer connection
4744 <qos Server connection TOS/DSCP value set by Squid
4745 <nfmark Server connection netfilter packet MARK set by Squid
4746
4747 >handshake Raw client handshake
4748 Initial client bytes received by Squid on a newly
4749 accepted TCP connection or inside a just established
4750 CONNECT tunnel. Squid stops accumulating handshake
4751 bytes as soon as the handshake parser succeeds or
4752 fails (determining whether the client is using the
4753 expected protocol).
4754
4755 For HTTP clients, the handshake is the request line.
4756 For TLS clients, the handshake consists of all TLS
4757 records up to and including the TLS record that
4758 contains the last byte of the first ClientHello
4759 message. For clients using an unsupported protocol,
4760 this field contains the bytes received by Squid at the
4761 time of the handshake parsing failure.
4762
4763 See the on_unsupported_protocol directive for more
4764 information on Squid handshake traffic expectations.
4765
4766 Current support is limited to these contexts:
4767 - http_port connections, but only when the
4768 on_unsupported_protocol directive is in use.
4769 - https_port connections (and CONNECT tunnels) that
4770 are subject to the ssl_bump peek or stare action.
4771
4772 To protect binary handshake data, this field is always
4773 base64-encoded (RFC 4648 Section 4). If logformat
4774 field encoding is configured, that encoding is applied
4775 on top of base64. Otherwise, the computed base64 value
4776 is recorded as is.
4777
4778 Time related format codes:
4779
4780 ts Seconds since epoch
4781 tu subsecond time (milliseconds)
4782 tl Local time. Optional strftime format argument
4783 default %d/%b/%Y:%H:%M:%S %z
4784 tg GMT time. Optional strftime format argument
4785 default %d/%b/%Y:%H:%M:%S %z
4786 tr Response time (milliseconds)
4787 dt Total time spent making DNS lookups (milliseconds)
4788 tS Approximate master transaction start time in
4789 <full seconds since epoch>.<fractional seconds> format.
4790 Currently, Squid considers the master transaction
4791 started when a complete HTTP request header initiating
4792 the transaction is received from the client. This is
4793 the same value that Squid uses to calculate transaction
4794 response time when logging %tr to access.log. Currently,
4795 Squid uses millisecond resolution for %tS values,
4796 similar to the default access.log "current time" field
4797 (%ts.%03tu).
4798
4799 Access Control related format codes:
4800
4801 et Tag returned by external acl
4802 ea Log string returned by external acl
4803 un User name (any available)
4804 ul User name from authentication
4805 ue User name from external acl helper
4806 ui User name from ident
4807 un A user name. Expands to the first available name
4808 from the following list of information sources:
4809 - authenticated user name, like %ul
4810 - user name supplied by an external ACL, like %ue
4811 - SSL client name, like %us
4812 - ident user name, like %ui
4813 credentials Client credentials. The exact meaning depends on
4814 the authentication scheme: For Basic authentication,
4815 it is the password; for Digest, the realm sent by the
4816 client; for NTLM and Negotiate, the client challenge
4817 or client credentials prefixed with "YR " or "KK ".
4818
4819 HTTP related format codes:
4820
4821 REQUEST
4822
4823 [http::]rm Request method (GET/POST etc)
4824 [http::]>rm Request method from client
4825 [http::]<rm Request method sent to server or peer
4826
4827 [http::]ru Request URL received (or computed) and sanitized
4828
4829 Logs request URI received from the client, a
4830 request adaptation service, or a request
4831 redirector (whichever was applied last).
4832
4833 Computed URLs are URIs of internally generated
4834 requests and various "error:..." URIs.
4835
4836 Honors strip_query_terms and uri_whitespace.
4837
4838 This field is not encoded by default. Encoding
4839 this field using variants of %-encoding will
4840 clash with uri_whitespace modifications that
4841 also use %-encoding.
4842
4843 [http::]>ru Request URL received from the client (or computed)
4844
4845 Computed URLs are URIs of internally generated
4846 requests and various "error:..." URIs.
4847
4848 Unlike %ru, this request URI is not affected
4849 by request adaptation, URL rewriting services,
4850 and strip_query_terms.
4851
4852 Honors uri_whitespace.
4853
4854 This field is using pass-through URL encoding
4855 by default. Encoding this field using other
4856 variants of %-encoding will clash with
4857 uri_whitespace modifications that also use
4858 %-encoding.
4859
4860 [http::]<ru Request URL sent to server or peer
4861 [http::]>rs Request URL scheme from client
4862 [http::]<rs Request URL scheme sent to server or peer
4863 [http::]>rd Request URL domain from client
4864 [http::]<rd Request URL domain sent to server or peer
4865 [http::]>rP Request URL port from client
4866 [http::]<rP Request URL port sent to server or peer
4867 [http::]rp Request URL path excluding hostname
4868 [http::]>rp Request URL path excluding hostname from client
4869 [http::]<rp Request URL path excluding hostname sent to server or peer
4870 [http::]rv Request protocol version
4871 [http::]>rv Request protocol version from client
4872 [http::]<rv Request protocol version sent to server or peer
4873
4874 [http::]>h Original received request header.
4875 Usually differs from the request header sent by
4876 Squid, although most fields are often preserved.
4877 Accepts optional header field name/value filter
4878 argument using name[:[separator]element] format.
4879 [http::]>ha Received request header after adaptation and
4880 redirection (pre-cache REQMOD vectoring point).
4881 Usually differs from the request header sent by
4882 Squid, although most fields are often preserved.
4883 Optional header name argument as for >h
4884
4885 RESPONSE
4886
4887 [http::]<Hs HTTP status code received from the next hop
4888 [http::]>Hs HTTP status code sent to the client
4889
4890 [http::]<h Reply header. Optional header name argument
4891 as for >h
4892
4893 [http::]mt MIME content type
4894
4895
4896 SIZE COUNTERS
4897
4898 [http::]st Total size of request + reply traffic with client
4899 [http::]>st Total size of request received from client.
4900 Excluding chunked encoding bytes.
4901 [http::]<st Total size of reply sent to client (after adaptation)
4902
4903 [http::]>sh Size of request headers received from client
4904 [http::]<sh Size of reply headers sent to client (after adaptation)
4905
4906 [http::]<sH Reply high offset sent
4907 [http::]<sS Upstream object size
4908
4909 [http::]<bs Number of HTTP-equivalent message body bytes
4910 received from the next hop, excluding chunked
4911 transfer encoding and control messages.
4912 Generated FTP listings are treated as
4913 received bodies.
4914
4915 TIMING
4916
4917 [http::]<pt Peer response time in milliseconds. The timer starts
4918 when the last request byte is sent to the next hop
4919 and stops when the last response byte is received.
4920 [http::]<tt Total time in milliseconds. The timer
4921 starts with the first connect request (or write I/O)
4922 sent to the first selected peer. The timer stops
4923 with the last I/O with the last peer.
4924
4925 Squid handling related format codes:
4926
4927 Ss Squid request status (TCP_MISS etc)
4928 Sh Squid hierarchy status (DEFAULT_PARENT etc)
4929
4930 SSL-related format codes:
4931
4932 ssl::bump_mode SslBump decision for the transaction:
4933
4934 For CONNECT requests that initiated bumping of
4935 a connection and for any request received on
4936 an already bumped connection, Squid logs the
4937 corresponding SslBump mode ("splice", "bump",
4938 "peek", "stare", "terminate", "server-first"
4939 or "client-first"). See the ssl_bump option
4940 for more information about these modes.
4941
4942 A "none" token is logged for requests that
4943 triggered "ssl_bump" ACL evaluation matching
4944 a "none" rule.
4945
4946 In all other cases, a single dash ("-") is
4947 logged.
4948
4949 ssl::>sni SSL client SNI sent to Squid.
4950
4951 ssl::>cert_subject
4952 The Subject field of the received client
4953 SSL certificate or a dash ('-') if Squid has
4954 received an invalid/malformed certificate or
4955 no certificate at all. Consider encoding the
4956 logged value because Subject often has spaces.
4957
4958 ssl::>cert_issuer
4959 The Issuer field of the received client
4960 SSL certificate or a dash ('-') if Squid has
4961 received an invalid/malformed certificate or
4962 no certificate at all. Consider encoding the
4963 logged value because Issuer often has spaces.
4964
4965 ssl::<cert_subject
4966 The Subject field of the received server
4967 TLS certificate or a dash ('-') if this is
4968 not available. Consider encoding the logged
4969 value because Subject often has spaces.
4970
4971 ssl::<cert_issuer
4972 The Issuer field of the received server
4973 TLS certificate or a dash ('-') if this is
4974 not available. Consider encoding the logged
4975 value because Issuer often has spaces.
4976
4977 ssl::<cert
4978 The received server x509 certificate in PEM
4979 format, including BEGIN and END lines (or a
4980 dash ('-') if the certificate is unavailable).
4981
4982 WARNING: Large certificates will exceed the
4983 current 8KB access.log record limit, resulting
4984 in truncated records. Such truncation usually
4985 happens in the middle of a record field. The
4986 limit applies to all access logging modules.
4987
4988 The logged certificate may have failed
4989 validation and may not be trusted by Squid.
4990 This field does not include any intermediate
4991 certificates that may have been received from
4992 the server or fetched during certificate
4993 validation process.
4994
4995 Currently, Squid only collects server
4996 certificates during step3 of SslBump
4997 processing; connections that were not subject
4998 to ssl_bump rules or that did not match a peek
4999 or stare rule at step2 will not have the
5000 server certificate information.
5001
5002 This field is using pass-through URL encoding
5003 by default.
5004
5005 ssl::<cert_errors
5006 The list of certificate validation errors
5007 detected by Squid (including OpenSSL and
5008 certificate validation helper components). The
5009 errors are listed in the discovery order. By
5010 default, the error codes are separated by ':'.
5011 Accepts an optional separator argument.
5012
5013 %ssl::>negotiated_version The negotiated TLS version of the
5014 client connection.
5015
5016 %ssl::<negotiated_version The negotiated TLS version of the
5017 last server or peer connection.
5018
5019 %ssl::>received_hello_version The TLS version of the Hello
5020 message received from TLS client.
5021
5022 %ssl::<received_hello_version The TLS version of the Hello
5023 message received from TLS server.
5024
5025 %ssl::>received_supported_version The maximum TLS version
5026 supported by the TLS client.
5027
5028 %ssl::<received_supported_version The maximum TLS version
5029 supported by the TLS server.
5030
5031 %ssl::>negotiated_cipher The negotiated cipher of the
5032 client connection.
5033
5034 %ssl::<negotiated_cipher The negotiated cipher of the
5035 last server or peer connection.
5036
5037 If ICAP is enabled, the following code becomes available (as
5038 well as ICAP log codes documented with the icap_log option):
5039
5040 icap::tt Total ICAP "blocking" time for the HTTP transaction. The
5041 timer ticks while Squid checks adaptation_access and while
5042 ICAP transaction(s) expect ICAP response headers, including
5043 the embedded adapted HTTP message headers (where applicable).
5044 This measurement is meant to estimate ICAP impact on HTTP
5045 transaction response times, but it does not currently account
5046 for slow ICAP response body delivery blocking HTTP progress.
5047
5048 Once Squid receives the final ICAP response headers (e.g.,
5049 ICAP 200 or 204) and the associated adapted HTTP message
5050 headers (if any) from the ICAP service, the corresponding ICAP
5051 transaction stops affecting this measurement, even though the
5052 transaction itself may continue for a long time (e.g., to
5053 finish sending the ICAP request and/or to finish receiving the
5054 ICAP response body).
5055
5056 When "blocking" sections of multiple concurrent ICAP
5057 transactions overlap in time, the overlapping segment is
5058 counted only once.
5059
5060 To see complete ICAP transaction response times (rather than
5061 the cumulative effect of their blocking sections) use the
5062 %adapt::all_trs logformat code or the icap_log directive.
5063
5064 If adaptation is enabled the following codes become available:
5065
5066 adapt::<last_h The header of the last ICAP response or
5067 meta-information from the last eCAP
5068 transaction related to the HTTP transaction.
5069 Like <h, accepts an optional header name
5070 argument.
5071
5072 adapt::sum_trs Summed adaptation transaction response
5073 times recorded as a comma-separated list in
5074 the order of transaction start time. Each time
5075 value is recorded as an integer number,
5076 representing response time of one or more
5077 adaptation (ICAP or eCAP) transaction in
5078 milliseconds. When a failed transaction is
5079 being retried or repeated, its time is not
5080 logged individually but added to the
5081 replacement (next) transaction. Lifetimes of individually
5082 listed adaptation transactions may overlap.
5083 See also: %icap::tt and %adapt::all_trs.
5084
5085 adapt::all_trs All adaptation transaction response times.
5086 Same as %adapt::sum_trs but response times of
5087 individual transactions are never added
5088 together. Instead, all transaction response
5089 times are recorded individually.
5090
5091 You can prefix adapt::*_trs format codes with adaptation
5092 service name in curly braces to record response time(s) specific
5093 to that service. For example: %{my_service}adapt::sum_trs
5094
5095 Format codes related to the PROXY protocol:
5096
5097 proxy_protocol::>h PROXY protocol header, including optional TLVs.
5098
5099 Supports the same field and element reporting/extraction logic
5100 as %http::>h. For configuration and reporting purposes, Squid
5101 maps each PROXY TLV to an HTTP header field: the TLV type
5102 (configured as a decimal integer) is the field name, and the
5103 TLV value is the field value. All TLVs of "LOCAL" connections
5104 (in PROXY protocol terminology) are currently skipped/ignored.
5105
5106 Squid also maps the following standard PROXY protocol header
5107 blocks to pseudo HTTP headers (their names use PROXY
5108 terminology and start with a colon, following HTTP tradition
5109 for pseudo headers): :command, :version, :src_addr, :dst_addr,
5110 :src_port, and :dst_port.
5111
5112 Without optional parameters, this logformat code logs
5113 pseudo headers and TLVs.
5114
5115 This format code uses pass-through URL encoding by default.
5116
5117 Example:
5118 # relay custom PROXY TLV #224 to adaptation services
5119 adaptation_meta Client-Foo "%proxy_protocol::>h{224}"
5120
5121 See also: %http::>h
5122
5123 The default formats available (which do not need re-defining) are:
5124
5125 logformat squid %ts.%03tu %6tr %>a %Ss/%03>Hs %<st %rm %ru %[un %Sh/%<a %mt
5126 logformat common %>a %[ui %[un [%tl] "%rm %ru HTTP/%rv" %>Hs %<st %Ss:%Sh
5127 logformat combined %>a %[ui %[un [%tl] "%rm %ru HTTP/%rv" %>Hs %<st "%{Referer}>h" "%{User-Agent}>h" %Ss:%Sh
5128 logformat referrer %ts.%03tu %>a %{Referer}>h %ru
5129 logformat useragent %>a [%tl] "%{User-Agent}>h"
5130
5131 NOTE: When the log_mime_hdrs directive is set to ON.
5132 The squid, common and combined formats have a safely encoded copy
5133 of the mime headers appended to each line within a pair of brackets.
5134
5135 NOTE: The common and combined formats are not quite true to the Apache definition.
5136 The logs from Squid contain an extra status and hierarchy code appended.
5137
5138 DOC_END
5139
5140 NAME: access_log cache_access_log
5141 TYPE: access_log
5142 LOC: Config.Log.accesslogs
5143 DEFAULT_IF_NONE: daemon:@DEFAULT_ACCESS_LOG@ squid
5144 DOC_START
5145 Configures whether and how Squid logs HTTP and ICP transactions.
5146 If access logging is enabled, a single line is logged for every
5147 matching HTTP or ICP request. The recommended directive formats are:
5148
5149 access_log <module>:<place> [option ...] [acl acl ...]
5150 access_log none [acl acl ...]
5151
5152 The following directive format is accepted but may be deprecated:
5153 access_log <module>:<place> [<logformat name> [acl acl ...]]
5154
5155 In most cases, the first ACL name must not contain the '=' character
5156 and should not be equal to an existing logformat name. You can always
5157 start with an 'all' ACL to work around those restrictions.
5158
5159 Will log to the specified module:place using the specified format (which
5160 must be defined in a logformat directive) those entries which match
5161 ALL the acl's specified (which must be defined in acl clauses).
5162 If no acl is specified, all requests will be logged to this destination.
5163
5164 ===== Available options for the recommended directive format =====
5165
5166 logformat=name Names log line format (either built-in or
5167 defined by a logformat directive). Defaults
5168 to 'squid'.
5169
5170 buffer-size=64KB Defines approximate buffering limit for log
5171 records (see buffered_logs). Squid should not
5172 keep more than the specified size and, hence,
5173 should flush records before the buffer becomes
5174 full to avoid overflows under normal
5175 conditions (the exact flushing algorithm is
5176 module-dependent though). The on-error option
5177 controls overflow handling.
5178
5179 on-error=die|drop Defines action on unrecoverable errors. The
5180 'drop' action ignores (i.e., does not log)
5181 affected log records. The default 'die' action
5182 kills the affected worker. The drop action
5183 support has not been tested for modules other
5184 than tcp.
5185
5186 rotate=N Specifies the number of log file rotations to
5187 make when you run 'squid -k rotate'. The default
5188 is to obey the logfile_rotate directive. Setting
5189 rotate=0 will disable the file name rotation,
5190 but the log files are still closed and re-opened.
5191 This will enable you to rename the logfiles
5192 yourself just before sending the rotate signal.
5193 Only supported by the stdio module.
5194
5195 ===== Modules Currently available =====
5196
5197 none Do not log any requests matching these ACL.
5198 Do not specify Place or logformat name.
5199
5200 stdio Write each log line to disk immediately at the completion of
5201 each request.
5202 Place: the filename and path to be written.
5203
5204 daemon Very similar to stdio. But instead of writing to disk the log
5205 line is passed to a daemon helper for asychronous handling instead.
5206 Place: varies depending on the daemon.
5207
5208 log_file_daemon Place: the file name and path to be written.
5209
5210 syslog To log each request via syslog facility.
5211 Place: The syslog facility and priority level for these entries.
5212 Place Format: facility.priority
5213
5214 where facility could be any of:
5215 authpriv, daemon, local0 ... local7 or user.
5216
5217 And priority could be any of:
5218 err, warning, notice, info, debug.
5219
5220 udp To send each log line as text data to a UDP receiver.
5221 Place: The destination host name or IP and port.
5222 Place Format: //host:port
5223
5224 tcp To send each log line as text data to a TCP receiver.
5225 Lines may be accumulated before sending (see buffered_logs).
5226 Place: The destination host name or IP and port.
5227 Place Format: //host:port
5228
5229 Default:
5230 access_log daemon:@DEFAULT_ACCESS_LOG@ squid
5231 DOC_END
5232
5233 NAME: icap_log
5234 TYPE: access_log
5235 IFDEF: ICAP_CLIENT
5236 LOC: Config.Log.icaplogs
5237 DEFAULT: none
5238 DOC_START
5239 ICAP log files record ICAP transaction summaries, one line per
5240 transaction.
5241
5242 The icap_log option format is:
5243 icap_log <filepath> [<logformat name> [acl acl ...]]
5244 icap_log none [acl acl ...]]
5245
5246 Please see access_log option documentation for details. The two
5247 kinds of logs share the overall configuration approach and many
5248 features.
5249
5250 ICAP processing of a single HTTP message or transaction may
5251 require multiple ICAP transactions. In such cases, multiple
5252 ICAP transaction log lines will correspond to a single access
5253 log line.
5254
5255 ICAP log supports many access.log logformat %codes. In ICAP context,
5256 HTTP message-related %codes are applied to the HTTP message embedded
5257 in an ICAP message. Logformat "%http::>..." codes are used for HTTP
5258 messages embedded in ICAP requests while "%http::<..." codes are used
5259 for HTTP messages embedded in ICAP responses. For example:
5260
5261 http::>h To-be-adapted HTTP message headers sent by Squid to
5262 the ICAP service. For REQMOD transactions, these are
5263 HTTP request headers. For RESPMOD, these are HTTP
5264 response headers, but Squid currently cannot log them
5265 (i.e., %http::>h will expand to "-" for RESPMOD).
5266
5267 http::<h Adapted HTTP message headers sent by the ICAP
5268 service to Squid (i.e., HTTP request headers in regular
5269 REQMOD; HTTP response headers in RESPMOD and during
5270 request satisfaction in REQMOD).
5271
5272 ICAP OPTIONS transactions do not embed HTTP messages.
5273
5274 Several logformat codes below deal with ICAP message bodies. An ICAP
5275 message body, if any, typically includes a complete HTTP message
5276 (required HTTP headers plus optional HTTP message body). When
5277 computing HTTP message body size for these logformat codes, Squid
5278 either includes or excludes chunked encoding overheads; see
5279 code-specific documentation for details.
5280
5281 For Secure ICAP services, all size-related information is currently
5282 computed before/after TLS encryption/decryption, as if TLS was not
5283 in use at all.
5284
5285 The following format codes are also available for ICAP logs:
5286
5287 icap::<A ICAP server IP address. Similar to <A.
5288
5289 icap::<service_name ICAP service name from the icap_service
5290 option in Squid configuration file.
5291
5292 icap::ru ICAP Request-URI. Similar to ru.
5293
5294 icap::rm ICAP request method (REQMOD, RESPMOD, or
5295 OPTIONS). Similar to existing rm.
5296
5297 icap::>st The total size of the ICAP request sent to the ICAP
5298 server (ICAP headers + ICAP body), including chunking
5299 metadata (if any).
5300
5301 icap::<st The total size of the ICAP response received from the
5302 ICAP server (ICAP headers + ICAP body), including
5303 chunking metadata (if any).
5304
5305 icap::<bs The size of the ICAP response body received from the
5306 ICAP server, excluding chunking metadata (if any).
5307
5308 icap::tr Transaction response time (in
5309 milliseconds). The timer starts when
5310 the ICAP transaction is created and
5311 stops when the transaction is completed.
5312 Similar to tr.
5313
5314 icap::tio Transaction I/O time (in milliseconds). The
5315 timer starts when the first ICAP request
5316 byte is scheduled for sending. The timers
5317 stops when the last byte of the ICAP response
5318 is received.
5319
5320 icap::to Transaction outcome: ICAP_ERR* for all
5321 transaction errors, ICAP_OPT for OPTION
5322 transactions, ICAP_ECHO for 204
5323 responses, ICAP_MOD for message
5324 modification, and ICAP_SAT for request
5325 satisfaction. Similar to Ss.
5326
5327 icap::Hs ICAP response status code. Similar to Hs.
5328
5329 icap::>h ICAP request header(s). Similar to >h.
5330
5331 icap::<h ICAP response header(s). Similar to <h.
5332
5333 The default ICAP log format, which can be used without an explicit
5334 definition, is called icap_squid:
5335
5336 logformat icap_squid %ts.%03tu %6icap::tr %>A %icap::to/%03icap::Hs %icap::<st %icap::rm %icap::ru %un -/%icap::<A -
5337
5338 See also: logformat and %adapt::<last_h
5339 DOC_END
5340
5341 NAME: logfile_daemon
5342 TYPE: string
5343 DEFAULT: @DEFAULT_LOGFILED@
5344 LOC: Log::TheConfig.logfile_daemon
5345 DOC_START
5346 Specify the path to the logfile-writing daemon. This daemon is
5347 used to write the access and store logs, if configured.
5348
5349 Squid sends a number of commands to the log daemon:
5350 L<data>\n - logfile data
5351 R\n - rotate file
5352 T\n - truncate file
5353 O\n - reopen file
5354 F\n - flush file
5355 r<n>\n - set rotate count to <n>
5356 b<n>\n - 1 = buffer output, 0 = don't buffer output
5357
5358 No responses is expected.
5359 DOC_END
5360
5361 NAME: stats_collection
5362 TYPE: acl_access
5363 LOC: Config.accessList.stats_collection
5364 DEFAULT: none
5365 DEFAULT_DOC: Allow logging for all transactions.
5366 COMMENT: allow|deny acl acl...
5367 DOC_START
5368 This options allows you to control which requests gets accounted
5369 in performance counters.
5370
5371 This clause only supports fast acl types.
5372 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
5373 DOC_END
5374
5375 NAME: cache_store_log
5376 TYPE: string
5377 DEFAULT: none
5378 LOC: Config.Log.store
5379 DOC_START
5380 Logs the activities of the storage manager. Shows which
5381 objects are ejected from the cache, and which objects are
5382 saved and for how long.
5383 There are not really utilities to analyze this data, so you can safely
5384 disable it (the default).
5385
5386 Store log uses modular logging outputs. See access_log for the list
5387 of modules supported.
5388
5389 Example:
5390 cache_store_log stdio:@DEFAULT_STORE_LOG@
5391 cache_store_log daemon:@DEFAULT_STORE_LOG@
5392 DOC_END
5393
5394 NAME: cache_swap_state cache_swap_log
5395 TYPE: string
5396 LOC: Config.Log.swap
5397 DEFAULT: none
5398 DEFAULT_DOC: Store the journal inside its cache_dir
5399 DOC_START
5400 Location for the cache "swap.state" file. This index file holds
5401 the metadata of objects saved on disk. It is used to rebuild
5402 the cache during startup. Normally this file resides in each
5403 'cache_dir' directory, but you may specify an alternate
5404 pathname here. Note you must give a full filename, not just
5405 a directory. Since this is the index for the whole object
5406 list you CANNOT periodically rotate it!
5407
5408 If %s can be used in the file name it will be replaced with a
5409 a representation of the cache_dir name where each / is replaced
5410 with '.'. This is needed to allow adding/removing cache_dir
5411 lines when cache_swap_log is being used.
5412
5413 If have more than one 'cache_dir', and %s is not used in the name
5414 these swap logs will have names such as:
5415
5416 cache_swap_log.00
5417 cache_swap_log.01
5418 cache_swap_log.02
5419
5420 The numbered extension (which is added automatically)
5421 corresponds to the order of the 'cache_dir' lines in this
5422 configuration file. If you change the order of the 'cache_dir'
5423 lines in this file, these index files will NOT correspond to
5424 the correct 'cache_dir' entry (unless you manually rename
5425 them). We recommend you do NOT use this option. It is
5426 better to keep these index files in each 'cache_dir' directory.
5427 DOC_END
5428
5429 NAME: logfile_rotate
5430 TYPE: int
5431 DEFAULT: 10
5432 LOC: Config.Log.rotateNumber
5433 DOC_START
5434 Specifies the default number of logfile rotations to make when you
5435 type 'squid -k rotate'. The default is 10, which will rotate
5436 with extensions 0 through 9. Setting logfile_rotate to 0 will
5437 disable the file name rotation, but the logfiles are still closed
5438 and re-opened. This will enable you to rename the logfiles
5439 yourself just before sending the rotate signal.
5440
5441 Note, from Squid-3.1 this option is only a default for cache.log,
5442 that log can be rotated separately by using debug_options.
5443
5444 Note, from Squid-4 this option is only a default for access.log
5445 recorded by stdio: module. Those logs can be rotated separately by
5446 using the rotate=N option on their access_log directive.
5447
5448 Note, the 'squid -k rotate' command normally sends a USR1
5449 signal to the running squid process. In certain situations
5450 (e.g. on Linux with Async I/O), USR1 is used for other
5451 purposes, so -k rotate uses another signal. It is best to get
5452 in the habit of using 'squid -k rotate' instead of 'kill -USR1
5453 <pid>'.
5454
5455 DOC_END
5456
5457 NAME: mime_table
5458 TYPE: string
5459 DEFAULT: @DEFAULT_MIME_TABLE@
5460 LOC: Config.mimeTablePathname
5461 DOC_START
5462 Path to Squid's icon configuration file.
5463
5464 You shouldn't need to change this, but the default file contains
5465 examples and formatting information if you do.
5466 DOC_END
5467
5468 NAME: log_mime_hdrs
5469 COMMENT: on|off
5470 TYPE: onoff
5471 LOC: Config.onoff.log_mime_hdrs
5472 DEFAULT: off
5473 DOC_START
5474 The Cache can record both the request and the response MIME
5475 headers for each HTTP transaction. The headers are encoded
5476 safely and will appear as two bracketed fields at the end of
5477 the access log (for either the native or httpd-emulated log
5478 formats). To enable this logging set log_mime_hdrs to 'on'.
5479 DOC_END
5480
5481 NAME: pid_filename
5482 TYPE: string
5483 DEFAULT: @DEFAULT_PID_FILE@
5484 LOC: Config.pidFilename
5485 DOC_START
5486 A filename to write the process-id to. To disable, enter "none".
5487 DOC_END
5488
5489 NAME: client_netmask
5490 TYPE: address
5491 LOC: Config.Addrs.client_netmask
5492 DEFAULT: no_addr
5493 DEFAULT_DOC: Log full client IP address
5494 DOC_START
5495 A netmask for client addresses in logfiles and cachemgr output.
5496 Change this to protect the privacy of your cache clients.
5497 A netmask of 255.255.255.0 will log all IP's in that range with
5498 the last digit set to '0'.
5499 DOC_END
5500
5501 NAME: strip_query_terms
5502 TYPE: onoff
5503 LOC: Config.onoff.strip_query_terms
5504 DEFAULT: on
5505 DOC_START
5506 By default, Squid strips query terms from requested URLs before
5507 logging. This protects your user's privacy and reduces log size.
5508
5509 When investigating HIT/MISS or other caching behaviour you
5510 will need to disable this to see the full URL used by Squid.
5511 DOC_END
5512
5513 NAME: buffered_logs
5514 COMMENT: on|off
5515 TYPE: onoff
5516 DEFAULT: off
5517 LOC: Config.onoff.buffered_logs
5518 DOC_START
5519 Whether to write/send access_log records ASAP or accumulate them and
5520 then write/send them in larger chunks. Buffering may improve
5521 performance because it decreases the number of I/Os. However,
5522 buffering increases the delay before log records become available to
5523 the final recipient (e.g., a disk file or logging daemon) and,
5524 hence, increases the risk of log records loss.
5525
5526 Note that even when buffered_logs are off, Squid may have to buffer
5527 records if it cannot write/send them immediately due to pending I/Os
5528 (e.g., the I/O writing the previous log record) or connectivity loss.
5529
5530 Currently honored by 'daemon' and 'tcp' access_log modules only.
5531 DOC_END
5532
5533 NAME: netdb_filename
5534 TYPE: string
5535 DEFAULT: stdio:@DEFAULT_NETDB_FILE@
5536 LOC: Config.netdbFilename
5537 IFDEF: USE_ICMP
5538 DOC_START
5539 Where Squid stores it's netdb journal.
5540 When enabled this journal preserves netdb state between restarts.
5541
5542 To disable, enter "none".
5543 DOC_END
5544
5545 NAME: tls_key_log
5546 TYPE: Security::KeyLog*
5547 DEFAULT: none
5548 LOC: Config.Log.tlsKeys
5549 IFDEF: USE_OPENSSL
5550 DOC_START
5551 Configures whether and where Squid records pre-master secret and
5552 related encryption details for TLS connections accepted or established
5553 by Squid. These connections include connections accepted at
5554 https_port, TLS connections opened to origin servers/cache_peers/ICAP
5555 services, and TLS tunnels bumped by Squid using the SslBump feature.
5556 This log (a.k.a. SSLKEYLOGFILE) is meant for triage with traffic
5557 inspection tools like Wireshark.
5558
5559 tls_key_log <destination> [options] [if [!]<acl>...]
5560
5561 WARNING: This log allows anybody to decrypt the corresponding
5562 encrypted TLS connections, both in-flight and postmortem.
5563
5564 At most one log file is supported at this time. Repeated tls_key_log
5565 directives are treated as fatal configuration errors. By default, no
5566 log is created or updated.
5567
5568 If the log file does not exist, Squid creates it. Otherwise, Squid
5569 appends an existing log file.
5570
5571 The directive is consulted whenever a TLS connection is accepted or
5572 established by Squid. TLS connections that fail the handshake may be
5573 logged if Squid got enough information to form a log record. A record
5574 is logged only if all of the configured ACLs match.
5575
5576 While transport-related ACLs like src and dst should work, Squid may
5577 not have access to higher-level information. For example, when logging
5578 accepted https_port connections, Squid does not yet have access to the
5579 expected HTTPS request. Similarly, an HTTPS response is not available
5580 when logging most TLS connections established by Squid.
5581
5582 The log record format is meant to be compatible with TLS deciphering
5583 features of Wireshark which relies on fields like CLIENT_RANDOM and
5584 RSA Master-Key. A single log record usually spans multiple lines.
5585 Technical documentation for that format is maintained inside the
5586 Wireshark code (e.g., see tls_keylog_process_lines() comments as of
5587 Wireshark commit e3d44136f0f0026c5e893fa249f458073f3b7328). TLS key
5588 log does not support custom record formats.
5589
5590 This clause only supports fast acl types.
5591 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
5592
5593 See access_log's <module>:<place> parameter for a list of supported
5594 logging destinations.
5595
5596 TLS key log supports all access_log key=value options with the
5597 exception of logformat=name.
5598
5599 Requires Squid built with OpenSSL support.
5600 DOC_END
5601
5602
5603 COMMENT_START
5604 OPTIONS FOR TROUBLESHOOTING
5605 -----------------------------------------------------------------------------
5606 COMMENT_END
5607
5608 NAME: cache_log
5609 TYPE: string
5610 DEFAULT_IF_NONE: @DEFAULT_CACHE_LOG@
5611 LOC: Debug::cache_log
5612 DOC_START
5613 Squid administrative logging file.
5614
5615 This is where general information about Squid behavior goes. You can
5616 increase the amount of data logged to this file and how often it is
5617 rotated with "debug_options"
5618 DOC_END
5619
5620 NAME: cache_log_message
5621 TYPE: cache_log_message
5622 DEFAULT: none
5623 DEFAULT_DOC: Use debug_options.
5624 LOC: Config.debugMessages
5625 DOC_START
5626 Configures logging of individual cache.log messages.
5627
5628 cache_log_message id=<number> option...
5629 cache_log_message ids=<number>-<number> option...
5630
5631 Most messages have _not_ been instrumented to support this directive
5632 yet. For the list of instrumented messages and their IDs, please see
5633 the doc/debug-messages.txt file.
5634
5635 Message ID corresponds to the message semantics rather than message
5636 text or source code location. The ID is stable across Squid
5637 instances and versions. Substantial changes in message semantics
5638 result in a new ID assignment. To reduce the danger of suppressing
5639 an important log message, the old IDs of removed (or substantially
5640 changed) messages are never reused.
5641
5642 If more than one cache_log_message directive refers to the same
5643 message ID, the last directive wins.
5644
5645 Use ids=min-max syntax to apply the same message configuration to an
5646 inclusive range of message IDs. An ID range with N values has
5647 exactly the same effect as typing N cache_log_message lines.
5648
5649 At least one option is required. Supported options are:
5650
5651 level=<number>: The logging level to use for the message. Squid
5652 command line options (-s and -d) as well as the debug_options
5653 directive control which levels go to syslog, stderr, and/or
5654 cache.log. In most environments, using level=2 or higher stops
5655 Squid from logging the message anywhere. By default, the
5656 hard-coded message-specific level is used.
5657
5658 limit=<number>: After logging the specified number of messages at
5659 the configured (or default) debugging level DL, start using
5660 level 3 (for DL 0 and 1) or 8 (for higher DL values). Usually,
5661 level-3+ messages are not logged anywhere so this option can
5662 often be used to effectively suppress the message. Each SMP
5663 Squid process gets the same limit.
5664 DOC_END
5665
5666 NAME: debug_options
5667 TYPE: eol
5668 DEFAULT: ALL,1
5669 DEFAULT_DOC: Log all critical and important messages.
5670 LOC: Debug::debugOptions
5671 DOC_START
5672 Logging options are set as section,level where each source file
5673 is assigned a unique section. Lower levels result in less
5674 output, Full debugging (level 9) can result in a very large
5675 log file, so be careful.
5676
5677 The magic word "ALL" sets debugging levels for all sections.
5678 The default is to run with "ALL,1" to record important warnings.
5679
5680 The rotate=N option can be used to keep more or less of these logs
5681 than would otherwise be kept by logfile_rotate.
5682 For most uses a single log should be enough to monitor current
5683 events affecting Squid.
5684 DOC_END
5685
5686 NAME: coredump_dir
5687 TYPE: string
5688 LOC: Config.coredump_dir
5689 DEFAULT_IF_NONE: none
5690 DEFAULT_DOC: Use the directory from where Squid was started.
5691 DOC_START
5692 By default Squid leaves core files in the directory from where
5693 it was started. If you set 'coredump_dir' to a directory
5694 that exists, Squid will chdir() to that directory at startup
5695 and coredump files will be left there.
5696
5697 In addition to changing the directory, the process permissions are updated
5698 to enable process tracing and/or coredump file generation. The details are
5699 OS-specific, but look for prctl(2) PR_SET_DUMPABLE and procctl(2)
5700 PROC_TRACE_CTL documentation as guiding examples.
5701
5702 CONFIG_START
5703
5704 # Leave coredumps in the first cache dir
5705 coredump_dir @DEFAULT_SWAP_DIR@
5706 CONFIG_END
5707 DOC_END
5708
5709
5710 COMMENT_START
5711 OPTIONS FOR FTP GATEWAYING
5712 -----------------------------------------------------------------------------
5713 COMMENT_END
5714
5715 NAME: ftp_user
5716 TYPE: string
5717 DEFAULT: Squid@
5718 LOC: Config.Ftp.anon_user
5719 DOC_START
5720 If you want the anonymous login password to be more informative
5721 (and enable the use of picky FTP servers), set this to something
5722 reasonable for your domain, like wwwuser@somewhere.net
5723
5724 The reason why this is domainless by default is the
5725 request can be made on the behalf of a user in any domain,
5726 depending on how the cache is used.
5727 Some FTP server also validate the email address is valid
5728 (for example perl.com).
5729 DOC_END
5730
5731 NAME: ftp_passive
5732 TYPE: onoff
5733 DEFAULT: on
5734 LOC: Config.Ftp.passive
5735 DOC_START
5736 If your firewall does not allow Squid to use passive
5737 connections, turn off this option.
5738
5739 Use of ftp_epsv_all option requires this to be ON.
5740 DOC_END
5741
5742 NAME: ftp_epsv_all
5743 TYPE: onoff
5744 DEFAULT: off
5745 LOC: Config.Ftp.epsv_all
5746 DOC_START
5747 FTP Protocol extensions permit the use of a special "EPSV ALL" command.
5748
5749 NATs may be able to put the connection on a "fast path" through the
5750 translator, as the EPRT command will never be used and therefore,
5751 translation of the data portion of the segments will never be needed.
5752
5753 When a client only expects to do two-way FTP transfers this may be
5754 useful.
5755 If squid finds that it must do a three-way FTP transfer after issuing
5756 an EPSV ALL command, the FTP session will fail.
5757
5758 If you have any doubts about this option do not use it.
5759 Squid will nicely attempt all other connection methods.
5760
5761 Requires ftp_passive to be ON (default) for any effect.
5762 DOC_END
5763
5764 NAME: ftp_epsv
5765 TYPE: ftp_epsv
5766 DEFAULT: none
5767 LOC: Config.accessList.ftp_epsv
5768 DOC_START
5769 FTP Protocol extensions permit the use of a special "EPSV" command.
5770
5771 NATs may be able to put the connection on a "fast path" through the
5772 translator using EPSV, as the EPRT command will never be used
5773 and therefore, translation of the data portion of the segments
5774 will never be needed.
5775
5776 EPSV is often required to interoperate with FTP servers on IPv6
5777 networks. On the other hand, it may break some IPv4 servers.
5778
5779 By default, EPSV may try EPSV with any FTP server. To fine tune
5780 that decision, you may restrict EPSV to certain clients or servers
5781 using ACLs:
5782
5783 ftp_epsv allow|deny al1 acl2 ...
5784
5785 WARNING: Disabling EPSV may cause problems with external NAT and IPv6.
5786
5787 Only fast ACLs are supported.
5788 Requires ftp_passive to be ON (default) for any effect.
5789 DOC_END
5790
5791 NAME: ftp_eprt
5792 TYPE: onoff
5793 DEFAULT: on
5794 LOC: Config.Ftp.eprt
5795 DOC_START
5796 FTP Protocol extensions permit the use of a special "EPRT" command.
5797
5798 This extension provides a protocol neutral alternative to the
5799 IPv4-only PORT command. When supported it enables active FTP data
5800 channels over IPv6 and efficient NAT handling.
5801
5802 Turning this OFF will prevent EPRT being attempted and will skip
5803 straight to using PORT for IPv4 servers.
5804
5805 Some devices are known to not handle this extension correctly and
5806 may result in crashes. Devices which support EPRT enough to fail
5807 cleanly will result in Squid attempting PORT anyway. This directive
5808 should only be disabled when EPRT results in device failures.
5809
5810 WARNING: Doing so will convert Squid back to the old behavior with all
5811 the related problems with external NAT devices/layers and IPv4-only FTP.
5812 DOC_END
5813
5814 NAME: ftp_sanitycheck
5815 TYPE: onoff
5816 DEFAULT: on
5817 LOC: Config.Ftp.sanitycheck
5818 DOC_START
5819 For security and data integrity reasons Squid by default performs
5820 sanity checks of the addresses of FTP data connections ensure the
5821 data connection is to the requested server. If you need to allow
5822 FTP connections to servers using another IP address for the data
5823 connection turn this off.
5824 DOC_END
5825
5826 NAME: ftp_telnet_protocol
5827 TYPE: onoff
5828 DEFAULT: on
5829 LOC: Config.Ftp.telnet
5830 DOC_START
5831 The FTP protocol is officially defined to use the telnet protocol
5832 as transport channel for the control connection. However, many
5833 implementations are broken and does not respect this aspect of
5834 the FTP protocol.
5835
5836 If you have trouble accessing files with ASCII code 255 in the
5837 path or similar problems involving this ASCII code you can
5838 try setting this directive to off. If that helps, report to the
5839 operator of the FTP server in question that their FTP server
5840 is broken and does not follow the FTP standard.
5841 DOC_END
5842
5843 COMMENT_START
5844 OPTIONS FOR EXTERNAL SUPPORT PROGRAMS
5845 -----------------------------------------------------------------------------
5846 COMMENT_END
5847
5848 NAME: diskd_program
5849 TYPE: string
5850 DEFAULT: @DEFAULT_DISKD@
5851 LOC: Config.Program.diskd
5852 DOC_START
5853 Specify the location of the diskd executable.
5854 Note this is only useful if you have compiled in
5855 diskd as one of the store io modules.
5856 DOC_END
5857
5858 NAME: unlinkd_program
5859 IFDEF: USE_UNLINKD
5860 TYPE: string
5861 DEFAULT: @DEFAULT_UNLINKD@
5862 LOC: Config.Program.unlinkd
5863 DOC_START
5864 Specify the location of the executable for file deletion process.
5865 DOC_END
5866
5867 NAME: pinger_program
5868 IFDEF: USE_ICMP
5869 TYPE: icmp
5870 DEFAULT: @DEFAULT_PINGER@
5871 LOC: IcmpCfg
5872 DOC_START
5873 Specify the location of the executable for the pinger process.
5874 DOC_END
5875
5876 NAME: pinger_enable
5877 TYPE: onoff
5878 DEFAULT: on
5879 LOC: IcmpCfg.enable
5880 IFDEF: USE_ICMP
5881 DOC_START
5882 Control whether the pinger is active at run-time.
5883 Enables turning ICMP pinger on and off with a simple
5884 squid -k reconfigure.
5885 DOC_END
5886
5887
5888 COMMENT_START
5889 OPTIONS FOR URL REWRITING
5890 -----------------------------------------------------------------------------
5891 COMMENT_END
5892
5893 NAME: url_rewrite_program redirect_program
5894 TYPE: wordlist
5895 LOC: Config.Program.redirect
5896 DEFAULT: none
5897 DOC_START
5898 The name and command line parameters of an admin-provided executable
5899 for redirecting clients or adjusting/replacing client request URLs.
5900
5901 This helper is consulted after the received request is cleared by
5902 http_access and adapted using eICAP/ICAP services (if any). If the
5903 helper does not redirect the client, Squid checks adapted_http_access
5904 and may consult the cache or forward the request to the next hop.
5905
5906
5907 For each request, the helper gets one line in the following format:
5908
5909 [channel-ID <SP>] request-URL [<SP> extras] <NL>
5910
5911 Use url_rewrite_extras to configure what Squid sends as 'extras'.
5912
5913
5914 The helper must reply to each query using a single line:
5915
5916 [channel-ID <SP>] result [<SP> kv-pairs] <NL>
5917
5918 The result section must match exactly one of the following outcomes:
5919
5920 OK [status=30N] url="..."
5921
5922 Redirect the client to a URL supplied in the 'url' parameter.
5923 Optional 'status' specifies the status code to send to the
5924 client in Squid's HTTP redirect response. It must be one of
5925 the standard HTTP redirect status codes: 301, 302, 303, 307,
5926 or 308. When no specific status is requested, Squid uses 302.
5927
5928 OK rewrite-url="..."
5929
5930 Replace the current request URL with the one supplied in the
5931 'rewrite-url' parameter. Squid fetches the resource specified
5932 by the new URL and forwards the received response (or its
5933 cached copy) to the client.
5934
5935 WARNING: Avoid rewriting URLs! When possible, redirect the
5936 client using an "OK url=..." helper response instead.
5937 Rewriting URLs may create inconsistent requests and/or break
5938 synchronization between internal client and origin server
5939 states, especially when URLs or other message parts contain
5940 snippets of that state. For example, Squid does not adjust
5941 Location headers and embedded URLs after the helper rewrites
5942 the request URL.
5943
5944 OK
5945 Keep the client request intact.
5946
5947 ERR
5948 Keep the client request intact.
5949
5950 BH [message="..."]
5951 A helper problem that should be reported to the Squid admin
5952 via a level-1 cache.log message. The 'message' parameter is
5953 reserved for specifying the log message.
5954
5955 In addition to the kv-pairs mentioned above, Squid also understands
5956 the following optional kv-pairs in URL rewriter responses:
5957
5958 clt_conn_tag=TAG
5959 Associates a TAG with the client TCP connection.
5960
5961 The clt_conn_tag=TAG pair is treated as a regular transaction
5962 annotation for the current request and also annotates future
5963 requests on the same client connection. A helper may update
5964 the TAG during subsequent requests by returning a new kv-pair.
5965
5966
5967 Helper messages contain the channel-ID part if and only if the
5968 url_rewrite_children directive specifies positive concurrency. As a
5969 channel-ID value, Squid sends a number between 0 and concurrency-1.
5970 The helper must echo back the received channel-ID in its response.
5971
5972 By default, Squid does not use a URL rewriter.
5973 DOC_END
5974
5975 NAME: url_rewrite_children redirect_children
5976 TYPE: HelperChildConfig
5977 DEFAULT: 20 startup=0 idle=1 concurrency=0
5978 LOC: Config.redirectChildren
5979 DOC_START
5980 Specifies the maximum number of redirector processes that Squid may
5981 spawn (numberofchildren) and several related options. Using too few of
5982 these helper processes (a.k.a. "helpers") creates request queues.
5983 Using too many helpers wastes your system resources.
5984
5985 Usage: numberofchildren [option]...
5986
5987 The startup= and idle= options allow some measure of skew in your
5988 tuning.
5989
5990 startup=
5991
5992 Sets a minimum of how many processes are to be spawned when Squid
5993 starts or reconfigures. When set to zero the first request will
5994 cause spawning of the first child process to handle it.
5995
5996 Starting too few will cause an initial slowdown in traffic as Squid
5997 attempts to simultaneously spawn enough processes to cope.
5998
5999 idle=
6000
6001 Sets a minimum of how many processes Squid is to try and keep available
6002 at all times. When traffic begins to rise above what the existing
6003 processes can handle this many more will be spawned up to the maximum
6004 configured. A minimum setting of 1 is required.
6005
6006 concurrency=
6007
6008 The number of requests each redirector helper can handle in
6009 parallel. Defaults to 0 which indicates the redirector
6010 is a old-style single threaded redirector.
6011
6012 When this directive is set to a value >= 1 then the protocol
6013 used to communicate with the helper is modified to include
6014 an ID in front of the request/response. The ID from the request
6015 must be echoed back with the response to that request.
6016
6017 queue-size=N
6018
6019 Sets the maximum number of queued requests. A request is queued when
6020 no existing child can accept it due to concurrency limit and no new
6021 child can be started due to numberofchildren limit. The default
6022 maximum is zero if url_rewrite_bypass is enabled and
6023 2*numberofchildren otherwise. If the queued requests exceed queue size
6024 and redirector_bypass configuration option is set, then redirector is
6025 bypassed. Otherwise, Squid is allowed to temporarily exceed the
6026 configured maximum, marking the affected helper as "overloaded". If
6027 the helper overload lasts more than 3 minutes, the action prescribed
6028 by the on-persistent-overload option applies.
6029
6030 on-persistent-overload=action
6031
6032 Specifies Squid reaction to a new helper request arriving when the helper
6033 has been overloaded for more that 3 minutes already. The number of queued
6034 requests determines whether the helper is overloaded (see the queue-size
6035 option).
6036
6037 Two actions are supported:
6038
6039 die Squid worker quits. This is the default behavior.
6040
6041 ERR Squid treats the helper request as if it was
6042 immediately submitted, and the helper immediately
6043 replied with an ERR response. This action has no effect
6044 on the already queued and in-progress helper requests.
6045 DOC_END
6046
6047 NAME: url_rewrite_host_header redirect_rewrites_host_header
6048 TYPE: onoff
6049 DEFAULT: on
6050 LOC: Config.onoff.redir_rewrites_host
6051 DOC_START
6052 To preserve same-origin security policies in browsers and
6053 prevent Host: header forgery by redirectors Squid rewrites
6054 any Host: header in redirected requests.
6055
6056 If you are running an accelerator this may not be a wanted
6057 effect of a redirector. This directive enables you disable
6058 Host: alteration in reverse-proxy traffic.
6059
6060 WARNING: Entries are cached on the result of the URL rewriting
6061 process, so be careful if you have domain-virtual hosts.
6062
6063 WARNING: Squid and other software verifies the URL and Host
6064 are matching, so be careful not to relay through other proxies
6065 or inspecting firewalls with this disabled.
6066 DOC_END
6067
6068 NAME: url_rewrite_access redirector_access
6069 TYPE: acl_access
6070 DEFAULT: none
6071 DEFAULT_DOC: Allow, unless rules exist in squid.conf.
6072 LOC: Config.accessList.redirector
6073 DOC_START
6074 If defined, this access list specifies which requests are
6075 sent to the redirector processes.
6076
6077 This clause supports both fast and slow acl types.
6078 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
6079 DOC_END
6080
6081 NAME: url_rewrite_bypass redirector_bypass
6082 TYPE: onoff
6083 LOC: Config.onoff.redirector_bypass
6084 DEFAULT: off
6085 DOC_START
6086 When this is 'on', a request will not go through the
6087 redirector if all the helpers are busy. If this is 'off' and the
6088 redirector queue grows too large, the action is prescribed by the
6089 on-persistent-overload option. You should only enable this if the
6090 redirectors are not critical to your caching system. If you use
6091 redirectors for access control, and you enable this option,
6092 users may have access to pages they should not
6093 be allowed to request.
6094
6095 Enabling this option sets the default url_rewrite_children queue-size
6096 option value to 0.
6097 DOC_END
6098
6099 NAME: url_rewrite_extras
6100 TYPE: TokenOrQuotedString
6101 LOC: Config.redirector_extras
6102 DEFAULT: "%>a/%>A %un %>rm myip=%la myport=%lp"
6103 DOC_START
6104 Specifies a string to be append to request line format for the
6105 rewriter helper. "Quoted" format values may contain spaces and
6106 logformat %macros. In theory, any logformat %macro can be used.
6107 In practice, a %macro expands as a dash (-) if the helper request is
6108 sent before the required macro information is available to Squid.
6109 DOC_END
6110
6111 NAME: url_rewrite_timeout
6112 TYPE: UrlHelperTimeout
6113 LOC: Config.onUrlRewriteTimeout
6114 DEFAULT: none
6115 DEFAULT_DOC: Squid waits for the helper response forever
6116 DOC_START
6117 Squid times active requests to redirector. The timeout value and Squid
6118 reaction to a timed out request are configurable using the following
6119 format:
6120
6121 url_rewrite_timeout timeout time-units on_timeout=<action> [response=<quoted-response>]
6122
6123 supported timeout actions:
6124 fail Squid return a ERR_GATEWAY_FAILURE error page
6125
6126 bypass Do not re-write the URL
6127
6128 retry Send the lookup to the helper again
6129
6130 use_configured_response
6131 Use the <quoted-response> as helper response
6132 DOC_END
6133
6134 COMMENT_START
6135 OPTIONS FOR STORE ID
6136 -----------------------------------------------------------------------------
6137 COMMENT_END
6138
6139 NAME: store_id_program storeurl_rewrite_program
6140 TYPE: wordlist
6141 LOC: Config.Program.store_id
6142 DEFAULT: none
6143 DOC_START
6144 Specify the location of the executable StoreID helper to use.
6145 Since they can perform almost any function there isn't one included.
6146
6147 For each requested URL, the helper will receive one line with the format
6148
6149 [channel-ID <SP>] URL [<SP> extras]<NL>
6150
6151
6152 After processing the request the helper must reply using the following format:
6153
6154 [channel-ID <SP>] result [<SP> kv-pairs]
6155
6156 The result code can be:
6157
6158 OK store-id="..."
6159 Use the StoreID supplied in 'store-id='.
6160
6161 ERR
6162 The default is to use HTTP request URL as the store ID.
6163
6164 BH
6165 An internal error occurred in the helper, preventing
6166 a result being identified.
6167
6168 In addition to the above kv-pairs Squid also understands the following
6169 optional kv-pairs received from URL rewriters:
6170 clt_conn_tag=TAG
6171 Associates a TAG with the client TCP connection.
6172 Please see url_rewrite_program related documentation for this
6173 kv-pair
6174
6175 Helper programs should be prepared to receive and possibly ignore
6176 additional whitespace-separated tokens on each input line.
6177
6178 When using the concurrency= option the protocol is changed by
6179 introducing a query channel tag in front of the request/response.
6180 The query channel tag is a number between 0 and concurrency-1.
6181 This value must be echoed back unchanged to Squid as the first part
6182 of the response relating to its request.
6183
6184 NOTE: when using StoreID refresh_pattern will apply to the StoreID
6185 returned from the helper and not the URL.
6186
6187 WARNING: Wrong StoreID value returned by a careless helper may result
6188 in the wrong cached response returned to the user.
6189
6190 By default, a StoreID helper is not used.
6191 DOC_END
6192
6193 NAME: store_id_extras
6194 TYPE: TokenOrQuotedString
6195 LOC: Config.storeId_extras
6196 DEFAULT: "%>a/%>A %un %>rm myip=%la myport=%lp"
6197 DOC_START
6198 Specifies a string to be append to request line format for the
6199 StoreId helper. "Quoted" format values may contain spaces and
6200 logformat %macros. In theory, any logformat %macro can be used.
6201 In practice, a %macro expands as a dash (-) if the helper request is
6202 sent before the required macro information is available to Squid.
6203 DOC_END
6204
6205 NAME: store_id_children storeurl_rewrite_children
6206 TYPE: HelperChildConfig
6207 DEFAULT: 20 startup=0 idle=1 concurrency=0
6208 LOC: Config.storeIdChildren
6209 DOC_START
6210 Specifies the maximum number of StoreID helper processes that Squid
6211 may spawn (numberofchildren) and several related options. Using
6212 too few of these helper processes (a.k.a. "helpers") creates request
6213 queues. Using too many helpers wastes your system resources.
6214
6215 Usage: numberofchildren [option]...
6216
6217 The startup= and idle= options allow some measure of skew in your
6218 tuning.
6219
6220 startup=
6221
6222 Sets a minimum of how many processes are to be spawned when Squid
6223 starts or reconfigures. When set to zero the first request will
6224 cause spawning of the first child process to handle it.
6225
6226 Starting too few will cause an initial slowdown in traffic as Squid
6227 attempts to simultaneously spawn enough processes to cope.
6228
6229 idle=
6230
6231 Sets a minimum of how many processes Squid is to try and keep available
6232 at all times. When traffic begins to rise above what the existing
6233 processes can handle this many more will be spawned up to the maximum
6234 configured. A minimum setting of 1 is required.
6235
6236 concurrency=
6237
6238 The number of requests each storeID helper can handle in
6239 parallel. Defaults to 0 which indicates the helper
6240 is a old-style single threaded program.
6241
6242 When this directive is set to a value >= 1 then the protocol
6243 used to communicate with the helper is modified to include
6244 an ID in front of the request/response. The ID from the request
6245 must be echoed back with the response to that request.
6246
6247 queue-size=N
6248
6249 Sets the maximum number of queued requests to N. A request is queued
6250 when no existing child can accept it due to concurrency limit and no
6251 new child can be started due to numberofchildren limit. The default
6252 maximum is 2*numberofchildren. If the queued requests exceed queue
6253 size and redirector_bypass configuration option is set, then
6254 redirector is bypassed. Otherwise, Squid is allowed to temporarily
6255 exceed the configured maximum, marking the affected helper as
6256 "overloaded". If the helper overload lasts more than 3 minutes, the
6257 action prescribed by the on-persistent-overload option applies.
6258
6259 on-persistent-overload=action
6260
6261 Specifies Squid reaction to a new helper request arriving when the helper
6262 has been overloaded for more that 3 minutes already. The number of queued
6263 requests determines whether the helper is overloaded (see the queue-size
6264 option).
6265
6266 Two actions are supported:
6267
6268 die Squid worker quits. This is the default behavior.
6269
6270 ERR Squid treats the helper request as if it was
6271 immediately submitted, and the helper immediately
6272 replied with an ERR response. This action has no effect
6273 on the already queued and in-progress helper requests.
6274 DOC_END
6275
6276 NAME: store_id_access storeurl_rewrite_access
6277 TYPE: acl_access
6278 DEFAULT: none
6279 DEFAULT_DOC: Allow, unless rules exist in squid.conf.
6280 LOC: Config.accessList.store_id
6281 DOC_START
6282 If defined, this access list specifies which requests are
6283 sent to the StoreID processes. By default all requests
6284 are sent.
6285
6286 This clause supports both fast and slow acl types.
6287 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
6288 DOC_END
6289
6290 NAME: store_id_bypass storeurl_rewrite_bypass
6291 TYPE: onoff
6292 LOC: Config.onoff.store_id_bypass
6293 DEFAULT: on
6294 DOC_START
6295 When this is 'on', a request will not go through the
6296 helper if all helpers are busy. If this is 'off' and the helper
6297 queue grows too large, the action is prescribed by the
6298 on-persistent-overload option. You should only enable this if the
6299 helpers are not critical to your caching system. If you use
6300 helpers for critical caching components, and you enable this
6301 option, users may not get objects from cache.
6302 This options sets default queue-size option of the store_id_children
6303 to 0.
6304 DOC_END
6305
6306 COMMENT_START
6307 OPTIONS FOR TUNING THE CACHE
6308 -----------------------------------------------------------------------------
6309 COMMENT_END
6310
6311 NAME: cache no_cache
6312 TYPE: acl_access
6313 DEFAULT: none
6314 DEFAULT_DOC: By default, this directive is unused and has no effect.
6315 LOC: Config.accessList.noCache
6316 DOC_START
6317 Requests denied by this directive will not be served from the cache
6318 and their responses will not be stored in the cache. This directive
6319 has no effect on other transactions and on already cached responses.
6320
6321 This clause supports both fast and slow acl types.
6322 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
6323
6324 This and the two other similar caching directives listed below are
6325 checked at different transaction processing stages, have different
6326 access to response information, affect different cache operations,
6327 and differ in slow ACLs support:
6328
6329 * cache: Checked before Squid makes a hit/miss determination.
6330 No access to reply information!
6331 Denies both serving a hit and storing a miss.
6332 Supports both fast and slow ACLs.
6333 * send_hit: Checked after a hit was detected.
6334 Has access to reply (hit) information.
6335 Denies serving a hit only.
6336 Supports fast ACLs only.
6337 * store_miss: Checked before storing a cachable miss.
6338 Has access to reply (miss) information.
6339 Denies storing a miss only.
6340 Supports fast ACLs only.
6341
6342 If you are not sure which of the three directives to use, apply the
6343 following decision logic:
6344
6345 * If your ACL(s) are of slow type _and_ need response info, redesign.
6346 Squid does not support that particular combination at this time.
6347 Otherwise:
6348 * If your directive ACL(s) are of slow type, use "cache"; and/or
6349 * if your directive ACL(s) need no response info, use "cache".
6350 Otherwise:
6351 * If you do not want the response cached, use store_miss; and/or
6352 * if you do not want a hit on a cached response, use send_hit.
6353 DOC_END
6354
6355 NAME: send_hit
6356 TYPE: acl_access
6357 DEFAULT: none
6358 DEFAULT_DOC: By default, this directive is unused and has no effect.
6359 LOC: Config.accessList.sendHit
6360 DOC_START
6361 Responses denied by this directive will not be served from the cache
6362 (but may still be cached, see store_miss). This directive has no
6363 effect on the responses it allows and on the cached objects.
6364
6365 Please see the "cache" directive for a summary of differences among
6366 store_miss, send_hit, and cache directives.
6367
6368 Unlike the "cache" directive, send_hit only supports fast acl
6369 types. See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
6370
6371 For example:
6372
6373 # apply custom Store ID mapping to some URLs
6374 acl MapMe dstdomain .c.example.com
6375 store_id_program ...
6376 store_id_access allow MapMe
6377
6378 # but prevent caching of special responses
6379 # such as 302 redirects that cause StoreID loops
6380 acl Ordinary http_status 200-299
6381 store_miss deny MapMe !Ordinary
6382
6383 # and do not serve any previously stored special responses
6384 # from the cache (in case they were already cached before
6385 # the above store_miss rule was in effect).
6386 send_hit deny MapMe !Ordinary
6387 DOC_END
6388
6389 NAME: store_miss
6390 TYPE: acl_access
6391 DEFAULT: none
6392 DEFAULT_DOC: By default, this directive is unused and has no effect.
6393 LOC: Config.accessList.storeMiss
6394 DOC_START
6395 Responses denied by this directive will not be cached (but may still
6396 be served from the cache, see send_hit). This directive has no
6397 effect on the responses it allows and on the already cached responses.
6398
6399 Please see the "cache" directive for a summary of differences among
6400 store_miss, send_hit, and cache directives. See the
6401 send_hit directive for a usage example.
6402
6403 Unlike the "cache" directive, store_miss only supports fast acl
6404 types. See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
6405 DOC_END
6406
6407 NAME: max_stale
6408 COMMENT: time-units
6409 TYPE: time_t
6410 LOC: Config.maxStale
6411 DEFAULT: 1 week
6412 DOC_START
6413 This option puts an upper limit on how stale content Squid
6414 will serve from the cache if cache validation fails.
6415 Can be overridden by the refresh_pattern max-stale option.
6416 DOC_END
6417
6418 NAME: refresh_pattern
6419 TYPE: refreshpattern
6420 LOC: Config.Refresh
6421 DEFAULT: none
6422 DOC_START
6423 usage: refresh_pattern [-i] regex min percent max [options]
6424
6425 By default, regular expressions are CASE-SENSITIVE. To make
6426 them case-insensitive, use the -i option.
6427
6428 'Min' is the time (in minutes) an object without an explicit
6429 expiry time should be considered fresh. The recommended
6430 value is 0, any higher values may cause dynamic applications
6431 to be erroneously cached unless the application designer
6432 has taken the appropriate actions.
6433
6434 'Percent' is a percentage of the objects age (time since last
6435 modification age) an object without explicit expiry time
6436 will be considered fresh.
6437
6438 'Max' is an upper limit on how long objects without an explicit
6439 expiry time will be considered fresh. The value is also used
6440 to form Cache-Control: max-age header for a request sent from
6441 Squid to origin/parent.
6442
6443 options: override-expire
6444 override-lastmod
6445 reload-into-ims
6446 ignore-reload
6447 ignore-no-store
6448 ignore-private
6449 max-stale=NN
6450 refresh-ims
6451 store-stale
6452
6453 override-expire enforces min age even if the server
6454 sent an explicit expiry time (e.g., with the
6455 Expires: header or Cache-Control: max-age). Doing this
6456 VIOLATES the HTTP standard. Enabling this feature
6457 could make you liable for problems which it causes.
6458
6459 Note: override-expire does not enforce staleness - it only extends
6460 freshness / min. If the server returns a Expires time which
6461 is longer than your max time, Squid will still consider
6462 the object fresh for that period of time.
6463
6464 override-lastmod enforces min age even on objects
6465 that were modified recently.
6466
6467 reload-into-ims changes a client no-cache or ``reload''
6468 request for a cached entry into a conditional request using
6469 If-Modified-Since and/or If-None-Match headers, provided the
6470 cached entry has a Last-Modified and/or a strong ETag header.
6471 Doing this VIOLATES the HTTP standard. Enabling this feature
6472 could make you liable for problems which it causes.
6473
6474 ignore-reload ignores a client no-cache or ``reload''
6475 header. Doing this VIOLATES the HTTP standard. Enabling
6476 this feature could make you liable for problems which
6477 it causes.
6478
6479 ignore-no-store ignores any ``Cache-control: no-store''
6480 headers received from a server. Doing this VIOLATES
6481 the HTTP standard. Enabling this feature could make you
6482 liable for problems which it causes.
6483
6484 ignore-private ignores any ``Cache-control: private''
6485 headers received from a server. Doing this VIOLATES
6486 the HTTP standard. Enabling this feature could make you
6487 liable for problems which it causes.
6488
6489 refresh-ims causes squid to contact the origin server
6490 when a client issues an If-Modified-Since request. This
6491 ensures that the client will receive an updated version
6492 if one is available.
6493
6494 store-stale stores responses even if they don't have explicit
6495 freshness or a validator (i.e., Last-Modified or an ETag)
6496 present, or if they're already stale. By default, Squid will
6497 not cache such responses because they usually can't be
6498 reused. Note that such responses will be stale by default.
6499
6500 max-stale=NN provide a maximum staleness factor. Squid won't
6501 serve objects more stale than this even if it failed to
6502 validate the object. Default: use the max_stale global limit.
6503
6504 Basically a cached object is:
6505
6506 FRESH if expire > now, else STALE
6507 STALE if age > max
6508 FRESH if lm-factor < percent, else STALE
6509 FRESH if age < min
6510 else STALE
6511
6512 The refresh_pattern lines are checked in the order listed here.
6513 The first entry which matches is used. If none of the entries
6514 match the default will be used.
6515
6516 Note, you must uncomment all the default lines if you want
6517 to change one. The default setting is only active if none is
6518 used.
6519
6520 CONFIG_START
6521
6522 #
6523 # Add any of your own refresh_pattern entries above these.
6524 #
6525 refresh_pattern ^ftp: 1440 20% 10080
6526 refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
6527 refresh_pattern . 0 20% 4320
6528 CONFIG_END
6529 DOC_END
6530
6531 NAME: quick_abort_min
6532 COMMENT: (KB)
6533 TYPE: kb_int64_t
6534 DEFAULT: 16 KB
6535 LOC: Config.quickAbort.min
6536 DOC_NONE
6537
6538 NAME: quick_abort_max
6539 COMMENT: (KB)
6540 TYPE: kb_int64_t
6541 DEFAULT: 16 KB
6542 LOC: Config.quickAbort.max
6543 DOC_NONE
6544
6545 NAME: quick_abort_pct
6546 COMMENT: (percent)
6547 TYPE: int
6548 DEFAULT: 95
6549 LOC: Config.quickAbort.pct
6550 DOC_START
6551 The cache by default continues downloading aborted requests
6552 which are almost completed (less than 16 KB remaining). This
6553 may be undesirable on slow (e.g. SLIP) links and/or very busy
6554 caches. Impatient users may tie up file descriptors and
6555 bandwidth by repeatedly requesting and immediately aborting
6556 downloads.
6557
6558 When the user aborts a request, Squid will check the
6559 quick_abort values to the amount of data transferred until
6560 then.
6561
6562 If the transfer has less than 'quick_abort_min' KB remaining,
6563 it will finish the retrieval.
6564
6565 If the transfer has more than 'quick_abort_max' KB remaining,
6566 it will abort the retrieval.
6567
6568 If more than 'quick_abort_pct' of the transfer has completed,
6569 it will finish the retrieval.
6570
6571 If you do not want any retrieval to continue after the client
6572 has aborted, set both 'quick_abort_min' and 'quick_abort_max'
6573 to '0 KB'.
6574
6575 If you want retrievals to always continue if they are being
6576 cached set 'quick_abort_min' to '-1 KB'.
6577 DOC_END
6578
6579 NAME: read_ahead_gap
6580 COMMENT: buffer-size
6581 TYPE: b_int64_t
6582 LOC: Config.readAheadGap
6583 DEFAULT: 16 KB
6584 DOC_START
6585 The amount of data the cache will buffer ahead of what has been
6586 sent to the client when retrieving an object from another server.
6587 DOC_END
6588
6589 NAME: negative_ttl
6590 IFDEF: USE_HTTP_VIOLATIONS
6591 COMMENT: time-units
6592 TYPE: time_t
6593 LOC: Config.negativeTtl
6594 DEFAULT: 0 seconds
6595 DOC_START
6596 Set the Default Time-to-Live (TTL) for failed requests.
6597 Certain types of failures (such as "connection refused" and
6598 "404 Not Found") are able to be negatively-cached for a short time.
6599 Modern web servers should provide Expires: header, however if they
6600 do not this can provide a minimum TTL.
6601 The default is not to cache errors with unknown expiry details.
6602
6603 Note that this is different from negative caching of DNS lookups.
6604
6605 WARNING: Doing this VIOLATES the HTTP standard. Enabling
6606 this feature could make you liable for problems which it
6607 causes.
6608 DOC_END
6609
6610 NAME: positive_dns_ttl
6611 COMMENT: time-units
6612 TYPE: time_t
6613 LOC: Config.positiveDnsTtl
6614 DEFAULT: 6 hours
6615 DOC_START
6616 Upper limit on how long Squid will cache positive DNS responses.
6617 Default is 6 hours (360 minutes). This directive must be set
6618 larger than negative_dns_ttl.
6619 DOC_END
6620
6621 NAME: negative_dns_ttl
6622 COMMENT: time-units
6623 TYPE: time_t
6624 LOC: Config.negativeDnsTtl
6625 DEFAULT: 1 minutes
6626 DOC_START
6627 Time-to-Live (TTL) for negative caching of failed DNS lookups.
6628 This also sets the lower cache limit on positive lookups.
6629 Minimum value is 1 second, and it is not recommendable to go
6630 much below 10 seconds.
6631 DOC_END
6632
6633 NAME: range_offset_limit
6634 COMMENT: size [acl acl...]
6635 TYPE: acl_b_size_t
6636 LOC: Config.rangeOffsetLimit
6637 DEFAULT: none
6638 DOC_START
6639 usage: (size) [units] [[!]aclname]
6640
6641 Sets an upper limit on how far (number of bytes) into the file
6642 a Range request may be to cause Squid to prefetch the whole file.
6643 If beyond this limit, Squid forwards the Range request as it is and
6644 the result is NOT cached.
6645
6646 This is to stop a far ahead range request (lets say start at 17MB)
6647 from making Squid fetch the whole object up to that point before
6648 sending anything to the client.
6649
6650 Multiple range_offset_limit lines may be specified, and they will
6651 be searched from top to bottom on each request until a match is found.
6652 The first match found will be used. If no line matches a request, the
6653 default limit of 0 bytes will be used.
6654
6655 'size' is the limit specified as a number of units.
6656
6657 'units' specifies whether to use bytes, KB, MB, etc.
6658 If no units are specified bytes are assumed.
6659
6660 A size of 0 causes Squid to never fetch more than the
6661 client requested. (default)
6662
6663 A size of 'none' causes Squid to always fetch the object from the
6664 beginning so it may cache the result. (2.0 style)
6665
6666 'aclname' is the name of a defined ACL.
6667
6668 NP: Using 'none' as the byte value here will override any quick_abort settings
6669 that may otherwise apply to the range request. The range request will
6670 be fully fetched from start to finish regardless of the client
6671 actions. This affects bandwidth usage.
6672 DOC_END
6673
6674 NAME: minimum_expiry_time
6675 COMMENT: (seconds)
6676 TYPE: time_t
6677 LOC: Config.minimum_expiry_time
6678 DEFAULT: 60 seconds
6679 DOC_START
6680 The minimum caching time according to (Expires - Date)
6681 headers Squid honors if the object can't be revalidated.
6682 The default is 60 seconds.
6683
6684 In reverse proxy environments it might be desirable to honor
6685 shorter object lifetimes. It is most likely better to make
6686 your server return a meaningful Last-Modified header however.
6687
6688 In ESI environments where page fragments often have short
6689 lifetimes, this will often be best set to 0.
6690 DOC_END
6691
6692 NAME: store_avg_object_size
6693 COMMENT: (bytes)
6694 TYPE: b_int64_t
6695 DEFAULT: 13 KB
6696 LOC: Config.Store.avgObjectSize
6697 DOC_START
6698 Average object size, used to estimate number of objects your
6699 cache can hold. The default is 13 KB.
6700
6701 This is used to pre-seed the cache index memory allocation to
6702 reduce expensive reallocate operations while handling clients
6703 traffic. Too-large values may result in memory allocation during
6704 peak traffic, too-small values will result in wasted memory.
6705
6706 Check the cache manager 'info' report metrics for the real
6707 object sizes seen by your Squid before tuning this.
6708 DOC_END
6709
6710 NAME: store_objects_per_bucket
6711 TYPE: int
6712 DEFAULT: 20
6713 LOC: Config.Store.objectsPerBucket
6714 DOC_START
6715 Target number of objects per bucket in the store hash table.
6716 Lowering this value increases the total number of buckets and
6717 also the storage maintenance rate. The default is 20.
6718 DOC_END
6719
6720 COMMENT_START
6721 HTTP OPTIONS
6722 -----------------------------------------------------------------------------
6723 COMMENT_END
6724
6725 NAME: request_header_max_size
6726 COMMENT: (KB)
6727 TYPE: b_size_t
6728 DEFAULT: 64 KB
6729 LOC: Config.maxRequestHeaderSize
6730 DOC_START
6731 This specifies the maximum size for HTTP headers in a request.
6732 Request headers are usually relatively small (about 512 bytes).
6733 Placing a limit on the request header size will catch certain
6734 bugs (for example with persistent connections) and possibly
6735 buffer-overflow or denial-of-service attacks.
6736 DOC_END
6737
6738 NAME: reply_header_max_size
6739 COMMENT: (KB)
6740 TYPE: b_size_t
6741 DEFAULT: 64 KB
6742 LOC: Config.maxReplyHeaderSize
6743 DOC_START
6744 This specifies the maximum size for HTTP headers in a reply.
6745 Reply headers are usually relatively small (about 512 bytes).
6746 Placing a limit on the reply header size will catch certain
6747 bugs (for example with persistent connections) and possibly
6748 buffer-overflow or denial-of-service attacks.
6749 DOC_END
6750
6751 NAME: request_body_max_size
6752 COMMENT: (bytes)
6753 TYPE: b_int64_t
6754 DEFAULT: 0 KB
6755 DEFAULT_DOC: No limit.
6756 LOC: Config.maxRequestBodySize
6757 DOC_START
6758 This specifies the maximum size for an HTTP request body.
6759 In other words, the maximum size of a PUT/POST request.
6760 A user who attempts to send a request with a body larger
6761 than this limit receives an "Invalid Request" error message.
6762 If you set this parameter to a zero (the default), there will
6763 be no limit imposed.
6764
6765 See also client_request_buffer_max_size for an alternative
6766 limitation on client uploads which can be configured.
6767 DOC_END
6768
6769 NAME: client_request_buffer_max_size
6770 COMMENT: (bytes)
6771 TYPE: b_size_t
6772 DEFAULT: 512 KB
6773 LOC: Config.maxRequestBufferSize
6774 DOC_START
6775 This specifies the maximum buffer size of a client request.
6776 It prevents squid eating too much memory when somebody uploads
6777 a large file.
6778 DOC_END
6779
6780 NAME: broken_posts
6781 IFDEF: USE_HTTP_VIOLATIONS
6782 TYPE: acl_access
6783 DEFAULT: none
6784 DEFAULT_DOC: Obey RFC 2616.
6785 LOC: Config.accessList.brokenPosts
6786 DOC_START
6787 A list of ACL elements which, if matched, causes Squid to send
6788 an extra CRLF pair after the body of a PUT/POST request.
6789
6790 Some HTTP servers has broken implementations of PUT/POST,
6791 and rely on an extra CRLF pair sent by some WWW clients.
6792
6793 Quote from RFC2616 section 4.1 on this matter:
6794
6795 Note: certain buggy HTTP/1.0 client implementations generate an
6796 extra CRLF's after a POST request. To restate what is explicitly
6797 forbidden by the BNF, an HTTP/1.1 client must not preface or follow
6798 a request with an extra CRLF.
6799
6800 This clause only supports fast acl types.
6801 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
6802
6803 Example:
6804 acl buggy_server url_regex ^http://....
6805 broken_posts allow buggy_server
6806 DOC_END
6807
6808 NAME: adaptation_uses_indirect_client icap_uses_indirect_client
6809 COMMENT: on|off
6810 TYPE: onoff
6811 IFDEF: FOLLOW_X_FORWARDED_FOR&&USE_ADAPTATION
6812 DEFAULT: on
6813 LOC: Adaptation::Config::use_indirect_client
6814 DOC_START
6815 Controls whether the indirect client IP address (instead of the direct
6816 client IP address) is passed to adaptation services.
6817
6818 See also: follow_x_forwarded_for adaptation_send_client_ip
6819 DOC_END
6820
6821 NAME: via
6822 IFDEF: USE_HTTP_VIOLATIONS
6823 COMMENT: on|off
6824 TYPE: onoff
6825 DEFAULT: on
6826 LOC: Config.onoff.via
6827 DOC_START
6828 If set (default), Squid will include a Via header in requests and
6829 replies as required by RFC2616.
6830 DOC_END
6831
6832 NAME: vary_ignore_expire
6833 COMMENT: on|off
6834 TYPE: onoff
6835 LOC: Config.onoff.vary_ignore_expire
6836 DEFAULT: off
6837 DOC_START
6838 Many HTTP servers supporting Vary gives such objects
6839 immediate expiry time with no cache-control header
6840 when requested by a HTTP/1.0 client. This option
6841 enables Squid to ignore such expiry times until
6842 HTTP/1.1 is fully implemented.
6843
6844 WARNING: If turned on this may eventually cause some
6845 varying objects not intended for caching to get cached.
6846 DOC_END
6847
6848 NAME: request_header_access
6849 IFDEF: USE_HTTP_VIOLATIONS
6850 TYPE: http_header_access
6851 LOC: Config.request_header_access
6852 DEFAULT: none
6853 DEFAULT_DOC: No limits.
6854 DOC_START
6855 Usage: request_header_access header_name allow|deny [!]aclname ...
6856
6857 WARNING: Doing this VIOLATES the HTTP standard. Enabling
6858 this feature could make you liable for problems which it
6859 causes.
6860
6861 This option replaces the old 'anonymize_headers' and the
6862 older 'http_anonymizer' option with something that is much
6863 more configurable. A list of ACLs for each header name allows
6864 removal of specific header fields under specific conditions.
6865
6866 This option only applies to outgoing HTTP request headers (i.e.,
6867 headers sent by Squid to the next HTTP hop such as a cache peer
6868 or an origin server). The option has no effect during cache hit
6869 detection. The equivalent adaptation vectoring point in ICAP
6870 terminology is post-cache REQMOD.
6871
6872 The option is applied to individual outgoing request header
6873 fields. For each request header field F, Squid uses the first
6874 qualifying sets of request_header_access rules:
6875
6876 1. Rules with header_name equal to F's name.
6877 2. Rules with header_name 'Other', provided F's name is not
6878 on the hard-coded list of commonly used HTTP header names.
6879 3. Rules with header_name 'All'.
6880
6881 Within that qualifying rule set, rule ACLs are checked as usual.
6882 If ACLs of an "allow" rule match, the header field is allowed to
6883 go through as is. If ACLs of a "deny" rule match, the header is
6884 removed and request_header_replace is then checked to identify
6885 if the removed header has a replacement. If no rules within the
6886 set have matching ACLs, the header field is left as is.
6887
6888 For example, to achieve the same behavior as the old
6889 'http_anonymizer standard' option, you should use:
6890
6891 request_header_access From deny all
6892 request_header_access Referer deny all
6893 request_header_access User-Agent deny all
6894
6895 Or, to reproduce the old 'http_anonymizer paranoid' feature
6896 you should use:
6897
6898 request_header_access Authorization allow all
6899 request_header_access Proxy-Authorization allow all
6900 request_header_access Cache-Control allow all
6901 request_header_access Content-Length allow all
6902 request_header_access Content-Type allow all
6903 request_header_access Date allow all
6904 request_header_access Host allow all
6905 request_header_access If-Modified-Since allow all
6906 request_header_access Pragma allow all
6907 request_header_access Accept allow all
6908 request_header_access Accept-Charset allow all
6909 request_header_access Accept-Encoding allow all
6910 request_header_access Accept-Language allow all
6911 request_header_access Connection allow all
6912 request_header_access All deny all
6913
6914 HTTP reply headers are controlled with the reply_header_access directive.
6915
6916 By default, all headers are allowed (no anonymizing is performed).
6917 DOC_END
6918
6919 NAME: reply_header_access
6920 IFDEF: USE_HTTP_VIOLATIONS
6921 TYPE: http_header_access
6922 LOC: Config.reply_header_access
6923 DEFAULT: none
6924 DEFAULT_DOC: No limits.
6925 DOC_START
6926 Usage: reply_header_access header_name allow|deny [!]aclname ...
6927
6928 WARNING: Doing this VIOLATES the HTTP standard. Enabling
6929 this feature could make you liable for problems which it
6930 causes.
6931
6932 This option only applies to reply headers, i.e., from the
6933 server to the client.
6934
6935 This is the same as request_header_access, but in the other
6936 direction. Please see request_header_access for detailed
6937 documentation.
6938
6939 For example, to achieve the same behavior as the old
6940 'http_anonymizer standard' option, you should use:
6941
6942 reply_header_access Server deny all
6943 reply_header_access WWW-Authenticate deny all
6944 reply_header_access Link deny all
6945
6946 Or, to reproduce the old 'http_anonymizer paranoid' feature
6947 you should use:
6948
6949 reply_header_access Allow allow all
6950 reply_header_access WWW-Authenticate allow all
6951 reply_header_access Proxy-Authenticate allow all
6952 reply_header_access Cache-Control allow all
6953 reply_header_access Content-Encoding allow all
6954 reply_header_access Content-Length allow all
6955 reply_header_access Content-Type allow all
6956 reply_header_access Date allow all
6957 reply_header_access Expires allow all
6958 reply_header_access Last-Modified allow all
6959 reply_header_access Location allow all
6960 reply_header_access Pragma allow all
6961 reply_header_access Content-Language allow all
6962 reply_header_access Retry-After allow all
6963 reply_header_access Title allow all
6964 reply_header_access Content-Disposition allow all
6965 reply_header_access Connection allow all
6966 reply_header_access All deny all
6967
6968 HTTP request headers are controlled with the request_header_access directive.
6969
6970 By default, all headers are allowed (no anonymizing is
6971 performed).
6972 DOC_END
6973
6974 NAME: request_header_replace header_replace
6975 IFDEF: USE_HTTP_VIOLATIONS
6976 TYPE: http_header_replace
6977 LOC: Config.request_header_access
6978 DEFAULT: none
6979 DOC_START
6980 Usage: request_header_replace header_name message
6981 Example: request_header_replace User-Agent Nutscrape/1.0 (CP/M; 8-bit)
6982
6983 This option allows you to change the contents of headers
6984 denied with request_header_access above, by replacing them
6985 with some fixed string.
6986
6987 This only applies to request headers, not reply headers.
6988
6989 By default, headers are removed if denied.
6990 DOC_END
6991
6992 NAME: reply_header_replace
6993 IFDEF: USE_HTTP_VIOLATIONS
6994 TYPE: http_header_replace
6995 LOC: Config.reply_header_access
6996 DEFAULT: none
6997 DOC_START
6998 Usage: reply_header_replace header_name message
6999 Example: reply_header_replace Server Foo/1.0
7000
7001 This option allows you to change the contents of headers
7002 denied with reply_header_access above, by replacing them
7003 with some fixed string.
7004
7005 This only applies to reply headers, not request headers.
7006
7007 By default, headers are removed if denied.
7008 DOC_END
7009
7010 NAME: request_header_add
7011 TYPE: HeaderWithAclList
7012 LOC: Config.request_header_add
7013 DEFAULT: none
7014 DOC_START
7015 Usage: request_header_add field-name field-value [ acl ... ]
7016 Example: request_header_add X-Client-CA "CA=%ssl::>cert_issuer" all
7017
7018 This option adds header fields to outgoing HTTP requests (i.e.,
7019 request headers sent by Squid to the next HTTP hop such as a
7020 cache peer or an origin server). The option has no effect during
7021 cache hit detection. The equivalent adaptation vectoring point
7022 in ICAP terminology is post-cache REQMOD.
7023
7024 Field-name is a token specifying an HTTP header name. If a
7025 standard HTTP header name is used, Squid does not check whether
7026 the new header conflicts with any existing headers or violates
7027 HTTP rules. If the request to be modified already contains a
7028 field with the same name, the old field is preserved but the
7029 header field values are not merged.
7030
7031 Field-value is either a token or a quoted string. If quoted
7032 string format is used, then the surrounding quotes are removed
7033 while escape sequences and %macros are processed.
7034
7035 One or more Squid ACLs may be specified to restrict header
7036 injection to matching requests. As always in squid.conf, all
7037 ACLs in the ACL list must be satisfied for the insertion to
7038 happen. The request_header_add supports fast ACLs only.
7039
7040 See also: reply_header_add.
7041 DOC_END
7042
7043 NAME: reply_header_add
7044 TYPE: HeaderWithAclList
7045 LOC: Config.reply_header_add
7046 DEFAULT: none
7047 DOC_START
7048 Usage: reply_header_add field-name field-value [ acl ... ]
7049 Example: reply_header_add X-Client-CA "CA=%ssl::>cert_issuer" all
7050
7051 This option adds header fields to outgoing HTTP responses (i.e., response
7052 headers delivered by Squid to the client). This option has no effect on
7053 cache hit detection. The equivalent adaptation vectoring point in
7054 ICAP terminology is post-cache RESPMOD. This option does not apply to
7055 successful CONNECT replies.
7056
7057 Field-name is a token specifying an HTTP header name. If a
7058 standard HTTP header name is used, Squid does not check whether
7059 the new header conflicts with any existing headers or violates
7060 HTTP rules. If the response to be modified already contains a
7061 field with the same name, the old field is preserved but the
7062 header field values are not merged.
7063
7064 Field-value is either a token or a quoted string. If quoted
7065 string format is used, then the surrounding quotes are removed
7066 while escape sequences and %macros are processed.
7067
7068 One or more Squid ACLs may be specified to restrict header
7069 injection to matching responses. As always in squid.conf, all
7070 ACLs in the ACL list must be satisfied for the insertion to
7071 happen. The reply_header_add option supports fast ACLs only.
7072
7073 See also: request_header_add.
7074 DOC_END
7075
7076 NAME: note
7077 TYPE: note
7078 LOC: Config.notes
7079 DEFAULT: none
7080 DOC_START
7081 This option used to log custom information about the master
7082 transaction. For example, an admin may configure Squid to log
7083 which "user group" the transaction belongs to, where "user group"
7084 will be determined based on a set of ACLs and not [just]
7085 authentication information.
7086 Values of key/value pairs can be logged using %{key}note macros:
7087
7088 note key value acl ...
7089 logformat myFormat ... %{key}note ...
7090
7091 This clause only supports fast acl types.
7092 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
7093 DOC_END
7094
7095 NAME: relaxed_header_parser
7096 COMMENT: on|off|warn
7097 TYPE: tristate
7098 LOC: Config.onoff.relaxed_header_parser
7099 DEFAULT: on
7100 DOC_START
7101 In the default "on" setting Squid accepts certain forms
7102 of non-compliant HTTP messages where it is unambiguous
7103 what the sending application intended even if the message
7104 is not correctly formatted. The messages is then normalized
7105 to the correct form when forwarded by Squid.
7106
7107 If set to "warn" then a warning will be emitted in cache.log
7108 each time such HTTP error is encountered.
7109
7110 If set to "off" then such HTTP errors will cause the request
7111 or response to be rejected.
7112 DOC_END
7113
7114 NAME: collapsed_forwarding
7115 COMMENT: (on|off)
7116 TYPE: onoff
7117 LOC: Config.onoff.collapsed_forwarding
7118 DEFAULT: off
7119 DOC_START
7120 This option controls whether Squid is allowed to merge multiple
7121 potentially cachable requests for the same URI before Squid knows
7122 whether the response is going to be cachable.
7123
7124 When enabled, instead of forwarding each concurrent request for
7125 the same URL, Squid just sends the first of them. The other, so
7126 called "collapsed" requests, wait for the response to the first
7127 request and, if it happens to be cachable, use that response.
7128 Here, "concurrent requests" means "received after the first
7129 request headers were parsed and before the corresponding response
7130 headers were parsed".
7131
7132 This feature is disabled by default: enabling collapsed
7133 forwarding needlessly delays forwarding requests that look
7134 cachable (when they are collapsed) but then need to be forwarded
7135 individually anyway because they end up being for uncachable
7136 content. However, in some cases, such as acceleration of highly
7137 cachable content with periodic or grouped expiration times, the
7138 gains from collapsing [large volumes of simultaneous refresh
7139 requests] outweigh losses from such delays.
7140
7141 Squid collapses two kinds of requests: regular client requests
7142 received on one of the listening ports and internal "cache
7143 revalidation" requests which are triggered by those regular
7144 requests hitting a stale cached object. Revalidation collapsing
7145 is currently disabled for Squid instances containing SMP-aware
7146 disk or memory caches and for Vary-controlled cached objects.
7147 DOC_END
7148
7149 NAME: collapsed_forwarding_access
7150 TYPE: acl_access
7151 DEFAULT: none
7152 DEFAULT_DOC: Requests may be collapsed if collapsed_forwarding is on.
7153 LOC: Config.accessList.collapsedForwardingAccess
7154 DOC_START
7155 Use this directive to restrict collapsed forwarding to a subset of
7156 eligible requests. The directive is checked for regular HTTP
7157 requests, internal revalidation requests, and HTCP/ICP requests.
7158
7159 collapsed_forwarding_access allow|deny [!]aclname ...
7160
7161 This directive cannot force collapsing. It has no effect on
7162 collapsing unless collapsed_forwarding is 'on', and all other
7163 collapsing preconditions are satisfied.
7164
7165 * A denied request will not collapse, and future transactions will
7166 not collapse on it (even if they are allowed to collapse).
7167
7168 * An allowed request may collapse, or future transactions may
7169 collapse on it (provided they are allowed to collapse).
7170
7171 This directive is evaluated before receiving HTTP response headers
7172 and without access to Squid-to-peer connection (if any).
7173
7174 Only fast ACLs are supported.
7175
7176 See also: collapsed_forwarding.
7177 DOC_END
7178
7179 NAME: shared_transient_entries_limit collapsed_forwarding_shared_entries_limit
7180 COMMENT: (number of entries)
7181 TYPE: int64_t
7182 LOC: Config.shared_transient_entries_limit
7183 DEFAULT: 16384
7184 DOC_START
7185 This directive limits the size of a table used for sharing current
7186 transaction information among SMP workers. A table entry stores meta
7187 information about a single cache entry being delivered to Squid
7188 client(s) by one or more SMP workers. A single table entry consumes
7189 less than 128 shared memory bytes.
7190
7191 The limit should be significantly larger than the number of
7192 concurrent non-collapsed cachable responses leaving Squid. For a
7193 cache that handles less than 5000 concurrent requests, the default
7194 setting of 16384 should be plenty.
7195
7196 Using excessively large values wastes shared memory. Limiting the
7197 table size too much results in hash collisions, leading to lower hit
7198 ratio and missed SMP request collapsing opportunities: Transactions
7199 left without a table entry cannot cache their responses and are
7200 invisible to other concurrent requests for the same resource.
7201
7202 A zero limit is allowed but unsupported. A positive small limit
7203 lowers hit ratio, but zero limit disables a lot of essential
7204 synchronization among SMP workers, leading to HTTP violations (e.g.,
7205 stale hit responses). It also disables shared collapsed forwarding:
7206 A worker becomes unable to collapse its requests on transactions in
7207 other workers, resulting in more trips to the origin server and more
7208 cache thrashing.
7209 DOC_END
7210
7211 COMMENT_START
7212 TIMEOUTS
7213 -----------------------------------------------------------------------------
7214 COMMENT_END
7215
7216 NAME: forward_timeout
7217 COMMENT: time-units
7218 TYPE: time_t
7219 LOC: Config.Timeout.forward
7220 DEFAULT: 4 minutes
7221 DOC_START
7222 This parameter specifies how long Squid should at most attempt in
7223 finding a forwarding path for the request before giving up.
7224 DOC_END
7225
7226 NAME: connect_timeout
7227 COMMENT: time-units
7228 TYPE: time_t
7229 LOC: Config.Timeout.connect
7230 DEFAULT: 1 minute
7231 DOC_START
7232 This parameter specifies how long to wait for the TCP connect to
7233 the requested server or peer to complete before Squid should
7234 attempt to find another path where to forward the request.
7235 DOC_END
7236
7237 NAME: peer_connect_timeout
7238 COMMENT: time-units
7239 TYPE: time_t
7240 LOC: Config.Timeout.peer_connect
7241 DEFAULT: 30 seconds
7242 DOC_START
7243 This parameter specifies how long to wait for a pending TCP
7244 connection to a peer cache. The default is 30 seconds. You
7245 may also set different timeout values for individual neighbors
7246 with the 'connect-timeout' option on a 'cache_peer' line.
7247 DOC_END
7248
7249 NAME: read_timeout
7250 COMMENT: time-units
7251 TYPE: time_t
7252 LOC: Config.Timeout.read
7253 DEFAULT: 15 minutes
7254 DOC_START
7255 Applied on peer server connections.
7256
7257 After each successful read(), the timeout will be extended by this
7258 amount. If no data is read again after this amount of time,
7259 the request is aborted and logged with ERR_READ_TIMEOUT.
7260
7261 The default is 15 minutes.
7262 DOC_END
7263
7264 NAME: write_timeout
7265 COMMENT: time-units
7266 TYPE: time_t
7267 LOC: Config.Timeout.write
7268 DEFAULT: 15 minutes
7269 DOC_START
7270 This timeout is tracked for all connections that have data
7271 available for writing and are waiting for the socket to become
7272 ready. After each successful write, the timeout is extended by
7273 the configured amount. If Squid has data to write but the
7274 connection is not ready for the configured duration, the
7275 transaction associated with the connection is terminated. The
7276 default is 15 minutes.
7277 DOC_END
7278
7279 NAME: request_timeout
7280 TYPE: time_t
7281 LOC: Config.Timeout.request
7282 DEFAULT: 5 minutes
7283 DOC_START
7284 How long to wait for complete HTTP request headers after initial
7285 connection establishment.
7286 DOC_END
7287
7288 NAME: request_start_timeout
7289 TYPE: time_t
7290 LOC: Config.Timeout.request_start_timeout
7291 DEFAULT: 5 minutes
7292 DOC_START
7293 How long to wait for the first request byte after initial
7294 connection establishment.
7295 DOC_END
7296
7297 NAME: client_idle_pconn_timeout persistent_request_timeout
7298 TYPE: time_t
7299 LOC: Config.Timeout.clientIdlePconn
7300 DEFAULT: 2 minutes
7301 DOC_START
7302 How long to wait for the next HTTP request on a persistent
7303 client connection after the previous request completes.
7304 DOC_END
7305
7306 NAME: ftp_client_idle_timeout
7307 TYPE: time_t
7308 LOC: Config.Timeout.ftpClientIdle
7309 DEFAULT: 30 minutes
7310 DOC_START
7311 How long to wait for an FTP request on a connection to Squid ftp_port.
7312 Many FTP clients do not deal with idle connection closures well,
7313 necessitating a longer default timeout than client_idle_pconn_timeout
7314 used for incoming HTTP requests.
7315 DOC_END
7316
7317 NAME: client_lifetime
7318 COMMENT: time-units
7319 TYPE: time_t
7320 LOC: Config.Timeout.lifetime
7321 DEFAULT: 1 day
7322 DOC_START
7323 The maximum amount of time a client (browser) is allowed to
7324 remain connected to the cache process. This protects the Cache
7325 from having a lot of sockets (and hence file descriptors) tied up
7326 in a CLOSE_WAIT state from remote clients that go away without
7327 properly shutting down (either because of a network failure or
7328 because of a poor client implementation). The default is one
7329 day, 1440 minutes.
7330
7331 NOTE: The default value is intended to be much larger than any
7332 client would ever need to be connected to your cache. You
7333 should probably change client_lifetime only as a last resort.
7334 If you seem to have many client connections tying up
7335 filedescriptors, we recommend first tuning the read_timeout,
7336 request_timeout, persistent_request_timeout and quick_abort values.
7337 DOC_END
7338
7339 NAME: pconn_lifetime
7340 COMMENT: time-units
7341 TYPE: time_t
7342 LOC: Config.Timeout.pconnLifetime
7343 DEFAULT: 0 seconds
7344 DOC_START
7345 Desired maximum lifetime of a persistent connection.
7346 When set, Squid will close a now-idle persistent connection that
7347 exceeded configured lifetime instead of moving the connection into
7348 the idle connection pool (or equivalent). No effect on ongoing/active
7349 transactions. Connection lifetime is the time period from the
7350 connection acceptance or opening time until "now".
7351
7352 This limit is useful in environments with long-lived connections
7353 where Squid configuration or environmental factors change during a
7354 single connection lifetime. If unrestricted, some connections may
7355 last for hours and even days, ignoring those changes that should
7356 have affected their behavior or their existence.
7357
7358 Currently, a new lifetime value supplied via Squid reconfiguration
7359 has no effect on already idle connections unless they become busy.
7360
7361 When set to '0' this limit is not used.
7362 DOC_END
7363
7364 NAME: half_closed_clients
7365 TYPE: onoff
7366 LOC: Config.onoff.half_closed_clients
7367 DEFAULT: off
7368 DOC_START
7369 Some clients may shutdown the sending side of their TCP
7370 connections, while leaving their receiving sides open. Sometimes,
7371 Squid can not tell the difference between a half-closed and a
7372 fully-closed TCP connection.
7373
7374 By default, Squid will immediately close client connections when
7375 read(2) returns "no more data to read."
7376
7377 Change this option to 'on' and Squid will keep open connections
7378 until a read(2) or write(2) on the socket returns an error.
7379 This may show some benefits for reverse proxies. But if not
7380 it is recommended to leave OFF.
7381 DOC_END
7382
7383 NAME: server_idle_pconn_timeout pconn_timeout
7384 TYPE: time_t
7385 LOC: Config.Timeout.serverIdlePconn
7386 DEFAULT: 1 minute
7387 DOC_START
7388 Timeout for idle persistent connections to servers and other
7389 proxies.
7390 DOC_END
7391
7392 NAME: ident_timeout
7393 TYPE: time_t
7394 IFDEF: USE_IDENT
7395 LOC: Ident::TheConfig.timeout
7396 DEFAULT: 10 seconds
7397 DOC_START
7398 Maximum time to wait for IDENT lookups to complete.
7399
7400 If this is too high, and you enabled IDENT lookups from untrusted
7401 users, you might be susceptible to denial-of-service by having
7402 many ident requests going at once.
7403 DOC_END
7404
7405 NAME: shutdown_lifetime
7406 COMMENT: time-units
7407 TYPE: time_t
7408 LOC: Config.shutdownLifetime
7409 DEFAULT: 30 seconds
7410 DOC_START
7411 When SIGTERM or SIGHUP is received, the cache is put into
7412 "shutdown pending" mode until all active sockets are closed.
7413 This value is the lifetime to set for all open descriptors
7414 during shutdown mode. Any active clients after this many
7415 seconds will receive a 'timeout' message.
7416 DOC_END
7417
7418 COMMENT_START
7419 ADMINISTRATIVE PARAMETERS
7420 -----------------------------------------------------------------------------
7421 COMMENT_END
7422
7423 NAME: cache_mgr
7424 TYPE: string
7425 DEFAULT: webmaster
7426 LOC: Config.adminEmail
7427 DOC_START
7428 Email-address of local cache manager who will receive
7429 mail if the cache dies. The default is "webmaster".
7430 DOC_END
7431
7432 NAME: mail_from
7433 TYPE: string
7434 DEFAULT: none
7435 LOC: Config.EmailFrom
7436 DOC_START
7437 From: email-address for mail sent when the cache dies.
7438 The default is to use 'squid@unique_hostname'.
7439
7440 See also: unique_hostname directive.
7441 DOC_END
7442
7443 NAME: mail_program
7444 TYPE: eol
7445 DEFAULT: mail
7446 LOC: Config.EmailProgram
7447 DOC_START
7448 Email program used to send mail if the cache dies.
7449 The default is "mail". The specified program must comply
7450 with the standard Unix mail syntax:
7451 mail-program recipient < mailfile
7452
7453 Optional command line options can be specified.
7454 DOC_END
7455
7456 NAME: cache_effective_user
7457 TYPE: string
7458 DEFAULT: @DEFAULT_CACHE_EFFECTIVE_USER@
7459 LOC: Config.effectiveUser
7460 DOC_START
7461 If you start Squid as root, it will change its effective/real
7462 UID/GID to the user specified below. The default is to change
7463 to UID of @DEFAULT_CACHE_EFFECTIVE_USER@.
7464 see also; cache_effective_group
7465 DOC_END
7466
7467 NAME: cache_effective_group
7468 TYPE: string
7469 DEFAULT: none
7470 DEFAULT_DOC: Use system group memberships of the cache_effective_user account
7471 LOC: Config.effectiveGroup
7472 DOC_START
7473 Squid sets the GID to the effective user's default group ID
7474 (taken from the password file) and supplementary group list
7475 from the groups membership.
7476
7477 If you want Squid to run with a specific GID regardless of
7478 the group memberships of the effective user then set this
7479 to the group (or GID) you want Squid to run as. When set
7480 all other group privileges of the effective user are ignored
7481 and only this GID is effective. If Squid is not started as
7482 root the user starting Squid MUST be member of the specified
7483 group.
7484
7485 This option is not recommended by the Squid Team.
7486 Our preference is for administrators to configure a secure
7487 user account for squid with UID/GID matching system policies.
7488 DOC_END
7489
7490 NAME: httpd_suppress_version_string
7491 COMMENT: on|off
7492 TYPE: onoff
7493 DEFAULT: off
7494 LOC: Config.onoff.httpd_suppress_version_string
7495 DOC_START
7496 Do not send Squid version string in HTTP metadata and generated content
7497 such as HTML error pages. Squid version string is still present in certain
7498 SNMP responses, cachemgr.cgi output, squidclient User-Agent request header
7499 field, various console output, and cache.log.
7500 DOC_END
7501
7502 NAME: visible_hostname
7503 TYPE: string
7504 LOC: Config.visibleHostname
7505 DEFAULT: none
7506 DEFAULT_DOC: Automatically detect the system host name
7507 DOC_START
7508 If you want to present a special hostname in error messages, etc,
7509 define this. Otherwise, the return value of gethostname()
7510 will be used. If you have multiple caches in a cluster and
7511 get errors about IP-forwarding you must set them to have individual
7512 names with this setting.
7513 DOC_END
7514
7515 NAME: unique_hostname
7516 TYPE: string
7517 LOC: Config.uniqueHostname
7518 DEFAULT: none
7519 DEFAULT_DOC: Copy the value from visible_hostname
7520 DOC_START
7521 If you want to have multiple machines with the same
7522 'visible_hostname' you must give each machine a different
7523 'unique_hostname' so forwarding loops can be detected.
7524 DOC_END
7525
7526 NAME: hostname_aliases
7527 TYPE: wordlist
7528 LOC: Config.hostnameAliases
7529 DEFAULT: none
7530 DOC_START
7531 A list of other DNS names your cache has.
7532 DOC_END
7533
7534 NAME: umask
7535 TYPE: int
7536 LOC: Config.umask
7537 DEFAULT: 027
7538 DOC_START
7539 Minimum umask which should be enforced while the proxy
7540 is running, in addition to the umask set at startup.
7541
7542 For a traditional octal representation of umasks, start
7543 your value with 0.
7544 DOC_END
7545
7546 COMMENT_START
7547 HTTPD-ACCELERATOR OPTIONS
7548 -----------------------------------------------------------------------------
7549 COMMENT_END
7550
7551 NAME: httpd_accel_surrogate_id
7552 TYPE: string
7553 DEFAULT: none
7554 DEFAULT_DOC: visible_hostname is used if no specific ID is set.
7555 LOC: Config.Accel.surrogate_id
7556 DOC_START
7557 Surrogates (http://www.esi.org/architecture_spec_1.0.html)
7558 need an identification token to allow control targeting. Because
7559 a farm of surrogates may all perform the same tasks, they may share
7560 an identification token.
7561
7562 When the surrogate is a reverse-proxy, this ID is also
7563 used as cdn-id for CDN-Loop detection (RFC 8586).
7564 DOC_END
7565
7566 NAME: http_accel_surrogate_remote
7567 COMMENT: on|off
7568 TYPE: onoff
7569 DEFAULT: off
7570 LOC: Config.onoff.surrogate_is_remote
7571 DOC_START
7572 Remote surrogates (such as those in a CDN) honour the header
7573 "Surrogate-Control: no-store-remote".
7574
7575 Set this to on to have squid behave as a remote surrogate.
7576 DOC_END
7577
7578 NAME: esi_parser
7579 IFDEF: USE_SQUID_ESI
7580 COMMENT: libxml2|expat
7581 TYPE: string
7582 LOC: ESIParser::Type
7583 DEFAULT: auto
7584 DEFAULT_DOC: Selects libxml2 if available at ./configure time or libexpat otherwise.
7585 DOC_START
7586 Selects the XML parsing library to use when interpreting responses with
7587 Edge Side Includes.
7588
7589 To disable ESI handling completely, ./configure Squid with --disable-esi.
7590 DOC_END
7591
7592 COMMENT_START
7593 DELAY POOL PARAMETERS
7594 -----------------------------------------------------------------------------
7595 COMMENT_END
7596
7597 NAME: delay_pools
7598 TYPE: delay_pool_count
7599 DEFAULT: 0
7600 IFDEF: USE_DELAY_POOLS
7601 LOC: Config.Delay
7602 DOC_START
7603 This represents the number of delay pools to be used. For example,
7604 if you have one class 2 delay pool and one class 3 delays pool, you
7605 have a total of 2 delay pools.
7606
7607 See also delay_parameters, delay_class, delay_access for pool
7608 configuration details.
7609 DOC_END
7610
7611 NAME: delay_class
7612 TYPE: delay_pool_class
7613 DEFAULT: none
7614 IFDEF: USE_DELAY_POOLS
7615 LOC: Config.Delay
7616 DOC_START
7617 This defines the class of each delay pool. There must be exactly one
7618 delay_class line for each delay pool. For example, to define two
7619 delay pools, one of class 2 and one of class 3, the settings above
7620 and here would be:
7621
7622 Example:
7623 delay_pools 4 # 4 delay pools
7624 delay_class 1 2 # pool 1 is a class 2 pool
7625 delay_class 2 3 # pool 2 is a class 3 pool
7626 delay_class 3 4 # pool 3 is a class 4 pool
7627 delay_class 4 5 # pool 4 is a class 5 pool
7628
7629 The delay pool classes are:
7630
7631 class 1 Everything is limited by a single aggregate
7632 bucket.
7633
7634 class 2 Everything is limited by a single aggregate
7635 bucket as well as an "individual" bucket chosen
7636 from bits 25 through 32 of the IPv4 address.
7637
7638 class 3 Everything is limited by a single aggregate
7639 bucket as well as a "network" bucket chosen
7640 from bits 17 through 24 of the IP address and a
7641 "individual" bucket chosen from bits 17 through
7642 32 of the IPv4 address.
7643
7644 class 4 Everything in a class 3 delay pool, with an
7645 additional limit on a per user basis. This
7646 only takes effect if the username is established
7647 in advance - by forcing authentication in your
7648 http_access rules.
7649
7650 class 5 Requests are grouped according their tag (see
7651 external_acl's tag= reply).
7652
7653
7654 Each pool also requires a delay_parameters directive to configure the pool size
7655 and speed limits used whenever the pool is applied to a request. Along with
7656 a set of delay_access directives to determine when it is used.
7657
7658 NOTE: If an IP address is a.b.c.d
7659 -> bits 25 through 32 are "d"
7660 -> bits 17 through 24 are "c"
7661 -> bits 17 through 32 are "c * 256 + d"
7662
7663 NOTE-2: Due to the use of bitmasks in class 2,3,4 pools they only apply to
7664 IPv4 traffic. Class 1 and 5 pools may be used with IPv6 traffic.
7665
7666 This clause only supports fast acl types.
7667 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
7668
7669 See also delay_parameters and delay_access.
7670 DOC_END
7671
7672 NAME: delay_access
7673 TYPE: delay_pool_access
7674 DEFAULT: none
7675 DEFAULT_DOC: Deny using the pool, unless allow rules exist in squid.conf for the pool.
7676 IFDEF: USE_DELAY_POOLS
7677 LOC: Config.Delay
7678 DOC_START
7679 This is used to determine which delay pool a request falls into.
7680
7681 delay_access is sorted per pool and the matching starts with pool 1,
7682 then pool 2, ..., and finally pool N. The first delay pool where the
7683 request is allowed is selected for the request. If it does not allow
7684 the request to any pool then the request is not delayed (default).
7685
7686 For example, if you want some_big_clients in delay
7687 pool 1 and lotsa_little_clients in delay pool 2:
7688
7689 delay_access 1 allow some_big_clients
7690 delay_access 1 deny all
7691 delay_access 2 allow lotsa_little_clients
7692 delay_access 2 deny all
7693 delay_access 3 allow authenticated_clients
7694
7695 See also delay_parameters and delay_class.
7696
7697 DOC_END
7698
7699 NAME: delay_parameters
7700 TYPE: delay_pool_rates
7701 DEFAULT: none
7702 IFDEF: USE_DELAY_POOLS
7703 LOC: Config.Delay
7704 DOC_START
7705 This defines the parameters for a delay pool. Each delay pool has
7706 a number of "buckets" associated with it, as explained in the
7707 description of delay_class.
7708
7709 For a class 1 delay pool, the syntax is:
7710 delay_class pool 1
7711 delay_parameters pool aggregate
7712
7713 For a class 2 delay pool:
7714 delay_class pool 2
7715 delay_parameters pool aggregate individual
7716
7717 For a class 3 delay pool:
7718 delay_class pool 3
7719 delay_parameters pool aggregate network individual
7720
7721 For a class 4 delay pool:
7722 delay_class pool 4
7723 delay_parameters pool aggregate network individual user
7724
7725 For a class 5 delay pool:
7726 delay_class pool 5
7727 delay_parameters pool tagrate
7728
7729 The option variables are:
7730
7731 pool a pool number - ie, a number between 1 and the
7732 number specified in delay_pools as used in
7733 delay_class lines.
7734
7735 aggregate the speed limit parameters for the aggregate bucket
7736 (class 1, 2, 3).
7737
7738 individual the speed limit parameters for the individual
7739 buckets (class 2, 3).
7740
7741 network the speed limit parameters for the network buckets
7742 (class 3).
7743
7744 user the speed limit parameters for the user buckets
7745 (class 4).
7746
7747 tagrate the speed limit parameters for the tag buckets
7748 (class 5).
7749
7750 A pair of delay parameters is written restore/maximum, where restore is
7751 the number of bytes (not bits - modem and network speeds are usually
7752 quoted in bits) per second placed into the bucket, and maximum is the
7753 maximum number of bytes which can be in the bucket at any time.
7754
7755 There must be one delay_parameters line for each delay pool.
7756
7757
7758 For example, if delay pool number 1 is a class 2 delay pool as in the
7759 above example, and is being used to strictly limit each host to 64Kbit/sec
7760 (plus overheads), with no overall limit, the line is:
7761
7762 delay_parameters 1 none 8000/8000
7763
7764 Note that 8 x 8K Byte/sec -> 64K bit/sec.
7765
7766 Note that the word 'none' is used to represent no limit.
7767
7768
7769 And, if delay pool number 2 is a class 3 delay pool as in the above
7770 example, and you want to limit it to a total of 256Kbit/sec (strict limit)
7771 with each 8-bit network permitted 64Kbit/sec (strict limit) and each
7772 individual host permitted 4800bit/sec with a bucket maximum size of 64Kbits
7773 to permit a decent web page to be downloaded at a decent speed
7774 (if the network is not being limited due to overuse) but slow down
7775 large downloads more significantly:
7776
7777 delay_parameters 2 32000/32000 8000/8000 600/8000
7778
7779 Note that 8 x 32K Byte/sec -> 256K bit/sec.
7780 8 x 8K Byte/sec -> 64K bit/sec.
7781 8 x 600 Byte/sec -> 4800 bit/sec.
7782
7783
7784 Finally, for a class 4 delay pool as in the example - each user will
7785 be limited to 128Kbits/sec no matter how many workstations they are logged into.:
7786
7787 delay_parameters 4 32000/32000 8000/8000 600/64000 16000/16000
7788
7789
7790 See also delay_class and delay_access.
7791
7792 DOC_END
7793
7794 NAME: delay_initial_bucket_level
7795 COMMENT: (percent, 0-100)
7796 TYPE: u_short
7797 DEFAULT: 50
7798 IFDEF: USE_DELAY_POOLS
7799 LOC: Config.Delay.initial
7800 DOC_START
7801 The initial bucket percentage is used to determine how much is put
7802 in each bucket when squid starts, is reconfigured, or first notices
7803 a host accessing it (in class 2 and class 3, individual hosts and
7804 networks only have buckets associated with them once they have been
7805 "seen" by squid).
7806 DOC_END
7807
7808 COMMENT_START
7809 CLIENT DELAY POOL PARAMETERS
7810 -----------------------------------------------------------------------------
7811 COMMENT_END
7812
7813 NAME: client_delay_pools
7814 TYPE: client_delay_pool_count
7815 DEFAULT: 0
7816 IFDEF: USE_DELAY_POOLS
7817 LOC: Config.ClientDelay
7818 DOC_START
7819 This option specifies the number of client delay pools used. It must
7820 preceed other client_delay_* options.
7821
7822 Example:
7823 client_delay_pools 2
7824
7825 See also client_delay_parameters and client_delay_access.
7826 DOC_END
7827
7828 NAME: client_delay_initial_bucket_level
7829 COMMENT: (percent, 0-no_limit)
7830 TYPE: u_short
7831 DEFAULT: 50
7832 IFDEF: USE_DELAY_POOLS
7833 LOC: Config.ClientDelay.initial
7834 DOC_START
7835 This option determines the initial bucket size as a percentage of
7836 max_bucket_size from client_delay_parameters. Buckets are created
7837 at the time of the "first" connection from the matching IP. Idle
7838 buckets are periodically deleted up.
7839
7840 You can specify more than 100 percent but note that such "oversized"
7841 buckets are not refilled until their size goes down to max_bucket_size
7842 from client_delay_parameters.
7843
7844 Example:
7845 client_delay_initial_bucket_level 50
7846 DOC_END
7847
7848 NAME: client_delay_parameters
7849 TYPE: client_delay_pool_rates
7850 DEFAULT: none
7851 IFDEF: USE_DELAY_POOLS
7852 LOC: Config.ClientDelay
7853 DOC_START
7854
7855 This option configures client-side bandwidth limits using the
7856 following format:
7857
7858 client_delay_parameters pool speed_limit max_bucket_size
7859
7860 pool is an integer ID used for client_delay_access matching.
7861
7862 speed_limit is bytes added to the bucket per second.
7863
7864 max_bucket_size is the maximum size of a bucket, enforced after any
7865 speed_limit additions.
7866
7867 Please see the delay_parameters option for more information and
7868 examples.
7869
7870 Example:
7871 client_delay_parameters 1 1024 2048
7872 client_delay_parameters 2 51200 16384
7873
7874 See also client_delay_access.
7875
7876 DOC_END
7877
7878 NAME: client_delay_access
7879 TYPE: client_delay_pool_access
7880 DEFAULT: none
7881 DEFAULT_DOC: Deny use of the pool, unless allow rules exist in squid.conf for the pool.
7882 IFDEF: USE_DELAY_POOLS
7883 LOC: Config.ClientDelay
7884 DOC_START
7885 This option determines the client-side delay pool for the
7886 request:
7887
7888 client_delay_access pool_ID allow|deny acl_name
7889
7890 All client_delay_access options are checked in their pool ID
7891 order, starting with pool 1. The first checked pool with allowed
7892 request is selected for the request. If no ACL matches or there
7893 are no client_delay_access options, the request bandwidth is not
7894 limited.
7895
7896 The ACL-selected pool is then used to find the
7897 client_delay_parameters for the request. Client-side pools are
7898 not used to aggregate clients. Clients are always aggregated
7899 based on their source IP addresses (one bucket per source IP).
7900
7901 This clause only supports fast acl types.
7902 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
7903 Additionally, only the client TCP connection details are available.
7904 ACLs testing HTTP properties will not work.
7905
7906 Please see delay_access for more examples.
7907
7908 Example:
7909 client_delay_access 1 allow low_rate_network
7910 client_delay_access 2 allow vips_network
7911
7912
7913 See also client_delay_parameters and client_delay_pools.
7914 DOC_END
7915
7916 NAME: response_delay_pool
7917 TYPE: response_delay_pool_parameters
7918 DEFAULT: none
7919 IFDEF: USE_DELAY_POOLS
7920 LOC: Config.MessageDelay
7921 DOC_START
7922 This option configures client response bandwidth limits using the
7923 following format:
7924
7925 response_delay_pool name [option=value] ...
7926
7927 name the response delay pool name
7928
7929 available options:
7930
7931 individual-restore The speed limit of an individual
7932 bucket(bytes/s). To be used in conjunction
7933 with 'individual-maximum'.
7934
7935 individual-maximum The maximum number of bytes which can
7936 be placed into the individual bucket. To be used
7937 in conjunction with 'individual-restore'.
7938
7939 aggregate-restore The speed limit for the aggregate
7940 bucket(bytes/s). To be used in conjunction with
7941 'aggregate-maximum'.
7942
7943 aggregate-maximum The maximum number of bytes which can
7944 be placed into the aggregate bucket. To be used
7945 in conjunction with 'aggregate-restore'.
7946
7947 initial-bucket-level The initial bucket size as a percentage
7948 of individual-maximum.
7949
7950 Individual and(or) aggregate bucket options may not be specified,
7951 meaning no individual and(or) aggregate speed limitation.
7952 See also response_delay_pool_access and delay_parameters for
7953 terminology details.
7954 DOC_END
7955
7956 NAME: response_delay_pool_access
7957 TYPE: response_delay_pool_access
7958 DEFAULT: none
7959 DEFAULT_DOC: Deny use of the pool, unless allow rules exist in squid.conf for the pool.
7960 IFDEF: USE_DELAY_POOLS
7961 LOC: Config.MessageDelay
7962 DOC_START
7963 Determines whether a specific named response delay pool is used
7964 for the transaction. The syntax for this directive is:
7965
7966 response_delay_pool_access pool_name allow|deny acl_name
7967
7968 All response_delay_pool_access options are checked in the order
7969 they appear in this configuration file. The first rule with a
7970 matching ACL wins. If (and only if) an "allow" rule won, Squid
7971 assigns the response to the corresponding named delay pool.
7972 DOC_END
7973
7974 COMMENT_START
7975 WCCPv1 AND WCCPv2 CONFIGURATION OPTIONS
7976 -----------------------------------------------------------------------------
7977 COMMENT_END
7978
7979 NAME: wccp_router
7980 TYPE: address
7981 LOC: Config.Wccp.router
7982 DEFAULT: any_addr
7983 DEFAULT_DOC: WCCP disabled.
7984 IFDEF: USE_WCCP
7985 DOC_START
7986 Use this option to define your WCCP ``home'' router for
7987 Squid.
7988
7989 wccp_router supports a single WCCP(v1) router
7990
7991 wccp2_router supports multiple WCCPv2 routers
7992
7993 only one of the two may be used at the same time and defines
7994 which version of WCCP to use.
7995 DOC_END
7996
7997 NAME: wccp2_router
7998 TYPE: IpAddress_list
7999 LOC: Config.Wccp2.router
8000 DEFAULT: none
8001 DEFAULT_DOC: WCCPv2 disabled.
8002 IFDEF: USE_WCCPv2
8003 DOC_START
8004 Use this option to define your WCCP ``home'' router for
8005 Squid.
8006
8007 wccp_router supports a single WCCP(v1) router
8008
8009 wccp2_router supports multiple WCCPv2 routers
8010
8011 only one of the two may be used at the same time and defines
8012 which version of WCCP to use.
8013 DOC_END
8014
8015 NAME: wccp_version
8016 TYPE: int
8017 LOC: Config.Wccp.version
8018 DEFAULT: 4
8019 IFDEF: USE_WCCP
8020 DOC_START
8021 This directive is only relevant if you need to set up WCCP(v1)
8022 to some very old and end-of-life Cisco routers. In all other
8023 setups it must be left unset or at the default setting.
8024 It defines an internal version in the WCCP(v1) protocol,
8025 with version 4 being the officially documented protocol.
8026
8027 According to some users, Cisco IOS 11.2 and earlier only
8028 support WCCP version 3. If you're using that or an earlier
8029 version of IOS, you may need to change this value to 3, otherwise
8030 do not specify this parameter.
8031 DOC_END
8032
8033 NAME: wccp2_rebuild_wait
8034 TYPE: onoff
8035 LOC: Config.Wccp2.rebuildwait
8036 DEFAULT: on
8037 IFDEF: USE_WCCPv2
8038 DOC_START
8039 If this is enabled Squid will wait for the cache dir rebuild to finish
8040 before sending the first wccp2 HereIAm packet
8041 DOC_END
8042
8043 NAME: wccp2_forwarding_method
8044 TYPE: wccp2_method
8045 LOC: Config.Wccp2.forwarding_method
8046 DEFAULT: gre
8047 IFDEF: USE_WCCPv2
8048 DOC_START
8049 WCCP2 allows the setting of forwarding methods between the
8050 router/switch and the cache. Valid values are as follows:
8051
8052 gre - GRE encapsulation (forward the packet in a GRE/WCCP tunnel)
8053 l2 - L2 redirect (forward the packet using Layer 2/MAC rewriting)
8054
8055 Currently (as of IOS 12.4) cisco routers only support GRE.
8056 Cisco switches only support the L2 redirect assignment method.
8057 DOC_END
8058
8059 NAME: wccp2_return_method
8060 TYPE: wccp2_method
8061 LOC: Config.Wccp2.return_method
8062 DEFAULT: gre
8063 IFDEF: USE_WCCPv2
8064 DOC_START
8065 WCCP2 allows the setting of return methods between the
8066 router/switch and the cache for packets that the cache
8067 decides not to handle. Valid values are as follows:
8068
8069 gre - GRE encapsulation (forward the packet in a GRE/WCCP tunnel)
8070 l2 - L2 redirect (forward the packet using Layer 2/MAC rewriting)
8071
8072 Currently (as of IOS 12.4) cisco routers only support GRE.
8073 Cisco switches only support the L2 redirect assignment.
8074
8075 If the "ip wccp redirect exclude in" command has been
8076 enabled on the cache interface, then it is still safe for
8077 the proxy server to use a l2 redirect method even if this
8078 option is set to GRE.
8079 DOC_END
8080
8081 NAME: wccp2_assignment_method
8082 TYPE: wccp2_amethod
8083 LOC: Config.Wccp2.assignment_method
8084 DEFAULT: hash
8085 IFDEF: USE_WCCPv2
8086 DOC_START
8087 WCCP2 allows the setting of methods to assign the WCCP hash
8088 Valid values are as follows:
8089
8090 hash - Hash assignment
8091 mask - Mask assignment
8092
8093 As a general rule, cisco routers support the hash assignment method
8094 and cisco switches support the mask assignment method.
8095 DOC_END
8096
8097 NAME: wccp2_service
8098 TYPE: wccp2_service
8099 LOC: Config.Wccp2.info
8100 DEFAULT_IF_NONE: standard 0
8101 DEFAULT_DOC: Use the 'web-cache' standard service.
8102 IFDEF: USE_WCCPv2
8103 DOC_START
8104 WCCP2 allows for multiple traffic services. There are two
8105 types: "standard" and "dynamic". The standard type defines
8106 one service id - http (id 0). The dynamic service ids can be from
8107 51 to 255 inclusive. In order to use a dynamic service id
8108 one must define the type of traffic to be redirected; this is done
8109 using the wccp2_service_info option.
8110
8111 The "standard" type does not require a wccp2_service_info option,
8112 just specifying the service id will suffice.
8113
8114 MD5 service authentication can be enabled by adding
8115 "password=<password>" to the end of this service declaration.
8116
8117 Examples:
8118
8119 wccp2_service standard 0 # for the 'web-cache' standard service
8120 wccp2_service dynamic 80 # a dynamic service type which will be
8121 # fleshed out with subsequent options.
8122 wccp2_service standard 0 password=foo
8123 DOC_END
8124
8125 NAME: wccp2_service_info
8126 TYPE: wccp2_service_info
8127 LOC: Config.Wccp2.info
8128 DEFAULT: none
8129 IFDEF: USE_WCCPv2
8130 DOC_START
8131 Dynamic WCCPv2 services require further information to define the
8132 traffic you wish to have diverted.
8133
8134 The format is:
8135
8136 wccp2_service_info <id> protocol=<protocol> flags=<flag>,<flag>..
8137 priority=<priority> ports=<port>,<port>..
8138
8139 The relevant WCCPv2 flags:
8140 + src_ip_hash, dst_ip_hash
8141 + source_port_hash, dst_port_hash
8142 + src_ip_alt_hash, dst_ip_alt_hash
8143 + src_port_alt_hash, dst_port_alt_hash
8144 + ports_source
8145
8146 The port list can be one to eight entries.
8147
8148 Example:
8149
8150 wccp2_service_info 80 protocol=tcp flags=src_ip_hash,ports_source
8151 priority=240 ports=80
8152
8153 Note: the service id must have been defined by a previous
8154 'wccp2_service dynamic <id>' entry.
8155 DOC_END
8156
8157 NAME: wccp2_weight
8158 TYPE: int
8159 LOC: Config.Wccp2.weight
8160 DEFAULT: 10000
8161 IFDEF: USE_WCCPv2
8162 DOC_START
8163 Each cache server gets assigned a set of the destination
8164 hash proportional to their weight.
8165 DOC_END
8166
8167 NAME: wccp_address
8168 TYPE: address
8169 LOC: Config.Wccp.address
8170 DEFAULT: 0.0.0.0
8171 DEFAULT_DOC: Address selected by the operating system.
8172 IFDEF: USE_WCCP
8173 DOC_START
8174 Use this option if you require WCCP(v1) to use a specific
8175 interface address.
8176
8177 The default behavior is to not bind to any specific address.
8178 DOC_END
8179
8180 NAME: wccp2_address
8181 TYPE: address
8182 LOC: Config.Wccp2.address
8183 DEFAULT: 0.0.0.0
8184 DEFAULT_DOC: Address selected by the operating system.
8185 IFDEF: USE_WCCPv2
8186 DOC_START
8187 Use this option if you require WCCPv2 to use a specific
8188 interface address.
8189
8190 The default behavior is to not bind to any specific address.
8191 DOC_END
8192
8193 COMMENT_START
8194 PERSISTENT CONNECTION HANDLING
8195 -----------------------------------------------------------------------------
8196
8197 Also see "pconn_timeout" in the TIMEOUTS section
8198 COMMENT_END
8199
8200 NAME: client_persistent_connections
8201 TYPE: onoff
8202 LOC: Config.onoff.client_pconns
8203 DEFAULT: on
8204 DOC_START
8205 Persistent connection support for clients.
8206 Squid uses persistent connections (when allowed). You can use
8207 this option to disable persistent connections with clients.
8208 DOC_END
8209
8210 NAME: server_persistent_connections
8211 TYPE: onoff
8212 LOC: Config.onoff.server_pconns
8213 DEFAULT: on
8214 DOC_START
8215 Persistent connection support for servers.
8216 Squid uses persistent connections (when allowed). You can use
8217 this option to disable persistent connections with servers.
8218 DOC_END
8219
8220 NAME: persistent_connection_after_error
8221 TYPE: onoff
8222 LOC: Config.onoff.error_pconns
8223 DEFAULT: on
8224 DOC_START
8225 With this directive the use of persistent connections after
8226 HTTP errors can be disabled. Useful if you have clients
8227 who fail to handle errors on persistent connections proper.
8228 DOC_END
8229
8230 NAME: detect_broken_pconn
8231 TYPE: onoff
8232 LOC: Config.onoff.detect_broken_server_pconns
8233 DEFAULT: off
8234 DOC_START
8235 Some servers have been found to incorrectly signal the use
8236 of HTTP/1.0 persistent connections even on replies not
8237 compatible, causing significant delays. This server problem
8238 has mostly been seen on redirects.
8239
8240 By enabling this directive Squid attempts to detect such
8241 broken replies and automatically assume the reply is finished
8242 after 10 seconds timeout.
8243 DOC_END
8244
8245 COMMENT_START
8246 CACHE DIGEST OPTIONS
8247 -----------------------------------------------------------------------------
8248 COMMENT_END
8249
8250 NAME: digest_generation
8251 IFDEF: USE_CACHE_DIGESTS
8252 TYPE: onoff
8253 LOC: Config.onoff.digest_generation
8254 DEFAULT: on
8255 DOC_START
8256 This controls whether the server will generate a Cache Digest
8257 of its contents. By default, Cache Digest generation is
8258 enabled if Squid is compiled with --enable-cache-digests defined.
8259 DOC_END
8260
8261 NAME: digest_bits_per_entry
8262 IFDEF: USE_CACHE_DIGESTS
8263 TYPE: int
8264 LOC: Config.digest.bits_per_entry
8265 DEFAULT: 5
8266 DOC_START
8267 This is the number of bits of the server's Cache Digest which
8268 will be associated with the Digest entry for a given HTTP
8269 Method and URL (public key) combination. The default is 5.
8270 DOC_END
8271
8272 NAME: digest_rebuild_period
8273 IFDEF: USE_CACHE_DIGESTS
8274 COMMENT: (seconds)
8275 TYPE: time_t
8276 LOC: Config.digest.rebuild_period
8277 DEFAULT: 1 hour
8278 DOC_START
8279 This is the wait time between Cache Digest rebuilds.
8280 DOC_END
8281
8282 NAME: digest_rewrite_period
8283 COMMENT: (seconds)
8284 IFDEF: USE_CACHE_DIGESTS
8285 TYPE: time_t
8286 LOC: Config.digest.rewrite_period
8287 DEFAULT: 1 hour
8288 DOC_START
8289 This is the wait time between Cache Digest writes to
8290 disk.
8291 DOC_END
8292
8293 NAME: digest_swapout_chunk_size
8294 COMMENT: (bytes)
8295 TYPE: b_size_t
8296 IFDEF: USE_CACHE_DIGESTS
8297 LOC: Config.digest.swapout_chunk_size
8298 DEFAULT: 4096 bytes
8299 DOC_START
8300 This is the number of bytes of the Cache Digest to write to
8301 disk at a time. It defaults to 4096 bytes (4KB), the Squid
8302 default swap page.
8303 DOC_END
8304
8305 NAME: digest_rebuild_chunk_percentage
8306 COMMENT: (percent, 0-100)
8307 IFDEF: USE_CACHE_DIGESTS
8308 TYPE: int
8309 LOC: Config.digest.rebuild_chunk_percentage
8310 DEFAULT: 10
8311 DOC_START
8312 This is the percentage of the Cache Digest to be scanned at a
8313 time. By default it is set to 10% of the Cache Digest.
8314 DOC_END
8315
8316 COMMENT_START
8317 SNMP OPTIONS
8318 -----------------------------------------------------------------------------
8319 COMMENT_END
8320
8321 NAME: snmp_port
8322 TYPE: u_short
8323 LOC: Config.Port.snmp
8324 DEFAULT: 0
8325 DEFAULT_DOC: SNMP disabled.
8326 IFDEF: SQUID_SNMP
8327 DOC_START
8328 The port number where Squid listens for SNMP requests. To enable
8329 SNMP support set this to a suitable port number. Port number
8330 3401 is often used for the Squid SNMP agent. By default it's
8331 set to "0" (disabled)
8332
8333 Example:
8334 snmp_port 3401
8335 DOC_END
8336
8337 NAME: snmp_access
8338 TYPE: acl_access
8339 LOC: Config.accessList.snmp
8340 DEFAULT: none
8341 DEFAULT_DOC: Deny, unless rules exist in squid.conf.
8342 IFDEF: SQUID_SNMP
8343 DOC_START
8344 Allowing or denying access to the SNMP port.
8345
8346 All access to the agent is denied by default.
8347 usage:
8348
8349 snmp_access allow|deny [!]aclname ...
8350
8351 This clause only supports fast acl types.
8352 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
8353
8354 Example:
8355 snmp_access allow snmppublic localhost
8356 snmp_access deny all
8357 DOC_END
8358
8359 NAME: snmp_incoming_address
8360 TYPE: address
8361 LOC: Config.Addrs.snmp_incoming
8362 DEFAULT: any_addr
8363 DEFAULT_DOC: Accept SNMP packets from all machine interfaces.
8364 IFDEF: SQUID_SNMP
8365 DOC_START
8366 Just like 'udp_incoming_address', but for the SNMP port.
8367
8368 snmp_incoming_address is used for the SNMP socket receiving
8369 messages from SNMP agents.
8370
8371 The default snmp_incoming_address is to listen on all
8372 available network interfaces.
8373 DOC_END
8374
8375 NAME: snmp_outgoing_address
8376 TYPE: address
8377 LOC: Config.Addrs.snmp_outgoing
8378 DEFAULT: no_addr
8379 DEFAULT_DOC: Use snmp_incoming_address or an address selected by the operating system.
8380 IFDEF: SQUID_SNMP
8381 DOC_START
8382 Just like 'udp_outgoing_address', but for the SNMP port.
8383
8384 snmp_outgoing_address is used for SNMP packets returned to SNMP
8385 agents.
8386
8387 If snmp_outgoing_address is not set it will use the same socket
8388 as snmp_incoming_address. Only change this if you want to have
8389 SNMP replies sent using another address than where this Squid
8390 listens for SNMP queries.
8391
8392 NOTE, snmp_incoming_address and snmp_outgoing_address can not have
8393 the same value since they both use the same port.
8394 DOC_END
8395
8396 COMMENT_START
8397 ICP OPTIONS
8398 -----------------------------------------------------------------------------
8399 COMMENT_END
8400
8401 NAME: icp_port udp_port
8402 TYPE: u_short
8403 DEFAULT: 0
8404 DEFAULT_DOC: ICP disabled.
8405 LOC: Config.Port.icp
8406 DOC_START
8407 The port number where Squid sends and receives ICP queries to
8408 and from neighbor caches. The standard UDP port for ICP is 3130.
8409
8410 Example:
8411 icp_port @DEFAULT_ICP_PORT@
8412 DOC_END
8413
8414 NAME: htcp_port
8415 IFDEF: USE_HTCP
8416 TYPE: u_short
8417 DEFAULT: 0
8418 DEFAULT_DOC: HTCP disabled.
8419 LOC: Config.Port.htcp
8420 DOC_START
8421 The port number where Squid sends and receives HTCP queries to
8422 and from neighbor caches. To turn it on you want to set it to
8423 4827.
8424
8425 Example:
8426 htcp_port 4827
8427 DOC_END
8428
8429 NAME: log_icp_queries
8430 COMMENT: on|off
8431 TYPE: onoff
8432 DEFAULT: on
8433 LOC: Config.onoff.log_udp
8434 DOC_START
8435 If set, ICP queries are logged to access.log. You may wish
8436 do disable this if your ICP load is VERY high to speed things
8437 up or to simplify log analysis.
8438 DOC_END
8439
8440 NAME: udp_incoming_address
8441 TYPE: address
8442 LOC:Config.Addrs.udp_incoming
8443 DEFAULT: any_addr
8444 DEFAULT_DOC: Accept packets from all machine interfaces.
8445 DOC_START
8446 udp_incoming_address is used for UDP packets received from other
8447 caches.
8448
8449 The default behavior is to not bind to any specific address.
8450
8451 Only change this if you want to have all UDP queries received on
8452 a specific interface/address.
8453
8454 NOTE: udp_incoming_address is used by the ICP, HTCP, and DNS
8455 modules. Altering it will affect all of them in the same manner.
8456
8457 see also; udp_outgoing_address
8458
8459 NOTE, udp_incoming_address and udp_outgoing_address can not
8460 have the same value since they both use the same port.
8461 DOC_END
8462
8463 NAME: udp_outgoing_address
8464 TYPE: address
8465 LOC: Config.Addrs.udp_outgoing
8466 DEFAULT: no_addr
8467 DEFAULT_DOC: Use udp_incoming_address or an address selected by the operating system.
8468 DOC_START
8469 udp_outgoing_address is used for UDP packets sent out to other
8470 caches.
8471
8472 The default behavior is to not bind to any specific address.
8473
8474 Instead it will use the same socket as udp_incoming_address.
8475 Only change this if you want to have UDP queries sent using another
8476 address than where this Squid listens for UDP queries from other
8477 caches.
8478
8479 NOTE: udp_outgoing_address is used by the ICP, HTCP, and DNS
8480 modules. Altering it will affect all of them in the same manner.
8481
8482 see also; udp_incoming_address
8483
8484 NOTE, udp_incoming_address and udp_outgoing_address can not
8485 have the same value since they both use the same port.
8486 DOC_END
8487
8488 NAME: icp_hit_stale
8489 COMMENT: on|off
8490 TYPE: onoff
8491 DEFAULT: off
8492 LOC: Config.onoff.icp_hit_stale
8493 DOC_START
8494 If you want to return ICP_HIT for stale cache objects, set this
8495 option to 'on'. If you have sibling relationships with caches
8496 in other administrative domains, this should be 'off'. If you only
8497 have sibling relationships with caches under your control,
8498 it is probably okay to set this to 'on'.
8499 If set to 'on', your siblings should use the option "allow-miss"
8500 on their cache_peer lines for connecting to you.
8501 DOC_END
8502
8503 NAME: minimum_direct_hops
8504 TYPE: int
8505 DEFAULT: 4
8506 LOC: Config.minDirectHops
8507 DOC_START
8508 If using the ICMP pinging stuff, do direct fetches for sites
8509 which are no more than this many hops away.
8510 DOC_END
8511
8512 NAME: minimum_direct_rtt
8513 COMMENT: (msec)
8514 TYPE: int
8515 DEFAULT: 400
8516 LOC: Config.minDirectRtt
8517 DOC_START
8518 If using the ICMP pinging stuff, do direct fetches for sites
8519 which are no more than this many rtt milliseconds away.
8520 DOC_END
8521
8522 NAME: netdb_low
8523 TYPE: int
8524 DEFAULT: 900
8525 LOC: Config.Netdb.low
8526 DOC_START
8527 The low water mark for the ICMP measurement database.
8528
8529 Note: high watermark controlled by netdb_high directive.
8530
8531 These watermarks are counts, not percents. The defaults are
8532 (low) 900 and (high) 1000. When the high water mark is
8533 reached, database entries will be deleted until the low
8534 mark is reached.
8535 DOC_END
8536
8537 NAME: netdb_high
8538 TYPE: int
8539 DEFAULT: 1000
8540 LOC: Config.Netdb.high
8541 DOC_START
8542 The high water mark for the ICMP measurement database.
8543
8544 Note: low watermark controlled by netdb_low directive.
8545
8546 These watermarks are counts, not percents. The defaults are
8547 (low) 900 and (high) 1000. When the high water mark is
8548 reached, database entries will be deleted until the low
8549 mark is reached.
8550 DOC_END
8551
8552 NAME: netdb_ping_period
8553 TYPE: time_t
8554 LOC: Config.Netdb.period
8555 DEFAULT: 5 minutes
8556 DOC_START
8557 The minimum period for measuring a site. There will be at
8558 least this much delay between successive pings to the same
8559 network. The default is five minutes.
8560 DOC_END
8561
8562 NAME: query_icmp
8563 COMMENT: on|off
8564 TYPE: onoff
8565 DEFAULT: off
8566 LOC: Config.onoff.query_icmp
8567 DOC_START
8568 If you want to ask your peers to include ICMP data in their ICP
8569 replies, enable this option.
8570
8571 If your peer has configured Squid (during compilation) with
8572 '--enable-icmp' that peer will send ICMP pings to origin server
8573 sites of the URLs it receives. If you enable this option the
8574 ICP replies from that peer will include the ICMP data (if available).
8575 Then, when choosing a parent cache, Squid will choose the parent with
8576 the minimal RTT to the origin server. When this happens, the
8577 hierarchy field of the access.log will be
8578 "CLOSEST_PARENT_MISS". This option is off by default.
8579 DOC_END
8580
8581 NAME: test_reachability
8582 COMMENT: on|off
8583 TYPE: onoff
8584 DEFAULT: off
8585 LOC: Config.onoff.test_reachability
8586 DOC_START
8587 When this is 'on', ICP MISS replies will be ICP_MISS_NOFETCH
8588 instead of ICP_MISS if the target host is NOT in the ICMP
8589 database, or has a zero RTT.
8590 DOC_END
8591
8592 NAME: icp_query_timeout
8593 COMMENT: (msec)
8594 DEFAULT: 0
8595 DEFAULT_DOC: Dynamic detection.
8596 TYPE: int
8597 LOC: Config.Timeout.icp_query
8598 DOC_START
8599 Normally Squid will automatically determine an optimal ICP
8600 query timeout value based on the round-trip-time of recent ICP
8601 queries. If you want to override the value determined by
8602 Squid, set this 'icp_query_timeout' to a non-zero value. This
8603 value is specified in MILLISECONDS, so, to use a 2-second
8604 timeout (the old default), you would write:
8605
8606 icp_query_timeout 2000
8607 DOC_END
8608
8609 NAME: maximum_icp_query_timeout
8610 COMMENT: (msec)
8611 DEFAULT: 2000
8612 TYPE: int
8613 LOC: Config.Timeout.icp_query_max
8614 DOC_START
8615 Normally the ICP query timeout is determined dynamically. But
8616 sometimes it can lead to very large values (say 5 seconds).
8617 Use this option to put an upper limit on the dynamic timeout
8618 value. Do NOT use this option to always use a fixed (instead
8619 of a dynamic) timeout value. To set a fixed timeout see the
8620 'icp_query_timeout' directive.
8621 DOC_END
8622
8623 NAME: minimum_icp_query_timeout
8624 COMMENT: (msec)
8625 DEFAULT: 5
8626 TYPE: int
8627 LOC: Config.Timeout.icp_query_min
8628 DOC_START
8629 Normally the ICP query timeout is determined dynamically. But
8630 sometimes it can lead to very small timeouts, even lower than
8631 the normal latency variance on your link due to traffic.
8632 Use this option to put an lower limit on the dynamic timeout
8633 value. Do NOT use this option to always use a fixed (instead
8634 of a dynamic) timeout value. To set a fixed timeout see the
8635 'icp_query_timeout' directive.
8636 DOC_END
8637
8638 NAME: background_ping_rate
8639 COMMENT: time-units
8640 TYPE: time_t
8641 DEFAULT: 10 seconds
8642 LOC: Config.backgroundPingRate
8643 DOC_START
8644 Controls how often the ICP pings are sent to siblings that
8645 have background-ping set.
8646 DOC_END
8647
8648 COMMENT_START
8649 MULTICAST ICP OPTIONS
8650 -----------------------------------------------------------------------------
8651 COMMENT_END
8652
8653 NAME: mcast_groups
8654 TYPE: wordlist
8655 LOC: Config.mcast_group_list
8656 DEFAULT: none
8657 DOC_START
8658 This tag specifies a list of multicast groups which your server
8659 should join to receive multicasted ICP queries.
8660
8661 NOTE! Be very careful what you put here! Be sure you
8662 understand the difference between an ICP _query_ and an ICP
8663 _reply_. This option is to be set only if you want to RECEIVE
8664 multicast queries. Do NOT set this option to SEND multicast
8665 ICP (use cache_peer for that). ICP replies are always sent via
8666 unicast, so this option does not affect whether or not you will
8667 receive replies from multicast group members.
8668
8669 You must be very careful to NOT use a multicast address which
8670 is already in use by another group of caches.
8671
8672 If you are unsure about multicast, please read the Multicast
8673 chapter in the Squid FAQ (http://www.squid-cache.org/FAQ/).
8674
8675 Usage: mcast_groups 239.128.16.128 224.0.1.20
8676
8677 By default, Squid doesn't listen on any multicast groups.
8678 DOC_END
8679
8680 NAME: mcast_miss_addr
8681 IFDEF: MULTICAST_MISS_STREAM
8682 TYPE: address
8683 LOC: Config.mcast_miss.addr
8684 DEFAULT: no_addr
8685 DEFAULT_DOC: disabled.
8686 DOC_START
8687 If you enable this option, every "cache miss" URL will
8688 be sent out on the specified multicast address.
8689
8690 Do not enable this option unless you are are absolutely
8691 certain you understand what you are doing.
8692 DOC_END
8693
8694 NAME: mcast_miss_ttl
8695 IFDEF: MULTICAST_MISS_STREAM
8696 TYPE: u_short
8697 LOC: Config.mcast_miss.ttl
8698 DEFAULT: 16
8699 DOC_START
8700 This is the time-to-live value for packets multicasted
8701 when multicasting off cache miss URLs is enabled. By
8702 default this is set to 'site scope', i.e. 16.
8703 DOC_END
8704
8705 NAME: mcast_miss_port
8706 IFDEF: MULTICAST_MISS_STREAM
8707 TYPE: u_short
8708 LOC: Config.mcast_miss.port
8709 DEFAULT: 3135
8710 DOC_START
8711 This is the port number to be used in conjunction with
8712 'mcast_miss_addr'.
8713 DOC_END
8714
8715 NAME: mcast_miss_encode_key
8716 IFDEF: MULTICAST_MISS_STREAM
8717 TYPE: string
8718 LOC: Config.mcast_miss.encode_key
8719 DEFAULT: XXXXXXXXXXXXXXXX
8720 DOC_START
8721 The URLs that are sent in the multicast miss stream are
8722 encrypted. This is the encryption key.
8723 DOC_END
8724
8725 NAME: mcast_icp_query_timeout
8726 COMMENT: (msec)
8727 DEFAULT: 2000
8728 TYPE: int
8729 LOC: Config.Timeout.mcast_icp_query
8730 DOC_START
8731 For multicast peers, Squid regularly sends out ICP "probes" to
8732 count how many other peers are listening on the given multicast
8733 address. This value specifies how long Squid should wait to
8734 count all the replies. The default is 2000 msec, or 2
8735 seconds.
8736 DOC_END
8737
8738 COMMENT_START
8739 INTERNAL ICON OPTIONS
8740 -----------------------------------------------------------------------------
8741 COMMENT_END
8742
8743 NAME: icon_directory
8744 TYPE: string
8745 LOC: Config.icons.directory
8746 DEFAULT: @DEFAULT_ICON_DIR@
8747 DOC_START
8748 Where the icons are stored. These are normally kept in
8749 @DEFAULT_ICON_DIR@
8750 DOC_END
8751
8752 NAME: global_internal_static
8753 TYPE: onoff
8754 LOC: Config.onoff.global_internal_static
8755 DEFAULT: on
8756 DOC_START
8757 This directive controls is Squid should intercept all requests for
8758 /squid-internal-static/ no matter which host the URL is requesting
8759 (default on setting), or if nothing special should be done for
8760 such URLs (off setting). The purpose of this directive is to make
8761 icons etc work better in complex cache hierarchies where it may
8762 not always be possible for all corners in the cache mesh to reach
8763 the server generating a directory listing.
8764 DOC_END
8765
8766 NAME: short_icon_urls
8767 TYPE: onoff
8768 LOC: Config.icons.use_short_names
8769 DEFAULT: on
8770 DOC_START
8771 If this is enabled Squid will use short URLs for icons.
8772 If disabled it will revert to the old behavior of including
8773 it's own name and port in the URL.
8774
8775 If you run a complex cache hierarchy with a mix of Squid and
8776 other proxies you may need to disable this directive.
8777 DOC_END
8778
8779 COMMENT_START
8780 ERROR PAGE OPTIONS
8781 -----------------------------------------------------------------------------
8782 COMMENT_END
8783
8784 NAME: error_directory
8785 TYPE: string
8786 LOC: Config.errorDirectory
8787 DEFAULT: none
8788 DEFAULT_DOC: Send error pages in the clients preferred language
8789 DOC_START
8790 If you wish to create your own versions of the default
8791 error files to customize them to suit your company copy
8792 the error/template files to another directory and point
8793 this tag at them.
8794
8795 WARNING: This option will disable multi-language support
8796 on error pages if used.
8797
8798 The squid developers are interested in making squid available in
8799 a wide variety of languages. If you are making translations for a
8800 language that Squid does not currently provide please consider
8801 contributing your translation back to the project.
8802 http://wiki.squid-cache.org/Translations
8803
8804 The squid developers working on translations are happy to supply drop-in
8805 translated error files in exchange for any new language contributions.
8806 DOC_END
8807
8808 NAME: error_default_language
8809 IFDEF: USE_ERR_LOCALES
8810 TYPE: string
8811 LOC: Config.errorDefaultLanguage
8812 DEFAULT: none
8813 DEFAULT_DOC: Generate English language pages.
8814 DOC_START
8815 Set the default language which squid will send error pages in
8816 if no existing translation matches the clients language
8817 preferences.
8818
8819 If unset (default) generic English will be used.
8820
8821 The squid developers are interested in making squid available in
8822 a wide variety of languages. If you are interested in making
8823 translations for any language see the squid wiki for details.
8824 http://wiki.squid-cache.org/Translations
8825 DOC_END
8826
8827 NAME: error_log_languages
8828 IFDEF: USE_ERR_LOCALES
8829 TYPE: onoff
8830 LOC: Config.errorLogMissingLanguages
8831 DEFAULT: on
8832 DOC_START
8833 Log to cache.log what languages users are attempting to
8834 auto-negotiate for translations.
8835
8836 Successful negotiations are not logged. Only failures
8837 have meaning to indicate that Squid may need an upgrade
8838 of its error page translations.
8839 DOC_END
8840
8841 NAME: err_page_stylesheet
8842 TYPE: string
8843 LOC: Config.errorStylesheet
8844 DEFAULT: @DEFAULT_CONFIG_DIR@/errorpage.css
8845 DOC_START
8846 CSS Stylesheet to pattern the display of Squid default error pages.
8847
8848 For information on CSS see http://www.w3.org/Style/CSS/
8849 DOC_END
8850
8851 NAME: err_html_text
8852 TYPE: eol
8853 LOC: Config.errHtmlText
8854 DEFAULT: none
8855 DOC_START
8856 HTML text to include in error messages. Make this a "mailto"
8857 URL to your admin address, or maybe just a link to your
8858 organizations Web page.
8859
8860 To include this in your error messages, you must rewrite
8861 the error template files (found in the "errors" directory).
8862 Wherever you want the 'err_html_text' line to appear,
8863 insert a %L tag in the error template file.
8864 DOC_END
8865
8866 NAME: email_err_data
8867 COMMENT: on|off
8868 TYPE: onoff
8869 LOC: Config.onoff.emailErrData
8870 DEFAULT: on
8871 DOC_START
8872 If enabled, information about the occurred error will be
8873 included in the mailto links of the ERR pages (if %W is set)
8874 so that the email body contains the data.
8875 Syntax is <A HREF="mailto:%w%W">%w</A>
8876 DOC_END
8877
8878 NAME: deny_info
8879 TYPE: denyinfo
8880 LOC: Config.denyInfoList
8881 DEFAULT: none
8882 DOC_START
8883 Usage: deny_info err_page_name acl
8884 or deny_info http://... acl
8885 or deny_info TCP_RESET acl
8886
8887 This can be used to return a ERR_ page for requests which
8888 do not pass the 'http_access' rules. Squid remembers the last
8889 acl it evaluated in http_access, and if a 'deny_info' line exists
8890 for that ACL Squid returns a corresponding error page.
8891
8892 The acl is typically the last acl on the http_access deny line which
8893 denied access. The exceptions to this rule are:
8894 - When Squid needs to request authentication credentials. It's then
8895 the first authentication related acl encountered
8896 - When none of the http_access lines matches. It's then the last
8897 acl processed on the last http_access line.
8898 - When the decision to deny access was made by an adaptation service,
8899 the acl name is the corresponding eCAP or ICAP service_name.
8900
8901 NP: If providing your own custom error pages with error_directory
8902 you may also specify them by your custom file name:
8903 Example: deny_info ERR_CUSTOM_ACCESS_DENIED bad_guys
8904
8905 By default Squid will send "403 Forbidden". A different 4xx or 5xx
8906 may be specified by prefixing the file name with the code and a colon.
8907 e.g. 404:ERR_CUSTOM_ACCESS_DENIED
8908
8909 Alternatively you can tell Squid to reset the TCP connection
8910 by specifying TCP_RESET.
8911
8912 Or you can specify an error URL or URL pattern. The browsers will
8913 get redirected to the specified URL after formatting tags have
8914 been replaced. Redirect will be done with 302 or 307 according to
8915 HTTP/1.1 specs. A different 3xx code may be specified by prefixing
8916 the URL. e.g. 303:http://example.com/
8917
8918 URL FORMAT TAGS:
8919 %a - username (if available. Password NOT included)
8920 %A - Local listening IP address the client connection was connected to
8921 %B - FTP path URL
8922 %e - Error number
8923 %E - Error description
8924 %h - Squid hostname
8925 %H - Request domain name
8926 %i - Client IP Address
8927 %M - Request Method
8928 %O - Unescaped message result from external ACL helper
8929 %o - Message result from external ACL helper
8930 %p - Request Port number
8931 %P - Request Protocol name
8932 %R - Request URL path
8933 %T - Timestamp in RFC 1123 format
8934 %U - Full canonical URL from client
8935 (HTTPS URLs terminate with *)
8936 %u - Full canonical URL from client
8937 %w - Admin email from squid.conf
8938 %x - Error name
8939 %% - Literal percent (%) code
8940
8941 DOC_END
8942
8943 COMMENT_START
8944 OPTIONS INFLUENCING REQUEST FORWARDING
8945 -----------------------------------------------------------------------------
8946 COMMENT_END
8947
8948 NAME: nonhierarchical_direct
8949 TYPE: onoff
8950 LOC: Config.onoff.nonhierarchical_direct
8951 DEFAULT: on
8952 DOC_START
8953 By default, Squid will send any non-hierarchical requests
8954 (not cacheable request type) direct to origin servers.
8955
8956 When this is set to "off", Squid will prefer to send these
8957 requests to parents.
8958
8959 Note that in most configurations, by turning this off you will only
8960 add latency to these request without any improvement in global hit
8961 ratio.
8962
8963 This option only sets a preference. If the parent is unavailable a
8964 direct connection to the origin server may still be attempted. To
8965 completely prevent direct connections use never_direct.
8966 DOC_END
8967
8968 NAME: prefer_direct
8969 TYPE: onoff
8970 LOC: Config.onoff.prefer_direct
8971 DEFAULT: off
8972 DOC_START
8973 Normally Squid tries to use parents for most requests. If you for some
8974 reason like it to first try going direct and only use a parent if
8975 going direct fails set this to on.
8976
8977 By combining nonhierarchical_direct off and prefer_direct on you
8978 can set up Squid to use a parent as a backup path if going direct
8979 fails.
8980
8981 Note: If you want Squid to use parents for all requests see
8982 the never_direct directive. prefer_direct only modifies how Squid
8983 acts on cacheable requests.
8984 DOC_END
8985
8986 NAME: cache_miss_revalidate
8987 COMMENT: on|off
8988 TYPE: onoff
8989 DEFAULT: on
8990 LOC: Config.onoff.cache_miss_revalidate
8991 DOC_START
8992 RFC 7232 defines a conditional request mechanism to prevent
8993 response objects being unnecessarily transferred over the network.
8994 If that mechanism is used by the client and a cache MISS occurs
8995 it can prevent new cache entries being created.
8996
8997 This option determines whether Squid on cache MISS will pass the
8998 client revalidation request to the server or tries to fetch new
8999 content for caching. It can be useful while the cache is mostly
9000 empty to more quickly have the cache populated by generating
9001 non-conditional GETs.
9002
9003 When set to 'on' (default), Squid will pass all client If-* headers
9004 to the server. This permits server responses without a cacheable
9005 payload to be delivered and on MISS no new cache entry is created.
9006
9007 When set to 'off' and if the request is cacheable, Squid will
9008 remove the clients If-Modified-Since and If-None-Match headers from
9009 the request sent to the server. This requests a 200 status response
9010 from the server to create a new cache entry with.
9011 DOC_END
9012
9013 NAME: always_direct
9014 TYPE: acl_access
9015 LOC: Config.accessList.AlwaysDirect
9016 DEFAULT: none
9017 DEFAULT_DOC: Prevent any cache_peer being used for this request.
9018 DOC_START
9019 Usage: always_direct allow|deny [!]aclname ...
9020
9021 Here you can use ACL elements to specify requests which should
9022 ALWAYS be forwarded by Squid to the origin servers without using
9023 any peers. For example, to always directly forward requests for
9024 local servers ignoring any parents or siblings you may have use
9025 something like:
9026
9027 acl local-servers dstdomain my.domain.net
9028 always_direct allow local-servers
9029
9030 To always forward FTP requests directly, use
9031
9032 acl FTP proto FTP
9033 always_direct allow FTP
9034
9035 NOTE: There is a similar, but opposite option named
9036 'never_direct'. You need to be aware that "always_direct deny
9037 foo" is NOT the same thing as "never_direct allow foo". You
9038 may need to use a deny rule to exclude a more-specific case of
9039 some other rule. Example:
9040
9041 acl local-external dstdomain external.foo.net
9042 acl local-servers dstdomain .foo.net
9043 always_direct deny local-external
9044 always_direct allow local-servers
9045
9046 NOTE: If your goal is to make the client forward the request
9047 directly to the origin server bypassing Squid then this needs
9048 to be done in the client configuration. Squid configuration
9049 can only tell Squid how Squid should fetch the object.
9050
9051 NOTE: This directive is not related to caching. The replies
9052 is cached as usual even if you use always_direct. To not cache
9053 the replies see the 'cache' directive.
9054
9055 This clause supports both fast and slow acl types.
9056 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
9057 DOC_END
9058
9059 NAME: never_direct
9060 TYPE: acl_access
9061 LOC: Config.accessList.NeverDirect
9062 DEFAULT: none
9063 DEFAULT_DOC: Allow DNS results to be used for this request.
9064 DOC_START
9065 Usage: never_direct allow|deny [!]aclname ...
9066
9067 never_direct is the opposite of always_direct. Please read
9068 the description for always_direct if you have not already.
9069
9070 With 'never_direct' you can use ACL elements to specify
9071 requests which should NEVER be forwarded directly to origin
9072 servers. For example, to force the use of a proxy for all
9073 requests, except those in your local domain use something like:
9074
9075 acl local-servers dstdomain .foo.net
9076 never_direct deny local-servers
9077 never_direct allow all
9078
9079 or if Squid is inside a firewall and there are local intranet
9080 servers inside the firewall use something like:
9081
9082 acl local-intranet dstdomain .foo.net
9083 acl local-external dstdomain external.foo.net
9084 always_direct deny local-external
9085 always_direct allow local-intranet
9086 never_direct allow all
9087
9088 This clause supports both fast and slow acl types.
9089 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
9090 DOC_END
9091
9092 COMMENT_START
9093 ADVANCED NETWORKING OPTIONS
9094 -----------------------------------------------------------------------------
9095 COMMENT_END
9096
9097 NAME: incoming_udp_average incoming_icp_average
9098 TYPE: int
9099 DEFAULT: 6
9100 LOC: Config.comm_incoming.udp.average
9101 DOC_START
9102 Heavy voodoo here. I can't even believe you are reading this.
9103 Are you crazy? Don't even think about adjusting these unless
9104 you understand the algorithms in comm_select.c first!
9105 DOC_END
9106
9107 NAME: incoming_tcp_average incoming_http_average
9108 TYPE: int
9109 DEFAULT: 4
9110 LOC: Config.comm_incoming.tcp.average
9111 DOC_START
9112 Heavy voodoo here. I can't even believe you are reading this.
9113 Are you crazy? Don't even think about adjusting these unless
9114 you understand the algorithms in comm_select.c first!
9115 DOC_END
9116
9117 NAME: incoming_dns_average
9118 TYPE: int
9119 DEFAULT: 4
9120 LOC: Config.comm_incoming.dns.average
9121 DOC_START
9122 Heavy voodoo here. I can't even believe you are reading this.
9123 Are you crazy? Don't even think about adjusting these unless
9124 you understand the algorithms in comm_select.c first!
9125 DOC_END
9126
9127 NAME: min_udp_poll_cnt min_icp_poll_cnt
9128 TYPE: int
9129 DEFAULT: 8
9130 LOC: Config.comm_incoming.udp.min_poll
9131 DOC_START
9132 Heavy voodoo here. I can't even believe you are reading this.
9133 Are you crazy? Don't even think about adjusting these unless
9134 you understand the algorithms in comm_select.c first!
9135 DOC_END
9136
9137 NAME: min_dns_poll_cnt
9138 TYPE: int
9139 DEFAULT: 8
9140 LOC: Config.comm_incoming.dns.min_poll
9141 DOC_START
9142 Heavy voodoo here. I can't even believe you are reading this.
9143 Are you crazy? Don't even think about adjusting these unless
9144 you understand the algorithms in comm_select.c first!
9145 DOC_END
9146
9147 NAME: min_tcp_poll_cnt min_http_poll_cnt
9148 TYPE: int
9149 DEFAULT: 8
9150 LOC: Config.comm_incoming.tcp.min_poll
9151 DOC_START
9152 Heavy voodoo here. I can't even believe you are reading this.
9153 Are you crazy? Don't even think about adjusting these unless
9154 you understand the algorithms in comm_select.c first!
9155 DOC_END
9156
9157 NAME: accept_filter
9158 TYPE: string
9159 DEFAULT: none
9160 LOC: Config.accept_filter
9161 DOC_START
9162 FreeBSD:
9163
9164 The name of an accept(2) filter to install on Squid's
9165 listen socket(s). This feature is perhaps specific to
9166 FreeBSD and requires support in the kernel.
9167
9168 The 'httpready' filter delays delivering new connections
9169 to Squid until a full HTTP request has been received.
9170 See the accf_http(9) man page for details.
9171
9172 The 'dataready' filter delays delivering new connections
9173 to Squid until there is some data to process.
9174 See the accf_dataready(9) man page for details.
9175
9176 Linux:
9177
9178 The 'data' filter delays delivering of new connections
9179 to Squid until there is some data to process by TCP_ACCEPT_DEFER.
9180 You may optionally specify a number of seconds to wait by
9181 'data=N' where N is the number of seconds. Defaults to 30
9182 if not specified. See the tcp(7) man page for details.
9183 EXAMPLE:
9184 # FreeBSD
9185 accept_filter httpready
9186 # Linux
9187 accept_filter data
9188 DOC_END
9189
9190 NAME: client_ip_max_connections
9191 TYPE: int
9192 LOC: Config.client_ip_max_connections
9193 DEFAULT: -1
9194 DEFAULT_DOC: No limit.
9195 DOC_START
9196 Set an absolute limit on the number of connections a single
9197 client IP can use. Any more than this and Squid will begin to drop
9198 new connections from the client until it closes some links.
9199
9200 Note that this is a global limit. It affects all HTTP, HTCP, and FTP
9201 connections from the client. For finer control use the ACL access controls.
9202
9203 Requires client_db to be enabled (the default).
9204
9205 WARNING: This may noticeably slow down traffic received via external proxies
9206 or NAT devices and cause them to rebound error messages back to their clients.
9207 DOC_END
9208
9209 NAME: tcp_recv_bufsize
9210 COMMENT: (bytes)
9211 TYPE: b_size_t
9212 DEFAULT: 0 bytes
9213 DEFAULT_DOC: Use operating system TCP defaults.
9214 LOC: Config.tcpRcvBufsz
9215 DOC_START
9216 Size of receive buffer to set for TCP sockets. Probably just
9217 as easy to change your kernel's default.
9218 Omit from squid.conf to use the default buffer size.
9219 DOC_END
9220
9221 COMMENT_START
9222 ICAP OPTIONS
9223 -----------------------------------------------------------------------------
9224 COMMENT_END
9225
9226 NAME: icap_enable
9227 TYPE: onoff
9228 IFDEF: ICAP_CLIENT
9229 COMMENT: on|off
9230 LOC: Adaptation::Icap::TheConfig.onoff
9231 DEFAULT: off
9232 DOC_START
9233 If you want to enable the ICAP module support, set this to on.
9234 DOC_END
9235
9236 NAME: icap_connect_timeout
9237 TYPE: time_t
9238 DEFAULT: none
9239 LOC: Adaptation::Icap::TheConfig.connect_timeout_raw
9240 IFDEF: ICAP_CLIENT
9241 DOC_START
9242 This parameter specifies how long to wait for the TCP connect to
9243 the requested ICAP server to complete before giving up and either
9244 terminating the HTTP transaction or bypassing the failure.
9245
9246 The default for optional services is peer_connect_timeout.
9247 The default for essential services is connect_timeout.
9248 If this option is explicitly set, its value applies to all services.
9249 DOC_END
9250
9251 NAME: icap_io_timeout
9252 COMMENT: time-units
9253 TYPE: time_t
9254 DEFAULT: none
9255 DEFAULT_DOC: Use read_timeout.
9256 LOC: Adaptation::Icap::TheConfig.io_timeout_raw
9257 IFDEF: ICAP_CLIENT
9258 DOC_START
9259 This parameter specifies how long to wait for an I/O activity on
9260 an established, active ICAP connection before giving up and
9261 either terminating the HTTP transaction or bypassing the
9262 failure.
9263 DOC_END
9264
9265 NAME: icap_service_failure_limit
9266 COMMENT: limit [in memory-depth time-units]
9267 TYPE: icap_service_failure_limit
9268 IFDEF: ICAP_CLIENT
9269 LOC: Adaptation::Icap::TheConfig
9270 DEFAULT: 10
9271 DOC_START
9272 The limit specifies the number of failures that Squid tolerates
9273 when establishing a new TCP connection with an ICAP service. If
9274 the number of failures exceeds the limit, the ICAP service is
9275 not used for new ICAP requests until it is time to refresh its
9276 OPTIONS.
9277
9278 A negative value disables the limit. Without the limit, an ICAP
9279 service will not be considered down due to connectivity failures
9280 between ICAP OPTIONS requests.
9281
9282 Squid forgets ICAP service failures older than the specified
9283 value of memory-depth. The memory fading algorithm
9284 is approximate because Squid does not remember individual
9285 errors but groups them instead, splitting the option
9286 value into ten time slots of equal length.
9287
9288 When memory-depth is 0 and by default this option has no
9289 effect on service failure expiration.
9290
9291 Squid always forgets failures when updating service settings
9292 using an ICAP OPTIONS transaction, regardless of this option
9293 setting.
9294
9295 For example,
9296 # suspend service usage after 10 failures in 5 seconds:
9297 icap_service_failure_limit 10 in 5 seconds
9298 DOC_END
9299
9300 NAME: icap_service_revival_delay
9301 TYPE: int
9302 IFDEF: ICAP_CLIENT
9303 LOC: Adaptation::Icap::TheConfig.service_revival_delay
9304 DEFAULT: 180
9305 DOC_START
9306 The delay specifies the number of seconds to wait after an ICAP
9307 OPTIONS request failure before requesting the options again. The
9308 failed ICAP service is considered "down" until fresh OPTIONS are
9309 fetched.
9310
9311 The actual delay cannot be smaller than the hardcoded minimum
9312 delay of 30 seconds.
9313 DOC_END
9314
9315 NAME: icap_preview_enable
9316 TYPE: onoff
9317 IFDEF: ICAP_CLIENT
9318 COMMENT: on|off
9319 LOC: Adaptation::Icap::TheConfig.preview_enable
9320 DEFAULT: on
9321 DOC_START
9322 The ICAP Preview feature allows the ICAP server to handle the
9323 HTTP message by looking only at the beginning of the message body
9324 or even without receiving the body at all. In some environments,
9325 previews greatly speedup ICAP processing.
9326
9327 During an ICAP OPTIONS transaction, the server may tell Squid what
9328 HTTP messages should be previewed and how big the preview should be.
9329 Squid will not use Preview if the server did not request one.
9330
9331 To disable ICAP Preview for all ICAP services, regardless of
9332 individual ICAP server OPTIONS responses, set this option to "off".
9333 Example:
9334 icap_preview_enable off
9335 DOC_END
9336
9337 NAME: icap_preview_size
9338 TYPE: int
9339 IFDEF: ICAP_CLIENT
9340 LOC: Adaptation::Icap::TheConfig.preview_size
9341 DEFAULT: -1
9342 DEFAULT_DOC: No preview sent.
9343 DOC_START
9344 The default size of preview data to be sent to the ICAP server.
9345 This value might be overwritten on a per server basis by OPTIONS requests.
9346 DOC_END
9347
9348 NAME: icap_206_enable
9349 TYPE: onoff
9350 IFDEF: ICAP_CLIENT
9351 COMMENT: on|off
9352 LOC: Adaptation::Icap::TheConfig.allow206_enable
9353 DEFAULT: on
9354 DOC_START
9355 206 (Partial Content) responses is an ICAP extension that allows the
9356 ICAP agents to optionally combine adapted and original HTTP message
9357 content. The decision to combine is postponed until the end of the
9358 ICAP response. Squid supports Partial Content extension by default.
9359
9360 Activation of the Partial Content extension is negotiated with each
9361 ICAP service during OPTIONS exchange. Most ICAP servers should handle
9362 negotiation correctly even if they do not support the extension, but
9363 some might fail. To disable Partial Content support for all ICAP
9364 services and to avoid any negotiation, set this option to "off".
9365
9366 Example:
9367 icap_206_enable off
9368 DOC_END
9369
9370 NAME: icap_default_options_ttl
9371 TYPE: int
9372 IFDEF: ICAP_CLIENT
9373 LOC: Adaptation::Icap::TheConfig.default_options_ttl
9374 DEFAULT: 60
9375 DOC_START
9376 The default TTL value for ICAP OPTIONS responses that don't have
9377 an Options-TTL header.
9378 DOC_END
9379
9380 NAME: icap_persistent_connections
9381 TYPE: onoff
9382 IFDEF: ICAP_CLIENT
9383 COMMENT: on|off
9384 LOC: Adaptation::Icap::TheConfig.reuse_connections
9385 DEFAULT: on
9386 DOC_START
9387 Whether or not Squid should use persistent connections to
9388 an ICAP server.
9389 DOC_END
9390
9391 NAME: adaptation_send_client_ip icap_send_client_ip
9392 TYPE: onoff
9393 IFDEF: USE_ADAPTATION
9394 COMMENT: on|off
9395 LOC: Adaptation::Config::send_client_ip
9396 DEFAULT: off
9397 DOC_START
9398 If enabled, Squid shares HTTP client IP information with adaptation
9399 services. For ICAP, Squid adds the X-Client-IP header to ICAP requests.
9400 For eCAP, Squid sets the libecap::metaClientIp transaction option.
9401
9402 See also: adaptation_uses_indirect_client
9403 DOC_END
9404
9405 NAME: adaptation_send_username icap_send_client_username
9406 TYPE: onoff
9407 IFDEF: USE_ADAPTATION
9408 COMMENT: on|off
9409 LOC: Adaptation::Config::send_username
9410 DEFAULT: off
9411 DOC_START
9412 This sends authenticated HTTP client username (if available) to
9413 the adaptation service.
9414
9415 For ICAP, the username value is encoded based on the
9416 icap_client_username_encode option and is sent using the header
9417 specified by the icap_client_username_header option.
9418 DOC_END
9419
9420 NAME: icap_client_username_header
9421 TYPE: string
9422 IFDEF: ICAP_CLIENT
9423 LOC: Adaptation::Icap::TheConfig.client_username_header
9424 DEFAULT: X-Client-Username
9425 DOC_START
9426 ICAP request header name to use for adaptation_send_username.
9427 DOC_END
9428
9429 NAME: icap_client_username_encode
9430 TYPE: onoff
9431 IFDEF: ICAP_CLIENT
9432 COMMENT: on|off
9433 LOC: Adaptation::Icap::TheConfig.client_username_encode
9434 DEFAULT: off
9435 DOC_START
9436 Whether to base64 encode the authenticated client username.
9437 DOC_END
9438
9439 NAME: icap_service
9440 TYPE: icap_service_type
9441 IFDEF: ICAP_CLIENT
9442 LOC: Adaptation::Icap::TheConfig
9443 DEFAULT: none
9444 DOC_START
9445 Defines a single ICAP service using the following format:
9446
9447 icap_service id vectoring_point uri [option ...]
9448
9449 id: ID
9450 an opaque identifier or name which is used to direct traffic to
9451 this specific service. Must be unique among all adaptation
9452 services in squid.conf.
9453
9454 vectoring_point: reqmod_precache|reqmod_postcache|respmod_precache|respmod_postcache
9455 This specifies at which point of transaction processing the
9456 ICAP service should be activated. *_postcache vectoring points
9457 are not yet supported.
9458
9459 uri: icap://servername:port/servicepath
9460 ICAP server and service location.
9461 icaps://servername:port/servicepath
9462 The "icap:" URI scheme is used for traditional ICAP server and
9463 service location (default port is 1344, connections are not
9464 encrypted). The "icaps:" URI scheme is for Secure ICAP
9465 services that use SSL/TLS-encrypted ICAP connections (by
9466 default, on port 11344).
9467
9468 ICAP does not allow a single service to handle both REQMOD and RESPMOD
9469 transactions. Squid does not enforce that requirement. You can specify
9470 services with the same service_url and different vectoring_points. You
9471 can even specify multiple identical services as long as their
9472 service_names differ.
9473
9474 To activate a service, use the adaptation_access directive. To group
9475 services, use adaptation_service_chain and adaptation_service_set.
9476
9477 Service options are separated by white space. ICAP services support
9478 the following name=value options:
9479
9480 bypass=on|off|1|0
9481 If set to 'on' or '1', the ICAP service is treated as
9482 optional. If the service cannot be reached or malfunctions,
9483 Squid will try to ignore any errors and process the message as
9484 if the service was not enabled. No all ICAP errors can be
9485 bypassed. If set to 0, the ICAP service is treated as
9486 essential and all ICAP errors will result in an error page
9487 returned to the HTTP client.
9488
9489 Bypass is off by default: services are treated as essential.
9490
9491 routing=on|off|1|0
9492 If set to 'on' or '1', the ICAP service is allowed to
9493 dynamically change the current message adaptation plan by
9494 returning a chain of services to be used next. The services
9495 are specified using the X-Next-Services ICAP response header
9496 value, formatted as a comma-separated list of service names.
9497 Each named service should be configured in squid.conf. Other
9498 services are ignored. An empty X-Next-Services value results
9499 in an empty plan which ends the current adaptation.
9500
9501 Dynamic adaptation plan may cross or cover multiple supported
9502 vectoring points in their natural processing order.
9503
9504 Routing is not allowed by default: the ICAP X-Next-Services
9505 response header is ignored.
9506
9507 ipv6=on|off
9508 Only has effect on split-stack systems. The default on those systems
9509 is to use IPv4-only connections. When set to 'on' this option will
9510 make Squid use IPv6-only connections to contact this ICAP service.
9511
9512 on-overload=block|bypass|wait|force
9513 If the service Max-Connections limit has been reached, do
9514 one of the following for each new ICAP transaction:
9515 * block: send an HTTP error response to the client
9516 * bypass: ignore the "over-connected" ICAP service
9517 * wait: wait (in a FIFO queue) for an ICAP connection slot
9518 * force: proceed, ignoring the Max-Connections limit
9519
9520 In SMP mode with N workers, each worker assumes the service
9521 connection limit is Max-Connections/N, even though not all
9522 workers may use a given service.
9523
9524 The default value is "bypass" if service is bypassable,
9525 otherwise it is set to "wait".
9526
9527
9528 max-conn=number
9529 Use the given number as the Max-Connections limit, regardless
9530 of the Max-Connections value given by the service, if any.
9531
9532 connection-encryption=on|off
9533 Determines the ICAP service effect on the connections_encrypted
9534 ACL.
9535
9536 The default is "on" for Secure ICAP services (i.e., those
9537 with the icaps:// service URIs scheme) and "off" for plain ICAP
9538 services.
9539
9540 Does not affect ICAP connections (e.g., does not turn Secure
9541 ICAP on or off).
9542
9543 ==== ICAPS / TLS OPTIONS ====
9544
9545 These options are used for Secure ICAP (icaps://....) services only.
9546
9547 tls-cert=/path/to/ssl/certificate
9548 A client X.509 certificate to use when connecting to
9549 this ICAP server.
9550
9551 tls-key=/path/to/ssl/key
9552 The private key corresponding to the previous
9553 tls-cert= option.
9554
9555 If tls-key= is not specified tls-cert= is assumed to
9556 reference a PEM file containing both the certificate
9557 and private key.
9558
9559 tls-cipher=... The list of valid TLS/SSL ciphers to use when connecting
9560 to this icap server.
9561
9562 tls-min-version=1.N
9563 The minimum TLS protocol version to permit. To control
9564 SSLv3 use the tls-options= parameter.
9565 Supported Values: 1.0 (default), 1.1, 1.2
9566
9567 tls-options=... Specify various OpenSSL library options:
9568
9569 NO_SSLv3 Disallow the use of SSLv3
9570
9571 SINGLE_DH_USE
9572 Always create a new key when using
9573 temporary/ephemeral DH key exchanges
9574
9575 ALL Enable various bug workarounds
9576 suggested as "harmless" by OpenSSL
9577 Be warned that this reduces SSL/TLS
9578 strength to some attacks.
9579
9580 See the OpenSSL SSL_CTX_set_options documentation for a
9581 more complete list. Options relevant only to SSLv2 are
9582 not supported.
9583
9584 tls-cafile= PEM file containing CA certificates to use when verifying
9585 the icap server certificate.
9586 Use to specify intermediate CA certificate(s) if not sent
9587 by the server. Or the full CA chain for the server when
9588 using the tls-default-ca=off flag.
9589 May be repeated to load multiple files.
9590
9591 tls-capath=... A directory containing additional CA certificates to
9592 use when verifying the icap server certificate.
9593 Requires OpenSSL or LibreSSL.
9594
9595 tls-crlfile=... A certificate revocation list file to use when
9596 verifying the icap server certificate.
9597
9598 tls-flags=... Specify various flags modifying the Squid TLS implementation:
9599
9600 DONT_VERIFY_PEER
9601 Accept certificates even if they fail to
9602 verify.
9603 DONT_VERIFY_DOMAIN
9604 Don't verify the icap server certificate
9605 matches the server name
9606
9607 tls-default-ca[=off]
9608 Whether to use the system Trusted CAs. Default is ON.
9609
9610 tls-domain= The icap server name as advertised in it's certificate.
9611 Used for verifying the correctness of the received icap
9612 server certificate. If not specified the icap server
9613 hostname extracted from ICAP URI will be used.
9614
9615 Older icap_service format without optional named parameters is
9616 deprecated but supported for backward compatibility.
9617
9618 Example:
9619 icap_service svcBlocker reqmod_precache icap://icap1.mydomain.net:1344/reqmod bypass=0
9620 icap_service svcLogger reqmod_precache icaps://icap2.mydomain.net:11344/reqmod routing=on
9621 DOC_END
9622
9623 NAME: icap_class
9624 TYPE: icap_class_type
9625 IFDEF: ICAP_CLIENT
9626 LOC: none
9627 DEFAULT: none
9628 DOC_START
9629 This deprecated option was documented to define an ICAP service
9630 chain, even though it actually defined a set of similar, redundant
9631 services, and the chains were not supported.
9632
9633 To define a set of redundant services, please use the
9634 adaptation_service_set directive. For service chains, use
9635 adaptation_service_chain.
9636 DOC_END
9637
9638 NAME: icap_access
9639 TYPE: icap_access_type
9640 IFDEF: ICAP_CLIENT
9641 LOC: none
9642 DEFAULT: none
9643 DOC_START
9644 This option is deprecated. Please use adaptation_access, which
9645 has the same ICAP functionality, but comes with better
9646 documentation, and eCAP support.
9647 DOC_END
9648
9649 COMMENT_START
9650 eCAP OPTIONS
9651 -----------------------------------------------------------------------------
9652 COMMENT_END
9653
9654 NAME: ecap_enable
9655 TYPE: onoff
9656 IFDEF: USE_ECAP
9657 COMMENT: on|off
9658 LOC: Adaptation::Ecap::TheConfig.onoff
9659 DEFAULT: off
9660 DOC_START
9661 Controls whether eCAP support is enabled.
9662 DOC_END
9663
9664 NAME: ecap_service
9665 TYPE: ecap_service_type
9666 IFDEF: USE_ECAP
9667 LOC: Adaptation::Ecap::TheConfig
9668 DEFAULT: none
9669 DOC_START
9670 Defines a single eCAP service
9671
9672 ecap_service id vectoring_point uri [option ...]
9673
9674 id: ID
9675 an opaque identifier or name which is used to direct traffic to
9676 this specific service. Must be unique among all adaptation
9677 services in squid.conf.
9678
9679 vectoring_point: reqmod_precache|reqmod_postcache|respmod_precache|respmod_postcache
9680 This specifies at which point of transaction processing the
9681 eCAP service should be activated. *_postcache vectoring points
9682 are not yet supported.
9683
9684 uri: ecap://vendor/service_name?custom&cgi=style&parameters=optional
9685 Squid uses the eCAP service URI to match this configuration
9686 line with one of the dynamically loaded services. Each loaded
9687 eCAP service must have a unique URI. Obtain the right URI from
9688 the service provider.
9689
9690 To activate a service, use the adaptation_access directive. To group
9691 services, use adaptation_service_chain and adaptation_service_set.
9692
9693 Service options are separated by white space. eCAP services support
9694 the following name=value options:
9695
9696 bypass=on|off|1|0
9697 If set to 'on' or '1', the eCAP service is treated as optional.
9698 If the service cannot be reached or malfunctions, Squid will try
9699 to ignore any errors and process the message as if the service
9700 was not enabled. No all eCAP errors can be bypassed.
9701 If set to 'off' or '0', the eCAP service is treated as essential
9702 and all eCAP errors will result in an error page returned to the
9703 HTTP client.
9704
9705 Bypass is off by default: services are treated as essential.
9706
9707 routing=on|off|1|0
9708 If set to 'on' or '1', the eCAP service is allowed to
9709 dynamically change the current message adaptation plan by
9710 returning a chain of services to be used next.
9711
9712 Dynamic adaptation plan may cross or cover multiple supported
9713 vectoring points in their natural processing order.
9714
9715 Routing is not allowed by default.
9716
9717 connection-encryption=on|off
9718 Determines the eCAP service effect on the connections_encrypted
9719 ACL.
9720
9721 Defaults to "on", which does not taint the master transaction
9722 w.r.t. that ACL.
9723
9724 Does not affect eCAP API calls.
9725
9726 Older ecap_service format without optional named parameters is
9727 deprecated but supported for backward compatibility.
9728
9729
9730 Example:
9731 ecap_service s1 reqmod_precache ecap://filters.R.us/leakDetector?on_error=block bypass=off
9732 ecap_service s2 respmod_precache ecap://filters.R.us/virusFilter config=/etc/vf.cfg bypass=on
9733 DOC_END
9734
9735 NAME: loadable_modules
9736 TYPE: wordlist
9737 IFDEF: USE_LOADABLE_MODULES
9738 LOC: Config.loadable_module_names
9739 DEFAULT: none
9740 DOC_START
9741 Instructs Squid to load the specified dynamic module(s) or activate
9742 preloaded module(s).
9743 Example:
9744 loadable_modules @DEFAULT_PREFIX@/lib/MinimalAdapter.so
9745 DOC_END
9746
9747 COMMENT_START
9748 MESSAGE ADAPTATION OPTIONS
9749 -----------------------------------------------------------------------------
9750 COMMENT_END
9751
9752 NAME: adaptation_service_set
9753 TYPE: adaptation_service_set_type
9754 IFDEF: USE_ADAPTATION
9755 LOC: none
9756 DEFAULT: none
9757 DOC_START
9758
9759 Configures an ordered set of similar, redundant services. This is
9760 useful when hot standby or backup adaptation servers are available.
9761
9762 adaptation_service_set set_name service_name1 service_name2 ...
9763
9764 The named services are used in the set declaration order. The first
9765 applicable adaptation service from the set is used first. The next
9766 applicable service is tried if and only if the transaction with the
9767 previous service fails and the message waiting to be adapted is still
9768 intact.
9769
9770 When adaptation starts, broken services are ignored as if they were
9771 not a part of the set. A broken service is a down optional service.
9772
9773 The services in a set must be attached to the same vectoring point
9774 (e.g., pre-cache) and use the same adaptation method (e.g., REQMOD).
9775
9776 If all services in a set are optional then adaptation failures are
9777 bypassable. If all services in the set are essential, then a
9778 transaction failure with one service may still be retried using
9779 another service from the set, but when all services fail, the master
9780 transaction fails as well.
9781
9782 A set may contain a mix of optional and essential services, but that
9783 is likely to lead to surprising results because broken services become
9784 ignored (see above), making previously bypassable failures fatal.
9785 Technically, it is the bypassability of the last failed service that
9786 matters.
9787
9788 See also: adaptation_access adaptation_service_chain
9789
9790 Example:
9791 adaptation_service_set svcBlocker urlFilterPrimary urlFilterBackup
9792 adaptation service_set svcLogger loggerLocal loggerRemote
9793 DOC_END
9794
9795 NAME: adaptation_service_chain
9796 TYPE: adaptation_service_chain_type
9797 IFDEF: USE_ADAPTATION
9798 LOC: none
9799 DEFAULT: none
9800 DOC_START
9801
9802 Configures a list of complementary services that will be applied
9803 one-by-one, forming an adaptation chain or pipeline. This is useful
9804 when Squid must perform different adaptations on the same message.
9805
9806 adaptation_service_chain chain_name service_name1 svc_name2 ...
9807
9808 The named services are used in the chain declaration order. The first
9809 applicable adaptation service from the chain is used first. The next
9810 applicable service is applied to the successful adaptation results of
9811 the previous service in the chain.
9812
9813 When adaptation starts, broken services are ignored as if they were
9814 not a part of the chain. A broken service is a down optional service.
9815
9816 Request satisfaction terminates the adaptation chain because Squid
9817 does not currently allow declaration of RESPMOD services at the
9818 "reqmod_precache" vectoring point (see icap_service or ecap_service).
9819
9820 The services in a chain must be attached to the same vectoring point
9821 (e.g., pre-cache) and use the same adaptation method (e.g., REQMOD).
9822
9823 A chain may contain a mix of optional and essential services. If an
9824 essential adaptation fails (or the failure cannot be bypassed for
9825 other reasons), the master transaction fails. Otherwise, the failure
9826 is bypassed as if the failed adaptation service was not in the chain.
9827
9828 See also: adaptation_access adaptation_service_set
9829
9830 Example:
9831 adaptation_service_chain svcRequest requestLogger urlFilter leakDetector
9832 DOC_END
9833
9834 NAME: adaptation_access
9835 TYPE: adaptation_access_type
9836 IFDEF: USE_ADAPTATION
9837 LOC: none
9838 DEFAULT: none
9839 DEFAULT_DOC: Allow, unless rules exist in squid.conf.
9840 DOC_START
9841 Sends an HTTP transaction to an ICAP or eCAP adaptation service.
9842
9843 adaptation_access service_name allow|deny [!]aclname...
9844 adaptation_access set_name allow|deny [!]aclname...
9845
9846 At each supported vectoring point, the adaptation_access
9847 statements are processed in the order they appear in this
9848 configuration file. Statements pointing to the following services
9849 are ignored (i.e., skipped without checking their ACL):
9850
9851 - services serving different vectoring points
9852 - "broken-but-bypassable" services
9853 - "up" services configured to ignore such transactions
9854 (e.g., based on the ICAP Transfer-Ignore header).
9855
9856 When a set_name is used, all services in the set are checked
9857 using the same rules, to find the first applicable one. See
9858 adaptation_service_set for details.
9859
9860 If an access list is checked and there is a match, the
9861 processing stops: For an "allow" rule, the corresponding
9862 adaptation service is used for the transaction. For a "deny"
9863 rule, no adaptation service is activated.
9864
9865 It is currently not possible to apply more than one adaptation
9866 service at the same vectoring point to the same HTTP transaction.
9867
9868 See also: icap_service and ecap_service
9869
9870 Example:
9871 adaptation_access service_1 allow all
9872 DOC_END
9873
9874 NAME: adaptation_service_iteration_limit
9875 TYPE: int
9876 IFDEF: USE_ADAPTATION
9877 LOC: Adaptation::Config::service_iteration_limit
9878 DEFAULT: 16
9879 DOC_START
9880 Limits the number of iterations allowed when applying adaptation
9881 services to a message. If your longest adaptation set or chain
9882 may have more than 16 services, increase the limit beyond its
9883 default value of 16. If detecting infinite iteration loops sooner
9884 is critical, make the iteration limit match the actual number
9885 of services in your longest adaptation set or chain.
9886
9887 Infinite adaptation loops are most likely with routing services.
9888
9889 See also: icap_service routing=1
9890 DOC_END
9891
9892 NAME: adaptation_masterx_shared_names
9893 TYPE: string
9894 IFDEF: USE_ADAPTATION
9895 LOC: Adaptation::Config::masterx_shared_name
9896 DEFAULT: none
9897 DOC_START
9898 For each master transaction (i.e., the HTTP request and response
9899 sequence, including all related ICAP and eCAP exchanges), Squid
9900 maintains a table of metadata. The table entries are (name, value)
9901 pairs shared among eCAP and ICAP exchanges. The table is destroyed
9902 with the master transaction.
9903
9904 This option specifies the table entry names that Squid must accept
9905 from and forward to the adaptation transactions.
9906
9907 An ICAP REQMOD or RESPMOD transaction may set an entry in the
9908 shared table by returning an ICAP header field with a name
9909 specified in adaptation_masterx_shared_names.
9910
9911 An eCAP REQMOD or RESPMOD transaction may set an entry in the
9912 shared table by implementing the libecap::visitEachOption() API
9913 to provide an option with a name specified in
9914 adaptation_masterx_shared_names.
9915
9916 Squid will store and forward the set entry to subsequent adaptation
9917 transactions within the same master transaction scope.
9918
9919 Only one shared entry name is supported at this time.
9920
9921 Example:
9922 # share authentication information among ICAP services
9923 adaptation_masterx_shared_names X-Subscriber-ID
9924 DOC_END
9925
9926 NAME: adaptation_meta
9927 TYPE: note
9928 IFDEF: USE_ADAPTATION
9929 LOC: Adaptation::Config::metaHeaders
9930 DEFAULT: none
9931 DOC_START
9932 This option allows Squid administrator to add custom ICAP request
9933 headers or eCAP options to Squid ICAP requests or eCAP transactions.
9934 Use it to pass custom authentication tokens and other
9935 transaction-state related meta information to an ICAP/eCAP service.
9936
9937 The addition of a meta header is ACL-driven:
9938 adaptation_meta name value [!]aclname ...
9939
9940 Processing for a given header name stops after the first ACL list match.
9941 Thus, it is impossible to add two headers with the same name. If no ACL
9942 lists match for a given header name, no such header is added. For
9943 example:
9944
9945 # do not debug transactions except for those that need debugging
9946 adaptation_meta X-Debug 1 needs_debugging
9947
9948 # log all transactions except for those that must remain secret
9949 adaptation_meta X-Log 1 !keep_secret
9950
9951 # mark transactions from users in the "G 1" group
9952 adaptation_meta X-Authenticated-Groups "G 1" authed_as_G1
9953
9954 The "value" parameter may be a regular squid.conf token or a "double
9955 quoted string". Within the quoted string, use backslash (\) to escape
9956 any character, which is currently only useful for escaping backslashes
9957 and double quotes. For example,
9958 "this string has one backslash (\\) and two \"quotes\""
9959
9960 Used adaptation_meta header values may be logged via %note
9961 logformat code. If multiple adaptation_meta headers with the same name
9962 are used during master transaction lifetime, the header values are
9963 logged in the order they were used and duplicate values are ignored
9964 (only the first repeated value will be logged).
9965 DOC_END
9966
9967 NAME: icap_retry
9968 TYPE: acl_access
9969 IFDEF: ICAP_CLIENT
9970 LOC: Adaptation::Icap::TheConfig.repeat
9971 DEFAULT_IF_NONE: deny all
9972 DOC_START
9973 This ACL determines which retriable ICAP transactions are
9974 retried. Transactions that received a complete ICAP response
9975 and did not have to consume or produce HTTP bodies to receive
9976 that response are usually retriable.
9977
9978 icap_retry allow|deny [!]aclname ...
9979
9980 Squid automatically retries some ICAP I/O timeouts and errors
9981 due to persistent connection race conditions.
9982
9983 See also: icap_retry_limit
9984 DOC_END
9985
9986 NAME: icap_retry_limit
9987 TYPE: int
9988 IFDEF: ICAP_CLIENT
9989 LOC: Adaptation::Icap::TheConfig.repeat_limit
9990 DEFAULT: 0
9991 DEFAULT_DOC: No retries are allowed.
9992 DOC_START
9993 Limits the number of retries allowed.
9994
9995 Communication errors due to persistent connection race
9996 conditions are unavoidable, automatically retried, and do not
9997 count against this limit.
9998
9999 See also: icap_retry
10000 DOC_END
10001
10002
10003 COMMENT_START
10004 DNS OPTIONS
10005 -----------------------------------------------------------------------------
10006 COMMENT_END
10007
10008 NAME: check_hostnames
10009 TYPE: onoff
10010 DEFAULT: off
10011 LOC: Config.onoff.check_hostnames
10012 DOC_START
10013 For security and stability reasons Squid can check
10014 hostnames for Internet standard RFC compliance. If you want
10015 Squid to perform these checks turn this directive on.
10016 DOC_END
10017
10018 NAME: allow_underscore
10019 TYPE: onoff
10020 DEFAULT: on
10021 LOC: Config.onoff.allow_underscore
10022 DOC_START
10023 Underscore characters is not strictly allowed in Internet hostnames
10024 but nevertheless used by many sites. Set this to off if you want
10025 Squid to be strict about the standard.
10026 This check is performed only when check_hostnames is set to on.
10027 DOC_END
10028
10029 NAME: dns_retransmit_interval
10030 TYPE: time_msec
10031 DEFAULT: 5 seconds
10032 LOC: Config.Timeout.idns_retransmit
10033 DOC_START
10034 Initial retransmit interval for DNS queries. The interval is
10035 doubled each time all configured DNS servers have been tried.
10036 DOC_END
10037
10038 NAME: dns_timeout
10039 TYPE: time_msec
10040 DEFAULT: 30 seconds
10041 LOC: Config.Timeout.idns_query
10042 DOC_START
10043 DNS Query timeout. If no response is received to a DNS query
10044 within this time all DNS servers for the queried domain
10045 are assumed to be unavailable.
10046 DOC_END
10047
10048 NAME: dns_packet_max
10049 TYPE: b_ssize_t
10050 DEFAULT_DOC: EDNS disabled
10051 DEFAULT: none
10052 LOC: Config.dns.packet_max
10053 DOC_START
10054 Maximum number of bytes packet size to advertise via EDNS.
10055 Set to "none" to disable EDNS large packet support.
10056
10057 For legacy reasons DNS UDP replies will default to 512 bytes which
10058 is too small for many responses. EDNS provides a means for Squid to
10059 negotiate receiving larger responses back immediately without having
10060 to failover with repeat requests. Responses larger than this limit
10061 will retain the old behaviour of failover to TCP DNS.
10062
10063 Squid has no real fixed limit internally, but allowing packet sizes
10064 over 1500 bytes requires network jumbogram support and is usually not
10065 necessary.
10066
10067 WARNING: The RFC also indicates that some older resolvers will reply
10068 with failure of the whole request if the extension is added. Some
10069 resolvers have already been identified which will reply with mangled
10070 EDNS response on occasion. Usually in response to many-KB jumbogram
10071 sizes being advertised by Squid.
10072 Squid will currently treat these both as an unable-to-resolve domain
10073 even if it would be resolvable without EDNS.
10074 DOC_END
10075
10076 NAME: dns_defnames
10077 COMMENT: on|off
10078 TYPE: onoff
10079 DEFAULT: off
10080 DEFAULT_DOC: Search for single-label domain names is disabled.
10081 LOC: Config.onoff.res_defnames
10082 DOC_START
10083 Normally the RES_DEFNAMES resolver option is disabled
10084 (see res_init(3)). This prevents caches in a hierarchy
10085 from interpreting single-component hostnames locally. To allow
10086 Squid to handle single-component names, enable this option.
10087 DOC_END
10088
10089 NAME: dns_multicast_local
10090 COMMENT: on|off
10091 TYPE: onoff
10092 DEFAULT: off
10093 DEFAULT_DOC: Search for .local and .arpa names is disabled.
10094 LOC: Config.onoff.dns_mdns
10095 DOC_START
10096 When set to on, Squid sends multicast DNS lookups on the local
10097 network for domains ending in .local and .arpa.
10098 This enables local servers and devices to be contacted in an
10099 ad-hoc or zero-configuration network environment.
10100 DOC_END
10101
10102 NAME: dns_nameservers
10103 TYPE: SBufList
10104 DEFAULT: none
10105 DEFAULT_DOC: Use operating system definitions
10106 LOC: Config.dns.nameservers
10107 DOC_START
10108 Use this if you want to specify a list of DNS name servers
10109 (IP addresses) to use instead of those given in your
10110 /etc/resolv.conf file.
10111
10112 On Windows platforms, if no value is specified here or in
10113 the /etc/resolv.conf file, the list of DNS name servers are
10114 taken from the Windows registry, both static and dynamic DHCP
10115 configurations are supported.
10116
10117 Example: dns_nameservers 10.0.0.1 192.172.0.4
10118 DOC_END
10119
10120 NAME: hosts_file
10121 TYPE: string
10122 DEFAULT: @DEFAULT_HOSTS@
10123 LOC: Config.etcHostsPath
10124 DOC_START
10125 Location of the host-local IP name-address associations
10126 database. Most Operating Systems have such a file on different
10127 default locations:
10128 - Un*X & Linux: /etc/hosts
10129 - Windows NT/2000: %SystemRoot%\system32\drivers\etc\hosts
10130 (%SystemRoot% value install default is c:\winnt)
10131 - Windows XP/2003: %SystemRoot%\system32\drivers\etc\hosts
10132 (%SystemRoot% value install default is c:\windows)
10133 - Windows 9x/Me: %windir%\hosts
10134 (%windir% value is usually c:\windows)
10135 - Cygwin: /etc/hosts
10136
10137 The file contains newline-separated definitions, in the
10138 form ip_address_in_dotted_form name [name ...] names are
10139 whitespace-separated. Lines beginning with an hash (#)
10140 character are comments.
10141
10142 The file is checked at startup and upon configuration.
10143 If set to 'none', it won't be checked.
10144 If append_domain is used, that domain will be added to
10145 domain-local (i.e. not containing any dot character) host
10146 definitions.
10147 DOC_END
10148
10149 NAME: append_domain
10150 TYPE: string
10151 LOC: Config.appendDomain
10152 DEFAULT: none
10153 DEFAULT_DOC: Use operating system definitions
10154 DOC_START
10155 Appends local domain name to hostnames without any dots in
10156 them. append_domain must begin with a period.
10157
10158 Be warned there are now Internet names with no dots in
10159 them using only top-domain names, so setting this may
10160 cause some Internet sites to become unavailable.
10161
10162 Example:
10163 append_domain .yourdomain.com
10164 DOC_END
10165
10166 NAME: ignore_unknown_nameservers
10167 TYPE: onoff
10168 LOC: Config.onoff.ignore_unknown_nameservers
10169 DEFAULT: on
10170 DOC_START
10171 By default Squid checks that DNS responses are received
10172 from the same IP addresses they are sent to. If they
10173 don't match, Squid ignores the response and writes a warning
10174 message to cache.log. You can allow responses from unknown
10175 nameservers by setting this option to 'off'.
10176 DOC_END
10177
10178 NAME: ipcache_size
10179 COMMENT: (number of entries)
10180 TYPE: int
10181 DEFAULT: 1024
10182 LOC: Config.ipcache.size
10183 DOC_START
10184 Maximum number of DNS IP cache entries.
10185 DOC_END
10186
10187 NAME: ipcache_low
10188 COMMENT: (percent)
10189 TYPE: int
10190 DEFAULT: 90
10191 LOC: Config.ipcache.low
10192 DOC_NONE
10193
10194 NAME: ipcache_high
10195 COMMENT: (percent)
10196 TYPE: int
10197 DEFAULT: 95
10198 LOC: Config.ipcache.high
10199 DOC_START
10200 The size, low-, and high-water marks for the IP cache.
10201 DOC_END
10202
10203 NAME: fqdncache_size
10204 COMMENT: (number of entries)
10205 TYPE: int
10206 DEFAULT: 1024
10207 LOC: Config.fqdncache.size
10208 DOC_START
10209 Maximum number of FQDN cache entries.
10210 DOC_END
10211
10212 COMMENT_START
10213 MISCELLANEOUS
10214 -----------------------------------------------------------------------------
10215 COMMENT_END
10216
10217 NAME: configuration_includes_quoted_values
10218 COMMENT: on|off
10219 TYPE: configuration_includes_quoted_values
10220 DEFAULT: off
10221 LOC: ConfigParser::RecognizeQuotedValues
10222 DOC_START
10223 If set, Squid will recognize each "quoted string" after a configuration
10224 directive as a single parameter. The quotes are stripped before the
10225 parameter value is interpreted or used.
10226 See "Values with spaces, quotes, and other special characters"
10227 section for more details.
10228 DOC_END
10229
10230 NAME: memory_pools
10231 COMMENT: on|off
10232 TYPE: onoff
10233 DEFAULT: on
10234 LOC: Config.onoff.mem_pools
10235 DOC_START
10236 If set, Squid will keep pools of allocated (but unused) memory
10237 available for future use. If memory is a premium on your
10238 system and you believe your malloc library outperforms Squid
10239 routines, disable this.
10240 DOC_END
10241
10242 NAME: memory_pools_limit
10243 COMMENT: (bytes)
10244 TYPE: b_int64_t
10245 DEFAULT: 5 MB
10246 LOC: Config.MemPools.limit
10247 DOC_START
10248 Used only with memory_pools on:
10249 memory_pools_limit 50 MB
10250
10251 If set to a non-zero value, Squid will keep at most the specified
10252 limit of allocated (but unused) memory in memory pools. All free()
10253 requests that exceed this limit will be handled by your malloc
10254 library. Squid does not pre-allocate any memory, just safe-keeps
10255 objects that otherwise would be free()d. Thus, it is safe to set
10256 memory_pools_limit to a reasonably high value even if your
10257 configuration will use less memory.
10258
10259 If set to none, Squid will keep all memory it can. That is, there
10260 will be no limit on the total amount of memory used for safe-keeping.
10261
10262 To disable memory allocation optimization, do not set
10263 memory_pools_limit to 0 or none. Set memory_pools to "off" instead.
10264
10265 An overhead for maintaining memory pools is not taken into account
10266 when the limit is checked. This overhead is close to four bytes per
10267 object kept. However, pools may actually _save_ memory because of
10268 reduced memory thrashing in your malloc library.
10269 DOC_END
10270
10271 NAME: forwarded_for
10272 COMMENT: on|off|transparent|truncate|delete
10273 TYPE: string
10274 DEFAULT: on
10275 LOC: opt_forwarded_for
10276 DOC_START
10277 If set to "on", Squid will append your client's IP address
10278 in the HTTP requests it forwards. By default it looks like:
10279
10280 X-Forwarded-For: 192.1.2.3
10281
10282 If set to "off", it will appear as
10283
10284 X-Forwarded-For: unknown
10285
10286 If set to "transparent", Squid will not alter the
10287 X-Forwarded-For header in any way.
10288
10289 If set to "delete", Squid will delete the entire
10290 X-Forwarded-For header.
10291
10292 If set to "truncate", Squid will remove all existing
10293 X-Forwarded-For entries, and place the client IP as the sole entry.
10294 DOC_END
10295
10296 NAME: cachemgr_passwd
10297 TYPE: cachemgrpasswd
10298 DEFAULT: none
10299 DEFAULT_DOC: No password. Actions which require password are denied.
10300 LOC: Config.passwd_list
10301 DOC_START
10302 Specify passwords for cachemgr operations.
10303
10304 Usage: cachemgr_passwd password action action ...
10305
10306 Some valid actions are (see cache manager menu for a full list):
10307 5min
10308 60min
10309 asndb
10310 authenticator
10311 cbdata
10312 client_list
10313 comm_incoming
10314 config *
10315 counters
10316 delay
10317 digest_stats
10318 dns
10319 events
10320 filedescriptors
10321 fqdncache
10322 histograms
10323 http_headers
10324 info
10325 io
10326 ipcache
10327 mem
10328 menu
10329 netdb
10330 non_peers
10331 objects
10332 offline_toggle *
10333 pconn
10334 peer_select
10335 reconfigure *
10336 redirector
10337 refresh
10338 server_list
10339 shutdown *
10340 store_digest
10341 storedir
10342 utilization
10343 via_headers
10344 vm_objects
10345
10346 * Indicates actions which will not be performed without a
10347 valid password, others can be performed if not listed here.
10348
10349 To disable an action, set the password to "disable".
10350 To allow performing an action without a password, set the
10351 password to "none".
10352
10353 Use the keyword "all" to set the same password for all actions.
10354
10355 Example:
10356 cachemgr_passwd secret shutdown
10357 cachemgr_passwd lesssssssecret info stats/objects
10358 cachemgr_passwd disable all
10359 DOC_END
10360
10361 NAME: client_db
10362 COMMENT: on|off
10363 TYPE: onoff
10364 DEFAULT: on
10365 LOC: Config.onoff.client_db
10366 DOC_START
10367 If you want to disable collecting per-client statistics,
10368 turn off client_db here.
10369 DOC_END
10370
10371 NAME: refresh_all_ims
10372 COMMENT: on|off
10373 TYPE: onoff
10374 DEFAULT: off
10375 LOC: Config.onoff.refresh_all_ims
10376 DOC_START
10377 When you enable this option, squid will always check
10378 the origin server for an update when a client sends an
10379 If-Modified-Since request. Many browsers use IMS
10380 requests when the user requests a reload, and this
10381 ensures those clients receive the latest version.
10382
10383 By default (off), squid may return a Not Modified response
10384 based on the age of the cached version.
10385 DOC_END
10386
10387 NAME: reload_into_ims
10388 IFDEF: USE_HTTP_VIOLATIONS
10389 COMMENT: on|off
10390 TYPE: onoff
10391 DEFAULT: off
10392 LOC: Config.onoff.reload_into_ims
10393 DOC_START
10394 When you enable this option, client no-cache or ``reload''
10395 requests will be changed to If-Modified-Since requests.
10396 Doing this VIOLATES the HTTP standard. Enabling this
10397 feature could make you liable for problems which it
10398 causes.
10399
10400 see also refresh_pattern for a more selective approach.
10401 DOC_END
10402
10403 NAME: connect_retries
10404 TYPE: int
10405 LOC: Config.connect_retries
10406 DEFAULT: 0
10407 DEFAULT_DOC: Do not retry failed connections.
10408 DOC_START
10409 Limits the number of reopening attempts when establishing a single
10410 TCP connection. All these attempts must still complete before the
10411 applicable connection opening timeout expires.
10412
10413 By default and when connect_retries is set to zero, Squid does not
10414 retry failed connection opening attempts.
10415
10416 The (not recommended) maximum is 10 tries. An attempt to configure a
10417 higher value results in the value of 10 being used (with a warning).
10418
10419 Squid may open connections to retry various high-level forwarding
10420 failures. For an outside observer, that activity may look like a
10421 low-level connection reopening attempt, but those high-level retries
10422 are governed by forward_max_tries instead.
10423
10424 See also: connect_timeout, forward_timeout, icap_connect_timeout,
10425 ident_timeout, and forward_max_tries.
10426 DOC_END
10427
10428 NAME: retry_on_error
10429 TYPE: onoff
10430 LOC: Config.retry.onerror
10431 DEFAULT: off
10432 DOC_START
10433 If set to ON Squid will automatically retry requests when
10434 receiving an error response with status 403 (Forbidden),
10435 500 (Internal Error), 501 or 503 (Service not available).
10436 Status 502 and 504 (Gateway errors) are always retried.
10437
10438 This is mainly useful if you are in a complex cache hierarchy to
10439 work around access control errors.
10440
10441 NOTE: This retry will attempt to find another working destination.
10442 Which is different from the server which just failed.
10443 DOC_END
10444
10445 NAME: as_whois_server
10446 TYPE: string
10447 LOC: Config.as_whois_server
10448 DEFAULT: whois.ra.net
10449 DOC_START
10450 WHOIS server to query for AS numbers. NOTE: AS numbers are
10451 queried only when Squid starts up, not for every request.
10452 DOC_END
10453
10454 NAME: offline_mode
10455 TYPE: onoff
10456 LOC: Config.onoff.offline
10457 DEFAULT: off
10458 DOC_START
10459 Enable this option and Squid will never try to validate cached
10460 objects.
10461 DOC_END
10462
10463 NAME: uri_whitespace
10464 TYPE: uri_whitespace
10465 LOC: Config.uri_whitespace
10466 DEFAULT: strip
10467 DOC_START
10468 What to do with requests that have whitespace characters in the
10469 URI. Options:
10470
10471 strip: The whitespace characters are stripped out of the URL.
10472 This is the behavior recommended by RFC2396 and RFC3986
10473 for tolerant handling of generic URI.
10474 NOTE: This is one difference between generic URI and HTTP URLs.
10475
10476 deny: The request is denied. The user receives an "Invalid
10477 Request" message.
10478 This is the behaviour recommended by RFC2616 for safe
10479 handling of HTTP request URL.
10480
10481 allow: The request is allowed and the URI is not changed. The
10482 whitespace characters remain in the URI. Note the
10483 whitespace is passed to redirector processes if they
10484 are in use.
10485 Note this may be considered a violation of RFC2616
10486 request parsing where whitespace is prohibited in the
10487 URL field.
10488
10489 encode: The request is allowed and the whitespace characters are
10490 encoded according to RFC1738.
10491
10492 chop: The request is allowed and the URI is chopped at the
10493 first whitespace.
10494
10495
10496 NOTE the current Squid implementation of encode and chop violates
10497 RFC2616 by not using a 301 redirect after altering the URL.
10498 DOC_END
10499
10500 NAME: chroot
10501 TYPE: string
10502 LOC: Config.chroot_dir
10503 DEFAULT: none
10504 DOC_START
10505 Specifies a directory where Squid should do a chroot() while
10506 initializing. This also causes Squid to fully drop root
10507 privileges after initializing. This means, for example, if you
10508 use a HTTP port less than 1024 and try to reconfigure, you may
10509 get an error saying that Squid can not open the port.
10510 DOC_END
10511
10512 NAME: pipeline_prefetch
10513 TYPE: pipelinePrefetch
10514 LOC: Config.pipeline_max_prefetch
10515 DEFAULT: 0
10516 DEFAULT_DOC: Do not pre-parse pipelined requests.
10517 DOC_START
10518 HTTP clients may send a pipeline of 1+N requests to Squid using a
10519 single connection, without waiting for Squid to respond to the first
10520 of those requests. This option limits the number of concurrent
10521 requests Squid will try to handle in parallel. If set to N, Squid
10522 will try to receive and process up to 1+N requests on the same
10523 connection concurrently.
10524
10525 Defaults to 0 (off) for bandwidth management and access logging
10526 reasons.
10527
10528 NOTE: pipelining requires persistent connections to clients.
10529
10530 WARNING: pipelining breaks NTLM and Negotiate/Kerberos authentication.
10531 DOC_END
10532
10533 NAME: high_response_time_warning
10534 TYPE: int
10535 COMMENT: (msec)
10536 LOC: Config.warnings.high_rptm
10537 DEFAULT: 0
10538 DEFAULT_DOC: disabled.
10539 DOC_START
10540 If the one-minute median response time exceeds this value,
10541 Squid prints a WARNING with debug level 0 to get the
10542 administrators attention. The value is in milliseconds.
10543 DOC_END
10544
10545 NAME: high_page_fault_warning
10546 TYPE: int
10547 LOC: Config.warnings.high_pf
10548 DEFAULT: 0
10549 DEFAULT_DOC: disabled.
10550 DOC_START
10551 If the one-minute average page fault rate exceeds this
10552 value, Squid prints a WARNING with debug level 0 to get
10553 the administrators attention. The value is in page faults
10554 per second.
10555 DOC_END
10556
10557 NAME: high_memory_warning
10558 TYPE: b_size_t
10559 LOC: Config.warnings.high_memory
10560 IFDEF: HAVE_MSTATS&&HAVE_GNUMALLOC_H
10561 DEFAULT: 0 KB
10562 DEFAULT_DOC: disabled.
10563 DOC_START
10564 If the memory usage (as determined by gnumalloc, if available and used)
10565 exceeds this amount, Squid prints a WARNING with debug level 0 to get
10566 the administrators attention.
10567 DOC_END
10568 # TODO: link high_memory_warning to mempools?
10569
10570 NAME: sleep_after_fork
10571 COMMENT: (microseconds)
10572 TYPE: int
10573 LOC: Config.sleep_after_fork
10574 DEFAULT: 0
10575 DOC_START
10576 When this is set to a non-zero value, the main Squid process
10577 sleeps the specified number of microseconds after a fork()
10578 system call. This sleep may help the situation where your
10579 system reports fork() failures due to lack of (virtual)
10580 memory. Note, however, if you have a lot of child
10581 processes, these sleep delays will add up and your
10582 Squid will not service requests for some amount of time
10583 until all the child processes have been started.
10584 On Windows value less then 1000 (1 milliseconds) are
10585 rounded to 1000.
10586 DOC_END
10587
10588 NAME: windows_ipaddrchangemonitor
10589 IFDEF: _SQUID_WINDOWS_
10590 COMMENT: on|off
10591 TYPE: onoff
10592 DEFAULT: on
10593 LOC: Config.onoff.WIN32_IpAddrChangeMonitor
10594 DOC_START
10595 On Windows Squid by default will monitor IP address changes and will
10596 reconfigure itself after any detected event. This is very useful for
10597 proxies connected to internet with dial-up interfaces.
10598 In some cases (a Proxy server acting as VPN gateway is one) it could be
10599 desiderable to disable this behaviour setting this to 'off'.
10600 Note: after changing this, Squid service must be restarted.
10601 DOC_END
10602
10603 NAME: eui_lookup
10604 TYPE: onoff
10605 IFDEF: USE_SQUID_EUI
10606 DEFAULT: on
10607 LOC: Eui::TheConfig.euiLookup
10608 DOC_START
10609 Whether to lookup the EUI or MAC address of a connected client.
10610 DOC_END
10611
10612 NAME: max_filedescriptors max_filedesc
10613 TYPE: int
10614 DEFAULT: 0
10615 DEFAULT_DOC: Use operating system soft limit set by ulimit.
10616 LOC: Config.max_filedescriptors
10617 DOC_START
10618 Set the maximum number of filedescriptors, either below the
10619 operating system default or up to the hard limit.
10620
10621 Remove from squid.conf to inherit the current ulimit soft
10622 limit setting.
10623
10624 Note: Changing this requires a restart of Squid. Also
10625 not all I/O types supports large values (eg on Windows).
10626 DOC_END
10627
10628 NAME: force_request_body_continuation
10629 TYPE: acl_access
10630 LOC: Config.accessList.forceRequestBodyContinuation
10631 DEFAULT: none
10632 DEFAULT_DOC: Deny, unless rules exist in squid.conf.
10633 DOC_START
10634 This option controls how Squid handles data upload requests from HTTP
10635 and FTP agents that require a "Please Continue" control message response
10636 to actually send the request body to Squid. It is mostly useful in
10637 adaptation environments.
10638
10639 When Squid receives an HTTP request with an "Expect: 100-continue"
10640 header or an FTP upload command (e.g., STOR), Squid normally sends the
10641 request headers or FTP command information to an adaptation service (or
10642 peer) and waits for a response. Most adaptation services (and some
10643 broken peers) may not respond to Squid at that stage because they may
10644 decide to wait for the HTTP request body or FTP data transfer. However,
10645 that request body or data transfer may never come because Squid has not
10646 responded with the HTTP 100 or FTP 150 (Please Continue) control message
10647 to the request sender yet!
10648
10649 An allow match tells Squid to respond with the HTTP 100 or FTP 150
10650 (Please Continue) control message on its own, before forwarding the
10651 request to an adaptation service or peer. Such a response usually forces
10652 the request sender to proceed with sending the body. A deny match tells
10653 Squid to delay that control response until the origin server confirms
10654 that the request body is needed. Delaying is the default behavior.
10655 DOC_END
10656
10657 NAME: http_upgrade_request_protocols
10658 TYPE: http_upgrade_request_protocols
10659 LOC: Config.http_upgrade_request_protocols
10660 DEFAULT: none
10661 DEFAULT_DOC: Upgrade header dropped, effectively blocking an upgrade attempt.
10662 DOC_START
10663 Controls client-initiated and server-confirmed switching from HTTP to
10664 another protocol (or to several protocols) using HTTP Upgrade mechanism
10665 defined in RFC 7230 Section 6.7. Squid itself does not understand the
10666 protocols being upgraded to and participates in the upgraded
10667 communication only as a dumb TCP proxy. Admins should not allow
10668 upgrading to protocols that require a more meaningful proxy
10669 participation.
10670
10671 Usage: http_upgrade_request_protocols <protocol> allow|deny [!]acl ...
10672
10673 The required "protocol" parameter is either an all-caps word OTHER or an
10674 explicit protocol name (e.g. "WebSocket") optionally followed by a slash
10675 and a version token (e.g. "HTTP/3"). Explicit protocol names and
10676 versions are case sensitive.
10677
10678 When an HTTP client sends an Upgrade request header, Squid iterates over
10679 the client-offered protocols and, for each protocol P (with an optional
10680 version V), evaluates the first non-empty set of
10681 http_upgrade_request_protocols rules (if any) from the following list:
10682
10683 * All rules with an explicit protocol name equal to P.
10684 * All rules that use OTHER instead of a protocol name.
10685
10686 In other words, rules using OTHER are considered for protocol P if and
10687 only if there are no rules mentioning P by name.
10688
10689 If both of the above sets are empty, then Squid removes protocol P from
10690 the Upgrade offer.
10691
10692 If the client sent a versioned protocol offer P/X, then explicit rules
10693 referring to the same-name but different-version protocol P/Y are
10694 declared inapplicable. Inapplicable rules are not evaluated (i.e. are
10695 ignored). However, inapplicable rules still belong to the first set of
10696 rules for P.
10697
10698 Within the applicable rule subset, individual rules are evaluated in
10699 their configuration order. If all ACLs of an applicable "allow" rule
10700 match, then the protocol offered by the client is forwarded to the next
10701 hop as is. If all ACLs of an applicable "deny" rule match, then the
10702 offer is dropped. If no applicable rules have matching ACLs, then the
10703 offer is also dropped. The first matching rule also ends rules
10704 evaluation for the offered protocol.
10705
10706 If all client-offered protocols are removed, then Squid forwards the
10707 client request without the Upgrade header. Squid never sends an empty
10708 Upgrade request header.
10709
10710 An Upgrade request header with a value violating HTTP syntax is dropped
10711 and ignored without an attempt to use extractable individual protocol
10712 offers.
10713
10714 Upon receiving an HTTP 101 (Switching Protocols) control message, Squid
10715 checks that the server listed at least one protocol name and sent a
10716 Connection:upgrade response header. Squid does not understand individual
10717 protocol naming and versioning concepts enough to implement stricter
10718 checks, but an admin can restrict HTTP 101 (Switching Protocols)
10719 responses further using http_reply_access. Responses denied by
10720 http_reply_access rules and responses flagged by the internal Upgrade
10721 checks result in HTTP 502 (Bad Gateway) ERR_INVALID_RESP errors and
10722 Squid-to-server connection closures.
10723
10724 If Squid sends an Upgrade request header, and the next hop (e.g., the
10725 origin server) responds with an acceptable HTTP 101 (Switching
10726 Protocols), then Squid forwards that message to the client and becomes
10727 a TCP tunnel.
10728
10729 The presence of an Upgrade request header alone does not preclude cache
10730 lookups. In other words, an Upgrade request might be satisfied from the
10731 cache, using regular HTTP caching rules.
10732
10733 This clause only supports fast acl types.
10734 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
10735
10736 Each of the following groups of configuration lines represents a
10737 separate configuration example:
10738
10739 # never upgrade to protocol Foo; all others are OK
10740 http_upgrade_request_protocols Foo deny all
10741 http_upgrade_request_protocols OTHER allow all
10742
10743 # only allow upgrades to protocol Bar (except for its first version)
10744 http_upgrade_request_protocols Bar/1 deny all
10745 http_upgrade_request_protocols Bar allow all
10746 http_upgrade_request_protocols OTHER deny all # this rule is optional
10747
10748 # only allow upgrades to protocol Baz, and only if Baz is the only offer
10749 acl UpgradeHeaderHasMultipleOffers ...
10750 http_upgrade_request_protocols Baz deny UpgradeHeaderHasMultipleOffers
10751 http_upgrade_request_protocols Baz allow all
10752 DOC_END
10753
10754 NAME: server_pconn_for_nonretriable
10755 TYPE: acl_access
10756 DEFAULT: none
10757 DEFAULT_DOC: Open new connections for forwarding requests Squid cannot retry safely.
10758 LOC: Config.accessList.serverPconnForNonretriable
10759 DOC_START
10760 This option provides fine-grained control over persistent connection
10761 reuse when forwarding HTTP requests that Squid cannot retry. It is useful
10762 in environments where opening new connections is very expensive
10763 (e.g., all connections are secured with TLS with complex client and server
10764 certificate validation) and race conditions associated with persistent
10765 connections are very rare and/or only cause minor problems.
10766
10767 HTTP prohibits retrying unsafe and non-idempotent requests (e.g., POST).
10768 Squid limitations also prohibit retrying all requests with bodies (e.g., PUT).
10769 By default, when forwarding such "risky" requests, Squid opens a new
10770 connection to the server or cache_peer, even if there is an idle persistent
10771 connection available. When Squid is configured to risk sending a non-retriable
10772 request on a previously used persistent connection, and the server closes
10773 the connection before seeing that risky request, the user gets an error response
10774 from Squid. In most cases, that error response will be HTTP 502 (Bad Gateway)
10775 with ERR_ZERO_SIZE_OBJECT or ERR_WRITE_ERROR (peer connection reset) error detail.
10776
10777 If an allow rule matches, Squid reuses an available idle persistent connection
10778 (if any) for the request that Squid cannot retry. If a deny rule matches, then
10779 Squid opens a new connection for the request that Squid cannot retry.
10780
10781 This option does not affect requests that Squid can retry. They will reuse idle
10782 persistent connections (if any).
10783
10784 This clause only supports fast acl types.
10785 See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
10786
10787 Example:
10788 acl SpeedIsWorthTheRisk method POST
10789 server_pconn_for_nonretriable allow SpeedIsWorthTheRisk
10790 DOC_END
10791
10792 NAME: happy_eyeballs_connect_timeout
10793 COMMENT: (msec)
10794 TYPE: int
10795 DEFAULT: 250
10796 LOC: Config.happyEyeballs.connect_timeout
10797 DOC_START
10798 This Happy Eyeballs (RFC 8305) tuning directive specifies the minimum
10799 delay between opening a primary to-server connection and opening a
10800 spare to-server connection for the same master transaction. This delay
10801 is similar to the Connection Attempt Delay in RFC 8305, but it is only
10802 applied to the first spare connection attempt. Subsequent spare
10803 connection attempts use happy_eyeballs_connect_gap, and primary
10804 connection attempts are not artificially delayed at all.
10805
10806 Terminology: The "primary" and "spare" designations are determined by
10807 the order of DNS answers received by Squid: If Squid DNS AAAA query
10808 was answered first, then primary connections are connections to IPv6
10809 peer addresses (while spare connections use IPv4 addresses).
10810 Similarly, if Squid DNS A query was answered first, then primary
10811 connections are connections to IPv4 peer addresses (while spare
10812 connections use IPv6 addresses).
10813
10814 Shorter happy_eyeballs_connect_timeout values reduce master
10815 transaction response time, potentially improving user-perceived
10816 response times (i.e., making user eyeballs happier). Longer delays
10817 reduce both concurrent connection level and server bombardment with
10818 connection requests, potentially improving overall Squid performance
10819 and reducing the chance of being blocked by servers for opening too
10820 many unused connections.
10821
10822 RFC 8305 prohibits happy_eyeballs_connect_timeout values smaller than
10823 10 (milliseconds) to "avoid congestion collapse in the presence of
10824 high packet-loss rates".
10825
10826 The following Happy Eyeballs directives place additional connection
10827 opening restrictions: happy_eyeballs_connect_gap and
10828 happy_eyeballs_connect_limit.
10829 DOC_END
10830
10831 NAME: happy_eyeballs_connect_gap
10832 COMMENT: (msec)
10833 TYPE: int
10834 DEFAULT: -1
10835 DEFAULT_DOC: no artificial delays between spare attempts
10836 LOC: Config.happyEyeballs.connect_gap
10837 DOC_START
10838 This Happy Eyeballs (RFC 8305) tuning directive specifies the
10839 minimum delay between opening spare to-server connections (to any
10840 server; i.e. across all concurrent master transactions in a Squid
10841 instance). Each SMP worker currently multiplies the configured gap
10842 by the total number of workers so that the combined spare connection
10843 opening rate of a Squid instance obeys the configured limit. The
10844 workers do not coordinate connection openings yet; a micro burst
10845 of spare connection openings may violate the configured gap.
10846
10847 This directive has similar trade-offs as
10848 happy_eyeballs_connect_timeout, but its focus is on limiting traffic
10849 amplification effects for Squid as a whole, while
10850 happy_eyeballs_connect_timeout works on an individual master
10851 transaction level.
10852
10853 The following Happy Eyeballs directives place additional connection
10854 opening restrictions: happy_eyeballs_connect_timeout and
10855 happy_eyeballs_connect_limit. See the former for related terminology.
10856 DOC_END
10857
10858 NAME: happy_eyeballs_connect_limit
10859 TYPE: int
10860 DEFAULT: -1
10861 DEFAULT_DOC: no artificial limit on the number of concurrent spare attempts
10862 LOC: Config.happyEyeballs.connect_limit
10863 DOC_START
10864 This Happy Eyeballs (RFC 8305) tuning directive specifies the
10865 maximum number of spare to-server connections (to any server; i.e.
10866 across all concurrent master transactions in a Squid instance).
10867 Each SMP worker gets an equal share of the total limit. However,
10868 the workers do not share the actual connection counts yet, so one
10869 (busier) worker cannot "borrow" spare connection slots from another
10870 (less loaded) worker.
10871
10872 Setting this limit to zero disables concurrent use of primary and
10873 spare TCP connections: Spare connection attempts are made only after
10874 all primary attempts fail. However, Squid would still use the
10875 DNS-related optimizations of the Happy Eyeballs approach.
10876
10877 This directive has similar trade-offs as happy_eyeballs_connect_gap,
10878 but its focus is on limiting Squid overheads, while
10879 happy_eyeballs_connect_gap focuses on the origin server and peer
10880 overheads.
10881
10882 The following Happy Eyeballs directives place additional connection
10883 opening restrictions: happy_eyeballs_connect_timeout and
10884 happy_eyeballs_connect_gap. See the former for related terminology.
10885 DOC_END
10886
10887 EOF