Guest User

Squid config

a guest
Apr 15th, 2020
50
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 292.71 KB | None | 0 0
  1. WELCOME TO SQUID 3.5.27
  2. # ----------------------------
  3. #
  4. # This is the documentation for the Squid configuration file.
  5. # This documentation can also be found online at:
  6. # http://www.squid-cache.org/Doc/config/
  7. #
  8. # You may wish to look at the Squid home page and wiki for the
  9. # FAQ and other documentation:
  10. # http://www.squid-cache.org/
  11. # http://wiki.squid-cache.org/SquidFaq
  12. # http://wiki.squid-cache.org/ConfigExamples
  13. #
  14. # This documentation shows what the defaults for various directives
  15. # happen to be. If you don't need to change the default, you should
  16. # leave the line out of your squid.conf in most cases.
  17. #
  18. # In some cases "none" refers to no default setting at all,
  19. # while in other cases it refers to the value of the option
  20. # - the comments for that keyword indicate if this is the case.
  21. #
  22.  
  23. # Configuration options can be included using the "include" directive.
  24. # Include takes a list of files to include. Quoting and wildcards are
  25. # supported.
  26. #
  27. # For example,
  28. #
  29. # include /path/to/included/file/squid.acl.config
  30. #
  31. # Includes can be nested up to a hard-coded depth of 16 levels.
  32. # This arbitrary restriction is to prevent recursive include references
  33. # from causing Squid entering an infinite loop whilst trying to load
  34. # configuration files.
  35. #
  36. # Values with byte units
  37. #
  38. # Squid accepts size units on some size related directives. All
  39. # such directives are documented with a default value displaying
  40. # a unit.
  41. #
  42. # Units accepted by Squid are:
  43. # bytes - byte
  44. # KB - Kilobyte (1024 bytes)
  45. # MB - Megabyte
  46. # GB - Gigabyte
  47. #
  48. # Values with spaces, quotes, and other special characters
  49. #
  50. # Squid supports directive parameters with spaces, quotes, and other
  51. # special characters. Surround such parameters with "double quotes". Use
  52. # the configuration_includes_quoted_values directive to enable or
  53. # disable that support.
  54. #
  55. # Squid supports reading configuration option parameters from external
  56. # files using the syntax:
  57. # parameters("/path/filename")
  58. # For example:
  59. # acl whitelist dstdomain parameters("/etc/squid/whitelist.txt")
  60. #
  61. # Conditional configuration
  62. #
  63. # If-statements can be used to make configuration directives
  64. # depend on conditions:
  65. #
  66. # if <CONDITION>
  67. # ... regular configuration directives ...
  68. # [else
  69. # ... regular configuration directives ...]
  70. # endif
  71. #
  72. # The else part is optional. The keywords "if", "else", and "endif"
  73. # must be typed on their own lines, as if they were regular
  74. # configuration directives.
  75. #
  76. # NOTE: An else-if condition is not supported.
  77. #
  78. # These individual conditions types are supported:
  79. #
  80. # true
  81. # Always evaluates to true.
  82. # false
  83. # Always evaluates to false.
  84. # <integer> = <integer>
  85. # Equality comparison of two integer numbers.
  86. #
  87. #
  88. # SMP-Related Macros
  89. #
  90. # The following SMP-related preprocessor macros can be used.
  91. #
  92. # ${process_name} expands to the current Squid process "name"
  93. # (e.g., squid1, squid2, or cache1).
  94. #
  95. # ${process_number} expands to the current Squid process
  96. # identifier, which is an integer number (e.g., 1, 2, 3) unique
  97. # across all Squid processes of the current service instance.
  98. #
  99. # ${service_name} expands into the current Squid service instance
  100. # name identifier which is provided by -n on the command line.
  101. #
  102.  
  103. # TAG: broken_vary_encoding
  104. # This option is not yet supported by Squid-3.
  105. #Default:
  106. # none
  107.  
  108. # TAG: cache_vary
  109. # This option is not yet supported by Squid-3.
  110. #Default:
  111. # none
  112.  
  113. # TAG: error_map
  114. # This option is not yet supported by Squid-3.
  115. #Default:
  116. # none
  117.  
  118. # TAG: external_refresh_check
  119. # This option is not yet supported by Squid-3.
  120. #Default:
  121. # none
  122.  
  123. # TAG: location_rewrite_program
  124. # This option is not yet supported by Squid-3.
  125. #Default:
  126. # none
  127.  
  128. # TAG: refresh_stale_hit
  129. # This option is not yet supported by Squid-3.
  130. #Default:
  131. # none
  132.  
  133. # TAG: hierarchy_stoplist
  134. # Remove this line. Use always_direct or cache_peer_access ACLs instead if you need to prevent cache_peer use.
  135. #Default:
  136. # none
  137.  
  138. # TAG: log_access
  139. # Remove this line. Use acls with access_log directives to control access logging
  140. #Default:
  141. # none
  142.  
  143. # TAG: log_icap
  144. # Remove this line. Use acls with icap_log directives to control icap logging
  145. #Default:
  146. # none
  147.  
  148. # TAG: ignore_ims_on_miss
  149. # Remove this line. The HTTP/1.1 feature is now configured by 'cache_miss_revalidate'.
  150. #Default:
  151. # none
  152.  
  153. # TAG: chunked_request_body_max_size
  154. # Remove this line. Squid is now HTTP/1.1 compliant.
  155. #Default:
  156. # none
  157.  
  158. # TAG: dns_v4_fallback
  159. # Remove this line. Squid performs a 'Happy Eyeballs' algorithm, the 'fallback' algorithm is no longer relevant.
  160. #Default:
  161. # none
  162.  
  163. # TAG: emulate_httpd_log
  164. # Replace this with an access_log directive using the format 'common' or 'combined'.
  165. #Default:
  166. # none
  167.  
  168. # TAG: forward_log
  169. # Use a regular access.log with ACL limiting it to MISS events.
  170. #Default:
  171. # none
  172.  
  173. # TAG: ftp_list_width
  174. # Remove this line. Configure FTP page display using the CSS controls in errorpages.css instead.
  175. #Default:
  176. # none
  177.  
  178. # TAG: ignore_expect_100
  179. # Remove this line. The HTTP/1.1 feature is now fully supported by default.
  180. #Default:
  181. # none
  182.  
  183. # TAG: log_fqdn
  184. # Remove this option from your config. To log FQDN use %>A in the log format.
  185. #Default:
  186. # none
  187.  
  188. # TAG: log_ip_on_direct
  189. # Remove this option from your config. To log server or peer names use %<A in the log format.
  190. #Default:
  191. # none
  192.  
  193. # TAG: maximum_single_addr_tries
  194. # Replaced by connect_retries. The behaviour has changed, please read the documentation before altering.
  195. #Default:
  196. # none
  197.  
  198. # TAG: referer_log
  199. # Replace this with an access_log directive using the format 'referrer'.
  200. #Default:
  201. # none
  202.  
  203. # TAG: update_headers
  204. # Remove this line. The feature is supported by default in storage types where update is implemented.
  205. #Default:
  206. # none
  207.  
  208. # TAG: url_rewrite_concurrency
  209. # Remove this line. Set the 'concurrency=' option of url_rewrite_children instead.
  210. #Default:
  211. # none
  212.  
  213. # TAG: useragent_log
  214. # Replace this with an access_log directive using the format 'useragent'.
  215. #Default:
  216. # none
  217.  
  218. # TAG: dns_testnames
  219. # Remove this line. DNS is no longer tested on startup.
  220. #Default:
  221. # none
  222.  
  223. # TAG: extension_methods
  224. # Remove this line. All valid methods for HTTP are accepted by default.
  225. #Default:
  226. # none
  227.  
  228. # TAG: zero_buffers
  229. #Default:
  230. # none
  231.  
  232. # TAG: incoming_rate
  233. #Default:
  234. # none
  235.  
  236. # TAG: server_http11
  237. # Remove this line. HTTP/1.1 is supported by default.
  238. #Default:
  239. # none
  240.  
  241. # TAG: upgrade_http0.9
  242. # Remove this line. ICY/1.0 streaming protocol is supported by default.
  243. #Default:
  244. # none
  245.  
  246. # TAG: zph_local
  247. # Alter these entries. Use the qos_flows directive instead.
  248. #Default:
  249. # none
  250.  
  251. # TAG: header_access
  252. # Since squid-3.0 replace with request_header_access or reply_header_access
  253. # depending on whether you wish to match client requests or server replies.
  254. #Default:
  255. # none
  256.  
  257. # TAG: httpd_accel_no_pmtu_disc
  258. # Since squid-3.0 use the 'disable-pmtu-discovery' flag on http_port instead.
  259. #Default:
  260. # none
  261.  
  262. # TAG: wais_relay_host
  263. # Replace this line with 'cache_peer' configuration.
  264. #Default:
  265. # none
  266.  
  267. # TAG: wais_relay_port
  268. # Replace this line with 'cache_peer' configuration.
  269. #Default:
  270. # none
  271.  
  272. # OPTIONS FOR SMP
  273. # -----------------------------------------------------------------------------
  274.  
  275. # TAG: workers
  276. # Number of main Squid processes or "workers" to fork and maintain.
  277. # 0: "no daemon" mode, like running "squid -N ..."
  278. # 1: "no SMP" mode, start one main Squid process daemon (default)
  279. # N: start N main Squid process daemons (i.e., SMP mode)
  280. #
  281. # In SMP mode, each worker does nearly all what a single Squid daemon
  282. # does (e.g., listen on http_port and forward HTTP requests).
  283. #Default:
  284. # SMP support disabled.
  285.  
  286. # TAG: cpu_affinity_map
  287. # Usage: cpu_affinity_map process_numbers=P1,P2,... cores=C1,C2,...
  288. #
  289. # Sets 1:1 mapping between Squid processes and CPU cores. For example,
  290. #
  291. # cpu_affinity_map process_numbers=1,2,3,4 cores=1,3,5,7
  292. #
  293. # affects processes 1 through 4 only and places them on the first
  294. # four even cores, starting with core #1.
  295. #
  296. # CPU cores are numbered starting from 1. Requires support for
  297. # sched_getaffinity(2) and sched_setaffinity(2) system calls.
  298. #
  299. # Multiple cpu_affinity_map options are merged.
  300. #
  301. # See also: workers
  302. #Default:
  303. # Let operating system decide.
  304.  
  305. # OPTIONS FOR AUTHENTICATION
  306. # -----------------------------------------------------------------------------
  307.  
  308. # TAG: auth_param
  309. # This is used to define parameters for the various authentication
  310. # schemes supported by Squid.
  311. #
  312. # format: auth_param scheme parameter [setting]
  313. #
  314. # The order in which authentication schemes are presented to the client is
  315. # dependent on the order the scheme first appears in config file. IE
  316. # has a bug (it's not RFC 2617 compliant) in that it will use the basic
  317. # scheme if basic is the first entry presented, even if more secure
  318. # schemes are presented. For now use the order in the recommended
  319. # settings section below. If other browsers have difficulties (don't
  320. # recognize the schemes offered even if you are using basic) either
  321. # put basic first, or disable the other schemes (by commenting out their
  322. # program entry).
  323. #
  324. # Once an authentication scheme is fully configured, it can only be
  325. # shutdown by shutting squid down and restarting. Changes can be made on
  326. # the fly and activated with a reconfigure. I.E. You can change to a
  327. # different helper, but not unconfigure the helper completely.
  328. #
  329. # Please note that while this directive defines how Squid processes
  330. # authentication it does not automatically activate authentication.
  331. # To use authentication you must in addition make use of ACLs based
  332. # on login name in http_access (proxy_auth, proxy_auth_regex or
  333. # external with %LOGIN used in the format tag). The browser will be
  334. # challenged for authentication on the first such acl encountered
  335. # in http_access processing and will also be re-challenged for new
  336. # login credentials if the request is being denied by a proxy_auth
  337. # type acl.
  338. #
  339. # WARNING: authentication can't be used in a transparently intercepting
  340. # proxy as the client then thinks it is talking to an origin server and
  341. # not the proxy. This is a limitation of bending the TCP/IP protocol to
  342. # transparently intercepting port 80, not a limitation in Squid.
  343. # Ports flagged 'transparent', 'intercept', or 'tproxy' have
  344. # authentication disabled.
  345. #
  346. # === Parameters common to all schemes. ===
  347. #
  348. # "program" cmdline
  349. # Specifies the command for the external authenticator.
  350. #
  351. # By default, each authentication scheme is not used unless a
  352. # program is specified.
  353. #
  354. # See http://wiki.squid-cache.org/Features/AddonHelpers for
  355. # more details on helper operations and creating your own.
  356. #
  357. # "key_extras" format
  358. # Specifies a string to be append to request line format for
  359. # the authentication helper. "Quoted" format values may contain
  360. # spaces and logformat %macros. In theory, any logformat %macro
  361. # can be used. In practice, a %macro expands as a dash (-) if
  362. # the helper request is sent before the required macro
  363. # information is available to Squid.
  364. #
  365. # By default, Squid uses request formats provided in
  366. # scheme-specific examples below (search for %credentials).
  367. #
  368. # The expanded key_extras value is added to the Squid credentials
  369. # cache and, hence, will affect authentication. It can be used to
  370. # autenticate different users with identical user names (e.g.,
  371. # when user authentication depends on http_port).
  372. #
  373. # Avoid adding frequently changing information to key_extras. For
  374. # example, if you add user source IP, and it changes frequently
  375. # in your environment, then max_user_ip ACL is going to treat
  376. # every user+IP combination as a unique "user", breaking the ACL
  377. # and wasting a lot of memory on those user records. It will also
  378. # force users to authenticate from scratch whenever their IP
  379. # changes.
  380. #
  381. # "realm" string
  382. # Specifies the protection scope (aka realm name) which is to be
  383. # reported to the client for the authentication scheme. It is
  384. # commonly part of the text the user will see when prompted for
  385. # their username and password.
  386. #
  387. # For Basic the default is "Squid proxy-caching web server".
  388. # For Digest there is no default, this parameter is mandatory.
  389. # For NTLM and Negotiate this parameter is ignored.
  390. #
  391. # "children" numberofchildren [startup=N] [idle=N] [concurrency=N]
  392. #
  393. # The maximum number of authenticator processes to spawn. If
  394. # you start too few Squid will have to wait for them to process
  395. # a backlog of credential verifications, slowing it down. When
  396. # password verifications are done via a (slow) network you are
  397. # likely to need lots of authenticator processes.
  398. #
  399. # The startup= and idle= options permit some skew in the exact
  400. # amount run. A minimum of startup=N will begin during startup
  401. # and reconfigure. Squid will start more in groups of up to
  402. # idle=N in an attempt to meet traffic needs and to keep idle=N
  403. # free above those traffic needs up to the maximum.
  404. #
  405. # The concurrency= option sets the number of concurrent requests
  406. # the helper can process. The default of 0 is used for helpers
  407. # who only supports one request at a time. Setting this to a
  408. # number greater than 0 changes the protocol used to include a
  409. # channel ID field first on the request/response line, allowing
  410. # multiple requests to be sent to the same helper in parallel
  411. # without waiting for the response.
  412. #
  413. # Concurrency must not be set unless it's known the helper
  414. # supports the input format with channel-ID fields.
  415. #
  416. # NOTE: NTLM and Negotiate schemes do not support concurrency
  417. # in the Squid code module even though some helpers can.
  418. #
  419. #
  420. #
  421. # === Example Configuration ===
  422. #
  423. # This configuration displays the recommended authentication scheme
  424. # order from most to least secure with recommended minimum configuration
  425. # settings for each scheme:
  426. #
  427. ##auth_param negotiate program <uncomment and complete this line to activate>
  428. ##auth_param negotiate children 20 startup=0 idle=1
  429. ##auth_param negotiate keep_alive on
  430. ##
  431. ##auth_param digest program <uncomment and complete this line to activate>
  432. ##auth_param digest children 20 startup=0 idle=1
  433. ##auth_param digest realm Squid proxy-caching web server
  434. ##auth_param digest nonce_garbage_interval 5 minutes
  435. ##auth_param digest nonce_max_duration 30 minutes
  436. ##auth_param digest nonce_max_count 50
  437. ##
  438. ##auth_param ntlm program <uncomment and complete this line to activate>
  439. ##auth_param ntlm children 20 startup=0 idle=1
  440. ##auth_param ntlm keep_alive on
  441. ##
  442. ##auth_param basic program <uncomment and complete this line>
  443. ##auth_param basic children 5 startup=5 idle=1
  444. ##auth_param basic realm Squid proxy-caching web server
  445. ##auth_param basic credentialsttl 2 hours
  446. #Default:
  447. # none
  448.  
  449. # TAG: authenticate_cache_garbage_interval
  450. # The time period between garbage collection across the username cache.
  451. # This is a trade-off between memory utilization (long intervals - say
  452. # 2 days) and CPU (short intervals - say 1 minute). Only change if you
  453. # have good reason to.
  454. #Default:
  455. # authenticate_cache_garbage_interval 1 hour
  456.  
  457. # TAG: authenticate_ttl
  458. # The time a user & their credentials stay in the logged in
  459. # user cache since their last request. When the garbage
  460. # interval passes, all user credentials that have passed their
  461. # TTL are removed from memory.
  462. #Default:
  463. # authenticate_ttl 1 hour
  464.  
  465. # TAG: authenticate_ip_ttl
  466. # If you use proxy authentication and the 'max_user_ip' ACL,
  467. # this directive controls how long Squid remembers the IP
  468. # addresses associated with each user. Use a small value
  469. # (e.g., 60 seconds) if your users might change addresses
  470. # quickly, as is the case with dialup. You might be safe
  471. # using a larger value (e.g., 2 hours) in a corporate LAN
  472. # environment with relatively static address assignments.
  473. #Default:
  474. # authenticate_ip_ttl 1 second
  475.  
  476. # ACCESS CONTROLS
  477. # -----------------------------------------------------------------------------
  478.  
  479. # TAG: external_acl_type
  480. # This option defines external acl classes using a helper program
  481. # to look up the status
  482. #
  483. # external_acl_type name [options] FORMAT.. /path/to/helper [helper arguments..]
  484. #
  485. # Options:
  486. #
  487. # ttl=n TTL in seconds for cached results (defaults to 3600
  488. # for 1 hour)
  489. #
  490. # negative_ttl=n
  491. # TTL for cached negative lookups (default same
  492. # as ttl)
  493. #
  494. # grace=n Percentage remaining of TTL where a refresh of a
  495. # cached entry should be initiated without needing to
  496. # wait for a new reply. (default is for no grace period)
  497. #
  498. # cache=n The maximum number of entries in the result cache. The
  499. # default limit is 262144 entries. Each cache entry usually
  500. # consumes at least 256 bytes. Squid currently does not remove
  501. # expired cache entries until the limit is reached, so a proxy
  502. # will sooner or later reach the limit. The expanded FORMAT
  503. # value is used as the cache key, so if the details in FORMAT
  504. # are highly variable, a larger cache may be needed to produce
  505. # reduction in helper load.
  506. #
  507. # children-max=n
  508. # Maximum number of acl helper processes spawned to service
  509. # external acl lookups of this type. (default 5)
  510. #
  511. # children-startup=n
  512. # Minimum number of acl helper processes to spawn during
  513. # startup and reconfigure to service external acl lookups
  514. # of this type. (default 0)
  515. #
  516. # children-idle=n
  517. # Number of acl helper processes to keep ahead of traffic
  518. # loads. Squid will spawn this many at once whenever load
  519. # rises above the capabilities of existing processes.
  520. # Up to the value of children-max. (default 1)
  521. #
  522. # concurrency=n concurrency level per process. Only used with helpers
  523. # capable of processing more than one query at a time.
  524. #
  525. # protocol=2.5 Compatibility mode for Squid-2.5 external acl helpers.
  526. #
  527. # ipv4 / ipv6 IP protocol used to communicate with this helper.
  528. # The default is to auto-detect IPv6 and use it when available.
  529. #
  530. #
  531. # FORMAT specifications
  532. #
  533. # %LOGIN Authenticated user login name
  534. # %un A user name. Expands to the first available name
  535. # from the following list of information sources:
  536. # - authenticated user name, like %ul or %LOGIN
  537. # - user name sent by an external ACL, like %EXT_USER
  538. # - SSL client name, like %us in logformat
  539. # - ident user name, like %ui in logformat
  540. # %EXT_USER Username from previous external acl
  541. # %EXT_LOG Log details from previous external acl
  542. # %EXT_TAG Tag from previous external acl
  543. # %IDENT Ident user name
  544. # %SRC Client IP
  545. # %SRCPORT Client source port
  546. # %URI Requested URI
  547. # %DST Requested host
  548. # %PROTO Requested URL scheme
  549. # %PORT Requested port
  550. # %PATH Requested URL path
  551. # %METHOD Request method
  552. # %MYADDR Squid interface address
  553. # %MYPORT Squid http_port number
  554. # %PATH Requested URL-path (including query-string if any)
  555. # %USER_CERT SSL User certificate in PEM format
  556. # %USER_CERTCHAIN SSL User certificate chain in PEM format
  557. # %USER_CERT_xx SSL User certificate subject attribute xx
  558. # %USER_CA_CERT_xx SSL User certificate issuer attribute xx
  559. # %ssl::>sni SSL client SNI sent to Squid
  560. # %ssl::<cert_subject SSL server certificate DN
  561. # %ssl::<cert_issuer SSL server certificate issuer DN
  562. #
  563. # %>{Header} HTTP request header "Header"
  564. # %>{Hdr:member}
  565. # HTTP request header "Hdr" list member "member"
  566. # %>{Hdr:;member}
  567. # HTTP request header list member using ; as
  568. # list separator. ; can be any non-alphanumeric
  569. # character.
  570. #
  571. # %<{Header} HTTP reply header "Header"
  572. # %<{Hdr:member}
  573. # HTTP reply header "Hdr" list member "member"
  574. # %<{Hdr:;member}
  575. # HTTP reply header list member using ; as
  576. # list separator. ; can be any non-alphanumeric
  577. # character.
  578. #
  579. # %ACL The name of the ACL being tested.
  580. # %DATA The ACL arguments. If not used then any arguments
  581. # is automatically added at the end of the line
  582. # sent to the helper.
  583. # NOTE: this will encode the arguments as one token,
  584. # whereas the default will pass each separately.
  585. #
  586. # %% The percent sign. Useful for helpers which need
  587. # an unchanging input format.
  588. #
  589. #
  590. # General request syntax:
  591. #
  592. # [channel-ID] FORMAT-values [acl-values ...]
  593. #
  594. #
  595. # FORMAT-values consists of transaction details expanded with
  596. # whitespace separation per the config file FORMAT specification
  597. # using the FORMAT macros listed above.
  598. #
  599. # acl-values consists of any string specified in the referencing
  600. # config 'acl ... external' line. see the "acl external" directive.
  601. #
  602. # Request values sent to the helper are URL escaped to protect
  603. # each value in requests against whitespaces.
  604. #
  605. # If using protocol=2.5 then the request sent to the helper is not
  606. # URL escaped to protect against whitespace.
  607. #
  608. # NOTE: protocol=3.0 is deprecated as no longer necessary.
  609. #
  610. # When using the concurrency= option the protocol is changed by
  611. # introducing a query channel tag in front of the request/response.
  612. # The query channel tag is a number between 0 and concurrency-1.
  613. # This value must be echoed back unchanged to Squid as the first part
  614. # of the response relating to its request.
  615. #
  616. #
  617. # The helper receives lines expanded per the above format specification
  618. # and for each input line returns 1 line starting with OK/ERR/BH result
  619. # code and optionally followed by additional keywords with more details.
  620. #
  621. #
  622. # General result syntax:
  623. #
  624. # [channel-ID] result keyword=value ...
  625. #
  626. # Result consists of one of the codes:
  627. #
  628. # OK
  629. # the ACL test produced a match.
  630. #
  631. # ERR
  632. # the ACL test does not produce a match.
  633. #
  634. # BH
  635. # An internal error occurred in the helper, preventing
  636. # a result being identified.
  637. #
  638. # The meaning of 'a match' is determined by your squid.conf
  639. # access control configuration. See the Squid wiki for details.
  640. #
  641. # Defined keywords:
  642. #
  643. # user= The users name (login)
  644. #
  645. # password= The users password (for login= cache_peer option)
  646. #
  647. # message= Message describing the reason for this response.
  648. # Available as %o in error pages.
  649. # Useful on (ERR and BH results).
  650. #
  651. # tag= Apply a tag to a request. Only sets a tag once,
  652. # does not alter existing tags.
  653. #
  654. # log= String to be logged in access.log. Available as
  655. # %ea in logformat specifications.
  656. #
  657. # clt_conn_tag= Associates a TAG with the client TCP connection.
  658. # Please see url_rewrite_program related documentation
  659. # for this kv-pair.
  660. #
  661. # Any keywords may be sent on any response whether OK, ERR or BH.
  662. #
  663. # All response keyword values need to be a single token with URL
  664. # escaping, or enclosed in double quotes (") and escaped using \ on
  665. # any double quotes or \ characters within the value. The wrapping
  666. # double quotes are removed before the value is interpreted by Squid.
  667. # \r and \n are also replace by CR and LF.
  668. #
  669. # Some example key values:
  670. #
  671. # user=John%20Smith
  672. # user="John Smith"
  673. # user="J. \"Bob\" Smith"
  674. #Default:
  675. # none
  676.  
  677. # TAG: acl
  678. # Defining an Access List
  679. #
  680. # Every access list definition must begin with an aclname and acltype,
  681. # followed by either type-specific arguments or a quoted filename that
  682. # they are read from.
  683. #
  684. # acl aclname acltype argument ...
  685. # acl aclname acltype "file" ...
  686. #
  687. # When using "file", the file should contain one item per line.
  688. #
  689. # Some acl types supports options which changes their default behaviour.
  690. # The available options are:
  691. #
  692. # -i,+i By default, regular expressions are CASE-SENSITIVE. To make them
  693. # case-insensitive, use the -i option. To return case-sensitive
  694. # use the +i option between patterns, or make a new ACL line
  695. # without -i.
  696. #
  697. # -n Disable lookups and address type conversions. If lookup or
  698. # conversion is required because the parameter type (IP or
  699. # domain name) does not match the message address type (domain
  700. # name or IP), then the ACL would immediately declare a mismatch
  701. # without any warnings or lookups.
  702. #
  703. # -- Used to stop processing all options, in the case the first acl
  704. # value has '-' character as first character (for example the '-'
  705. # is a valid domain name)
  706. #
  707. # Some acl types require suspending the current request in order
  708. # to access some external data source.
  709. # Those which do are marked with the tag [slow], those which
  710. # don't are marked as [fast].
  711. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl
  712. # for further information
  713. #
  714. # ***** ACL TYPES AVAILABLE *****
  715. #
  716. # acl aclname src ip-address/mask ... # clients IP address [fast]
  717. # acl aclname src addr1-addr2/mask ... # range of addresses [fast]
  718. # acl aclname dst [-n] ip-address/mask ... # URL host's IP address [slow]
  719. # acl aclname localip ip-address/mask ... # IP address the client connected to [fast]
  720. #
  721. # acl aclname arp mac-address ... (xx:xx:xx:xx:xx:xx notation)
  722. # # [fast]
  723. # # The 'arp' ACL code is not portable to all operating systems.
  724. # # It works on Linux, Solaris, Windows, FreeBSD, and some other
  725. # # BSD variants.
  726. # #
  727. # # NOTE: Squid can only determine the MAC/EUI address for IPv4
  728. # # clients that are on the same subnet. If the client is on a
  729. # # different subnet, then Squid cannot find out its address.
  730. # #
  731. # # NOTE 2: IPv6 protocol does not contain ARP. MAC/EUI is either
  732. # # encoded directly in the IPv6 address or not available.
  733. #
  734. # acl aclname srcdomain .foo.com ...
  735. # # reverse lookup, from client IP [slow]
  736. # acl aclname dstdomain [-n] .foo.com ...
  737. # # Destination server from URL [fast]
  738. # acl aclname srcdom_regex [-i] \.foo\.com ...
  739. # # regex matching client name [slow]
  740. # acl aclname dstdom_regex [-n] [-i] \.foo\.com ...
  741. # # regex matching server [fast]
  742. # #
  743. # # For dstdomain and dstdom_regex a reverse lookup is tried if a IP
  744. # # based URL is used and no match is found. The name "none" is used
  745. # # if the reverse lookup fails.
  746. #
  747. # acl aclname src_as number ...
  748. # acl aclname dst_as number ...
  749. # # [fast]
  750. # # Except for access control, AS numbers can be used for
  751. # # routing of requests to specific caches. Here's an
  752. # # example for routing all requests for AS#1241 and only
  753. # # those to mycache.mydomain.net:
  754. # # acl asexample dst_as 1241
  755. # # cache_peer_access mycache.mydomain.net allow asexample
  756. # # cache_peer_access mycache_mydomain.net deny all
  757. #
  758. # acl aclname peername myPeer ...
  759. # # [fast]
  760. # # match against a named cache_peer entry
  761. # # set unique name= on cache_peer lines for reliable use.
  762. #
  763. # acl aclname time [day-abbrevs] [h1:m1-h2:m2]
  764. # # [fast]
  765. # # day-abbrevs:
  766. # # S - Sunday
  767. # # M - Monday
  768. # # T - Tuesday
  769. # # W - Wednesday
  770. # # H - Thursday
  771. # # F - Friday
  772. # # A - Saturday
  773. # # h1:m1 must be less than h2:m2
  774. #
  775. # acl aclname url_regex [-i] ^http:// ...
  776. # # regex matching on whole URL [fast]
  777. # acl aclname urllogin [-i] [^a-zA-Z0-9] ...
  778. # # regex matching on URL login field
  779. # acl aclname urlpath_regex [-i] \.gif$ ...
  780. # # regex matching on URL path [fast]
  781. #
  782. # acl aclname port 80 70 21 0-1024... # destination TCP port [fast]
  783. # # ranges are alloed
  784. # acl aclname localport 3128 ... # TCP port the client connected to [fast]
  785. # # NP: for interception mode this is usually '80'
  786. #
  787. # acl aclname myportname 3128 ... # *_port name [fast]
  788. #
  789. # acl aclname proto HTTP FTP ... # request protocol [fast]
  790. #
  791. # acl aclname method GET POST ... # HTTP request method [fast]
  792. #
  793. # acl aclname http_status 200 301 500- 400-403 ...
  794. # # status code in reply [fast]
  795. #
  796. # acl aclname browser [-i] regexp ...
  797. # # pattern match on User-Agent header (see also req_header below) [fast]
  798. #
  799. # acl aclname referer_regex [-i] regexp ...
  800. # # pattern match on Referer header [fast]
  801. # # Referer is highly unreliable, so use with care
  802. #
  803. # acl aclname ident username ...
  804. # acl aclname ident_regex [-i] pattern ...
  805. # # string match on ident output [slow]
  806. # # use REQUIRED to accept any non-null ident.
  807. #
  808. # acl aclname proxy_auth [-i] username ...
  809. # acl aclname proxy_auth_regex [-i] pattern ...
  810. # # perform http authentication challenge to the client and match against
  811. # # supplied credentials [slow]
  812. # #
  813. # # takes a list of allowed usernames.
  814. # # use REQUIRED to accept any valid username.
  815. # #
  816. # # Will use proxy authentication in forward-proxy scenarios, and plain
  817. # # http authenticaiton in reverse-proxy scenarios
  818. # #
  819. # # NOTE: when a Proxy-Authentication header is sent but it is not
  820. # # needed during ACL checking the username is NOT logged
  821. # # in access.log.
  822. # #
  823. # # NOTE: proxy_auth requires a EXTERNAL authentication program
  824. # # to check username/password combinations (see
  825. # # auth_param directive).
  826. # #
  827. # # NOTE: proxy_auth can't be used in a transparent/intercepting proxy
  828. # # as the browser needs to be configured for using a proxy in order
  829. # # to respond to proxy authentication.
  830. #
  831. # acl aclname snmp_community string ...
  832. # # A community string to limit access to your SNMP Agent [fast]
  833. # # Example:
  834. # #
  835. # # acl snmppublic snmp_community public
  836. #
  837. # acl aclname maxconn number
  838. # # This will be matched when the client's IP address has
  839. # # more than <number> TCP connections established. [fast]
  840. # # NOTE: This only measures direct TCP links so X-Forwarded-For
  841. # # indirect clients are not counted.
  842. #
  843. # acl aclname max_user_ip [-s] number
  844. # # This will be matched when the user attempts to log in from more
  845. # # than <number> different ip addresses. The authenticate_ip_ttl
  846. # # parameter controls the timeout on the ip entries. [fast]
  847. # # If -s is specified the limit is strict, denying browsing
  848. # # from any further IP addresses until the ttl has expired. Without
  849. # # -s Squid will just annoy the user by "randomly" denying requests.
  850. # # (the counter is reset each time the limit is reached and a
  851. # # request is denied)
  852. # # NOTE: in acceleration mode or where there is mesh of child proxies,
  853. # # clients may appear to come from multiple addresses if they are
  854. # # going through proxy farms, so a limit of 1 may cause user problems.
  855. #
  856. # acl aclname random probability
  857. # # Pseudo-randomly match requests. Based on the probability given.
  858. # # Probability may be written as a decimal (0.333), fraction (1/3)
  859. # # or ratio of matches:non-matches (3:5).
  860. #
  861. # acl aclname req_mime_type [-i] mime-type ...
  862. # # regex match against the mime type of the request generated
  863. # # by the client. Can be used to detect file upload or some
  864. # # types HTTP tunneling requests [fast]
  865. # # NOTE: This does NOT match the reply. You cannot use this
  866. # # to match the returned file type.
  867. #
  868. # acl aclname req_header header-name [-i] any\.regex\.here
  869. # # regex match against any of the known request headers. May be
  870. # # thought of as a superset of "browser", "referer" and "mime-type"
  871. # # ACL [fast]
  872. #
  873. # acl aclname rep_mime_type [-i] mime-type ...
  874. # # regex match against the mime type of the reply received by
  875. # # squid. Can be used to detect file download or some
  876. # # types HTTP tunneling requests. [fast]
  877. # # NOTE: This has no effect in http_access rules. It only has
  878. # # effect in rules that affect the reply data stream such as
  879. # # http_reply_access.
  880. #
  881. # acl aclname rep_header header-name [-i] any\.regex\.here
  882. # # regex match against any of the known reply headers. May be
  883. # # thought of as a superset of "browser", "referer" and "mime-type"
  884. # # ACLs [fast]
  885. #
  886. # acl aclname external class_name [arguments...]
  887. # # external ACL lookup via a helper class defined by the
  888. # # external_acl_type directive [slow]
  889. #
  890. # acl aclname user_cert attribute values...
  891. # # match against attributes in a user SSL certificate
  892. # # attribute is one of DN/C/O/CN/L/ST or a numerical OID [fast]
  893. #
  894. # acl aclname ca_cert attribute values...
  895. # # match against attributes a users issuing CA SSL certificate
  896. # # attribute is one of DN/C/O/CN/L/ST or a numerical OID [fast]
  897. #
  898. # acl aclname ext_user username ...
  899. # acl aclname ext_user_regex [-i] pattern ...
  900. # # string match on username returned by external acl helper [slow]
  901. # # use REQUIRED to accept any non-null user name.
  902. #
  903. # acl aclname tag tagvalue ...
  904. # # string match on tag returned by external acl helper [fast]
  905. # # DEPRECATED. Only the first tag will match with this ACL.
  906. # # Use the 'note' ACL instead for handling multiple tag values.
  907. #
  908. # acl aclname hier_code codename ...
  909. # # string match against squid hierarchy code(s); [fast]
  910. # # e.g., DIRECT, PARENT_HIT, NONE, etc.
  911. # #
  912. # # NOTE: This has no effect in http_access rules. It only has
  913. # # effect in rules that affect the reply data stream such as
  914. # # http_reply_access.
  915. #
  916. # acl aclname note name [value ...]
  917. # # match transaction annotation [fast]
  918. # # Without values, matches any annotation with a given name.
  919. # # With value(s), matches any annotation with a given name that
  920. # # also has one of the given values.
  921. # # Names and values are compared using a string equality test.
  922. # # Annotation sources include note and adaptation_meta directives
  923. # # as well as helper and eCAP responses.
  924. #
  925. # acl aclname adaptation_service service ...
  926. # # Matches the name of any icap_service, ecap_service,
  927. # # adaptation_service_set, or adaptation_service_chain that Squid
  928. # # has used (or attempted to use) for the master transaction.
  929. # # This ACL must be defined after the corresponding adaptation
  930. # # service is named in squid.conf. This ACL is usable with
  931. # # adaptation_meta because it starts matching immediately after
  932. # # the service has been selected for adaptation.
  933. #
  934. # acl aclname any-of acl1 acl2 ...
  935. # # match any one of the acls [fast or slow]
  936. # # The first matching ACL stops further ACL evaluation.
  937. # #
  938. # # ACLs from multiple any-of lines with the same name are ORed.
  939. # # For example, A = (a1 or a2) or (a3 or a4) can be written as
  940. # # acl A any-of a1 a2
  941. # # acl A any-of a3 a4
  942. # #
  943. # # This group ACL is fast if all evaluated ACLs in the group are fast
  944. # # and slow otherwise.
  945. #
  946. # acl aclname all-of acl1 acl2 ...
  947. # # match all of the acls [fast or slow]
  948. # # The first mismatching ACL stops further ACL evaluation.
  949. # #
  950. # # ACLs from multiple all-of lines with the same name are ORed.
  951. # # For example, B = (b1 and b2) or (b3 and b4) can be written as
  952. # # acl B all-of b1 b2
  953. # # acl B all-of b3 b4
  954. # #
  955. # # This group ACL is fast if all evaluated ACLs in the group are fast
  956. # # and slow otherwise.
  957. #
  958. # Examples:
  959. # acl macaddress arp 09:00:2b:23:45:67
  960. # acl myexample dst_as 1241
  961. # acl password proxy_auth REQUIRED
  962. # acl fileupload req_mime_type -i ^multipart/form-data$
  963. # acl javascript rep_mime_type -i ^application/x-javascript$
  964. #
  965. #Default:
  966. # ACLs all, manager, localhost, and to_localhost are predefined.
  967. #
  968. #
  969. # Recommended minimum configuration:
  970. #
  971.  
  972. # Example rule allowing access from your local networks.
  973. # Adapt to list your (internal) IP networks from where browsing
  974. # should be allowed
  975. #acl all src all
  976. acl localnet src 127.0.0.1 # RFC1918 possible internal network
  977. #acl localnet src 10.0.0.0/8 # RFC1918 possible internal network
  978. #acl localnet src 172.16.0.0/12 # RFC1918 possible internal network
  979. acl localnet src 192.168.0.0/16 # RFC1918 possible internal network
  980. #acl localnet src 192.168.1.0/24 # RFC1918 possible internal network
  981. #acl localnet src fc00::/7 # RFC 4193 local private network range
  982. #acl localnet src fe80::/10 # RFC 4291 link-local (directly plugged) machines
  983.  
  984. acl SSL_ports port 443
  985. acl Safe_ports port 80 # http
  986. acl Safe_ports port 21 # ftp
  987. acl Safe_ports port 443 # https
  988. acl Safe_ports port 70 # gopher
  989. acl Safe_ports port 210 # wais
  990. acl Safe_ports port 1025-65535 # unregistered ports
  991. acl Safe_ports port 280 # http-mgmt
  992. acl Safe_ports port 488 # gss-http
  993. acl Safe_ports port 591 # filemaker
  994. acl Safe_ports port 777 # multiling http
  995. acl CONNECT method CONNECT
  996.  
  997. # TAG: proxy_protocol_access
  998. # Determine which client proxies can be trusted to provide correct
  999. # information regarding real client IP address using PROXY protocol.
  1000. #
  1001. # Requests may pass through a chain of several other proxies
  1002. # before reaching us. The original source details may by sent in:
  1003. # * HTTP message Forwarded header, or
  1004. # * HTTP message X-Forwarded-For header, or
  1005. # * PROXY protocol connection header.
  1006. #
  1007. # This directive is solely for validating new PROXY protocol
  1008. # connections received from a port flagged with require-proxy-header.
  1009. # It is checked only once after TCP connection setup.
  1010. #
  1011. # A deny match results in TCP connection closure.
  1012. #
  1013. # An allow match is required for Squid to permit the corresponding
  1014. # TCP connection, before Squid even looks for HTTP request headers.
  1015. # If there is an allow match, Squid starts using PROXY header information
  1016. # to determine the source address of the connection for all future ACL
  1017. # checks, logging, etc.
  1018. #
  1019. # SECURITY CONSIDERATIONS:
  1020. #
  1021. # Any host from which we accept client IP details can place
  1022. # incorrect information in the relevant header, and Squid
  1023. # will use the incorrect information as if it were the
  1024. # source address of the request. This may enable remote
  1025. # hosts to bypass any access control restrictions that are
  1026. # based on the client's source addresses.
  1027. #
  1028. # This clause only supports fast acl types.
  1029. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1030. #Default:
  1031. # all TCP connections to ports with require-proxy-header will be denied
  1032.  
  1033. # TAG: follow_x_forwarded_for
  1034. # Determine which client proxies can be trusted to provide correct
  1035. # information regarding real client IP address.
  1036. #
  1037. # Requests may pass through a chain of several other proxies
  1038. # before reaching us. The original source details may by sent in:
  1039. # * HTTP message Forwarded header, or
  1040. # * HTTP message X-Forwarded-For header, or
  1041. # * PROXY protocol connection header.
  1042. #
  1043. # PROXY protocol connections are controlled by the proxy_protocol_access
  1044. # directive which is checked before this.
  1045. #
  1046. # If a request reaches us from a source that is allowed by this
  1047. # directive, then we trust the information it provides regarding
  1048. # the IP of the client it received from (if any).
  1049. #
  1050. # For the purpose of ACLs used in this directive the src ACL type always
  1051. # matches the address we are testing and srcdomain matches its rDNS.
  1052. #
  1053. # On each HTTP request Squid checks for X-Forwarded-For header fields.
  1054. # If found the header values are iterated in reverse order and an allow
  1055. # match is required for Squid to continue on to the next value.
  1056. # The verification ends when a value receives a deny match, cannot be
  1057. # tested, or there are no more values to test.
  1058. # NOTE: Squid does not yet follow the Forwarded HTTP header.
  1059. #
  1060. # The end result of this process is an IP address that we will
  1061. # refer to as the indirect client address. This address may
  1062. # be treated as the client address for access control, ICAP, delay
  1063. # pools and logging, depending on the acl_uses_indirect_client,
  1064. # icap_uses_indirect_client, delay_pool_uses_indirect_client,
  1065. # log_uses_indirect_client and tproxy_uses_indirect_client options.
  1066. #
  1067. # This clause only supports fast acl types.
  1068. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1069. #
  1070. # SECURITY CONSIDERATIONS:
  1071. #
  1072. # Any host from which we accept client IP details can place
  1073. # incorrect information in the relevant header, and Squid
  1074. # will use the incorrect information as if it were the
  1075. # source address of the request. This may enable remote
  1076. # hosts to bypass any access control restrictions that are
  1077. # based on the client's source addresses.
  1078. #
  1079. # For example:
  1080. #
  1081. #acl localhost src 127.0.0.1
  1082. # acl my_other_proxy srcdomain .proxy.example.com
  1083. # follow_x_forwarded_for allow localhost
  1084. # follow_x_forwarded_for allow my_other_proxy
  1085. #Default:
  1086. # X-Forwarded-For header will be ignored.
  1087.  
  1088. # TAG: acl_uses_indirect_client on|off
  1089. # Controls whether the indirect client address
  1090. # (see follow_x_forwarded_for) is used instead of the
  1091. # direct client address in acl matching.
  1092. #
  1093. # NOTE: maxconn ACL considers direct TCP links and indirect
  1094. # clients will always have zero. So no match.
  1095. #Default:
  1096. # acl_uses_indirect_client on
  1097.  
  1098. # TAG: delay_pool_uses_indirect_client on|off
  1099. # Controls whether the indirect client address
  1100. # (see follow_x_forwarded_for) is used instead of the
  1101. # direct client address in delay pools.
  1102. #Default:
  1103. # delay_pool_uses_indirect_client on
  1104.  
  1105. # TAG: log_uses_indirect_client on|off
  1106. # Controls whether the indirect client address
  1107. # (see follow_x_forwarded_for) is used instead of the
  1108. # direct client address in the access log.
  1109. #Default:
  1110. # log_uses_indirect_client on
  1111.  
  1112. # TAG: tproxy_uses_indirect_client on|off
  1113. # Controls whether the indirect client address
  1114. # (see follow_x_forwarded_for) is used instead of the
  1115. # direct client address when spoofing the outgoing client.
  1116. #
  1117. # This has no effect on requests arriving in non-tproxy
  1118. # mode ports.
  1119. #
  1120. # SECURITY WARNING: Usage of this option is dangerous
  1121. # and should not be used trivially. Correct configuration
  1122. # of follow_x_forwarded_for with a limited set of trusted
  1123. # sources is required to prevent abuse of your proxy.
  1124. #Default:
  1125. # tproxy_uses_indirect_client off
  1126.  
  1127. # TAG: spoof_client_ip
  1128. # Control client IP address spoofing of TPROXY traffic based on
  1129. # defined access lists.
  1130. #
  1131. # spoof_client_ip allow|deny [!]aclname ...
  1132. #
  1133. # If there are no "spoof_client_ip" lines present, the default
  1134. # is to "allow" spoofing of any suitable request.
  1135. #
  1136. # Note that the cache_peer "no-tproxy" option overrides this ACL.
  1137. #
  1138. # This clause supports fast acl types.
  1139. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1140. #Default:
  1141. # Allow spoofing on all TPROXY traffic.
  1142.  
  1143. # TAG: http_access
  1144. # Allowing or Denying access based on defined access lists
  1145. #
  1146. # To allow or deny a message received on an HTTP, HTTPS, or FTP port:
  1147. # http_access allow|deny [!]aclname ...
  1148. #
  1149. # NOTE on default values:
  1150. #
  1151. # If there are no "access" lines present, the default is to deny
  1152. # the request.
  1153. #
  1154. # If none of the "access" lines cause a match, the default is the
  1155. # opposite of the last line in the list. If the last line was
  1156. # deny, the default is allow. Conversely, if the last line
  1157. # is allow, the default will be deny. For these reasons, it is a
  1158. # good idea to have an "deny all" entry at the end of your access
  1159. # lists to avoid potential confusion.
  1160. #
  1161. # This clause supports both fast and slow acl types.
  1162. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1163. #
  1164. #Default:
  1165. # Deny, unless rules exist in squid.conf.
  1166. #
  1167.  
  1168. #
  1169. # Recommended minimum Access Permission configuration:
  1170. #
  1171. # Deny requests to certain unsafe ports
  1172. http_access allow all !Safe_ports
  1173.  
  1174. # Deny CONNECT to other than secure SSL ports
  1175. http_access deny CONNECT !SSL_ports
  1176.  
  1177. # Only allow cachemgr access from localhost
  1178. http_access allow localhost manager
  1179. http_access deny manager
  1180.  
  1181. # We strongly recommend the following be uncommented to protect innocent
  1182. # web applications running on the proxy server who think the only
  1183. # one who can access services on "localhost" is a local user
  1184. #http_access deny to_localhost
  1185.  
  1186. #
  1187. # INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
  1188. #
  1189.  
  1190. # Example rule allowing access from your local networks.
  1191. # Adapt localnet in the ACL section to list your (internal) IP networks
  1192. # from where browsing should be allowed
  1193. #http_access allow localnet
  1194. http_access allow localhost
  1195.  
  1196. #http_access allow localnet
  1197.  
  1198. # And finally deny all other access to this proxy
  1199. # TAG: http_access deny all
  1200. # TAG: http_access allow all
  1201.  
  1202. # TAG: adapted_http_access
  1203. # Allowing or Denying access based on defined access lists
  1204. #
  1205. # Essentially identical to http_access, but runs after redirectors
  1206. # and ICAP/eCAP adaptation. Allowing access control based on their
  1207. # output.
  1208. #
  1209. # If not set then only http_access is used.
  1210. #Default:
  1211. # Allow, unless rules exist in squid.conf.
  1212.  
  1213. # TAG: http_reply_access
  1214. # Allow replies to client requests. This is complementary to http_access.
  1215. #
  1216. # http_reply_access allow|deny [!] aclname ...
  1217. #
  1218. # NOTE: if there are no access lines present, the default is to allow
  1219. # all replies.
  1220. #
  1221. # If none of the access lines cause a match the opposite of the
  1222. # last line will apply. Thus it is good practice to end the rules
  1223. # with an "allow all" or "deny all" entry.
  1224. #
  1225. # This clause supports both fast and slow acl types.
  1226. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1227. #Default:
  1228. # Allow, unless rules exist in squid.conf.
  1229.  
  1230. # TAG: icp_access
  1231. # Allowing or Denying access to the ICP port based on defined
  1232. # access lists
  1233. #
  1234. # icp_access allow|deny [!]aclname ...
  1235. #
  1236. # NOTE: The default if no icp_access lines are present is to
  1237. # deny all traffic. This default may cause problems with peers
  1238. # using ICP.
  1239. #
  1240. # This clause only supports fast acl types.
  1241. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1242. #
  1243. ## Allow ICP queries from local networks only
  1244. ##icp_access allow localnet
  1245. ##icp_access deny all
  1246. #Default:
  1247. # Deny, unless rules exist in squid.conf.
  1248.  
  1249. # TAG: htcp_access
  1250. # Allowing or Denying access to the HTCP port based on defined
  1251. # access lists
  1252. #
  1253. # htcp_access allow|deny [!]aclname ...
  1254. #
  1255. # See also htcp_clr_access for details on access control for
  1256. # cache purge (CLR) HTCP messages.
  1257. #
  1258. # NOTE: The default if no htcp_access lines are present is to
  1259. # deny all traffic. This default may cause problems with peers
  1260. # using the htcp option.
  1261. #
  1262. # This clause only supports fast acl types.
  1263. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1264. #
  1265. ## Allow HTCP queries from local networks only
  1266. ##htcp_access allow localnet
  1267. ##htcp_access deny all
  1268. #Default:
  1269. # Deny, unless rules exist in squid.conf.
  1270.  
  1271. # TAG: htcp_clr_access
  1272. # Allowing or Denying access to purge content using HTCP based
  1273. # on defined access lists.
  1274. # See htcp_access for details on general HTCP access control.
  1275. #
  1276. # htcp_clr_access allow|deny [!]aclname ...
  1277. #
  1278. # This clause only supports fast acl types.
  1279. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1280. #
  1281. ## Allow HTCP CLR requests from trusted peers
  1282. #acl htcp_clr_peer src 192.0.2.2 2001:DB8::2
  1283. #htcp_clr_access allow htcp_clr_peer
  1284. #htcp_clr_access deny all
  1285. #Default:
  1286. # Deny, unless rules exist in squid.conf.
  1287.  
  1288. # TAG: miss_access
  1289. # Determines whether network access is permitted when satisfying a request.
  1290. #
  1291. # For example;
  1292. # to force your neighbors to use you as a sibling instead of
  1293. # a parent.
  1294. #
  1295. # acl localclients src 192.0.2.0/24 2001:DB8::a:0/64
  1296. # miss_access deny !localclients
  1297. # miss_access allow all
  1298. #
  1299. # This means only your local clients are allowed to fetch relayed/MISS
  1300. # replies from the network and all other clients can only fetch cached
  1301. # objects (HITs).
  1302. #
  1303. # The default for this setting allows all clients who passed the
  1304. # http_access rules to relay via this proxy.
  1305. #
  1306. # This clause only supports fast acl types.
  1307. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1308. #Default:
  1309. # Allow, unless rules exist in squid.conf.
  1310.  
  1311. # TAG: ident_lookup_access
  1312. # A list of ACL elements which, if matched, cause an ident
  1313. # (RFC 931) lookup to be performed for this request. For
  1314. # example, you might choose to always perform ident lookups
  1315. # for your main multi-user Unix boxes, but not for your Macs
  1316. # and PCs. By default, ident lookups are not performed for
  1317. # any requests.
  1318. #
  1319. # To enable ident lookups for specific client addresses, you
  1320. # can follow this example:
  1321. #
  1322. # acl ident_aware_hosts src 198.168.1.0/24
  1323. # ident_lookup_access allow ident_aware_hosts
  1324. # ident_lookup_access deny all
  1325. #
  1326. # Only src type ACL checks are fully supported. A srcdomain
  1327. # ACL might work at times, but it will not always provide
  1328. # the correct result.
  1329. #
  1330. # This clause only supports fast acl types.
  1331. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  1332. #Default:
  1333. # Unless rules exist in squid.conf, IDENT is not fetched.
  1334.  
  1335. # TAG: reply_body_max_size size [acl acl...]
  1336. # This option specifies the maximum size of a reply body. It can be
  1337. # used to prevent users from downloading very large files, such as
  1338. # MP3's and movies. When the reply headers are received, the
  1339. # reply_body_max_size lines are processed, and the first line where
  1340. # all (if any) listed ACLs are true is used as the maximum body size
  1341. # for this reply.
  1342. #
  1343. # This size is checked twice. First when we get the reply headers,
  1344. # we check the content-length value. If the content length value exists
  1345. # and is larger than the allowed size, the request is denied and the
  1346. # user receives an error message that says "the request or reply
  1347. # is too large." If there is no content-length, and the reply
  1348. # size exceeds this limit, the client's connection is just closed
  1349. # and they will receive a partial reply.
  1350. #
  1351. # WARNING: downstream caches probably can not detect a partial reply
  1352. # if there is no content-length header, so they will cache
  1353. # partial responses and give them out as hits. You should NOT
  1354. # use this option if you have downstream caches.
  1355. #
  1356. # WARNING: A maximum size smaller than the size of squid's error messages
  1357. # will cause an infinite loop and crash squid. Ensure that the smallest
  1358. # non-zero value you use is greater that the maximum header size plus
  1359. # the size of your largest error page.
  1360. #
  1361. # If you set this parameter none (the default), there will be
  1362. # no limit imposed.
  1363. #
  1364. # Configuration Format is:
  1365. # reply_body_max_size SIZE UNITS [acl ...]
  1366. # ie.
  1367. # reply_body_max_size 10 MB
  1368. #
  1369. #Default:
  1370. # No limit is applied.
  1371.  
  1372. # NETWORK OPTIONS
  1373. # -----------------------------------------------------------------------------
  1374.  
  1375. # TAG: http_port
  1376. # Usage: port [mode] [options]
  1377. # hostname:port [mode] [options]
  1378. # 1.2.3.4:port [mode] [options]
  1379. #
  1380. # The socket addresses where Squid will listen for HTTP client
  1381. # requests. You may specify multiple socket addresses.
  1382. # There are three forms: port alone, hostname with port, and
  1383. # IP address with port. If you specify a hostname or IP
  1384. # address, Squid binds the socket to that specific
  1385. # address. Most likely, you do not need to bind to a specific
  1386. # address, so you can use the port number alone.
  1387. #
  1388. # If you are running Squid in accelerator mode, you
  1389. # probably want to listen on port 80 also, or instead.
  1390. #
  1391. # The -a command line option may be used to specify additional
  1392. # port(s) where Squid listens for proxy request. Such ports will
  1393. # be plain proxy ports with no options.
  1394. #
  1395. # You may specify multiple socket addresses on multiple lines.
  1396. #
  1397. # Modes:
  1398. #
  1399. # intercept Support for IP-Layer NAT interception delivering
  1400. # traffic to this Squid port.
  1401. # NP: disables authentication on the port.
  1402. #
  1403. # tproxy Support Linux TPROXY (or BSD divert-to) with spoofing
  1404. # of outgoing connections using the client IP address.
  1405. # NP: disables authentication on the port.
  1406. #
  1407. # accel Accelerator / reverse proxy mode
  1408. #
  1409. # ssl-bump For each CONNECT request allowed by ssl_bump ACLs,
  1410. # establish secure connection with the client and with
  1411. # the server, decrypt HTTPS messages as they pass through
  1412. # Squid, and treat them as unencrypted HTTP messages,
  1413. # becoming the man-in-the-middle.
  1414. #
  1415. # The ssl_bump option is required to fully enable
  1416. # bumping of CONNECT requests.
  1417. #
  1418. # Omitting the mode flag causes default forward proxy mode to be used.
  1419. #
  1420. #
  1421. # Accelerator Mode Options:
  1422. #
  1423. # defaultsite=domainname
  1424. # What to use for the Host: header if it is not present
  1425. # in a request. Determines what site (not origin server)
  1426. # accelerators should consider the default.
  1427. #
  1428. # no-vhost Disable using HTTP/1.1 Host header for virtual domain support.
  1429. #
  1430. # protocol= Protocol to reconstruct accelerated and intercepted
  1431. # requests with. Defaults to HTTP/1.1 for http_port and
  1432. # HTTPS/1.1 for https_port.
  1433. # When an unsupported value is configured Squid will
  1434. # produce a FATAL error.
  1435. # Values: HTTP or HTTP/1.1, HTTPS or HTTPS/1.1
  1436. #
  1437. # vport Virtual host port support. Using the http_port number
  1438. # instead of the port passed on Host: headers.
  1439. #
  1440. # vport=NN Virtual host port support. Using the specified port
  1441. # number instead of the port passed on Host: headers.
  1442. #
  1443. # act-as-origin
  1444. # Act as if this Squid is the origin server.
  1445. # This currently means generate new Date: and Expires:
  1446. # headers on HIT instead of adding Age:.
  1447. #
  1448. # ignore-cc Ignore request Cache-Control headers.
  1449. #
  1450. # WARNING: This option violates HTTP specifications if
  1451. # used in non-accelerator setups.
  1452. #
  1453. # allow-direct Allow direct forwarding in accelerator mode. Normally
  1454. # accelerated requests are denied direct forwarding as if
  1455. # never_direct was used.
  1456. #
  1457. # WARNING: this option opens accelerator mode to security
  1458. # vulnerabilities usually only affecting in interception
  1459. # mode. Make sure to protect forwarding with suitable
  1460. # http_access rules when using this.
  1461. #
  1462. #
  1463. # SSL Bump Mode Options:
  1464. # In addition to these options ssl-bump requires TLS/SSL options.
  1465. #
  1466. # generate-host-certificates[=<on|off>]
  1467. # Dynamically create SSL server certificates for the
  1468. # destination hosts of bumped CONNECT requests.When
  1469. # enabled, the cert and key options are used to sign
  1470. # generated certificates. Otherwise generated
  1471. # certificate will be selfsigned.
  1472. # If there is a CA certificate lifetime of the generated
  1473. # certificate equals lifetime of the CA certificate. If
  1474. # generated certificate is selfsigned lifetime is three
  1475. # years.
  1476. # This option is disabled by default. See the ssl-bump
  1477. # option above for more information.
  1478. #
  1479. # dynamic_cert_mem_cache_size=SIZE
  1480. # Approximate total RAM size spent on cached generated
  1481. # certificates. If set to zero, caching is disabled.
  1482. #
  1483. # TLS / SSL Options:
  1484. #
  1485. # cert= Path to SSL certificate (PEM format).
  1486. #
  1487. # key= Path to SSL private key file (PEM format)
  1488. # if not specified, the certificate file is
  1489. # assumed to be a combined certificate and
  1490. # key file.
  1491. #
  1492. # version= The version of SSL/TLS supported
  1493. # 1 automatic (default)
  1494. # 2 SSLv2 only
  1495. # 3 SSLv3 only
  1496. # 4 TLSv1.0 only
  1497. # 5 TLSv1.1 only
  1498. # 6 TLSv1.2 only
  1499. #
  1500. # cipher= Colon separated list of supported ciphers.
  1501. # NOTE: some ciphers such as EDH ciphers depend on
  1502. # additional settings. If those settings are
  1503. # omitted the ciphers may be silently ignored
  1504. # by the OpenSSL library.
  1505. #
  1506. # options= Various SSL implementation options. The most important
  1507. # being:
  1508. # NO_SSLv2 Disallow the use of SSLv2
  1509. # NO_SSLv3 Disallow the use of SSLv3
  1510. # NO_TLSv1 Disallow the use of TLSv1.0
  1511. # NO_TLSv1_1 Disallow the use of TLSv1.1
  1512. # NO_TLSv1_2 Disallow the use of TLSv1.2
  1513. # SINGLE_DH_USE Always create a new key when using
  1514. # temporary/ephemeral DH key exchanges
  1515. # NO_TICKET Disables TLS tickets extension
  1516. #
  1517. # SINGLE_ECDH_USE
  1518. # Enable ephemeral ECDH key exchange.
  1519. # The adopted curve should be specified
  1520. # using the tls-dh option.
  1521. #
  1522. # ALL Enable various bug workarounds
  1523. # suggested as "harmless" by OpenSSL
  1524. # Be warned that this reduces SSL/TLS
  1525. # strength to some attacks.
  1526. # See OpenSSL SSL_CTX_set_options documentation for a
  1527. # complete list of options.
  1528. #
  1529. # clientca= File containing the list of CAs to use when
  1530. # requesting a client certificate.
  1531. #
  1532. # cafile= File containing additional CA certificates to
  1533. # use when verifying client certificates. If unset
  1534. # clientca will be used.
  1535. #
  1536. # capath= Directory containing additional CA certificates
  1537. # and CRL lists to use when verifying client certificates.
  1538. #
  1539. # crlfile= File of additional CRL lists to use when verifying
  1540. # the client certificate, in addition to CRLs stored in
  1541. # the capath. Implies VERIFY_CRL flag below.
  1542. #
  1543. # tls-dh=[curve:]file
  1544. # File containing DH parameters for temporary/ephemeral DH key
  1545. # exchanges, optionally prefixed by a curve for ephemeral ECDH
  1546. # key exchanges.
  1547. # See OpenSSL documentation for details on how to create the
  1548. # DH parameter file. Supported curves for ECDH can be listed
  1549. # using the "openssl ecparam -list_curves" command.
  1550. # WARNING: EDH and EECDH ciphers will be silently disabled if
  1551. # this option is not set.
  1552. #
  1553. # sslflags= Various flags modifying the use of SSL:
  1554. # DELAYED_AUTH
  1555. # Don't request client certificates
  1556. # immediately, but wait until acl processing
  1557. # requires a certificate (not yet implemented).
  1558. # NO_DEFAULT_CA
  1559. # Don't use the default CA lists built in
  1560. # to OpenSSL.
  1561. # NO_SESSION_REUSE
  1562. # Don't allow for session reuse. Each connection
  1563. # will result in a new SSL session.
  1564. # VERIFY_CRL
  1565. # Verify CRL lists when accepting client
  1566. # certificates.
  1567. # VERIFY_CRL_ALL
  1568. # Verify CRL lists for all certificates in the
  1569. # client certificate chain.
  1570. #
  1571. # sslcontext= SSL session ID context identifier.
  1572. #
  1573. # Other Options:
  1574. #
  1575. # connection-auth[=on|off]
  1576. # use connection-auth=off to tell Squid to prevent
  1577. # forwarding Microsoft connection oriented authentication
  1578. # (NTLM, Negotiate and Kerberos)
  1579. #
  1580. # disable-pmtu-discovery=
  1581. # Control Path-MTU discovery usage:
  1582. # off lets OS decide on what to do (default).
  1583. # transparent disable PMTU discovery when transparent
  1584. # support is enabled.
  1585. # always disable always PMTU discovery.
  1586. #
  1587. # In many setups of transparently intercepting proxies
  1588. # Path-MTU discovery can not work on traffic towards the
  1589. # clients. This is the case when the intercepting device
  1590. # does not fully track connections and fails to forward
  1591. # ICMP must fragment messages to the cache server. If you
  1592. # have such setup and experience that certain clients
  1593. # sporadically hang or never complete requests set
  1594. # disable-pmtu-discovery option to 'transparent'.
  1595. #
  1596. # name= Specifies a internal name for the port. Defaults to
  1597. # the port specification (port or addr:port)
  1598. #
  1599. # tcpkeepalive[=idle,interval,timeout]
  1600. # Enable TCP keepalive probes of idle connections.
  1601. # In seconds; idle is the initial time before TCP starts
  1602. # probing the connection, interval how often to probe, and
  1603. # timeout the time before giving up.
  1604. #
  1605. # require-proxy-header
  1606. # Require PROXY protocol version 1 or 2 connections.
  1607. # The proxy_protocol_access is required to whitelist
  1608. # downstream proxies which can be trusted.
  1609. #
  1610. # If you run Squid on a dual-homed machine with an internal
  1611. # and an external interface we recommend you to specify the
  1612. # internal address:port in http_port. This way Squid will only be
  1613. # visible on the internal address.
  1614. #
  1615. #
  1616.  
  1617. # Squid normally listens to port 3128
  1618. http_port 1984
  1619.  
  1620. # TAG: https_port
  1621. # Note: This option is only available if Squid is rebuilt with the
  1622. # --with-openssl
  1623. #
  1624. # Usage: [ip:]port cert=certificate.pem [key=key.pem] [mode] [options...]
  1625. #
  1626. # The socket address where Squid will listen for client requests made
  1627. # over TLS or SSL connections. Commonly referred to as HTTPS.
  1628. #
  1629. # This is most useful for situations where you are running squid in
  1630. # accelerator mode and you want to do the SSL work at the accelerator level.
  1631. #
  1632. # You may specify multiple socket addresses on multiple lines,
  1633. # each with their own SSL certificate and/or options.
  1634. #
  1635. # Modes:
  1636. #
  1637. # accel Accelerator / reverse proxy mode
  1638. #
  1639. # intercept Support for IP-Layer interception of
  1640. # outgoing requests without browser settings.
  1641. # NP: disables authentication and IPv6 on the port.
  1642. #
  1643. # tproxy Support Linux TPROXY for spoofing outgoing
  1644. # connections using the client IP address.
  1645. # NP: disables authentication and maybe IPv6 on the port.
  1646. #
  1647. # ssl-bump For each intercepted connection allowed by ssl_bump
  1648. # ACLs, establish a secure connection with the client and with
  1649. # the server, decrypt HTTPS messages as they pass through
  1650. # Squid, and treat them as unencrypted HTTP messages,
  1651. # becoming the man-in-the-middle.
  1652. #
  1653. # An "ssl_bump server-first" match is required to
  1654. # fully enable bumping of intercepted SSL connections.
  1655. #
  1656. # Requires tproxy or intercept.
  1657. #
  1658. # Omitting the mode flag causes default forward proxy mode to be used.
  1659. #
  1660. #
  1661. # See http_port for a list of generic options
  1662. #
  1663. #
  1664. # SSL Options:
  1665. #
  1666. # cert= Path to SSL certificate (PEM format).
  1667. #
  1668. # key= Path to SSL private key file (PEM format)
  1669. # if not specified, the certificate file is
  1670. # assumed to be a combined certificate and
  1671. # key file.
  1672. #
  1673. # version= The version of SSL/TLS supported
  1674. # 1 automatic (default)
  1675. # 2 SSLv2 only
  1676. # 3 SSLv3 only
  1677. # 4 TLSv1 only
  1678. #
  1679. # cipher= Colon separated list of supported ciphers.
  1680. #
  1681. # options= Various SSL engine options. The most important
  1682. # being:
  1683. # NO_SSLv2 Disallow the use of SSLv2
  1684. # NO_SSLv3 Disallow the use of SSLv3
  1685. # NO_TLSv1 Disallow the use of TLSv1
  1686. #
  1687. # SINGLE_DH_USE Always create a new key when using
  1688. # temporary/ephemeral DH key exchanges
  1689. #
  1690. # SINGLE_ECDH_USE
  1691. # Enable ephemeral ECDH key exchange.
  1692. # The adopted curve should be specified
  1693. # using the tls-dh option.
  1694. #
  1695. # See src/ssl_support.c or OpenSSL SSL_CTX_set_options
  1696. # documentation for a complete list of options.
  1697. #
  1698. # clientca= File containing the list of CAs to use when
  1699. # requesting a client certificate.
  1700. #
  1701. # cafile= File containing additional CA certificates to
  1702. # use when verifying client certificates. If unset
  1703. # clientca will be used.
  1704. #
  1705. # capath= Directory containing additional CA certificates
  1706. # and CRL lists to use when verifying client certificates.
  1707. #
  1708. # crlfile= File of additional CRL lists to use when verifying
  1709. # the client certificate, in addition to CRLs stored in
  1710. # the capath. Implies VERIFY_CRL flag below.
  1711. #
  1712. # tls-dh=[curve:]file
  1713. # File containing DH parameters for temporary/ephemeral DH key
  1714. # exchanges, optionally prefixed by a curve for ephemeral ECDH
  1715. # key exchanges.
  1716. #
  1717. # sslflags= Various flags modifying the use of SSL:
  1718. # DELAYED_AUTH
  1719. # Don't request client certificates
  1720. # immediately, but wait until acl processing
  1721. # requires a certificate (not yet implemented).
  1722. # NO_DEFAULT_CA
  1723. # Don't use the default CA lists built in
  1724. # to OpenSSL.
  1725. # NO_SESSION_REUSE
  1726. # Don't allow for session reuse. Each connection
  1727. # will result in a new SSL session.
  1728. # VERIFY_CRL
  1729. # Verify CRL lists when accepting client
  1730. # certificates.
  1731. # VERIFY_CRL_ALL
  1732. # Verify CRL lists for all certificates in the
  1733. # client certificate chain.
  1734. #
  1735. # sslcontext= SSL session ID context identifier.
  1736. #
  1737. # generate-host-certificates[=<on|off>]
  1738. # Dynamically create SSL server certificates for the
  1739. # destination hosts of bumped SSL requests.When
  1740. # enabled, the cert and key options are used to sign
  1741. # generated certificates. Otherwise generated
  1742. # certificate will be selfsigned.
  1743. # If there is CA certificate life time of generated
  1744. # certificate equals lifetime of CA certificate. If
  1745. # generated certificate is selfsigned lifetime is three
  1746. # years.
  1747. # This option is disabled by default. See the ssl-bump
  1748. # option above for more information.
  1749. #
  1750. # dynamic_cert_mem_cache_size=SIZE
  1751. # Approximate total RAM size spent on cached generated
  1752. # certificates. If set to zero, caching is disabled.
  1753. #
  1754. # See http_port for a list of available options.
  1755. #Default:
  1756. # none
  1757.  
  1758. # TAG: ftp_port
  1759. # Enables Native FTP proxy by specifying the socket address where Squid
  1760. # listens for FTP client requests. See http_port directive for various
  1761. # ways to specify the listening address and mode.
  1762. #
  1763. # Usage: ftp_port address [mode] [options]
  1764. #
  1765. # WARNING: This is a new, experimental, complex feature that has seen
  1766. # limited production exposure. Some Squid modules (e.g., caching) do not
  1767. # currently work with native FTP proxying, and many features have not
  1768. # even been tested for compatibility. Test well before deploying!
  1769. #
  1770. # Native FTP proxying differs substantially from proxying HTTP requests
  1771. # with ftp:// URIs because Squid works as an FTP server and receives
  1772. # actual FTP commands (rather than HTTP requests with FTP URLs).
  1773. #
  1774. # Native FTP commands accepted at ftp_port are internally converted or
  1775. # wrapped into HTTP-like messages. The same happens to Native FTP
  1776. # responses received from FTP origin servers. Those HTTP-like messages
  1777. # are shoveled through regular access control and adaptation layers
  1778. # between the FTP client and the FTP origin server. This allows Squid to
  1779. # examine, adapt, block, and log FTP exchanges. Squid reuses most HTTP
  1780. # mechanisms when shoveling wrapped FTP messages. For example,
  1781. # http_access and adaptation_access directives are used.
  1782. #
  1783. # Modes:
  1784. #
  1785. # intercept Same as http_port intercept. The FTP origin address is
  1786. # determined based on the intended destination of the
  1787. # intercepted connection.
  1788. #
  1789. # tproxy Support Linux TPROXY for spoofing outgoing
  1790. # connections using the client IP address.
  1791. # NP: disables authentication and maybe IPv6 on the port.
  1792. #
  1793. # By default (i.e., without an explicit mode option), Squid extracts the
  1794. # FTP origin address from the login@origin parameter of the FTP USER
  1795. # command. Many popular FTP clients support such native FTP proxying.
  1796. #
  1797. # Options:
  1798. #
  1799. # name=token Specifies an internal name for the port. Defaults to
  1800. # the port address. Usable with myportname ACL.
  1801. #
  1802. # ftp-track-dirs
  1803. # Enables tracking of FTP directories by injecting extra
  1804. # PWD commands and adjusting Request-URI (in wrapping
  1805. # HTTP requests) to reflect the current FTP server
  1806. # directory. Tracking is disabled by default.
  1807. #
  1808. # protocol=FTP Protocol to reconstruct accelerated and intercepted
  1809. # requests with. Defaults to FTP. No other accepted
  1810. # values have been tested with. An unsupported value
  1811. # results in a FATAL error. Accepted values are FTP,
  1812. # HTTP (or HTTP/1.1), and HTTPS (or HTTPS/1.1).
  1813. #
  1814. # Other http_port modes and options that are not specific to HTTP and
  1815. # HTTPS may also work.
  1816. #Default:
  1817. # none
  1818.  
  1819. # TAG: tcp_outgoing_tos
  1820. # Allows you to select a TOS/Diffserv value for packets outgoing
  1821. # on the server side, based on an ACL.
  1822. #
  1823. # tcp_outgoing_tos ds-field [!]aclname ...
  1824. #
  1825. # Example where normal_service_net uses the TOS value 0x00
  1826. # and good_service_net uses 0x20
  1827. #
  1828. # acl normal_service_net src 10.0.0.0/24
  1829. # acl good_service_net src 10.0.1.0/24
  1830. # tcp_outgoing_tos 0x00 normal_service_net
  1831. # tcp_outgoing_tos 0x20 good_service_net
  1832. #
  1833. # TOS/DSCP values really only have local significance - so you should
  1834. # know what you're specifying. For more information, see RFC2474,
  1835. # RFC2475, and RFC3260.
  1836. #
  1837. # The TOS/DSCP byte must be exactly that - a octet value 0 - 255, or
  1838. # "default" to use whatever default your host has.
  1839. # Note that only multiples of 4 are usable as the two rightmost bits have
  1840. # been redefined for use by ECN (RFC 3168 section 23.1).
  1841. # The squid parser will enforce this by masking away the ECN bits.
  1842. #
  1843. # Processing proceeds in the order specified, and stops at first fully
  1844. # matching line.
  1845. #
  1846. # Only fast ACLs are supported.
  1847. #Default:
  1848. # none
  1849.  
  1850. # TAG: clientside_tos
  1851. # Allows you to select a TOS/DSCP value for packets being transmitted
  1852. # on the client-side, based on an ACL.
  1853. #
  1854. # clientside_tos ds-field [!]aclname ...
  1855. #
  1856. # Example where normal_service_net uses the TOS value 0x00
  1857. # and good_service_net uses 0x20
  1858. #
  1859. # acl normal_service_net src 10.0.0.0/24
  1860. # acl good_service_net src 10.0.1.0/24
  1861. # clientside_tos 0x00 normal_service_net
  1862. # clientside_tos 0x20 good_service_net
  1863. #
  1864. # Note: This feature is incompatible with qos_flows. Any TOS values set here
  1865. # will be overwritten by TOS values in qos_flows.
  1866. #
  1867. # The TOS/DSCP byte must be exactly that - a octet value 0 - 255, or
  1868. # "default" to use whatever default your host has.
  1869. # Note that only multiples of 4 are usable as the two rightmost bits have
  1870. # been redefined for use by ECN (RFC 3168 section 23.1).
  1871. # The squid parser will enforce this by masking away the ECN bits.
  1872. #
  1873. #Default:
  1874. # none
  1875.  
  1876. # TAG: tcp_outgoing_mark
  1877. # Note: This option is only available if Squid is rebuilt with the
  1878. # Packet MARK (Linux)
  1879. #
  1880. # Allows you to apply a Netfilter mark value to outgoing packets
  1881. # on the server side, based on an ACL.
  1882. #
  1883. # tcp_outgoing_mark mark-value [!]aclname ...
  1884. #
  1885. # Example where normal_service_net uses the mark value 0x00
  1886. # and good_service_net uses 0x20
  1887. #
  1888. # acl normal_service_net src 10.0.0.0/24
  1889. # acl good_service_net src 10.0.1.0/24
  1890. # tcp_outgoing_mark 0x00 normal_service_net
  1891. # tcp_outgoing_mark 0x20 good_service_net
  1892. #
  1893. # Only fast ACLs are supported.
  1894. #Default:
  1895. # none
  1896.  
  1897. # TAG: clientside_mark
  1898. # Note: This option is only available if Squid is rebuilt with the
  1899. # Packet MARK (Linux)
  1900. #
  1901. # Allows you to apply a Netfilter mark value to packets being transmitted
  1902. # on the client-side, based on an ACL.
  1903. #
  1904. # clientside_mark mark-value [!]aclname ...
  1905. #
  1906. # Example where normal_service_net uses the mark value 0x00
  1907. # and good_service_net uses 0x20
  1908. #
  1909. # acl normal_service_net src 10.0.0.0/24
  1910. # acl good_service_net src 10.0.1.0/24
  1911. # clientside_mark 0x00 normal_service_net
  1912. # clientside_mark 0x20 good_service_net
  1913. #
  1914. # Note: This feature is incompatible with qos_flows. Any mark values set here
  1915. # will be overwritten by mark values in qos_flows.
  1916. #Default:
  1917. # none
  1918.  
  1919. # TAG: qos_flows
  1920. # Allows you to select a TOS/DSCP value to mark outgoing
  1921. # connections to the client, based on where the reply was sourced.
  1922. # For platforms using netfilter, allows you to set a netfilter mark
  1923. # value instead of, or in addition to, a TOS value.
  1924. #
  1925. # By default this functionality is disabled. To enable it with the default
  1926. # settings simply use "qos_flows mark" or "qos_flows tos". Default
  1927. # settings will result in the netfilter mark or TOS value being copied
  1928. # from the upstream connection to the client. Note that it is the connection
  1929. # CONNMARK value not the packet MARK value that is copied.
  1930. #
  1931. # It is not currently possible to copy the mark or TOS value from the
  1932. # client to the upstream connection request.
  1933. #
  1934. # TOS values really only have local significance - so you should
  1935. # know what you're specifying. For more information, see RFC2474,
  1936. # RFC2475, and RFC3260.
  1937. #
  1938. # The TOS/DSCP byte must be exactly that - a octet value 0 - 255.
  1939. # Note that only multiples of 4 are usable as the two rightmost bits have
  1940. # been redefined for use by ECN (RFC 3168 section 23.1).
  1941. # The squid parser will enforce this by masking away the ECN bits.
  1942. #
  1943. # Mark values can be any unsigned 32-bit integer value.
  1944. #
  1945. # This setting is configured by setting the following values:
  1946. #
  1947. # tos|mark Whether to set TOS or netfilter mark values
  1948. #
  1949. # local-hit=0xFF Value to mark local cache hits.
  1950. #
  1951. # sibling-hit=0xFF Value to mark hits from sibling peers.
  1952. #
  1953. # parent-hit=0xFF Value to mark hits from parent peers.
  1954. #
  1955. # miss=0xFF[/mask] Value to mark cache misses. Takes precedence
  1956. # over the preserve-miss feature (see below), unless
  1957. # mask is specified, in which case only the bits
  1958. # specified in the mask are written.
  1959. #
  1960. # The TOS variant of the following features are only possible on Linux
  1961. # and require your kernel to be patched with the TOS preserving ZPH
  1962. # patch, available from http://zph.bratcheda.org
  1963. # No patch is needed to preserve the netfilter mark, which will work
  1964. # with all variants of netfilter.
  1965. #
  1966. # disable-preserve-miss
  1967. # This option disables the preservation of the TOS or netfilter
  1968. # mark. By default, the existing TOS or netfilter mark value of
  1969. # the response coming from the remote server will be retained
  1970. # and masked with miss-mark.
  1971. # NOTE: in the case of a netfilter mark, the mark must be set on
  1972. # the connection (using the CONNMARK target) not on the packet
  1973. # (MARK target).
  1974. #
  1975. # miss-mask=0xFF
  1976. # Allows you to mask certain bits in the TOS or mark value
  1977. # received from the remote server, before copying the value to
  1978. # the TOS sent towards clients.
  1979. # Default for tos: 0xFF (TOS from server is not changed).
  1980. # Default for mark: 0xFFFFFFFF (mark from server is not changed).
  1981. #
  1982. # All of these features require the --enable-zph-qos compilation flag
  1983. # (enabled by default). Netfilter marking also requires the
  1984. # libnetfilter_conntrack libraries (--with-netfilter-conntrack) and
  1985. # libcap 2.09+ (--with-libcap).
  1986. #
  1987. #Default:
  1988. # none
  1989.  
  1990. # TAG: tcp_outgoing_address
  1991. # Allows you to map requests to different outgoing IP addresses
  1992. # based on the username or source address of the user making
  1993. # the request.
  1994. #
  1995. # tcp_outgoing_address ipaddr [[!]aclname] ...
  1996. #
  1997. # For example;
  1998. # Forwarding clients with dedicated IPs for certain subnets.
  1999. #
  2000. # acl normal_service_net src 10.0.0.0/24
  2001. # acl good_service_net src 10.0.2.0/24
  2002. #
  2003. # tcp_outgoing_address 2001:db8::c001 good_service_net
  2004. # tcp_outgoing_address 10.1.0.2 good_service_net
  2005. #
  2006. # tcp_outgoing_address 2001:db8::beef normal_service_net
  2007. # tcp_outgoing_address 10.1.0.1 normal_service_net
  2008. #
  2009. # tcp_outgoing_address 2001:db8::1
  2010. # tcp_outgoing_address 10.1.0.3
  2011. #
  2012. # Processing proceeds in the order specified, and stops at first fully
  2013. # matching line.
  2014. #
  2015. # Squid will add an implicit IP version test to each line.
  2016. # Requests going to IPv4 websites will use the outgoing 10.1.0.* addresses.
  2017. # Requests going to IPv6 websites will use the outgoing 2001:db8:* addresses.
  2018. #
  2019. #
  2020. # NOTE: The use of this directive using client dependent ACLs is
  2021. # incompatible with the use of server side persistent connections. To
  2022. # ensure correct results it is best to set server_persistent_connections
  2023. # to off when using this directive in such configurations.
  2024. #
  2025. # NOTE: The use of this directive to set a local IP on outgoing TCP links
  2026. # is incompatible with using TPROXY to set client IP out outbound TCP links.
  2027. # When needing to contact peers use the no-tproxy cache_peer option and the
  2028. # client_dst_passthru directive re-enable normal forwarding such as this.
  2029. #
  2030. #Default:
  2031. # Address selection is performed by the operating system.
  2032.  
  2033. # TAG: host_verify_strict
  2034. # Regardless of this option setting, when dealing with intercepted
  2035. # traffic, Squid always verifies that the destination IP address matches
  2036. # the Host header domain or IP (called 'authority form URL').
  2037. #
  2038. # This enforcement is performed to satisfy a MUST-level requirement in
  2039. # RFC 2616 section 14.23: "The Host field value MUST represent the naming
  2040. # authority of the origin server or gateway given by the original URL".
  2041. #
  2042. # When set to ON:
  2043. # Squid always responds with an HTTP 409 (Conflict) error
  2044. # page and logs a security warning if there is no match.
  2045. #
  2046. # Squid verifies that the destination IP address matches
  2047. # the Host header for forward-proxy and reverse-proxy traffic
  2048. # as well. For those traffic types, Squid also enables the
  2049. # following checks, comparing the corresponding Host header
  2050. # and Request-URI components:
  2051. #
  2052. # * The host names (domain or IP) must be identical,
  2053. # but valueless or missing Host header disables all checks.
  2054. # For the two host names to match, both must be either IP
  2055. # or FQDN.
  2056. #
  2057. # * Port numbers must be identical, but if a port is missing
  2058. # the scheme-default port is assumed.
  2059. #
  2060. #
  2061. # When set to OFF (the default):
  2062. # Squid allows suspicious requests to continue but logs a
  2063. # security warning and blocks caching of the response.
  2064. #
  2065. # * Forward-proxy traffic is not checked at all.
  2066. #
  2067. # * Reverse-proxy traffic is not checked at all.
  2068. #
  2069. # * Intercepted traffic which passes verification is handled
  2070. # according to client_dst_passthru.
  2071. #
  2072. # * Intercepted requests which fail verification are sent
  2073. # to the client original destination instead of DIRECT.
  2074. # This overrides 'client_dst_passthru off'.
  2075. #
  2076. # For now suspicious intercepted CONNECT requests are always
  2077. # responded to with an HTTP 409 (Conflict) error page.
  2078. #
  2079. #
  2080. # SECURITY NOTE:
  2081. #
  2082. # As described in CVE-2009-0801 when the Host: header alone is used
  2083. # to determine the destination of a request it becomes trivial for
  2084. # malicious scripts on remote websites to bypass browser same-origin
  2085. # security policy and sandboxing protections.
  2086. #
  2087. # The cause of this is that such applets are allowed to perform their
  2088. # own HTTP stack, in which case the same-origin policy of the browser
  2089. # sandbox only verifies that the applet tries to contact the same IP
  2090. # as from where it was loaded at the IP level. The Host: header may
  2091. # be different from the connected IP and approved origin.
  2092. #
  2093. #Default:
  2094. # host_verify_strict off
  2095.  
  2096. # TAG: client_dst_passthru
  2097. # With NAT or TPROXY intercepted traffic Squid may pass the request
  2098. # directly to the original client destination IP or seek a faster
  2099. # source using the HTTP Host header.
  2100. #
  2101. # Using Host to locate alternative servers can provide faster
  2102. # connectivity with a range of failure recovery options.
  2103. # But can also lead to connectivity trouble when the client and
  2104. # server are attempting stateful interactions unaware of the proxy.
  2105. #
  2106. # This option (on by default) prevents alternative DNS entries being
  2107. # located to send intercepted traffic DIRECT to an origin server.
  2108. # The clients original destination IP and port will be used instead.
  2109. #
  2110. # Regardless of this option setting, when dealing with intercepted
  2111. # traffic Squid will verify the Host: header and any traffic which
  2112. # fails Host verification will be treated as if this option were ON.
  2113. #
  2114. # see host_verify_strict for details on the verification process.
  2115. #Default:
  2116. # client_dst_passthru on
  2117.  
  2118. # SSL OPTIONS
  2119. # -----------------------------------------------------------------------------
  2120.  
  2121. # TAG: ssl_unclean_shutdown
  2122. # Note: This option is only available if Squid is rebuilt with the
  2123. # --with-openssl
  2124. #
  2125. # Some browsers (especially MSIE) bugs out on SSL shutdown
  2126. # messages.
  2127. #Default:
  2128. # ssl_unclean_shutdown off
  2129.  
  2130. # TAG: ssl_engine
  2131. # Note: This option is only available if Squid is rebuilt with the
  2132. # --with-openssl
  2133. #
  2134. # The OpenSSL engine to use. You will need to set this if you
  2135. # would like to use hardware SSL acceleration for example.
  2136. #Default:
  2137. # none
  2138.  
  2139. # TAG: sslproxy_client_certificate
  2140. # Note: This option is only available if Squid is rebuilt with the
  2141. # --with-openssl
  2142. #
  2143. # Client SSL Certificate to use when proxying https:// URLs
  2144. #Default:
  2145. # none
  2146.  
  2147. # TAG: sslproxy_client_key
  2148. # Note: This option is only available if Squid is rebuilt with the
  2149. # --with-openssl
  2150. #
  2151. # Client SSL Key to use when proxying https:// URLs
  2152. #Default:
  2153. # none
  2154.  
  2155. # TAG: sslproxy_version
  2156. # Note: This option is only available if Squid is rebuilt with the
  2157. # --with-openssl
  2158. #
  2159. # SSL version level to use when proxying https:// URLs
  2160. #
  2161. # The versions of SSL/TLS supported:
  2162. #
  2163. # 1 automatic (default)
  2164. # 2 SSLv2 only
  2165. # 3 SSLv3 only
  2166. # 4 TLSv1.0 only
  2167. # 5 TLSv1.1 only
  2168. # 6 TLSv1.2 only
  2169. #Default:
  2170. # automatic SSL/TLS version negotiation
  2171.  
  2172. # TAG: sslproxy_options
  2173. # Note: This option is only available if Squid is rebuilt with the
  2174. # --with-openssl
  2175. #
  2176. # Colon (:) or comma (,) separated list of SSL implementation options
  2177. # to use when proxying https:// URLs
  2178. #
  2179. # The most important being:
  2180. #
  2181. # NO_SSLv2 Disallow the use of SSLv2
  2182. # NO_SSLv3 Disallow the use of SSLv3
  2183. # NO_TLSv1 Disallow the use of TLSv1.0
  2184. # NO_TLSv1_1 Disallow the use of TLSv1.1
  2185. # NO_TLSv1_2 Disallow the use of TLSv1.2
  2186. #
  2187. # SINGLE_DH_USE
  2188. # Always create a new key when using temporary/ephemeral
  2189. # DH key exchanges
  2190. #
  2191. # NO_TICKET
  2192. # Disable use of RFC5077 session tickets. Some servers
  2193. # may have problems understanding the TLS extension due
  2194. # to ambiguous specification in RFC4507.
  2195. #
  2196. # ALL Enable various bug workarounds suggested as "harmless"
  2197. # by OpenSSL. Be warned that this may reduce SSL/TLS
  2198. # strength to some attacks.
  2199. #
  2200. # See the OpenSSL SSL_CTX_set_options documentation for a
  2201. # complete list of possible options.
  2202. #
  2203. # WARNING: This directive takes a single token. If a space is used
  2204. # the value(s) after that space are SILENTLY IGNORED.
  2205. #Default:
  2206. # none
  2207.  
  2208. # TAG: sslproxy_cipher
  2209. # Note: This option is only available if Squid is rebuilt with the
  2210. # --with-openssl
  2211. #
  2212. # SSL cipher list to use when proxying https:// URLs
  2213. #
  2214. # Colon separated list of supported ciphers.
  2215. #Default:
  2216. # none
  2217.  
  2218. # TAG: sslproxy_cafile
  2219. # Note: This option is only available if Squid is rebuilt with the
  2220. # --with-openssl
  2221. #
  2222. # file containing CA certificates to use when verifying server
  2223. # certificates while proxying https:// URLs
  2224. #Default:
  2225. # none
  2226.  
  2227. # TAG: sslproxy_capath
  2228. # Note: This option is only available if Squid is rebuilt with the
  2229. # --with-openssl
  2230. #
  2231. # directory containing CA certificates to use when verifying
  2232. # server certificates while proxying https:// URLs
  2233. #Default:
  2234. # none
  2235.  
  2236. # TAG: sslproxy_session_ttl
  2237. # Note: This option is only available if Squid is rebuilt with the
  2238. # --with-openssl
  2239. #
  2240. # Sets the timeout value for SSL sessions
  2241. #Default:
  2242. # sslproxy_session_ttl 300
  2243.  
  2244. # TAG: sslproxy_session_cache_size
  2245. # Note: This option is only available if Squid is rebuilt with the
  2246. # --with-openssl
  2247. #
  2248. # Sets the cache size to use for ssl session
  2249. #Default:
  2250. # sslproxy_session_cache_size 2 MB
  2251.  
  2252. # TAG: sslproxy_foreign_intermediate_certs
  2253. # Note: This option is only available if Squid is rebuilt with the
  2254. # --with-openssl
  2255. #
  2256. # Many origin servers fail to send their full server certificate
  2257. # chain for verification, assuming the client already has or can
  2258. # easily locate any missing intermediate certificates.
  2259. #
  2260. # Squid uses the certificates from the specified file to fill in
  2261. # these missing chains when trying to validate origin server
  2262. # certificate chains.
  2263. #
  2264. # The file is expected to contain zero or more PEM-encoded
  2265. # intermediate certificates. These certificates are not treated
  2266. # as trusted root certificates, and any self-signed certificate in
  2267. # this file will be ignored.
  2268. #Default:
  2269. # none
  2270.  
  2271. # TAG: sslproxy_cert_sign_hash
  2272. # Note: This option is only available if Squid is rebuilt with the
  2273. # --with-openssl
  2274. #
  2275. # Sets the hashing algorithm to use when signing generated certificates.
  2276. # Valid algorithm names depend on the OpenSSL library used. The following
  2277. # names are usually available: sha1, sha256, sha512, and md5. Please see
  2278. # your OpenSSL library manual for the available hashes. By default, Squids
  2279. # that support this option use sha256 hashes.
  2280. #
  2281. # Squid does not forcefully purge cached certificates that were generated
  2282. # with an algorithm other than the currently configured one. They remain
  2283. # in the cache, subject to the regular cache eviction policy, and become
  2284. # useful if the algorithm changes again.
  2285. #Default:
  2286. # none
  2287.  
  2288. # TAG: ssl_bump
  2289. # Note: This option is only available if Squid is rebuilt with the
  2290. # --with-openssl
  2291. #
  2292. # This option is consulted when a CONNECT request is received on
  2293. # an http_port (or a new connection is intercepted at an
  2294. # https_port), provided that port was configured with an ssl-bump
  2295. # flag. The subsequent data on the connection is either treated as
  2296. # HTTPS and decrypted OR tunneled at TCP level without decryption,
  2297. # depending on the first matching bumping "action".
  2298. #
  2299. # ssl_bump <action> [!]acl ...
  2300. #
  2301. # The following bumping actions are currently supported:
  2302. #
  2303. # splice
  2304. # Become a TCP tunnel without decrypting proxied traffic.
  2305. # This is the default action.
  2306. #
  2307. # bump
  2308. # When used on step SslBump1, establishes a secure connection
  2309. # with the client first, then connect to the server.
  2310. # When used on step SslBump2 or SslBump3, establishes a secure
  2311. # connection with the server and, using a mimicked server
  2312. # certificate, with the client.
  2313. #
  2314. # peek
  2315. # Receive client (step SslBump1) or server (step SslBump2)
  2316. # certificate while preserving the possibility of splicing the
  2317. # connection. Peeking at the server certificate (during step 2)
  2318. # usually precludes bumping of the connection at step 3.
  2319. #
  2320. # stare
  2321. # Receive client (step SslBump1) or server (step SslBump2)
  2322. # certificate while preserving the possibility of bumping the
  2323. # connection. Staring at the server certificate (during step 2)
  2324. # usually precludes splicing of the connection at step 3.
  2325. #
  2326. # terminate
  2327. # Close client and server connections.
  2328. #
  2329. # Backward compatibility actions available at step SslBump1:
  2330. #
  2331. # client-first
  2332. # Bump the connection. Establish a secure connection with the
  2333. # client first, then connect to the server. This old mode does
  2334. # not allow Squid to mimic server SSL certificate and does not
  2335. # work with intercepted SSL connections.
  2336. #
  2337. # server-first
  2338. # Bump the connection. Establish a secure connection with the
  2339. # server first, then establish a secure connection with the
  2340. # client, using a mimicked server certificate. Works with both
  2341. # CONNECT requests and intercepted SSL connections, but does
  2342. # not allow to make decisions based on SSL handshake info.
  2343. #
  2344. # peek-and-splice
  2345. # Decide whether to bump or splice the connection based on
  2346. # client-to-squid and server-to-squid SSL hello messages.
  2347. # XXX: Remove.
  2348. #
  2349. # none
  2350. # Same as the "splice" action.
  2351. #
  2352. # All ssl_bump rules are evaluated at each of the supported bumping
  2353. # steps. Rules with actions that are impossible at the current step are
  2354. # ignored. The first matching ssl_bump action wins and is applied at the
  2355. # end of the current step. If no rules match, the splice action is used.
  2356. # See the at_step ACL for a list of the supported SslBump steps.
  2357. #
  2358. # This clause supports both fast and slow acl types.
  2359. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  2360. #
  2361. # See also: http_port ssl-bump, https_port ssl-bump, and acl at_step.
  2362. #
  2363. #
  2364. # # Example: Bump all TLS connections except those originating from
  2365. # # localhost or those going to example.com.
  2366. #
  2367. # acl broken_sites ssl::server_name .example.com
  2368. # ssl_bump splice localhost
  2369. # ssl_bump splice broken_sites
  2370. # ssl_bump bump all
  2371. #Default:
  2372. # Become a TCP tunnel without decrypting proxied traffic.
  2373.  
  2374. # TAG: sslproxy_flags
  2375. # Note: This option is only available if Squid is rebuilt with the
  2376. # --with-openssl
  2377. #
  2378. # Various flags modifying the use of SSL while proxying https:// URLs:
  2379. # DONT_VERIFY_PEER Accept certificates that fail verification.
  2380. # For refined control, see sslproxy_cert_error.
  2381. # NO_DEFAULT_CA Don't use the default CA list built in
  2382. # to OpenSSL.
  2383. #Default:
  2384. # none
  2385.  
  2386. # TAG: sslproxy_cert_error
  2387. # Note: This option is only available if Squid is rebuilt with the
  2388. # --with-openssl
  2389. #
  2390. # Use this ACL to bypass server certificate validation errors.
  2391. #
  2392. # For example, the following lines will bypass all validation errors
  2393. # when talking to servers for example.com. All other
  2394. # validation errors will result in ERR_SECURE_CONNECT_FAIL error.
  2395. #
  2396. # acl BrokenButTrustedServers dstdomain example.com
  2397. # sslproxy_cert_error allow BrokenButTrustedServers
  2398. # sslproxy_cert_error deny all
  2399. #
  2400. # This clause only supports fast acl types.
  2401. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  2402. # Using slow acl types may result in server crashes
  2403. #
  2404. # Without this option, all server certificate validation errors
  2405. # terminate the transaction to protect Squid and the client.
  2406. #
  2407. # SQUID_X509_V_ERR_INFINITE_VALIDATION error cannot be bypassed
  2408. # but should not happen unless your OpenSSL library is buggy.
  2409. #
  2410. # SECURITY WARNING:
  2411. # Bypassing validation errors is dangerous because an
  2412. # error usually implies that the server cannot be trusted
  2413. # and the connection may be insecure.
  2414. #
  2415. # See also: sslproxy_flags and DONT_VERIFY_PEER.
  2416. #Default:
  2417. # Server certificate errors terminate the transaction.
  2418.  
  2419. # TAG: sslproxy_cert_sign
  2420. # Note: This option is only available if Squid is rebuilt with the
  2421. # --with-openssl
  2422. #
  2423. #
  2424. # sslproxy_cert_sign <signing algorithm> acl ...
  2425. #
  2426. # The following certificate signing algorithms are supported:
  2427. #
  2428. # signTrusted
  2429. # Sign using the configured CA certificate which is usually
  2430. # placed in and trusted by end-user browsers. This is the
  2431. # default for trusted origin server certificates.
  2432. #
  2433. # signUntrusted
  2434. # Sign to guarantee an X509_V_ERR_CERT_UNTRUSTED browser error.
  2435. # This is the default for untrusted origin server certificates
  2436. # that are not self-signed (see ssl::certUntrusted).
  2437. #
  2438. # signSelf
  2439. # Sign using a self-signed certificate with the right CN to
  2440. # generate a X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT error in the
  2441. # browser. This is the default for self-signed origin server
  2442. # certificates (see ssl::certSelfSigned).
  2443. #
  2444. # This clause only supports fast acl types.
  2445. #
  2446. # When sslproxy_cert_sign acl(s) match, Squid uses the corresponding
  2447. # signing algorithm to generate the certificate and ignores all
  2448. # subsequent sslproxy_cert_sign options (the first match wins). If no
  2449. # acl(s) match, the default signing algorithm is determined by errors
  2450. # detected when obtaining and validating the origin server certificate.
  2451. #
  2452. # WARNING: SQUID_X509_V_ERR_DOMAIN_MISMATCH and ssl:certDomainMismatch can
  2453. # be used with sslproxy_cert_adapt, but if and only if Squid is bumping a
  2454. # CONNECT request that carries a domain name. In all other cases (CONNECT
  2455. # to an IP address or an intercepted SSL connection), Squid cannot detect
  2456. # the domain mismatch at certificate generation time when
  2457. # bump-server-first is used.
  2458. #Default:
  2459. # none
  2460.  
  2461. # TAG: sslproxy_cert_adapt
  2462. # Note: This option is only available if Squid is rebuilt with the
  2463. # --with-openssl
  2464. #
  2465. #
  2466. # sslproxy_cert_adapt <adaptation algorithm> acl ...
  2467. #
  2468. # The following certificate adaptation algorithms are supported:
  2469. #
  2470. # setValidAfter
  2471. # Sets the "Not After" property to the "Not After" property of
  2472. # the CA certificate used to sign generated certificates.
  2473. #
  2474. # setValidBefore
  2475. # Sets the "Not Before" property to the "Not Before" property of
  2476. # the CA certificate used to sign generated certificates.
  2477. #
  2478. # setCommonName or setCommonName{CN}
  2479. # Sets Subject.CN property to the host name specified as a
  2480. # CN parameter or, if no explicit CN parameter was specified,
  2481. # extracted from the CONNECT request. It is a misconfiguration
  2482. # to use setCommonName without an explicit parameter for
  2483. # intercepted or tproxied SSL connections.
  2484. #
  2485. # This clause only supports fast acl types.
  2486. #
  2487. # Squid first groups sslproxy_cert_adapt options by adaptation algorithm.
  2488. # Within a group, when sslproxy_cert_adapt acl(s) match, Squid uses the
  2489. # corresponding adaptation algorithm to generate the certificate and
  2490. # ignores all subsequent sslproxy_cert_adapt options in that algorithm's
  2491. # group (i.e., the first match wins within each algorithm group). If no
  2492. # acl(s) match, the default mimicking action takes place.
  2493. #
  2494. # WARNING: SQUID_X509_V_ERR_DOMAIN_MISMATCH and ssl:certDomainMismatch can
  2495. # be used with sslproxy_cert_adapt, but if and only if Squid is bumping a
  2496. # CONNECT request that carries a domain name. In all other cases (CONNECT
  2497. # to an IP address or an intercepted SSL connection), Squid cannot detect
  2498. # the domain mismatch at certificate generation time when
  2499. # bump-server-first is used.
  2500. #Default:
  2501. # none
  2502.  
  2503. # TAG: sslpassword_program
  2504. # Note: This option is only available if Squid is rebuilt with the
  2505. # --with-openssl
  2506. #
  2507. # Specify a program used for entering SSL key passphrases
  2508. # when using encrypted SSL certificate keys. If not specified
  2509. # keys must either be unencrypted, or Squid started with the -N
  2510. # option to allow it to query interactively for the passphrase.
  2511. #
  2512. # The key file name is given as argument to the program allowing
  2513. # selection of the right password if you have multiple encrypted
  2514. # keys.
  2515. #Default:
  2516. # none
  2517.  
  2518. # OPTIONS RELATING TO EXTERNAL SSL_CRTD
  2519. # -----------------------------------------------------------------------------
  2520.  
  2521. # TAG: sslcrtd_program
  2522. # Note: This option is only available if Squid is rebuilt with the
  2523. # --enable-ssl-crtd
  2524. #
  2525. # Specify the location and options of the executable for ssl_crtd process.
  2526. # /usr/lib/squid/ssl_crtd program requires -s and -M parameters
  2527. # For more information use:
  2528. # /usr/lib/squid/ssl_crtd -h
  2529. #Default:
  2530. # sslcrtd_program /usr/lib/squid/ssl_crtd -s /var/lib/ssl_db -M 4MB
  2531.  
  2532. # TAG: sslcrtd_children
  2533. # Note: This option is only available if Squid is rebuilt with the
  2534. # --enable-ssl-crtd
  2535. #
  2536. # The maximum number of processes spawn to service ssl server.
  2537. # The maximum this may be safely set to is 32.
  2538. #
  2539. # The startup= and idle= options allow some measure of skew in your
  2540. # tuning.
  2541. #
  2542. # startup=N
  2543. #
  2544. # Sets the minimum number of processes to spawn when Squid
  2545. # starts or reconfigures. When set to zero the first request will
  2546. # cause spawning of the first child process to handle it.
  2547. #
  2548. # Starting too few children temporary slows Squid under load while it
  2549. # tries to spawn enough additional processes to cope with traffic.
  2550. #
  2551. # idle=N
  2552. #
  2553. # Sets a minimum of how many processes Squid is to try and keep available
  2554. # at all times. When traffic begins to rise above what the existing
  2555. # processes can handle this many more will be spawned up to the maximum
  2556. # configured. A minimum setting of 1 is required.
  2557. #
  2558. # You must have at least one ssl_crtd process.
  2559. #Default:
  2560. # sslcrtd_children 32 startup=5 idle=1
  2561.  
  2562. # TAG: sslcrtvalidator_program
  2563. # Note: This option is only available if Squid is rebuilt with the
  2564. # --with-openssl
  2565. #
  2566. # Specify the location and options of the executable for ssl_crt_validator
  2567. # process.
  2568. #
  2569. # Usage: sslcrtvalidator_program [ttl=n] [cache=n] path ...
  2570. #
  2571. # Options:
  2572. # ttl=n TTL in seconds for cached results. The default is 60 secs
  2573. # cache=n limit the result cache size. The default value is 2048
  2574. #Default:
  2575. # none
  2576.  
  2577. # TAG: sslcrtvalidator_children
  2578. # Note: This option is only available if Squid is rebuilt with the
  2579. # --with-openssl
  2580. #
  2581. # The maximum number of processes spawn to service SSL server.
  2582. # The maximum this may be safely set to is 32.
  2583. #
  2584. # The startup= and idle= options allow some measure of skew in your
  2585. # tuning.
  2586. #
  2587. # startup=N
  2588. #
  2589. # Sets the minimum number of processes to spawn when Squid
  2590. # starts or reconfigures. When set to zero the first request will
  2591. # cause spawning of the first child process to handle it.
  2592. #
  2593. # Starting too few children temporary slows Squid under load while it
  2594. # tries to spawn enough additional processes to cope with traffic.
  2595. #
  2596. # idle=N
  2597. #
  2598. # Sets a minimum of how many processes Squid is to try and keep available
  2599. # at all times. When traffic begins to rise above what the existing
  2600. # processes can handle this many more will be spawned up to the maximum
  2601. # configured. A minimum setting of 1 is required.
  2602. #
  2603. # concurrency=
  2604. #
  2605. # The number of requests each certificate validator helper can handle in
  2606. # parallel. A value of 0 indicates the certficate validator does not
  2607. # support concurrency. Defaults to 1.
  2608. #
  2609. # When this directive is set to a value >= 1 then the protocol
  2610. # used to communicate with the helper is modified to include
  2611. # a request ID in front of the request/response. The request
  2612. # ID from the request must be echoed back with the response
  2613. # to that request.
  2614. #
  2615. # You must have at least one ssl_crt_validator process.
  2616. #Default:
  2617. # sslcrtvalidator_children 32 startup=5 idle=1 concurrency=1
  2618.  
  2619. # OPTIONS WHICH AFFECT THE NEIGHBOR SELECTION ALGORITHM
  2620. # -----------------------------------------------------------------------------
  2621.  
  2622. # TAG: cache_peer
  2623. # To specify other caches in a hierarchy, use the format:
  2624. #
  2625. # cache_peer hostname type http-port icp-port [options]
  2626. #
  2627. # For example,
  2628. #
  2629. # # proxy icp
  2630. # # hostname type port port options
  2631. # # -------------------- -------- ----- ----- -----------
  2632. # cache_peer parent.foo.net parent 3128 3130 default
  2633. # cache_peer sib1.foo.net sibling 3128 3130 proxy-only
  2634. # cache_peer sib2.foo.net sibling 3128 3130 proxy-only
  2635. # cache_peer example.com parent 80 0 default
  2636. # cache_peer cdn.example.com sibling 3128 0
  2637. #
  2638. # type: either 'parent', 'sibling', or 'multicast'.
  2639. #
  2640. # proxy-port: The port number where the peer accept HTTP requests.
  2641. # For other Squid proxies this is usually 3128
  2642. # For web servers this is usually 80
  2643. #
  2644. # icp-port: Used for querying neighbor caches about objects.
  2645. # Set to 0 if the peer does not support ICP or HTCP.
  2646. # See ICP and HTCP options below for additional details.
  2647. #
  2648. #
  2649. # ==== ICP OPTIONS ====
  2650. #
  2651. # You MUST also set icp_port and icp_access explicitly when using these options.
  2652. # The defaults will prevent peer traffic using ICP.
  2653. #
  2654. #
  2655. # no-query Disable ICP queries to this neighbor.
  2656. #
  2657. # multicast-responder
  2658. # Indicates the named peer is a member of a multicast group.
  2659. # ICP queries will not be sent directly to the peer, but ICP
  2660. # replies will be accepted from it.
  2661. #
  2662. # closest-only Indicates that, for ICP_OP_MISS replies, we'll only forward
  2663. # CLOSEST_PARENT_MISSes and never FIRST_PARENT_MISSes.
  2664. #
  2665. # background-ping
  2666. # To only send ICP queries to this neighbor infrequently.
  2667. # This is used to keep the neighbor round trip time updated
  2668. # and is usually used in conjunction with weighted-round-robin.
  2669. #
  2670. #
  2671. # ==== HTCP OPTIONS ====
  2672. #
  2673. # You MUST also set htcp_port and htcp_access explicitly when using these options.
  2674. # The defaults will prevent peer traffic using HTCP.
  2675. #
  2676. #
  2677. # htcp Send HTCP, instead of ICP, queries to the neighbor.
  2678. # You probably also want to set the "icp-port" to 4827
  2679. # instead of 3130. This directive accepts a comma separated
  2680. # list of options described below.
  2681. #
  2682. # htcp=oldsquid Send HTCP to old Squid versions (2.5 or earlier).
  2683. #
  2684. # htcp=no-clr Send HTCP to the neighbor but without
  2685. # sending any CLR requests. This cannot be used with
  2686. # only-clr.
  2687. #
  2688. # htcp=only-clr Send HTCP to the neighbor but ONLY CLR requests.
  2689. # This cannot be used with no-clr.
  2690. #
  2691. # htcp=no-purge-clr
  2692. # Send HTCP to the neighbor including CLRs but only when
  2693. # they do not result from PURGE requests.
  2694. #
  2695. # htcp=forward-clr
  2696. # Forward any HTCP CLR requests this proxy receives to the peer.
  2697. #
  2698. #
  2699. # ==== PEER SELECTION METHODS ====
  2700. #
  2701. # The default peer selection method is ICP, with the first responding peer
  2702. # being used as source. These options can be used for better load balancing.
  2703. #
  2704. #
  2705. # default This is a parent cache which can be used as a "last-resort"
  2706. # if a peer cannot be located by any of the peer-selection methods.
  2707. # If specified more than once, only the first is used.
  2708. #
  2709. # round-robin Load-Balance parents which should be used in a round-robin
  2710. # fashion in the absence of any ICP queries.
  2711. # weight=N can be used to add bias.
  2712. #
  2713. # weighted-round-robin
  2714. # Load-Balance parents which should be used in a round-robin
  2715. # fashion with the frequency of each parent being based on the
  2716. # round trip time. Closer parents are used more often.
  2717. # Usually used for background-ping parents.
  2718. # weight=N can be used to add bias.
  2719. #
  2720. # carp Load-Balance parents which should be used as a CARP array.
  2721. # The requests will be distributed among the parents based on the
  2722. # CARP load balancing hash function based on their weight.
  2723. #
  2724. # userhash Load-balance parents based on the client proxy_auth or ident username.
  2725. #
  2726. # sourcehash Load-balance parents based on the client source IP.
  2727. #
  2728. # multicast-siblings
  2729. # To be used only for cache peers of type "multicast".
  2730. # ALL members of this multicast group have "sibling"
  2731. # relationship with it, not "parent". This is to a multicast
  2732. # group when the requested object would be fetched only from
  2733. # a "parent" cache, anyway. It's useful, e.g., when
  2734. # configuring a pool of redundant Squid proxies, being
  2735. # members of the same multicast group.
  2736. #
  2737. #
  2738. # ==== PEER SELECTION OPTIONS ====
  2739. #
  2740. # weight=N use to affect the selection of a peer during any weighted
  2741. # peer-selection mechanisms.
  2742. # The weight must be an integer; default is 1,
  2743. # larger weights are favored more.
  2744. # This option does not affect parent selection if a peering
  2745. # protocol is not in use.
  2746. #
  2747. # basetime=N Specify a base amount to be subtracted from round trip
  2748. # times of parents.
  2749. # It is subtracted before division by weight in calculating
  2750. # which parent to fectch from. If the rtt is less than the
  2751. # base time the rtt is set to a minimal value.
  2752. #
  2753. # ttl=N Specify a TTL to use when sending multicast ICP queries
  2754. # to this address.
  2755. # Only useful when sending to a multicast group.
  2756. # Because we don't accept ICP replies from random
  2757. # hosts, you must configure other group members as
  2758. # peers with the 'multicast-responder' option.
  2759. #
  2760. # no-delay To prevent access to this neighbor from influencing the
  2761. # delay pools.
  2762. #
  2763. # digest-url=URL Tell Squid to fetch the cache digest (if digests are
  2764. # enabled) for this host from the specified URL rather
  2765. # than the Squid default location.
  2766. #
  2767. #
  2768. # ==== CARP OPTIONS ====
  2769. #
  2770. # carp-key=key-specification
  2771. # use a different key than the full URL to hash against the peer.
  2772. # the key-specification is a comma-separated list of the keywords
  2773. # scheme, host, port, path, params
  2774. # Order is not important.
  2775. #
  2776. # ==== ACCELERATOR / REVERSE-PROXY OPTIONS ====
  2777. #
  2778. # originserver Causes this parent to be contacted as an origin server.
  2779. # Meant to be used in accelerator setups when the peer
  2780. # is a web server.
  2781. #
  2782. # forceddomain=name
  2783. # Set the Host header of requests forwarded to this peer.
  2784. # Useful in accelerator setups where the server (peer)
  2785. # expects a certain domain name but clients may request
  2786. # others. ie example.com or www.example.com
  2787. #
  2788. # no-digest Disable request of cache digests.
  2789. #
  2790. # no-netdb-exchange
  2791. # Disables requesting ICMP RTT database (NetDB).
  2792. #
  2793. #
  2794. # ==== AUTHENTICATION OPTIONS ====
  2795. #
  2796. # login=user:password
  2797. # If this is a personal/workgroup proxy and your parent
  2798. # requires proxy authentication.
  2799. #
  2800. # Note: The string can include URL escapes (i.e. %20 for
  2801. # spaces). This also means % must be written as %%.
  2802. #
  2803. # login=PASSTHRU
  2804. # Send login details received from client to this peer.
  2805. # Both Proxy- and WWW-Authorization headers are passed
  2806. # without alteration to the peer.
  2807. # Authentication is not required by Squid for this to work.
  2808. #
  2809. # Note: This will pass any form of authentication but
  2810. # only Basic auth will work through a proxy unless the
  2811. # connection-auth options are also used.
  2812. #
  2813. # login=PASS Send login details received from client to this peer.
  2814. # Authentication is not required by this option.
  2815. #
  2816. # If there are no client-provided authentication headers
  2817. # to pass on, but username and password are available
  2818. # from an external ACL user= and password= result tags
  2819. # they may be sent instead.
  2820. #
  2821. # Note: To combine this with proxy_auth both proxies must
  2822. # share the same user database as HTTP only allows for
  2823. # a single login (one for proxy, one for origin server).
  2824. # Also be warned this will expose your users proxy
  2825. # password to the peer. USE WITH CAUTION
  2826. #
  2827. # login=*:password
  2828. # Send the username to the upstream cache, but with a
  2829. # fixed password. This is meant to be used when the peer
  2830. # is in another administrative domain, but it is still
  2831. # needed to identify each user.
  2832. # The star can optionally be followed by some extra
  2833. # information which is added to the username. This can
  2834. # be used to identify this proxy to the peer, similar to
  2835. # the login=username:password option above.
  2836. #
  2837. # login=NEGOTIATE
  2838. # If this is a personal/workgroup proxy and your parent
  2839. # requires a secure proxy authentication.
  2840. # The first principal from the default keytab or defined by
  2841. # the environment variable KRB5_KTNAME will be used.
  2842. #
  2843. # WARNING: The connection may transmit requests from multiple
  2844. # clients. Negotiate often assumes end-to-end authentication
  2845. # and a single-client. Which is not strictly true here.
  2846. #
  2847. # login=NEGOTIATE:principal_name
  2848. # If this is a personal/workgroup proxy and your parent
  2849. # requires a secure proxy authentication.
  2850. # The principal principal_name from the default keytab or
  2851. # defined by the environment variable KRB5_KTNAME will be
  2852. # used.
  2853. #
  2854. # WARNING: The connection may transmit requests from multiple
  2855. # clients. Negotiate often assumes end-to-end authentication
  2856. # and a single-client. Which is not strictly true here.
  2857. #
  2858. # connection-auth=on|off
  2859. # Tell Squid that this peer does or not support Microsoft
  2860. # connection oriented authentication, and any such
  2861. # challenges received from there should be ignored.
  2862. # Default is auto to automatically determine the status
  2863. # of the peer.
  2864. #
  2865. #
  2866. # ==== SSL / HTTPS / TLS OPTIONS ====
  2867. #
  2868. # ssl Encrypt connections to this peer with SSL/TLS.
  2869. #
  2870. # sslcert=/path/to/ssl/certificate
  2871. # A client SSL certificate to use when connecting to
  2872. # this peer.
  2873. #
  2874. # sslkey=/path/to/ssl/key
  2875. # The private SSL key corresponding to sslcert above.
  2876. # If 'sslkey' is not specified 'sslcert' is assumed to
  2877. # reference a combined file containing both the
  2878. # certificate and the key.
  2879. #
  2880. # Notes:
  2881. #
  2882. # On Debian/Ubuntu systems a default snakeoil certificate is
  2883. # available in /etc/ssl and users can set:
  2884. #
  2885. # cert=/etc/ssl/certs/ssl-cert-snakeoil.pem
  2886. #
  2887. # and
  2888. #
  2889. # key=/etc/ssl/private/ssl-cert-snakeoil.key
  2890. #
  2891. # for testing.
  2892. #
  2893. # sslversion=1|2|3|4|5|6
  2894. # The SSL version to use when connecting to this peer
  2895. # 1 = automatic (default)
  2896. # 2 = SSL v2 only
  2897. # 3 = SSL v3 only
  2898. # 4 = TLS v1.0 only
  2899. # 5 = TLS v1.1 only
  2900. # 6 = TLS v1.2 only
  2901. #
  2902. # sslcipher=... The list of valid SSL ciphers to use when connecting
  2903. # to this peer.
  2904. #
  2905. # ssloptions=... Specify various SSL implementation options:
  2906. #
  2907. # NO_SSLv2 Disallow the use of SSLv2
  2908. # NO_SSLv3 Disallow the use of SSLv3
  2909. # NO_TLSv1 Disallow the use of TLSv1.0
  2910. # NO_TLSv1_1 Disallow the use of TLSv1.1
  2911. # NO_TLSv1_2 Disallow the use of TLSv1.2
  2912. #
  2913. # SINGLE_DH_USE
  2914. # Always create a new key when using
  2915. # temporary/ephemeral DH key exchanges
  2916. #
  2917. # NO_TICKET
  2918. # Disable use of RFC5077 session tickets. Some servers
  2919. # may have problems understanding the TLS extension due
  2920. # to ambiguous specification in RFC4507.
  2921. #
  2922. # ALL Enable various bug workarounds
  2923. # suggested as "harmless" by OpenSSL
  2924. # Be warned that this reduces SSL/TLS
  2925. # strength to some attacks.
  2926. #
  2927. # See the OpenSSL SSL_CTX_set_options documentation for a
  2928. # more complete list.
  2929. #
  2930. # sslcafile=... A file containing additional CA certificates to use
  2931. # when verifying the peer certificate.
  2932. #
  2933. # sslcapath=... A directory containing additional CA certificates to
  2934. # use when verifying the peer certificate.
  2935. #
  2936. # sslcrlfile=... A certificate revocation list file to use when
  2937. # verifying the peer certificate.
  2938. #
  2939. # sslflags=... Specify various flags modifying the SSL implementation:
  2940. #
  2941. # DONT_VERIFY_PEER
  2942. # Accept certificates even if they fail to
  2943. # verify.
  2944. # NO_DEFAULT_CA
  2945. # Don't use the default CA list built in
  2946. # to OpenSSL.
  2947. # DONT_VERIFY_DOMAIN
  2948. # Don't verify the peer certificate
  2949. # matches the server name
  2950. #
  2951. # ssldomain= The peer name as advertised in it's certificate.
  2952. # Used for verifying the correctness of the received peer
  2953. # certificate. If not specified the peer hostname will be
  2954. # used.
  2955. #
  2956. # front-end-https
  2957. # Enable the "Front-End-Https: On" header needed when
  2958. # using Squid as a SSL frontend in front of Microsoft OWA.
  2959. # See MS KB document Q307347 for details on this header.
  2960. # If set to auto the header will only be added if the
  2961. # request is forwarded as a https:// URL.
  2962. #
  2963. #
  2964. # ==== GENERAL OPTIONS ====
  2965. #
  2966. # connect-timeout=N
  2967. # A peer-specific connect timeout.
  2968. # Also see the peer_connect_timeout directive.
  2969. #
  2970. # connect-fail-limit=N
  2971. # How many times connecting to a peer must fail before
  2972. # it is marked as down. Standby connection failures
  2973. # count towards this limit. Default is 10.
  2974. #
  2975. # allow-miss Disable Squid's use of only-if-cached when forwarding
  2976. # requests to siblings. This is primarily useful when
  2977. # icp_hit_stale is used by the sibling. Excessive use
  2978. # of this option may result in forwarding loops. One way
  2979. # to prevent peering loops when using this option, is to
  2980. # deny cache peer usage on requests from a peer:
  2981. # acl fromPeer ...
  2982. # cache_peer_access peerName deny fromPeer
  2983. #
  2984. # max-conn=N Limit the number of concurrent connections the Squid
  2985. # may open to this peer, including already opened idle
  2986. # and standby connections. There is no peer-specific
  2987. # connection limit by default.
  2988. #
  2989. # A peer exceeding the limit is not used for new
  2990. # requests unless a standby connection is available.
  2991. #
  2992. # max-conn currently works poorly with idle persistent
  2993. # connections: When a peer reaches its max-conn limit,
  2994. # and there are idle persistent connections to the peer,
  2995. # the peer may not be selected because the limiting code
  2996. # does not know whether Squid can reuse those idle
  2997. # connections.
  2998. #
  2999. # standby=N Maintain a pool of N "hot standby" connections to an
  3000. # UP peer, available for requests when no idle
  3001. # persistent connection is available (or safe) to use.
  3002. # By default and with zero N, no such pool is maintained.
  3003. # N must not exceed the max-conn limit (if any).
  3004. #
  3005. # At start or after reconfiguration, Squid opens new TCP
  3006. # standby connections until there are N connections
  3007. # available and then replenishes the standby pool as
  3008. # opened connections are used up for requests. A used
  3009. # connection never goes back to the standby pool, but
  3010. # may go to the regular idle persistent connection pool
  3011. # shared by all peers and origin servers.
  3012. #
  3013. # Squid never opens multiple new standby connections
  3014. # concurrently. This one-at-a-time approach minimizes
  3015. # flooding-like effect on peers. Furthermore, just a few
  3016. # standby connections should be sufficient in most cases
  3017. # to supply most new requests with a ready-to-use
  3018. # connection.
  3019. #
  3020. # Standby connections obey server_idle_pconn_timeout.
  3021. # For the feature to work as intended, the peer must be
  3022. # configured to accept and keep them open longer than
  3023. # the idle timeout at the connecting Squid, to minimize
  3024. # race conditions typical to idle used persistent
  3025. # connections. Default request_timeout and
  3026. # server_idle_pconn_timeout values ensure such a
  3027. # configuration.
  3028. #
  3029. # name=xxx Unique name for the peer.
  3030. # Required if you have multiple peers on the same host
  3031. # but different ports.
  3032. # This name can be used in cache_peer_access and similar
  3033. # directives to identify the peer.
  3034. # Can be used by outgoing access controls through the
  3035. # peername ACL type.
  3036. #
  3037. # no-tproxy Do not use the client-spoof TPROXY support when forwarding
  3038. # requests to this peer. Use normal address selection instead.
  3039. # This overrides the spoof_client_ip ACL.
  3040. #
  3041. # proxy-only objects fetched from the peer will not be stored locally.
  3042. #
  3043. #Default:
  3044. # none
  3045.  
  3046. # TAG: cache_peer_domain
  3047. # Use to limit the domains for which a neighbor cache will be
  3048. # queried.
  3049. #
  3050. # Usage:
  3051. # cache_peer_domain cache-host domain [domain ...]
  3052. # cache_peer_domain cache-host !domain
  3053. #
  3054. # For example, specifying
  3055. #
  3056. # cache_peer_domain parent.foo.net .edu
  3057. #
  3058. # has the effect such that UDP query packets are sent to
  3059. # 'bigserver' only when the requested object exists on a
  3060. # server in the .edu domain. Prefixing the domainname
  3061. # with '!' means the cache will be queried for objects
  3062. # NOT in that domain.
  3063. #
  3064. # NOTE: * Any number of domains may be given for a cache-host,
  3065. # either on the same or separate lines.
  3066. # * When multiple domains are given for a particular
  3067. # cache-host, the first matched domain is applied.
  3068. # * Cache hosts with no domain restrictions are queried
  3069. # for all requests.
  3070. # * There are no defaults.
  3071. # * There is also a 'cache_peer_access' tag in the ACL
  3072. # section.
  3073. #Default:
  3074. # none
  3075.  
  3076. # TAG: cache_peer_access
  3077. # Restricts usage of cache_peer proxies.
  3078. #
  3079. # Usage:
  3080. # cache_peer_access peer-name allow|deny [!]aclname ...
  3081. #
  3082. # For the required peer-name parameter, use either the value of the
  3083. # cache_peer name=value parameter or, if name=value is missing, the
  3084. # cache_peer hostname parameter.
  3085. #
  3086. # This directive narrows down the selection of peering candidates, but
  3087. # does not determine the order in which the selected candidates are
  3088. # contacted. That order is determined by the peer selection algorithms
  3089. # (see PEER SELECTION sections in the cache_peer documentation).
  3090. #
  3091. # If a deny rule matches, the corresponding peer will not be contacted
  3092. # for the current transaction -- Squid will not send ICP queries and
  3093. # will not forward HTTP requests to that peer. An allow match leaves
  3094. # the corresponding peer in the selection. The first match for a given
  3095. # peer wins for that peer.
  3096. #
  3097. # The relative order of cache_peer_access directives for the same peer
  3098. # matters. The relative order of any two cache_peer_access directives
  3099. # for different peers does not matter. To ease interpretation, it is a
  3100. # good idea to group cache_peer_access directives for the same peer
  3101. # together.
  3102. #
  3103. # A single cache_peer_access directive may be evaluated multiple times
  3104. # for a given transaction because individual peer selection algorithms
  3105. # may check it independently from each other. These redundant checks
  3106. # may be optimized away in future Squid versions.
  3107. #
  3108. # This clause only supports fast acl types.
  3109. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  3110. #Default:
  3111. # No peer usage restrictions.
  3112.  
  3113. # TAG: neighbor_type_domain
  3114. # Modify the cache_peer neighbor type when passing requests
  3115. # about specific domains to the peer.
  3116. #
  3117. # Usage:
  3118. # neighbor_type_domain neighbor parent|sibling domain domain ...
  3119. #
  3120. # For example:
  3121. # cache_peer foo.example.com parent 3128 3130
  3122. # neighbor_type_domain foo.example.com sibling .au .de
  3123. #
  3124. # The above configuration treats all requests to foo.example.com as a
  3125. # parent proxy unless the request is for a .au or .de ccTLD domain name.
  3126. #Default:
  3127. # The peer type from cache_peer directive is used for all requests to that peer.
  3128.  
  3129. # TAG: dead_peer_timeout (seconds)
  3130. # This controls how long Squid waits to declare a peer cache
  3131. # as "dead." If there are no ICP replies received in this
  3132. # amount of time, Squid will declare the peer dead and not
  3133. # expect to receive any further ICP replies. However, it
  3134. # continues to send ICP queries, and will mark the peer as
  3135. # alive upon receipt of the first subsequent ICP reply.
  3136. #
  3137. # This timeout also affects when Squid expects to receive ICP
  3138. # replies from peers. If more than 'dead_peer' seconds have
  3139. # passed since the last ICP reply was received, Squid will not
  3140. # expect to receive an ICP reply on the next query. Thus, if
  3141. # your time between requests is greater than this timeout, you
  3142. # will see a lot of requests sent DIRECT to origin servers
  3143. # instead of to your parents.
  3144. #Default:
  3145. # dead_peer_timeout 10 seconds
  3146.  
  3147. # TAG: forward_max_tries
  3148. # Controls how many different forward paths Squid will try
  3149. # before giving up. See also forward_timeout.
  3150. #
  3151. # NOTE: connect_retries (default: none) can make each of these
  3152. # possible forwarding paths be tried multiple times.
  3153. #Default:
  3154. # forward_max_tries 25
  3155.  
  3156. # MEMORY CACHE OPTIONS
  3157. # -----------------------------------------------------------------------------
  3158.  
  3159. # TAG: cache_mem (bytes)
  3160. # NOTE: THIS PARAMETER DOES NOT SPECIFY THE MAXIMUM PROCESS SIZE.
  3161. # IT ONLY PLACES A LIMIT ON HOW MUCH ADDITIONAL MEMORY SQUID WILL
  3162. # USE AS A MEMORY CACHE OF OBJECTS. SQUID USES MEMORY FOR OTHER
  3163. # THINGS AS WELL. SEE THE SQUID FAQ SECTION 8 FOR DETAILS.
  3164. #
  3165. # 'cache_mem' specifies the ideal amount of memory to be used
  3166. # for:
  3167. # * In-Transit objects
  3168. # * Hot Objects
  3169. # * Negative-Cached objects
  3170. #
  3171. # Data for these objects are stored in 4 KB blocks. This
  3172. # parameter specifies the ideal upper limit on the total size of
  3173. # 4 KB blocks allocated. In-Transit objects take the highest
  3174. # priority.
  3175. #
  3176. # In-transit objects have priority over the others. When
  3177. # additional space is needed for incoming data, negative-cached
  3178. # and hot objects will be released. In other words, the
  3179. # negative-cached and hot objects will fill up any unused space
  3180. # not needed for in-transit objects.
  3181. #
  3182. # If circumstances require, this limit will be exceeded.
  3183. # Specifically, if your incoming request rate requires more than
  3184. # 'cache_mem' of memory to hold in-transit objects, Squid will
  3185. # exceed this limit to satisfy the new requests. When the load
  3186. # decreases, blocks will be freed until the high-water mark is
  3187. # reached. Thereafter, blocks will be used to store hot
  3188. # objects.
  3189. #
  3190. # If shared memory caching is enabled, Squid does not use the shared
  3191. # cache space for in-transit objects, but they still consume as much
  3192. # local memory as they need. For more details about the shared memory
  3193. # cache, see memory_cache_shared.
  3194. #Default:
  3195. # cache_mem 256 MB
  3196.  
  3197. # TAG: maximum_object_size_in_memory (bytes)
  3198. # Objects greater than this size will not be attempted to kept in
  3199. # the memory cache. This should be set high enough to keep objects
  3200. # accessed frequently in memory to improve performance whilst low
  3201. # enough to keep larger objects from hoarding cache_mem.
  3202. #Default:
  3203. # maximum_object_size_in_memory 512 KB
  3204.  
  3205. # TAG: memory_cache_shared on|off
  3206. # Controls whether the memory cache is shared among SMP workers.
  3207. #
  3208. # The shared memory cache is meant to occupy cache_mem bytes and replace
  3209. # the non-shared memory cache, although some entities may still be
  3210. # cached locally by workers for now (e.g., internal and in-transit
  3211. # objects may be served from a local memory cache even if shared memory
  3212. # caching is enabled).
  3213. #
  3214. # By default, the memory cache is shared if and only if all of the
  3215. # following conditions are satisfied: Squid runs in SMP mode with
  3216. # multiple workers, cache_mem is positive, and Squid environment
  3217. # supports required IPC primitives (e.g., POSIX shared memory segments
  3218. # and GCC-style atomic operations).
  3219. #
  3220. # To avoid blocking locks, shared memory uses opportunistic algorithms
  3221. # that do not guarantee that every cachable entity that could have been
  3222. # shared among SMP workers will actually be shared.
  3223. #Default:
  3224. # "on" where supported if doing memory caching with multiple SMP workers.
  3225.  
  3226. # TAG: memory_cache_mode
  3227. # Controls which objects to keep in the memory cache (cache_mem)
  3228. #
  3229. # always Keep most recently fetched objects in memory (default)
  3230. #
  3231. # disk Only disk cache hits are kept in memory, which means
  3232. # an object must first be cached on disk and then hit
  3233. # a second time before cached in memory.
  3234. #
  3235. # network Only objects fetched from network is kept in memory
  3236. #Default:
  3237. # Keep the most recently fetched objects in memory
  3238.  
  3239. # TAG: memory_replacement_policy
  3240. # The memory replacement policy parameter determines which
  3241. # objects are purged from memory when memory space is needed.
  3242. #
  3243. # See cache_replacement_policy for details on algorithms.
  3244. #Default:
  3245. # memory_replacement_policy lru
  3246.  
  3247. # DISK CACHE OPTIONS
  3248. # -----------------------------------------------------------------------------
  3249.  
  3250. # TAG: cache_replacement_policy
  3251. # The cache replacement policy parameter determines which
  3252. # objects are evicted (replaced) when disk space is needed.
  3253. #
  3254. # lru : Squid's original list based LRU policy
  3255. # heap GDSF : Greedy-Dual Size Frequency
  3256. # heap LFUDA: Least Frequently Used with Dynamic Aging
  3257. # heap LRU : LRU policy implemented using a heap
  3258. #
  3259. # Applies to any cache_dir lines listed below this directive.
  3260. #
  3261. # The LRU policies keeps recently referenced objects.
  3262. #
  3263. # The heap GDSF policy optimizes object hit rate by keeping smaller
  3264. # popular objects in cache so it has a better chance of getting a
  3265. # hit. It achieves a lower byte hit rate than LFUDA though since
  3266. # it evicts larger (possibly popular) objects.
  3267. #
  3268. # The heap LFUDA policy keeps popular objects in cache regardless of
  3269. # their size and thus optimizes byte hit rate at the expense of
  3270. # hit rate since one large, popular object will prevent many
  3271. # smaller, slightly less popular objects from being cached.
  3272. #
  3273. # Both policies utilize a dynamic aging mechanism that prevents
  3274. # cache pollution that can otherwise occur with frequency-based
  3275. # replacement policies.
  3276. #
  3277. # NOTE: if using the LFUDA replacement policy you should increase
  3278. # the value of maximum_object_size above its default of 4 MB to
  3279. # to maximize the potential byte hit rate improvement of LFUDA.
  3280. #
  3281. # For more information about the GDSF and LFUDA cache replacement
  3282. # policies see http://www.hpl.hp.com/techreports/1999/HPL-1999-69.html
  3283. # and http://fog.hpl.external.hp.com/techreports/98/HPL-98-173.html.
  3284. #Default:
  3285. # cache_replacement_policy lru
  3286.  
  3287. # TAG: minimum_object_size (bytes)
  3288. # Objects smaller than this size will NOT be saved on disk. The
  3289. # value is specified in bytes, and the default is 0 KB, which
  3290. # means all responses can be stored.
  3291. #Default:
  3292. # no limit
  3293.  
  3294. # TAG: maximum_object_size (bytes)
  3295. # Set the default value for max-size parameter on any cache_dir.
  3296. # The value is specified in bytes, and the default is 4 MB.
  3297. #
  3298. # If you wish to get a high BYTES hit ratio, you should probably
  3299. # increase this (one 32 MB object hit counts for 3200 10KB
  3300. # hits).
  3301. #
  3302. # If you wish to increase hit ratio more than you want to
  3303. # save bandwidth you should leave this low.
  3304. #
  3305. # NOTE: if using the LFUDA replacement policy you should increase
  3306. # this value to maximize the byte hit rate improvement of LFUDA!
  3307. # See cache_replacement_policy for a discussion of this policy.
  3308. #Default:
  3309. # maximum_object_size 4 MB
  3310.  
  3311. # TAG: cache_dir
  3312. # Format:
  3313. # cache_dir Type Directory-Name Fs-specific-data [options]
  3314. #
  3315. # You can specify multiple cache_dir lines to spread the
  3316. # cache among different disk partitions.
  3317. #
  3318. # Type specifies the kind of storage system to use. Only "ufs"
  3319. # is built by default. To enable any of the other storage systems
  3320. # see the --enable-storeio configure option.
  3321. #
  3322. # 'Directory' is a top-level directory where cache swap
  3323. # files will be stored. If you want to use an entire disk
  3324. # for caching, this can be the mount-point directory.
  3325. # The directory must exist and be writable by the Squid
  3326. # process. Squid will NOT create this directory for you.
  3327. #
  3328. # In SMP configurations, cache_dir must not precede the workers option
  3329. # and should use configuration macros or conditionals to give each
  3330. # worker interested in disk caching a dedicated cache directory.
  3331. #
  3332. #
  3333. # ==== The ufs store type ====
  3334. #
  3335. # "ufs" is the old well-known Squid storage format that has always
  3336. # been there.
  3337. #
  3338. # Usage:
  3339. # cache_dir ufs Directory-Name Mbytes L1 L2 [options]
  3340. #
  3341. # 'Mbytes' is the amount of disk space (MB) to use under this
  3342. # directory. The default is 100 MB. Change this to suit your
  3343. # configuration. Do NOT put the size of your disk drive here.
  3344. # Instead, if you want Squid to use the entire disk drive,
  3345. # subtract 20% and use that value.
  3346. #
  3347. # 'L1' is the number of first-level subdirectories which
  3348. # will be created under the 'Directory'. The default is 16.
  3349. #
  3350. # 'L2' is the number of second-level subdirectories which
  3351. # will be created under each first-level directory. The default
  3352. # is 256.
  3353. #
  3354. #
  3355. # ==== The aufs store type ====
  3356. #
  3357. # "aufs" uses the same storage format as "ufs", utilizing
  3358. # POSIX-threads to avoid blocking the main Squid process on
  3359. # disk-I/O. This was formerly known in Squid as async-io.
  3360. #
  3361. # Usage:
  3362. # cache_dir aufs Directory-Name Mbytes L1 L2 [options]
  3363. #
  3364. # see argument descriptions under ufs above
  3365. #
  3366. #
  3367. # ==== The diskd store type ====
  3368. #
  3369. # "diskd" uses the same storage format as "ufs", utilizing a
  3370. # separate process to avoid blocking the main Squid process on
  3371. # disk-I/O.
  3372. #
  3373. # Usage:
  3374. # cache_dir diskd Directory-Name Mbytes L1 L2 [options] [Q1=n] [Q2=n]
  3375. #
  3376. # see argument descriptions under ufs above
  3377. #
  3378. # Q1 specifies the number of unacknowledged I/O requests when Squid
  3379. # stops opening new files. If this many messages are in the queues,
  3380. # Squid won't open new files. Default is 64
  3381. #
  3382. # Q2 specifies the number of unacknowledged messages when Squid
  3383. # starts blocking. If this many messages are in the queues,
  3384. # Squid blocks until it receives some replies. Default is 72
  3385. #
  3386. # When Q1 < Q2 (the default), the cache directory is optimized
  3387. # for lower response time at the expense of a decrease in hit
  3388. # ratio. If Q1 > Q2, the cache directory is optimized for
  3389. # higher hit ratio at the expense of an increase in response
  3390. # time.
  3391. #
  3392. #
  3393. # ==== The rock store type ====
  3394. #
  3395. # Usage:
  3396. # cache_dir rock Directory-Name Mbytes [options]
  3397. #
  3398. # The Rock Store type is a database-style storage. All cached
  3399. # entries are stored in a "database" file, using fixed-size slots.
  3400. # A single entry occupies one or more slots.
  3401. #
  3402. # If possible, Squid using Rock Store creates a dedicated kid
  3403. # process called "disker" to avoid blocking Squid worker(s) on disk
  3404. # I/O. One disker kid is created for each rock cache_dir. Diskers
  3405. # are created only when Squid, running in daemon mode, has support
  3406. # for the IpcIo disk I/O module.
  3407. #
  3408. # swap-timeout=msec: Squid will not start writing a miss to or
  3409. # reading a hit from disk if it estimates that the swap operation
  3410. # will take more than the specified number of milliseconds. By
  3411. # default and when set to zero, disables the disk I/O time limit
  3412. # enforcement. Ignored when using blocking I/O module because
  3413. # blocking synchronous I/O does not allow Squid to estimate the
  3414. # expected swap wait time.
  3415. #
  3416. # max-swap-rate=swaps/sec: Artificially limits disk access using
  3417. # the specified I/O rate limit. Swap out requests that
  3418. # would cause the average I/O rate to exceed the limit are
  3419. # delayed. Individual swap in requests (i.e., hits or reads) are
  3420. # not delayed, but they do contribute to measured swap rate and
  3421. # since they are placed in the same FIFO queue as swap out
  3422. # requests, they may wait longer if max-swap-rate is smaller.
  3423. # This is necessary on file systems that buffer "too
  3424. # many" writes and then start blocking Squid and other processes
  3425. # while committing those writes to disk. Usually used together
  3426. # with swap-timeout to avoid excessive delays and queue overflows
  3427. # when disk demand exceeds available disk "bandwidth". By default
  3428. # and when set to zero, disables the disk I/O rate limit
  3429. # enforcement. Currently supported by IpcIo module only.
  3430. #
  3431. # slot-size=bytes: The size of a database "record" used for
  3432. # storing cached responses. A cached response occupies at least
  3433. # one slot and all database I/O is done using individual slots so
  3434. # increasing this parameter leads to more disk space waste while
  3435. # decreasing it leads to more disk I/O overheads. Should be a
  3436. # multiple of your operating system I/O page size. Defaults to
  3437. # 16KBytes. A housekeeping header is stored with each slot and
  3438. # smaller slot-sizes will be rejected. The header is smaller than
  3439. # 100 bytes.
  3440. #
  3441. #
  3442. # ==== COMMON OPTIONS ====
  3443. #
  3444. # no-store no new objects should be stored to this cache_dir.
  3445. #
  3446. # min-size=n the minimum object size in bytes this cache_dir
  3447. # will accept. It's used to restrict a cache_dir
  3448. # to only store large objects (e.g. AUFS) while
  3449. # other stores are optimized for smaller objects
  3450. # (e.g. Rock).
  3451. # Defaults to 0.
  3452. #
  3453. # max-size=n the maximum object size in bytes this cache_dir
  3454. # supports.
  3455. # The value in maximum_object_size directive sets
  3456. # the default unless more specific details are
  3457. # available (ie a small store capacity).
  3458. #
  3459. # Note: To make optimal use of the max-size limits you should order
  3460. # the cache_dir lines with the smallest max-size value first.
  3461. #
  3462. #Default:
  3463. # No disk cache. Store cache ojects only in memory.
  3464. #
  3465.  
  3466. # Uncomment and adjust the following to add a disk cache directory.
  3467. #cache_dir ufs /var/spool/squid 100 16 256
  3468.  
  3469. # TAG: store_dir_select_algorithm
  3470. # How Squid selects which cache_dir to use when the response
  3471. # object will fit into more than one.
  3472. #
  3473. # Regardless of which algorithm is used the cache_dir min-size
  3474. # and max-size parameters are obeyed. As such they can affect
  3475. # the selection algorithm by limiting the set of considered
  3476. # cache_dir.
  3477. #
  3478. # Algorithms:
  3479. #
  3480. # least-load
  3481. #
  3482. # This algorithm is suited to caches with similar cache_dir
  3483. # sizes and disk speeds.
  3484. #
  3485. # The disk with the least I/O pending is selected.
  3486. # When there are multiple disks with the same I/O load ranking
  3487. # the cache_dir with most available capacity is selected.
  3488. #
  3489. # When a mix of cache_dir sizes are configured the faster disks
  3490. # have a naturally lower I/O loading and larger disks have more
  3491. # capacity. So space used to store objects and data throughput
  3492. # may be very unbalanced towards larger disks.
  3493. #
  3494. #
  3495. # round-robin
  3496. #
  3497. # This algorithm is suited to caches with unequal cache_dir
  3498. # disk sizes.
  3499. #
  3500. # Each cache_dir is selected in a rotation. The next suitable
  3501. # cache_dir is used.
  3502. #
  3503. # Available cache_dir capacity is only considered in relation
  3504. # to whether the object will fit and meets the min-size and
  3505. # max-size parameters.
  3506. #
  3507. # Disk I/O loading is only considered to prevent overload on slow
  3508. # disks. This algorithm does not spread objects by size, so any
  3509. # I/O loading per-disk may appear very unbalanced and volatile.
  3510. #
  3511. # If several cache_dirs use similar min-size, max-size, or other
  3512. # limits to to reject certain responses, then do not group such
  3513. # cache_dir lines together, to avoid round-robin selection bias
  3514. # towards the first cache_dir after the group. Instead, interleave
  3515. # cache_dir lines from different groups. For example:
  3516. #
  3517. # store_dir_select_algorithm round-robin
  3518. # cache_dir rock /hdd1 ... min-size=100000
  3519. # cache_dir rock /ssd1 ... max-size=99999
  3520. # cache_dir rock /hdd2 ... min-size=100000
  3521. # cache_dir rock /ssd2 ... max-size=99999
  3522. # cache_dir rock /hdd3 ... min-size=100000
  3523. # cache_dir rock /ssd3 ... max-size=99999
  3524. cache_dir ufs /var/spool/squid 100 16 256
  3525. #Default:
  3526. # store_dir_select_algorithm least-load
  3527.  
  3528. # TAG: max_open_disk_fds
  3529. # To avoid having disk as the I/O bottleneck Squid can optionally
  3530. # bypass the on-disk cache if more than this amount of disk file
  3531. # descriptors are open.
  3532. #
  3533. # A value of 0 indicates no limit.
  3534. #Default:
  3535. # no limit
  3536.  
  3537. # TAG: cache_swap_low (percent, 0-100)
  3538. # The low-water mark for AUFS/UFS/diskd cache object eviction by
  3539. # the cache_replacement_policy algorithm.
  3540. #
  3541. # Removal begins when the swap (disk) usage of a cache_dir is
  3542. # above this low-water mark and attempts to maintain utilization
  3543. # near the low-water mark.
  3544. #
  3545. # As swap utilization increases towards the high-water mark set
  3546. # by cache_swap_high object eviction becomes more agressive.
  3547. #
  3548. # The value difference in percentages between low- and high-water
  3549. # marks represent an eviction rate of 300 objects per second and
  3550. # the rate continues to scale in agressiveness by multiples of
  3551. # this above the high-water mark.
  3552. #
  3553. # Defaults are 90% and 95%. If you have a large cache, 5% could be
  3554. # hundreds of MB. If this is the case you may wish to set these
  3555. # numbers closer together.
  3556. #
  3557. # See also cache_swap_high and cache_replacement_policy
  3558. #Default:
  3559. # cache_swap_low 90
  3560.  
  3561. # TAG: cache_swap_high (percent, 0-100)
  3562. # The high-water mark for AUFS/UFS/diskd cache object eviction by
  3563. # the cache_replacement_policy algorithm.
  3564. #
  3565. # Removal begins when the swap (disk) usage of a cache_dir is
  3566. # above the low-water mark set by cache_swap_low and attempts to
  3567. # maintain utilization near the low-water mark.
  3568. #
  3569. # As swap utilization increases towards this high-water mark object
  3570. # eviction becomes more agressive.
  3571. #
  3572. # The value difference in percentages between low- and high-water
  3573. # marks represent an eviction rate of 300 objects per second and
  3574. # the rate continues to scale in agressiveness by multiples of
  3575. # this above the high-water mark.
  3576. #
  3577. # Defaults are 90% and 95%. If you have a large cache, 5% could be
  3578. # hundreds of MB. If this is the case you may wish to set these
  3579. # numbers closer together.
  3580. #
  3581. # See also cache_swap_low and cache_replacement_policy
  3582. #Default:
  3583. # cache_swap_high 95
  3584.  
  3585. # LOGFILE OPTIONS
  3586. # -----------------------------------------------------------------------------
  3587.  
  3588. # TAG: logformat
  3589. # Usage:
  3590. #
  3591. # logformat <name> <format specification>
  3592. #
  3593. # Defines an access log format.
  3594. #
  3595. # The <format specification> is a string with embedded % format codes
  3596. #
  3597. # % format codes all follow the same basic structure where all but
  3598. # the formatcode is optional. Output strings are automatically escaped
  3599. # as required according to their context and the output format
  3600. # modifiers are usually not needed, but can be specified if an explicit
  3601. # output format is desired.
  3602. #
  3603. # % ["|[|'|#] [-] [[0]width] [{argument}] formatcode
  3604. #
  3605. # " output in quoted string format
  3606. # [ output in squid text log format as used by log_mime_hdrs
  3607. # # output in URL quoted format
  3608. # ' output as-is
  3609. #
  3610. # - left aligned
  3611. #
  3612. # width minimum and/or maximum field width:
  3613. # [width_min][.width_max]
  3614. # When minimum starts with 0, the field is zero-padded.
  3615. # String values exceeding maximum width are truncated.
  3616. #
  3617. # {arg} argument such as header name etc
  3618. #
  3619. # Format codes:
  3620. #
  3621. # % a literal % character
  3622. # sn Unique sequence number per log line entry
  3623. # err_code The ID of an error response served by Squid or
  3624. # a similar internal error identifier.
  3625. # err_detail Additional err_code-dependent error information.
  3626. # note The annotation specified by the argument. Also
  3627. # logs the adaptation meta headers set by the
  3628. # adaptation_meta configuration parameter.
  3629. # If no argument given all annotations logged.
  3630. # The argument may include a separator to use with
  3631. # annotation values:
  3632. # name[:separator]
  3633. # By default, multiple note values are separated with ","
  3634. # and multiple notes are separated with "\r\n".
  3635. # When logging named notes with %{name}note, the
  3636. # explicitly configured separator is used between note
  3637. # values. When logging all notes with %note, the
  3638. # explicitly configured separator is used between
  3639. # individual notes. There is currently no way to
  3640. # specify both value and notes separators when logging
  3641. # all notes with %note.
  3642. #
  3643. # Connection related format codes:
  3644. #
  3645. # >a Client source IP address
  3646. # >A Client FQDN
  3647. # >p Client source port
  3648. # >eui Client source EUI (MAC address, EUI-48 or EUI-64 identifier)
  3649. # >la Local IP address the client connected to
  3650. # >lp Local port number the client connected to
  3651. # >qos Client connection TOS/DSCP value set by Squid
  3652. # >nfmark Client connection netfilter mark set by Squid
  3653. #
  3654. # la Local listening IP address the client connection was connected to.
  3655. # lp Local listening port number the client connection was connected to.
  3656. #
  3657. # <a Server IP address of the last server or peer connection
  3658. # <A Server FQDN or peer name
  3659. # <p Server port number of the last server or peer connection
  3660. # <la Local IP address of the last server or peer connection
  3661. # <lp Local port number of the last server or peer connection
  3662. # <qos Server connection TOS/DSCP value set by Squid
  3663. # <nfmark Server connection netfilter mark set by Squid
  3664. #
  3665. # Time related format codes:
  3666. #
  3667. # ts Seconds since epoch
  3668. # tu subsecond time (milliseconds)
  3669. # tl Local time. Optional strftime format argument
  3670. # default %d/%b/%Y:%H:%M:%S %z
  3671. # tg GMT time. Optional strftime format argument
  3672. # default %d/%b/%Y:%H:%M:%S %z
  3673. # tr Response time (milliseconds)
  3674. # dt Total time spent making DNS lookups (milliseconds)
  3675. # tS Approximate master transaction start time in
  3676. # <full seconds since epoch>.<fractional seconds> format.
  3677. # Currently, Squid considers the master transaction
  3678. # started when a complete HTTP request header initiating
  3679. # the transaction is received from the client. This is
  3680. # the same value that Squid uses to calculate transaction
  3681. # response time when logging %tr to access.log. Currently,
  3682. # Squid uses millisecond resolution for %tS values,
  3683. # similar to the default access.log "current time" field
  3684. # (%ts.%03tu).
  3685. #
  3686. # Access Control related format codes:
  3687. #
  3688. # et Tag returned by external acl
  3689. # ea Log string returned by external acl
  3690. # un User name (any available)
  3691. # ul User name from authentication
  3692. # ue User name from external acl helper
  3693. # ui User name from ident
  3694. # un A user name. Expands to the first available name
  3695. # from the following list of information sources:
  3696. # - authenticated user name, like %ul
  3697. # - user name supplied by an external ACL, like %ue
  3698. # - SSL client name, like %us
  3699. # - ident user name, like %ui
  3700. # credentials Client credentials. The exact meaning depends on
  3701. # the authentication scheme: For Basic authentication,
  3702. # it is the password; for Digest, the realm sent by the
  3703. # client; for NTLM and Negotiate, the client challenge
  3704. # or client credentials prefixed with "YR " or "KK ".
  3705. #
  3706. # HTTP related format codes:
  3707. #
  3708. # REQUEST
  3709. #
  3710. # [http::]rm Request method (GET/POST etc)
  3711. # [http::]>rm Request method from client
  3712. # [http::]<rm Request method sent to server or peer
  3713. # [http::]ru Request URL from client (historic, filtered for logging)
  3714. # [http::]>ru Request URL from client
  3715. # [http::]<ru Request URL sent to server or peer
  3716. # [http::]>rs Request URL scheme from client
  3717. # [http::]<rs Request URL scheme sent to server or peer
  3718. # [http::]>rd Request URL domain from client
  3719. # [http::]<rd Request URL domain sent to server or peer
  3720. # [http::]>rP Request URL port from client
  3721. # [http::]<rP Request URL port sent to server or peer
  3722. # [http::]rp Request URL path excluding hostname
  3723. # [http::]>rp Request URL path excluding hostname from client
  3724. # [http::]<rp Request URL path excluding hostname sent to server or peer
  3725. # [http::]rv Request protocol version
  3726. # [http::]>rv Request protocol version from client
  3727. # [http::]<rv Request protocol version sent to server or peer
  3728. #
  3729. # [http::]>h Original received request header.
  3730. # Usually differs from the request header sent by
  3731. # Squid, although most fields are often preserved.
  3732. # Accepts optional header field name/value filter
  3733. # argument using name[:[separator]element] format.
  3734. # [http::]>ha Received request header after adaptation and
  3735. # redirection (pre-cache REQMOD vectoring point).
  3736. # Usually differs from the request header sent by
  3737. # Squid, although most fields are often preserved.
  3738. # Optional header name argument as for >h
  3739. #
  3740. #
  3741. # RESPONSE
  3742. #
  3743. # [http::]<Hs HTTP status code received from the next hop
  3744. # [http::]>Hs HTTP status code sent to the client
  3745. #
  3746. # [http::]<h Reply header. Optional header name argument
  3747. # as for >h
  3748. #
  3749. # [http::]mt MIME content type
  3750. #
  3751. #
  3752. # SIZE COUNTERS
  3753. #
  3754. # [http::]st Total size of request + reply traffic with client
  3755. # [http::]>st Total size of request received from client.
  3756. # Excluding chunked encoding bytes.
  3757. # [http::]<st Total size of reply sent to client (after adaptation)
  3758. #
  3759. # [http::]>sh Size of request headers received from client
  3760. # [http::]<sh Size of reply headers sent to client (after adaptation)
  3761. #
  3762. # [http::]<sH Reply high offset sent
  3763. # [http::]<sS Upstream object size
  3764. #
  3765. # [http::]<bs Number of HTTP-equivalent message body bytes
  3766. # received from the next hop, excluding chunked
  3767. # transfer encoding and control messages.
  3768. # Generated FTP/Gopher listings are treated as
  3769. # received bodies.
  3770. #
  3771. #
  3772. # TIMING
  3773. #
  3774. # [http::]<pt Peer response time in milliseconds. The timer starts
  3775. # when the last request byte is sent to the next hop
  3776. # and stops when the last response byte is received.
  3777. # [http::]<tt Total time in milliseconds. The timer
  3778. # starts with the first connect request (or write I/O)
  3779. # sent to the first selected peer. The timer stops
  3780. # with the last I/O with the last peer.
  3781. #
  3782. # Squid handling related format codes:
  3783. #
  3784. # Ss Squid request status (TCP_MISS etc)
  3785. # Sh Squid hierarchy status (DEFAULT_PARENT etc)
  3786. #
  3787. # SSL-related format codes:
  3788. #
  3789. # ssl::bump_mode SslBump decision for the transaction:
  3790. #
  3791. # For CONNECT requests that initiated bumping of
  3792. # a connection and for any request received on
  3793. # an already bumped connection, Squid logs the
  3794. # corresponding SslBump mode ("server-first" or
  3795. # "client-first"). See the ssl_bump option for
  3796. # more information about these modes.
  3797. #
  3798. # A "none" token is logged for requests that
  3799. # triggered "ssl_bump" ACL evaluation matching
  3800. # either a "none" rule or no rules at all.
  3801. #
  3802. # In all other cases, a single dash ("-") is
  3803. # logged.
  3804. #
  3805. # ssl::>sni SSL client SNI sent to Squid. Available only
  3806. # after the peek, stare, or splice SSL bumping
  3807. # actions.
  3808. #
  3809. # If ICAP is enabled, the following code becomes available (as
  3810. # well as ICAP log codes documented with the icap_log option):
  3811. #
  3812. # icap::tt Total ICAP processing time for the HTTP
  3813. # transaction. The timer ticks when ICAP
  3814. # ACLs are checked and when ICAP
  3815. # transaction is in progress.
  3816. #
  3817. # If adaptation is enabled the following three codes become available:
  3818. #
  3819. # adapt::<last_h The header of the last ICAP response or
  3820. # meta-information from the last eCAP
  3821. # transaction related to the HTTP transaction.
  3822. # Like <h, accepts an optional header name
  3823. # argument.
  3824. #
  3825. # adapt::sum_trs Summed adaptation transaction response
  3826. # times recorded as a comma-separated list in
  3827. # the order of transaction start time. Each time
  3828. # value is recorded as an integer number,
  3829. # representing response time of one or more
  3830. # adaptation (ICAP or eCAP) transaction in
  3831. # milliseconds. When a failed transaction is
  3832. # being retried or repeated, its time is not
  3833. # logged individually but added to the
  3834. # replacement (next) transaction. See also:
  3835. # adapt::all_trs.
  3836. #
  3837. # adapt::all_trs All adaptation transaction response times.
  3838. # Same as adaptation_strs but response times of
  3839. # individual transactions are never added
  3840. # together. Instead, all transaction response
  3841. # times are recorded individually.
  3842. #
  3843. # You can prefix adapt::*_trs format codes with adaptation
  3844. # service name in curly braces to record response time(s) specific
  3845. # to that service. For example: %{my_service}adapt::sum_trs
  3846. #
  3847. # If SSL is enabled, the following formating codes become available:
  3848. #
  3849. # %ssl::>cert_subject The Subject field of the received client
  3850. # SSL certificate or a dash ('-') if Squid has
  3851. # received an invalid/malformed certificate or
  3852. # no certificate at all. Consider encoding the
  3853. # logged value because Subject often has spaces.
  3854. #
  3855. # %ssl::>cert_issuer The Issuer field of the received client
  3856. # SSL certificate or a dash ('-') if Squid has
  3857. # received an invalid/malformed certificate or
  3858. # no certificate at all. Consider encoding the
  3859. # logged value because Issuer often has spaces.
  3860. #
  3861. # The default formats available (which do not need re-defining) are:
  3862. #
  3863. #logformat squid %ts.%03tu %6tr %>a %Ss/%03>Hs %<st %rm %ru %[un %Sh/%<a %mt
  3864. #logformat common %>a %[ui %[un [%tl] "%rm %ru HTTP/%rv" %>Hs %<st %Ss:%Sh
  3865. #logformat combined %>a %[ui %[un [%tl] "%rm %ru HTTP/%rv" %>Hs %<st "%{Referer}>h" "%{User-Agent}>h" %Ss:%Sh
  3866. #logformat referrer %ts.%03tu %>a %{Referer}>h %ru
  3867. #logformat useragent %>a [%tl] "%{User-Agent}>h"
  3868. #
  3869. # NOTE: When the log_mime_hdrs directive is set to ON.
  3870. # The squid, common and combined formats have a safely encoded copy
  3871. # of the mime headers appended to each line within a pair of brackets.
  3872. #
  3873. # NOTE: The common and combined formats are not quite true to the Apache definition.
  3874. # The logs from Squid contain an extra status and hierarchy code appended.
  3875. #
  3876. #Default:
  3877. # The format definitions squid, common, combined, referrer, useragent are built in.
  3878.  
  3879. # TAG: access_log
  3880. # Configures whether and how Squid logs HTTP and ICP transactions.
  3881. # If access logging is enabled, a single line is logged for every
  3882. # matching HTTP or ICP request. The recommended directive formats are:
  3883. #
  3884. # access_log <module>:<place> [option ...] [acl acl ...]
  3885. # access_log none [acl acl ...]
  3886. #
  3887. # The following directive format is accepted but may be deprecated:
  3888. # access_log <module>:<place> [<logformat name> [acl acl ...]]
  3889. #
  3890. # In most cases, the first ACL name must not contain the '=' character
  3891. # and should not be equal to an existing logformat name. You can always
  3892. # start with an 'all' ACL to work around those restrictions.
  3893. #
  3894. # Will log to the specified module:place using the specified format (which
  3895. # must be defined in a logformat directive) those entries which match
  3896. # ALL the acl's specified (which must be defined in acl clauses).
  3897. # If no acl is specified, all requests will be logged to this destination.
  3898. #
  3899. # ===== Available options for the recommended directive format =====
  3900. #
  3901. # logformat=name Names log line format (either built-in or
  3902. # defined by a logformat directive). Defaults
  3903. # to 'squid'.
  3904. #
  3905. # buffer-size=64KB Defines approximate buffering limit for log
  3906. # records (see buffered_logs). Squid should not
  3907. # keep more than the specified size and, hence,
  3908. # should flush records before the buffer becomes
  3909. # full to avoid overflows under normal
  3910. # conditions (the exact flushing algorithm is
  3911. # module-dependent though). The on-error option
  3912. # controls overflow handling.
  3913. #
  3914. # on-error=die|drop Defines action on unrecoverable errors. The
  3915. # 'drop' action ignores (i.e., does not log)
  3916. # affected log records. The default 'die' action
  3917. # kills the affected worker. The drop action
  3918. # support has not been tested for modules other
  3919. # than tcp.
  3920. #
  3921. # ===== Modules Currently available =====
  3922. #
  3923. # none Do not log any requests matching these ACL.
  3924. # Do not specify Place or logformat name.
  3925. #
  3926. # stdio Write each log line to disk immediately at the completion of
  3927. # each request.
  3928. # Place: the filename and path to be written.
  3929. #
  3930. # daemon Very similar to stdio. But instead of writing to disk the log
  3931. # line is passed to a daemon helper for asychronous handling instead.
  3932. # Place: varies depending on the daemon.
  3933. #
  3934. # log_file_daemon Place: the file name and path to be written.
  3935. #
  3936. # syslog To log each request via syslog facility.
  3937. # Place: The syslog facility and priority level for these entries.
  3938. # Place Format: facility.priority
  3939. #
  3940. # where facility could be any of:
  3941. # authpriv, daemon, local0 ... local7 or user.
  3942. #
  3943. # And priority could be any of:
  3944. # err, warning, notice, info, debug.
  3945. #
  3946. # udp To send each log line as text data to a UDP receiver.
  3947. # Place: The destination host name or IP and port.
  3948. # Place Format: //host:port
  3949. #
  3950. # tcp To send each log line as text data to a TCP receiver.
  3951. # Lines may be accumulated before sending (see buffered_logs).
  3952. # Place: The destination host name or IP and port.
  3953. # Place Format: //host:port
  3954. #
  3955. # Default:
  3956. # access_log daemon:/var/log/squid/access.log squid
  3957. #Default:
  3958. # access_log daemon:/var/log/squid/access.log squid
  3959.  
  3960. # TAG: icap_log
  3961. # ICAP log files record ICAP transaction summaries, one line per
  3962. # transaction.
  3963. #
  3964. # The icap_log option format is:
  3965. # icap_log <filepath> [<logformat name> [acl acl ...]]
  3966. # icap_log none [acl acl ...]]
  3967. #
  3968. # Please see access_log option documentation for details. The two
  3969. # kinds of logs share the overall configuration approach and many
  3970. # features.
  3971. #
  3972. # ICAP processing of a single HTTP message or transaction may
  3973. # require multiple ICAP transactions. In such cases, multiple
  3974. # ICAP transaction log lines will correspond to a single access
  3975. # log line.
  3976. #
  3977. # ICAP log supports many access.log logformat %codes. In ICAP context,
  3978. # HTTP message-related %codes are applied to the HTTP message embedded
  3979. # in an ICAP message. Logformat "%http::>..." codes are used for HTTP
  3980. # messages embedded in ICAP requests while "%http::<..." codes are used
  3981. # for HTTP messages embedded in ICAP responses. For example:
  3982. #
  3983. # http::>h To-be-adapted HTTP message headers sent by Squid to
  3984. # the ICAP service. For REQMOD transactions, these are
  3985. # HTTP request headers. For RESPMOD, these are HTTP
  3986. # response headers, but Squid currently cannot log them
  3987. # (i.e., %http::>h will expand to "-" for RESPMOD).
  3988. #
  3989. # http::<h Adapted HTTP message headers sent by the ICAP
  3990. # service to Squid (i.e., HTTP request headers in regular
  3991. # REQMOD; HTTP response headers in RESPMOD and during
  3992. # request satisfaction in REQMOD).
  3993. #
  3994. # ICAP OPTIONS transactions do not embed HTTP messages.
  3995. #
  3996. # Several logformat codes below deal with ICAP message bodies. An ICAP
  3997. # message body, if any, typically includes a complete HTTP message
  3998. # (required HTTP headers plus optional HTTP message body). When
  3999. # computing HTTP message body size for these logformat codes, Squid
  4000. # either includes or excludes chunked encoding overheads; see
  4001. # code-specific documentation for details.
  4002. #
  4003. # For Secure ICAP services, all size-related information is currently
  4004. # computed before/after TLS encryption/decryption, as if TLS was not
  4005. # in use at all.
  4006. #
  4007. # The following format codes are also available for ICAP logs:
  4008. #
  4009. # icap::<A ICAP server IP address. Similar to <A.
  4010. #
  4011. # icap::<service_name ICAP service name from the icap_service
  4012. # option in Squid configuration file.
  4013. #
  4014. # icap::ru ICAP Request-URI. Similar to ru.
  4015. #
  4016. # icap::rm ICAP request method (REQMOD, RESPMOD, or
  4017. # OPTIONS). Similar to existing rm.
  4018. #
  4019. # icap::>st The total size of the ICAP request sent to the ICAP
  4020. # server (ICAP headers + ICAP body), including chunking
  4021. # metadata (if any).
  4022. #
  4023. # icap::<st The total size of the ICAP response received from the
  4024. # ICAP server (ICAP headers + ICAP body), including
  4025. # chunking metadata (if any).
  4026. #
  4027. # icap::<bs The size of the ICAP response body received from the
  4028. # ICAP server, excluding chunking metadata (if any).
  4029. #
  4030. # icap::tr Transaction response time (in
  4031. # milliseconds). The timer starts when
  4032. # the ICAP transaction is created and
  4033. # stops when the transaction is completed.
  4034. # Similar to tr.
  4035. #
  4036. # icap::tio Transaction I/O time (in milliseconds). The
  4037. # timer starts when the first ICAP request
  4038. # byte is scheduled for sending. The timers
  4039. # stops when the last byte of the ICAP response
  4040. # is received.
  4041. #
  4042. # icap::to Transaction outcome: ICAP_ERR* for all
  4043. # transaction errors, ICAP_OPT for OPTION
  4044. # transactions, ICAP_ECHO for 204
  4045. # responses, ICAP_MOD for message
  4046. # modification, and ICAP_SAT for request
  4047. # satisfaction. Similar to Ss.
  4048. #
  4049. # icap::Hs ICAP response status code. Similar to Hs.
  4050. #
  4051. # icap::>h ICAP request header(s). Similar to >h.
  4052. #
  4053. # icap::<h ICAP response header(s). Similar to <h.
  4054. #
  4055. # The default ICAP log format, which can be used without an explicit
  4056. # definition, is called icap_squid:
  4057. #
  4058. #logformat icap_squid %ts.%03tu %6icap::tr %>A %icap::to/%03icap::Hs %icap::<st %icap::rm %icap::ru %un -/%icap::<A -
  4059. #
  4060. # See also: logformat and %adapt::<last_h
  4061. #Default:
  4062. # none
  4063.  
  4064. # TAG: logfile_daemon
  4065. # Specify the path to the logfile-writing daemon. This daemon is
  4066. # used to write the access and store logs, if configured.
  4067. #
  4068. # Squid sends a number of commands to the log daemon:
  4069. # L<data>\n - logfile data
  4070. # R\n - rotate file
  4071. # T\n - truncate file
  4072. # O\n - reopen file
  4073. # F\n - flush file
  4074. # r<n>\n - set rotate count to <n>
  4075. # b<n>\n - 1 = buffer output, 0 = don't buffer output
  4076. #
  4077. # No responses is expected.
  4078. #Default:
  4079. # logfile_daemon /usr/lib/squid/log_file_daemon
  4080.  
  4081. # TAG: stats_collection allow|deny acl acl...
  4082. # This options allows you to control which requests gets accounted
  4083. # in performance counters.
  4084. #
  4085. # This clause only supports fast acl types.
  4086. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  4087. #Default:
  4088. # Allow logging for all transactions.
  4089.  
  4090. # TAG: cache_store_log
  4091. # Logs the activities of the storage manager. Shows which
  4092. # objects are ejected from the cache, and which objects are
  4093. # saved and for how long.
  4094. # There are not really utilities to analyze this data, so you can safely
  4095. # disable it (the default).
  4096. #
  4097. # Store log uses modular logging outputs. See access_log for the list
  4098. # of modules supported.
  4099. #
  4100. # Example:
  4101. # cache_store_log stdio:/var/log/squid/store.log
  4102. # cache_store_log daemon:/var/log/squid/store.log
  4103. #Default:
  4104. # none
  4105.  
  4106. # TAG: cache_swap_state
  4107. # Location for the cache "swap.state" file. This index file holds
  4108. # the metadata of objects saved on disk. It is used to rebuild
  4109. # the cache during startup. Normally this file resides in each
  4110. # 'cache_dir' directory, but you may specify an alternate
  4111. # pathname here. Note you must give a full filename, not just
  4112. # a directory. Since this is the index for the whole object
  4113. # list you CANNOT periodically rotate it!
  4114. #
  4115. # If %s can be used in the file name it will be replaced with a
  4116. # a representation of the cache_dir name where each / is replaced
  4117. # with '.'. This is needed to allow adding/removing cache_dir
  4118. # lines when cache_swap_log is being used.
  4119. #
  4120. # If have more than one 'cache_dir', and %s is not used in the name
  4121. # these swap logs will have names such as:
  4122. #
  4123. # cache_swap_log.00
  4124. # cache_swap_log.01
  4125. # cache_swap_log.02
  4126. #
  4127. # The numbered extension (which is added automatically)
  4128. # corresponds to the order of the 'cache_dir' lines in this
  4129. # configuration file. If you change the order of the 'cache_dir'
  4130. # lines in this file, these index files will NOT correspond to
  4131. # the correct 'cache_dir' entry (unless you manually rename
  4132. # them). We recommend you do NOT use this option. It is
  4133. # better to keep these index files in each 'cache_dir' directory.
  4134. #Default:
  4135. # Store the journal inside its cache_dir
  4136.  
  4137. # TAG: logfile_rotate
  4138. # Specifies the number of logfile rotations to make when you
  4139. # type 'squid -k rotate'. The default is 10, which will rotate
  4140. # with extensions 0 through 9. Setting logfile_rotate to 0 will
  4141. # disable the file name rotation, but the logfiles are still closed
  4142. # and re-opened. This will enable you to rename the logfiles
  4143. # yourself just before sending the rotate signal.
  4144. #
  4145. # Note, the 'squid -k rotate' command normally sends a USR1
  4146. # signal to the running squid process. In certain situations
  4147. # (e.g. on Linux with Async I/O), USR1 is used for other
  4148. # purposes, so -k rotate uses another signal. It is best to get
  4149. # in the habit of using 'squid -k rotate' instead of 'kill -USR1
  4150. # <pid>'.
  4151. #
  4152. # Note, from Squid-3.1 this option is only a default for cache.log,
  4153. # that log can be rotated separately by using debug_options.
  4154. #
  4155. # Note2, for Debian/Linux the default of logfile_rotate is
  4156. # zero, since it includes external logfile-rotation methods.
  4157. #Default:
  4158. # logfile_rotate 0
  4159.  
  4160. # TAG: mime_table
  4161. # Path to Squid's icon configuration file.
  4162. #
  4163. # You shouldn't need to change this, but the default file contains
  4164. # examples and formatting information if you do.
  4165. #Default:
  4166. # mime_table /usr/share/squid/mime.conf
  4167.  
  4168. # TAG: log_mime_hdrs on|off
  4169. # The Cache can record both the request and the response MIME
  4170. # headers for each HTTP transaction. The headers are encoded
  4171. # safely and will appear as two bracketed fields at the end of
  4172. # the access log (for either the native or httpd-emulated log
  4173. # formats). To enable this logging set log_mime_hdrs to 'on'.
  4174. #Default:
  4175. # log_mime_hdrs off
  4176.  
  4177. # TAG: pid_filename
  4178. # A filename to write the process-id to. To disable, enter "none".
  4179. #Default:
  4180. # pid_filename /var/run/squid.pid
  4181.  
  4182. # TAG: client_netmask
  4183. # A netmask for client addresses in logfiles and cachemgr output.
  4184. # Change this to protect the privacy of your cache clients.
  4185. # A netmask of 255.255.255.0 will log all IP's in that range with
  4186. # the last digit set to '0'.
  4187. #Default:
  4188. # Log full client IP address
  4189.  
  4190. # TAG: strip_query_terms
  4191. # By default, Squid strips query terms from requested URLs before
  4192. # logging. This protects your user's privacy and reduces log size.
  4193. #
  4194. # When investigating HIT/MISS or other caching behaviour you
  4195. # will need to disable this to see the full URL used by Squid.
  4196. #Default:
  4197. # strip_query_terms on
  4198.  
  4199. # TAG: buffered_logs on|off
  4200. # Whether to write/send access_log records ASAP or accumulate them and
  4201. # then write/send them in larger chunks. Buffering may improve
  4202. # performance because it decreases the number of I/Os. However,
  4203. # buffering increases the delay before log records become available to
  4204. # the final recipient (e.g., a disk file or logging daemon) and,
  4205. # hence, increases the risk of log records loss.
  4206. #
  4207. # Note that even when buffered_logs are off, Squid may have to buffer
  4208. # records if it cannot write/send them immediately due to pending I/Os
  4209. # (e.g., the I/O writing the previous log record) or connectivity loss.
  4210. #
  4211. # Currently honored by 'daemon' and 'tcp' access_log modules only.
  4212. #Default:
  4213. # buffered_logs off
  4214.  
  4215. # TAG: netdb_filename
  4216. # Where Squid stores it's netdb journal.
  4217. # When enabled this journal preserves netdb state between restarts.
  4218. #
  4219. # To disable, enter "none".
  4220. #Default:
  4221. # netdb_filename stdio:/var/log/squid/netdb.state
  4222.  
  4223. # OPTIONS FOR TROUBLESHOOTING
  4224. # -----------------------------------------------------------------------------
  4225.  
  4226. # TAG: cache_log
  4227. # Squid administrative logging file.
  4228. #
  4229. # This is where general information about Squid behavior goes. You can
  4230. # increase the amount of data logged to this file and how often it is
  4231. # rotated with "debug_options"
  4232. #Default:
  4233. # cache_log /var/log/squid/cache.log
  4234.  
  4235. # TAG: debug_options
  4236. # Logging options are set as section,level where each source file
  4237. # is assigned a unique section. Lower levels result in less
  4238. # output, Full debugging (level 9) can result in a very large
  4239. # log file, so be careful.
  4240. #
  4241. # The magic word "ALL" sets debugging levels for all sections.
  4242. # The default is to run with "ALL,1" to record important warnings.
  4243. #
  4244. # The rotate=N option can be used to keep more or less of these logs
  4245. # than would otherwise be kept by logfile_rotate.
  4246. # For most uses a single log should be enough to monitor current
  4247. # events affecting Squid.
  4248. #Default:
  4249. # Log all critical and important messages.
  4250.  
  4251. # TAG: coredump_dir
  4252. # By default Squid leaves core files in the directory from where
  4253. # it was started. If you set 'coredump_dir' to a directory
  4254. # that exists, Squid will chdir() to that directory at startup
  4255. # and coredump files will be left there.
  4256. #
  4257. #Default:
  4258. # Use the directory from where Squid was started.
  4259. #
  4260.  
  4261. # Leave coredumps in the first cache dir
  4262. coredump_dir /var/spool/squid
  4263.  
  4264. # OPTIONS FOR FTP GATEWAYING
  4265. # -----------------------------------------------------------------------------
  4266.  
  4267. # TAG: ftp_user
  4268. # If you want the anonymous login password to be more informative
  4269. # (and enable the use of picky FTP servers), set this to something
  4270. # reasonable for your domain, like [email protected]
  4271. #
  4272. # The reason why this is domainless by default is the
  4273. # request can be made on the behalf of a user in any domain,
  4274. # depending on how the cache is used.
  4275. # Some FTP server also validate the email address is valid
  4276. # (for example perl.com).
  4277. #Default:
  4278. # ftp_user Squid@
  4279.  
  4280. # TAG: ftp_passive
  4281. # If your firewall does not allow Squid to use passive
  4282. # connections, turn off this option.
  4283. #
  4284. # Use of ftp_epsv_all option requires this to be ON.
  4285. #Default:
  4286. # ftp_passive on
  4287.  
  4288. # TAG: ftp_epsv_all
  4289. # FTP Protocol extensions permit the use of a special "EPSV ALL" command.
  4290. #
  4291. # NATs may be able to put the connection on a "fast path" through the
  4292. # translator, as the EPRT command will never be used and therefore,
  4293. # translation of the data portion of the segments will never be needed.
  4294. #
  4295. # When a client only expects to do two-way FTP transfers this may be
  4296. # useful.
  4297. # If squid finds that it must do a three-way FTP transfer after issuing
  4298. # an EPSV ALL command, the FTP session will fail.
  4299. #
  4300. # If you have any doubts about this option do not use it.
  4301. # Squid will nicely attempt all other connection methods.
  4302. #
  4303. # Requires ftp_passive to be ON (default) for any effect.
  4304. #Default:
  4305. # ftp_epsv_all off
  4306.  
  4307. # TAG: ftp_epsv
  4308. # FTP Protocol extensions permit the use of a special "EPSV" command.
  4309. #
  4310. # NATs may be able to put the connection on a "fast path" through the
  4311. # translator using EPSV, as the EPRT command will never be used
  4312. # and therefore, translation of the data portion of the segments
  4313. # will never be needed.
  4314. #
  4315. # EPSV is often required to interoperate with FTP servers on IPv6
  4316. # networks. On the other hand, it may break some IPv4 servers.
  4317. #
  4318. # By default, EPSV may try EPSV with any FTP server. To fine tune
  4319. # that decision, you may restrict EPSV to certain clients or servers
  4320. # using ACLs:
  4321. #
  4322. # ftp_epsv allow|deny al1 acl2 ...
  4323. #
  4324. # WARNING: Disabling EPSV may cause problems with external NAT and IPv6.
  4325. #
  4326. # Only fast ACLs are supported.
  4327. # Requires ftp_passive to be ON (default) for any effect.
  4328. #Default:
  4329. # none
  4330.  
  4331. # TAG: ftp_eprt
  4332. # FTP Protocol extensions permit the use of a special "EPRT" command.
  4333. #
  4334. # This extension provides a protocol neutral alternative to the
  4335. # IPv4-only PORT command. When supported it enables active FTP data
  4336. # channels over IPv6 and efficient NAT handling.
  4337. #
  4338. # Turning this OFF will prevent EPRT being attempted and will skip
  4339. # straight to using PORT for IPv4 servers.
  4340. #
  4341. # Some devices are known to not handle this extension correctly and
  4342. # may result in crashes. Devices which suport EPRT enough to fail
  4343. # cleanly will result in Squid attempting PORT anyway. This directive
  4344. # should only be disabled when EPRT results in device failures.
  4345. #
  4346. # WARNING: Doing so will convert Squid back to the old behavior with all
  4347. # the related problems with external NAT devices/layers and IPv4-only FTP.
  4348. #Default:
  4349. # ftp_eprt on
  4350.  
  4351. # TAG: ftp_sanitycheck
  4352. # For security and data integrity reasons Squid by default performs
  4353. # sanity checks of the addresses of FTP data connections ensure the
  4354. # data connection is to the requested server. If you need to allow
  4355. # FTP connections to servers using another IP address for the data
  4356. # connection turn this off.
  4357. #Default:
  4358. # ftp_sanitycheck on
  4359.  
  4360. # TAG: ftp_telnet_protocol
  4361. # The FTP protocol is officially defined to use the telnet protocol
  4362. # as transport channel for the control connection. However, many
  4363. # implementations are broken and does not respect this aspect of
  4364. # the FTP protocol.
  4365. #
  4366. # If you have trouble accessing files with ASCII code 255 in the
  4367. # path or similar problems involving this ASCII code you can
  4368. # try setting this directive to off. If that helps, report to the
  4369. # operator of the FTP server in question that their FTP server
  4370. # is broken and does not follow the FTP standard.
  4371. #Default:
  4372. # ftp_telnet_protocol on
  4373.  
  4374. # OPTIONS FOR EXTERNAL SUPPORT PROGRAMS
  4375. # -----------------------------------------------------------------------------
  4376.  
  4377. # TAG: diskd_program
  4378. # Specify the location of the diskd executable.
  4379. # Note this is only useful if you have compiled in
  4380. # diskd as one of the store io modules.
  4381. #Default:
  4382. # diskd_program /usr/lib/squid/diskd
  4383.  
  4384. # TAG: unlinkd_program
  4385. # Specify the location of the executable for file deletion process.
  4386. #Default:
  4387. # unlinkd_program /usr/lib/squid/unlinkd
  4388.  
  4389. # TAG: pinger_program
  4390. # Specify the location of the executable for the pinger process.
  4391. #Default:
  4392. # pinger_program /usr/lib/squid/pinger
  4393.  
  4394. # TAG: pinger_enable
  4395. # Control whether the pinger is active at run-time.
  4396. # Enables turning ICMP pinger on and off with a simple
  4397. # squid -k reconfigure.
  4398. #Default:
  4399. # pinger_enable on
  4400.  
  4401. # OPTIONS FOR URL REWRITING
  4402. # -----------------------------------------------------------------------------
  4403.  
  4404. # TAG: url_rewrite_program
  4405. # Specify the location of the executable URL rewriter to use.
  4406. # Since they can perform almost any function there isn't one included.
  4407. #
  4408. # For each requested URL, the rewriter will receive on line with the format
  4409. #
  4410. # [channel-ID <SP>] URL [<SP> extras]<NL>
  4411. #
  4412. # See url_rewrite_extras on how to send "extras" with optional values to
  4413. # the helper.
  4414. # After processing the request the helper must reply using the following format:
  4415. #
  4416. # [channel-ID <SP>] result [<SP> kv-pairs]
  4417. #
  4418. # The result code can be:
  4419. #
  4420. # OK status=30N url="..."
  4421. # Redirect the URL to the one supplied in 'url='.
  4422. # 'status=' is optional and contains the status code to send
  4423. # the client in Squids HTTP response. It must be one of the
  4424. # HTTP redirect status codes: 301, 302, 303, 307, 308.
  4425. # When no status is given Squid will use 302.
  4426. #
  4427. # OK rewrite-url="..."
  4428. # Rewrite the URL to the one supplied in 'rewrite-url='.
  4429. # The new URL is fetched directly by Squid and returned to
  4430. # the client as the response to its request.
  4431. #
  4432. # OK
  4433. # When neither of url= and rewrite-url= are sent Squid does
  4434. # not change the URL.
  4435. #
  4436. # ERR
  4437. # Do not change the URL.
  4438. #
  4439. # BH
  4440. # An internal error occurred in the helper, preventing
  4441. # a result being identified. The 'message=' key name is
  4442. # reserved for delivering a log message.
  4443. #
  4444. #
  4445. # In addition to the above kv-pairs Squid also understands the following
  4446. # optional kv-pairs received from URL rewriters:
  4447. # clt_conn_tag=TAG
  4448. # Associates a TAG with the client TCP connection.
  4449. # The TAG is treated as a regular annotation but persists across
  4450. # future requests on the client connection rather than just the
  4451. # current request. A helper may update the TAG during subsequent
  4452. # requests be returning a new kv-pair.
  4453. #
  4454. # When using the concurrency= option the protocol is changed by
  4455. # introducing a query channel tag in front of the request/response.
  4456. # The query channel tag is a number between 0 and concurrency-1.
  4457. # This value must be echoed back unchanged to Squid as the first part
  4458. # of the response relating to its request.
  4459. #
  4460. # WARNING: URL re-writing ability should be avoided whenever possible.
  4461. # Use the URL redirect form of response instead.
  4462. #
  4463. # Re-write creates a difference in the state held by the client
  4464. # and server. Possibly causing confusion when the server response
  4465. # contains snippets of its view state. Embeded URLs, response
  4466. # and content Location headers, etc. are not re-written by this
  4467. # interface.
  4468. #
  4469. # By default, a URL rewriter is not used.
  4470. #Default:
  4471. # none
  4472.  
  4473. # TAG: url_rewrite_children
  4474. # The maximum number of redirector processes to spawn. If you limit
  4475. # it too few Squid will have to wait for them to process a backlog of
  4476. # URLs, slowing it down. If you allow too many they will use RAM
  4477. # and other system resources noticably.
  4478. #
  4479. # The startup= and idle= options allow some measure of skew in your
  4480. # tuning.
  4481. #
  4482. # startup=
  4483. #
  4484. # Sets a minimum of how many processes are to be spawned when Squid
  4485. # starts or reconfigures. When set to zero the first request will
  4486. # cause spawning of the first child process to handle it.
  4487. #
  4488. # Starting too few will cause an initial slowdown in traffic as Squid
  4489. # attempts to simultaneously spawn enough processes to cope.
  4490. #
  4491. # idle=
  4492. #
  4493. # Sets a minimum of how many processes Squid is to try and keep available
  4494. # at all times. When traffic begins to rise above what the existing
  4495. # processes can handle this many more will be spawned up to the maximum
  4496. # configured. A minimum setting of 1 is required.
  4497. #
  4498. # concurrency=
  4499. #
  4500. # The number of requests each redirector helper can handle in
  4501. # parallel. Defaults to 0 which indicates the redirector
  4502. # is a old-style single threaded redirector.
  4503. #
  4504. # When this directive is set to a value >= 1 then the protocol
  4505. # used to communicate with the helper is modified to include
  4506. # an ID in front of the request/response. The ID from the request
  4507. # must be echoed back with the response to that request.
  4508. #Default:
  4509. # url_rewrite_children 20 startup=0 idle=1 concurrency=0
  4510.  
  4511. # TAG: url_rewrite_host_header
  4512. # To preserve same-origin security policies in browsers and
  4513. # prevent Host: header forgery by redirectors Squid rewrites
  4514. # any Host: header in redirected requests.
  4515. #
  4516. # If you are running an accelerator this may not be a wanted
  4517. # effect of a redirector. This directive enables you disable
  4518. # Host: alteration in reverse-proxy traffic.
  4519. #
  4520. # WARNING: Entries are cached on the result of the URL rewriting
  4521. # process, so be careful if you have domain-virtual hosts.
  4522. #
  4523. # WARNING: Squid and other software verifies the URL and Host
  4524. # are matching, so be careful not to relay through other proxies
  4525. # or inspecting firewalls with this disabled.
  4526. #Default:
  4527. # url_rewrite_host_header on
  4528.  
  4529. # TAG: url_rewrite_access
  4530. # If defined, this access list specifies which requests are
  4531. # sent to the redirector processes.
  4532. #
  4533. # This clause supports both fast and slow acl types.
  4534. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  4535. #Default:
  4536. # Allow, unless rules exist in squid.conf.
  4537.  
  4538. # TAG: url_rewrite_bypass
  4539. # When this is 'on', a request will not go through the
  4540. # redirector if all the helpers are busy. If this is 'off'
  4541. # and the redirector queue grows too large, Squid will exit
  4542. # with a FATAL error and ask you to increase the number of
  4543. # redirectors. You should only enable this if the redirectors
  4544. # are not critical to your caching system. If you use
  4545. # redirectors for access control, and you enable this option,
  4546. # users may have access to pages they should not
  4547. # be allowed to request.
  4548. #Default:
  4549. # url_rewrite_bypass off
  4550.  
  4551. # TAG: url_rewrite_extras
  4552. # Specifies a string to be append to request line format for the
  4553. # rewriter helper. "Quoted" format values may contain spaces and
  4554. # logformat %macros. In theory, any logformat %macro can be used.
  4555. # In practice, a %macro expands as a dash (-) if the helper request is
  4556. # sent before the required macro information is available to Squid.
  4557. #Default:
  4558. # url_rewrite_extras "%>a/%>A %un %>rm myip=%la myport=%lp"
  4559.  
  4560. # OPTIONS FOR STORE ID
  4561. # -----------------------------------------------------------------------------
  4562.  
  4563. # TAG: store_id_program
  4564. # Specify the location of the executable StoreID helper to use.
  4565. # Since they can perform almost any function there isn't one included.
  4566. #
  4567. # For each requested URL, the helper will receive one line with the format
  4568. #
  4569. # [channel-ID <SP>] URL [<SP> extras]<NL>
  4570. #
  4571. #
  4572. # After processing the request the helper must reply using the following format:
  4573. #
  4574. # [channel-ID <SP>] result [<SP> kv-pairs]
  4575. #
  4576. # The result code can be:
  4577. #
  4578. # OK store-id="..."
  4579. # Use the StoreID supplied in 'store-id='.
  4580. #
  4581. # ERR
  4582. # The default is to use HTTP request URL as the store ID.
  4583. #
  4584. # BH
  4585. # An internal error occured in the helper, preventing
  4586. # a result being identified.
  4587. #
  4588. # In addition to the above kv-pairs Squid also understands the following
  4589. # optional kv-pairs received from URL rewriters:
  4590. # clt_conn_tag=TAG
  4591. # Associates a TAG with the client TCP connection.
  4592. # Please see url_rewrite_program related documentation for this
  4593. # kv-pair
  4594. #
  4595. # Helper programs should be prepared to receive and possibly ignore
  4596. # additional whitespace-separated tokens on each input line.
  4597. #
  4598. # When using the concurrency= option the protocol is changed by
  4599. # introducing a query channel tag in front of the request/response.
  4600. # The query channel tag is a number between 0 and concurrency-1.
  4601. # This value must be echoed back unchanged to Squid as the first part
  4602. # of the response relating to its request.
  4603. #
  4604. # NOTE: when using StoreID refresh_pattern will apply to the StoreID
  4605. # returned from the helper and not the URL.
  4606. #
  4607. # WARNING: Wrong StoreID value returned by a careless helper may result
  4608. # in the wrong cached response returned to the user.
  4609. #
  4610. # By default, a StoreID helper is not used.
  4611. #Default:
  4612. # none
  4613.  
  4614. # TAG: store_id_extras
  4615. # Specifies a string to be append to request line format for the
  4616. # StoreId helper. "Quoted" format values may contain spaces and
  4617. # logformat %macros. In theory, any logformat %macro can be used.
  4618. # In practice, a %macro expands as a dash (-) if the helper request is
  4619. # sent before the required macro information is available to Squid.
  4620. #Default:
  4621. # store_id_extras "%>a/%>A %un %>rm myip=%la myport=%lp"
  4622.  
  4623. # TAG: store_id_children
  4624. # The maximum number of StoreID helper processes to spawn. If you limit
  4625. # it too few Squid will have to wait for them to process a backlog of
  4626. # requests, slowing it down. If you allow too many they will use RAM
  4627. # and other system resources noticably.
  4628. #
  4629. # The startup= and idle= options allow some measure of skew in your
  4630. # tuning.
  4631. #
  4632. # startup=
  4633. #
  4634. # Sets a minimum of how many processes are to be spawned when Squid
  4635. # starts or reconfigures. When set to zero the first request will
  4636. # cause spawning of the first child process to handle it.
  4637. #
  4638. # Starting too few will cause an initial slowdown in traffic as Squid
  4639. # attempts to simultaneously spawn enough processes to cope.
  4640. #
  4641. # idle=
  4642. #
  4643. # Sets a minimum of how many processes Squid is to try and keep available
  4644. # at all times. When traffic begins to rise above what the existing
  4645. # processes can handle this many more will be spawned up to the maximum
  4646. # configured. A minimum setting of 1 is required.
  4647. #
  4648. # concurrency=
  4649. #
  4650. # The number of requests each storeID helper can handle in
  4651. # parallel. Defaults to 0 which indicates the helper
  4652. # is a old-style single threaded program.
  4653. #
  4654. # When this directive is set to a value >= 1 then the protocol
  4655. # used to communicate with the helper is modified to include
  4656. # an ID in front of the request/response. The ID from the request
  4657. # must be echoed back with the response to that request.
  4658. #Default:
  4659. # store_id_children 20 startup=0 idle=1 concurrency=0
  4660.  
  4661. # TAG: store_id_access
  4662. # If defined, this access list specifies which requests are
  4663. # sent to the StoreID processes. By default all requests
  4664. # are sent.
  4665. #
  4666. # This clause supports both fast and slow acl types.
  4667. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  4668. #Default:
  4669. # Allow, unless rules exist in squid.conf.
  4670.  
  4671. # TAG: store_id_bypass
  4672. # When this is 'on', a request will not go through the
  4673. # helper if all helpers are busy. If this is 'off'
  4674. # and the helper queue grows too large, Squid will exit
  4675. # with a FATAL error and ask you to increase the number of
  4676. # helpers. You should only enable this if the helperss
  4677. # are not critical to your caching system. If you use
  4678. # helpers for critical caching components, and you enable this
  4679. # option, users may not get objects from cache.
  4680. #Default:
  4681. # store_id_bypass on
  4682.  
  4683. # OPTIONS FOR TUNING THE CACHE
  4684. # -----------------------------------------------------------------------------
  4685.  
  4686. # TAG: cache
  4687. # Requests denied by this directive will not be served from the cache
  4688. # and their responses will not be stored in the cache. This directive
  4689. # has no effect on other transactions and on already cached responses.
  4690. #
  4691. # This clause supports both fast and slow acl types.
  4692. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  4693. #
  4694. # This and the two other similar caching directives listed below are
  4695. # checked at different transaction processing stages, have different
  4696. # access to response information, affect different cache operations,
  4697. # and differ in slow ACLs support:
  4698. #
  4699. # * cache: Checked before Squid makes a hit/miss determination.
  4700. # No access to reply information!
  4701. # Denies both serving a hit and storing a miss.
  4702. # Supports both fast and slow ACLs.
  4703. # * send_hit: Checked after a hit was detected.
  4704. # Has access to reply (hit) information.
  4705. # Denies serving a hit only.
  4706. # Supports fast ACLs only.
  4707. # * store_miss: Checked before storing a cachable miss.
  4708. # Has access to reply (miss) information.
  4709. # Denies storing a miss only.
  4710. # Supports fast ACLs only.
  4711. #
  4712. # If you are not sure which of the three directives to use, apply the
  4713. # following decision logic:
  4714. #
  4715. # * If your ACL(s) are of slow type _and_ need response info, redesign.
  4716. # Squid does not support that particular combination at this time.
  4717. # Otherwise:
  4718. # * If your directive ACL(s) are of slow type, use "cache"; and/or
  4719. # * if your directive ACL(s) need no response info, use "cache".
  4720. # Otherwise:
  4721. # * If you do not want the response cached, use store_miss; and/or
  4722. # * if you do not want a hit on a cached response, use send_hit.
  4723. #Default:
  4724. # By default, this directive is unused and has no effect.
  4725.  
  4726. # TAG: send_hit
  4727. # Responses denied by this directive will not be served from the cache
  4728. # (but may still be cached, see store_miss). This directive has no
  4729. # effect on the responses it allows and on the cached objects.
  4730. #
  4731. # Please see the "cache" directive for a summary of differences among
  4732. # store_miss, send_hit, and cache directives.
  4733. #
  4734. # Unlike the "cache" directive, send_hit only supports fast acl
  4735. # types. See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  4736. #
  4737. # For example:
  4738. #
  4739. # # apply custom Store ID mapping to some URLs
  4740. # acl MapMe dstdomain .c.example.com
  4741. # store_id_program ...
  4742. # store_id_access allow MapMe
  4743. #
  4744. # # but prevent caching of special responses
  4745. # # such as 302 redirects that cause StoreID loops
  4746. # acl Ordinary http_status 200-299
  4747. # store_miss deny MapMe !Ordinary
  4748. #
  4749. # # and do not serve any previously stored special responses
  4750. # # from the cache (in case they were already cached before
  4751. # # the above store_miss rule was in effect).
  4752. # send_hit deny MapMe !Ordinary
  4753. #Default:
  4754. # By default, this directive is unused and has no effect.
  4755.  
  4756. # TAG: store_miss
  4757. # Responses denied by this directive will not be cached (but may still
  4758. # be served from the cache, see send_hit). This directive has no
  4759. # effect on the responses it allows and on the already cached responses.
  4760. #
  4761. # Please see the "cache" directive for a summary of differences among
  4762. # store_miss, send_hit, and cache directives. See the
  4763. # send_hit directive for a usage example.
  4764. #
  4765. # Unlike the "cache" directive, store_miss only supports fast acl
  4766. # types. See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  4767. #Default:
  4768. # By default, this directive is unused and has no effect.
  4769.  
  4770. # TAG: max_stale time-units
  4771. # This option puts an upper limit on how stale content Squid
  4772. # will serve from the cache if cache validation fails.
  4773. # Can be overriden by the refresh_pattern max-stale option.
  4774. #Default:
  4775. # max_stale 1 week
  4776.  
  4777. # TAG: refresh_pattern
  4778. # usage: refresh_pattern [-i] regex min percent max [options]
  4779. #
  4780. # By default, regular expressions are CASE-SENSITIVE. To make
  4781. # them case-insensitive, use the -i option.
  4782. #
  4783. # 'Min' is the time (in minutes) an object without an explicit
  4784. # expiry time should be considered fresh. The recommended
  4785. # value is 0, any higher values may cause dynamic applications
  4786. # to be erroneously cached unless the application designer
  4787. # has taken the appropriate actions.
  4788. #
  4789. # 'Percent' is a percentage of the objects age (time since last
  4790. # modification age) an object without explicit expiry time
  4791. # will be considered fresh.
  4792. #
  4793. # 'Max' is an upper limit on how long objects without an explicit
  4794. # expiry time will be considered fresh. The value is also used
  4795. # to form Cache-Control: max-age header for a request sent from
  4796. # Squid to origin/parent.
  4797. #
  4798. # options: override-expire
  4799. # override-lastmod
  4800. # reload-into-ims
  4801. # ignore-reload
  4802. # ignore-no-store
  4803. # ignore-must-revalidate
  4804. # ignore-private
  4805. # ignore-auth
  4806. # max-stale=NN
  4807. # refresh-ims
  4808. # store-stale
  4809. #
  4810. # override-expire enforces min age even if the server
  4811. # sent an explicit expiry time (e.g., with the
  4812. # Expires: header or Cache-Control: max-age). Doing this
  4813. # VIOLATES the HTTP standard. Enabling this feature
  4814. # could make you liable for problems which it causes.
  4815. #
  4816. # Note: override-expire does not enforce staleness - it only extends
  4817. # freshness / min. If the server returns a Expires time which
  4818. # is longer than your max time, Squid will still consider
  4819. # the object fresh for that period of time.
  4820. #
  4821. # override-lastmod enforces min age even on objects
  4822. # that were modified recently.
  4823. #
  4824. # reload-into-ims changes a client no-cache or ``reload''
  4825. # request for a cached entry into a conditional request using
  4826. # If-Modified-Since and/or If-None-Match headers, provided the
  4827. # cached entry has a Last-Modified and/or a strong ETag header.
  4828. # Doing this VIOLATES the HTTP standard. Enabling this feature
  4829. # could make you liable for problems which it causes.
  4830. #
  4831. # ignore-reload ignores a client no-cache or ``reload''
  4832. # header. Doing this VIOLATES the HTTP standard. Enabling
  4833. # this feature could make you liable for problems which
  4834. # it causes.
  4835. #
  4836. # ignore-no-store ignores any ``Cache-control: no-store''
  4837. # headers received from a server. Doing this VIOLATES
  4838. # the HTTP standard. Enabling this feature could make you
  4839. # liable for problems which it causes.
  4840. #
  4841. # ignore-must-revalidate ignores any ``Cache-Control: must-revalidate``
  4842. # headers received from a server. Doing this VIOLATES
  4843. # the HTTP standard. Enabling this feature could make you
  4844. # liable for problems which it causes.
  4845. #
  4846. # ignore-private ignores any ``Cache-control: private''
  4847. # headers received from a server. Doing this VIOLATES
  4848. # the HTTP standard. Enabling this feature could make you
  4849. # liable for problems which it causes.
  4850. #
  4851. # ignore-auth caches responses to requests with authorization,
  4852. # as if the originserver had sent ``Cache-control: public''
  4853. # in the response header. Doing this VIOLATES the HTTP standard.
  4854. # Enabling this feature could make you liable for problems which
  4855. # it causes.
  4856. #
  4857. # refresh-ims causes squid to contact the origin server
  4858. # when a client issues an If-Modified-Since request. This
  4859. # ensures that the client will receive an updated version
  4860. # if one is available.
  4861. #
  4862. # store-stale stores responses even if they don't have explicit
  4863. # freshness or a validator (i.e., Last-Modified or an ETag)
  4864. # present, or if they're already stale. By default, Squid will
  4865. # not cache such responses because they usually can't be
  4866. # reused. Note that such responses will be stale by default.
  4867. #
  4868. # max-stale=NN provide a maximum staleness factor. Squid won't
  4869. # serve objects more stale than this even if it failed to
  4870. # validate the object. Default: use the max_stale global limit.
  4871. #
  4872. # Basically a cached object is:
  4873. #
  4874. # FRESH if expire > now, else STALE
  4875. # STALE if age > max
  4876. # FRESH if lm-factor < percent, else STALE
  4877. # FRESH if age < min
  4878. # else STALE
  4879. #
  4880. # The refresh_pattern lines are checked in the order listed here.
  4881. # The first entry which matches is used. If none of the entries
  4882. # match the default will be used.
  4883. #
  4884. # Note, you must uncomment all the default lines if you want
  4885. # to change one. The default setting is only active if none is
  4886. # used.
  4887. #
  4888. #
  4889.  
  4890. #
  4891. # Add any of your own refresh_pattern entries above these.
  4892. #
  4893. refresh_pattern ^ftp: 1440 20% 10080
  4894. refresh_pattern ^gopher: 1440 0% 1440
  4895. refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
  4896. refresh_pattern (Release|Packages(.gz)*)$ 0 20% 2880
  4897. # example lin deb packages
  4898. #refresh_pattern (\.deb|\.udeb)$ 129600 100% 129600
  4899. refresh_pattern . 0 20% 4320
  4900.  
  4901. # TAG: quick_abort_min (KB)
  4902. #Default:
  4903. # quick_abort_min 16 KB
  4904.  
  4905. # TAG: quick_abort_max (KB)
  4906. #Default:
  4907. # quick_abort_max 16 KB
  4908.  
  4909. # TAG: quick_abort_pct (percent)
  4910. # The cache by default continues downloading aborted requests
  4911. # which are almost completed (less than 16 KB remaining). This
  4912. # may be undesirable on slow (e.g. SLIP) links and/or very busy
  4913. # caches. Impatient users may tie up file descriptors and
  4914. # bandwidth by repeatedly requesting and immediately aborting
  4915. # downloads.
  4916. #
  4917. # When the user aborts a request, Squid will check the
  4918. # quick_abort values to the amount of data transferred until
  4919. # then.
  4920. #
  4921. # If the transfer has less than 'quick_abort_min' KB remaining,
  4922. # it will finish the retrieval.
  4923. #
  4924. # If the transfer has more than 'quick_abort_max' KB remaining,
  4925. # it will abort the retrieval.
  4926. #
  4927. # If more than 'quick_abort_pct' of the transfer has completed,
  4928. # it will finish the retrieval.
  4929. #
  4930. # If you do not want any retrieval to continue after the client
  4931. # has aborted, set both 'quick_abort_min' and 'quick_abort_max'
  4932. # to '0 KB'.
  4933. #
  4934. # If you want retrievals to always continue if they are being
  4935. # cached set 'quick_abort_min' to '-1 KB'.
  4936. #Default:
  4937. # quick_abort_pct 95
  4938.  
  4939. # TAG: read_ahead_gap buffer-size
  4940. # The amount of data the cache will buffer ahead of what has been
  4941. # sent to the client when retrieving an object from another server.
  4942. #Default:
  4943. # read_ahead_gap 16 KB
  4944.  
  4945. # TAG: negative_ttl time-units
  4946. # Set the Default Time-to-Live (TTL) for failed requests.
  4947. # Certain types of failures (such as "connection refused" and
  4948. # "404 Not Found") are able to be negatively-cached for a short time.
  4949. # Modern web servers should provide Expires: header, however if they
  4950. # do not this can provide a minimum TTL.
  4951. # The default is not to cache errors with unknown expiry details.
  4952. #
  4953. # Note that this is different from negative caching of DNS lookups.
  4954. #
  4955. # WARNING: Doing this VIOLATES the HTTP standard. Enabling
  4956. # this feature could make you liable for problems which it
  4957. # causes.
  4958. #Default:
  4959. # negative_ttl 0 seconds
  4960.  
  4961. # TAG: positive_dns_ttl time-units
  4962. # Upper limit on how long Squid will cache positive DNS responses.
  4963. # Default is 6 hours (360 minutes). This directive must be set
  4964. # larger than negative_dns_ttl.
  4965. #Default:
  4966. # positive_dns_ttl 6 hours
  4967.  
  4968. # TAG: negative_dns_ttl time-units
  4969. # Time-to-Live (TTL) for negative caching of failed DNS lookups.
  4970. # This also sets the lower cache limit on positive lookups.
  4971. # Minimum value is 1 second, and it is not recommendable to go
  4972. # much below 10 seconds.
  4973. #Default:
  4974. # negative_dns_ttl 1 minutes
  4975.  
  4976. # TAG: range_offset_limit size [acl acl...]
  4977. # usage: (size) [units] [[!]aclname]
  4978. #
  4979. # Sets an upper limit on how far (number of bytes) into the file
  4980. # a Range request may be to cause Squid to prefetch the whole file.
  4981. # If beyond this limit, Squid forwards the Range request as it is and
  4982. # the result is NOT cached.
  4983. #
  4984. # This is to stop a far ahead range request (lets say start at 17MB)
  4985. # from making Squid fetch the whole object up to that point before
  4986. # sending anything to the client.
  4987. #
  4988. # Multiple range_offset_limit lines may be specified, and they will
  4989. # be searched from top to bottom on each request until a match is found.
  4990. # The first match found will be used. If no line matches a request, the
  4991. # default limit of 0 bytes will be used.
  4992. #
  4993. # 'size' is the limit specified as a number of units.
  4994. #
  4995. # 'units' specifies whether to use bytes, KB, MB, etc.
  4996. # If no units are specified bytes are assumed.
  4997. #
  4998. # A size of 0 causes Squid to never fetch more than the
  4999. # client requested. (default)
  5000. #
  5001. # A size of 'none' causes Squid to always fetch the object from the
  5002. # beginning so it may cache the result. (2.0 style)
  5003. #
  5004. # 'aclname' is the name of a defined ACL.
  5005. #
  5006. # NP: Using 'none' as the byte value here will override any quick_abort settings
  5007. # that may otherwise apply to the range request. The range request will
  5008. # be fully fetched from start to finish regardless of the client
  5009. # actions. This affects bandwidth usage.
  5010. #Default:
  5011. # none
  5012.  
  5013. # TAG: minimum_expiry_time (seconds)
  5014. # The minimum caching time according to (Expires - Date)
  5015. # headers Squid honors if the object can't be revalidated.
  5016. # The default is 60 seconds.
  5017. #
  5018. # In reverse proxy environments it might be desirable to honor
  5019. # shorter object lifetimes. It is most likely better to make
  5020. # your server return a meaningful Last-Modified header however.
  5021. #
  5022. # In ESI environments where page fragments often have short
  5023. # lifetimes, this will often be best set to 0.
  5024. #Default:
  5025. # minimum_expiry_time 60 seconds
  5026.  
  5027. # TAG: store_avg_object_size (bytes)
  5028. # Average object size, used to estimate number of objects your
  5029. # cache can hold. The default is 13 KB.
  5030. #
  5031. # This is used to pre-seed the cache index memory allocation to
  5032. # reduce expensive reallocate operations while handling clients
  5033. # traffic. Too-large values may result in memory allocation during
  5034. # peak traffic, too-small values will result in wasted memory.
  5035. #
  5036. # Check the cache manager 'info' report metrics for the real
  5037. # object sizes seen by your Squid before tuning this.
  5038. #Default:
  5039. # store_avg_object_size 13 KB
  5040.  
  5041. # TAG: store_objects_per_bucket
  5042. # Target number of objects per bucket in the store hash table.
  5043. # Lowering this value increases the total number of buckets and
  5044. # also the storage maintenance rate. The default is 20.
  5045. #Default:
  5046. # store_objects_per_bucket 20
  5047.  
  5048. # HTTP OPTIONS
  5049. # -----------------------------------------------------------------------------
  5050.  
  5051. # TAG: request_header_max_size (KB)
  5052. # This specifies the maximum size for HTTP headers in a request.
  5053. # Request headers are usually relatively small (about 512 bytes).
  5054. # Placing a limit on the request header size will catch certain
  5055. # bugs (for example with persistent connections) and possibly
  5056. # buffer-overflow or denial-of-service attacks.
  5057. #Default:
  5058. # request_header_max_size 64 KB
  5059.  
  5060. # TAG: reply_header_max_size (KB)
  5061. # This specifies the maximum size for HTTP headers in a reply.
  5062. # Reply headers are usually relatively small (about 512 bytes).
  5063. # Placing a limit on the reply header size will catch certain
  5064. # bugs (for example with persistent connections) and possibly
  5065. # buffer-overflow or denial-of-service attacks.
  5066. #Default:
  5067. # reply_header_max_size 64 KB
  5068.  
  5069. # TAG: request_body_max_size (bytes)
  5070. # This specifies the maximum size for an HTTP request body.
  5071. # In other words, the maximum size of a PUT/POST request.
  5072. # A user who attempts to send a request with a body larger
  5073. # than this limit receives an "Invalid Request" error message.
  5074. # If you set this parameter to a zero (the default), there will
  5075. # be no limit imposed.
  5076. #
  5077. # See also client_request_buffer_max_size for an alternative
  5078. # limitation on client uploads which can be configured.
  5079. #Default:
  5080. # No limit.
  5081.  
  5082. # TAG: client_request_buffer_max_size (bytes)
  5083. # This specifies the maximum buffer size of a client request.
  5084. # It prevents squid eating too much memory when somebody uploads
  5085. # a large file.
  5086. #Default:
  5087. # client_request_buffer_max_size 512 KB
  5088.  
  5089. # TAG: broken_posts
  5090. # A list of ACL elements which, if matched, causes Squid to send
  5091. # an extra CRLF pair after the body of a PUT/POST request.
  5092. #
  5093. # Some HTTP servers has broken implementations of PUT/POST,
  5094. # and rely on an extra CRLF pair sent by some WWW clients.
  5095. #
  5096. # Quote from RFC2616 section 4.1 on this matter:
  5097. #
  5098. # Note: certain buggy HTTP/1.0 client implementations generate an
  5099. # extra CRLF's after a POST request. To restate what is explicitly
  5100. # forbidden by the BNF, an HTTP/1.1 client must not preface or follow
  5101. # a request with an extra CRLF.
  5102. #
  5103. # This clause only supports fast acl types.
  5104. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  5105. #
  5106. #Example:
  5107. # acl buggy_server url_regex ^http://....
  5108. # broken_posts allow buggy_server
  5109. #Default:
  5110. # Obey RFC 2616.
  5111.  
  5112. # TAG: adaptation_uses_indirect_client on|off
  5113. # Controls whether the indirect client IP address (instead of the direct
  5114. # client IP address) is passed to adaptation services.
  5115. #
  5116. # See also: follow_x_forwarded_for adaptation_send_client_ip
  5117. #Default:
  5118. # adaptation_uses_indirect_client on
  5119.  
  5120. # TAG: via on|off
  5121. # If set (default), Squid will include a Via header in requests and
  5122. # replies as required by RFC2616.
  5123. #Default:
  5124. # via on
  5125.  
  5126. # TAG: ie_refresh on|off
  5127. # Microsoft Internet Explorer up until version 5.5 Service
  5128. # Pack 1 has an issue with transparent proxies, wherein it
  5129. # is impossible to force a refresh. Turning this on provides
  5130. # a partial fix to the problem, by causing all IMS-REFRESH
  5131. # requests from older IE versions to check the origin server
  5132. # for fresh content. This reduces hit ratio by some amount
  5133. # (~10% in my experience), but allows users to actually get
  5134. # fresh content when they want it. Note because Squid
  5135. # cannot tell if the user is using 5.5 or 5.5SP1, the behavior
  5136. # of 5.5 is unchanged from old versions of Squid (i.e. a
  5137. # forced refresh is impossible). Newer versions of IE will,
  5138. # hopefully, continue to have the new behavior and will be
  5139. # handled based on that assumption. This option defaults to
  5140. # the old Squid behavior, which is better for hit ratios but
  5141. # worse for clients using IE, if they need to be able to
  5142. # force fresh content.
  5143. #Default:
  5144. # ie_refresh off
  5145.  
  5146. # TAG: vary_ignore_expire on|off
  5147. # Many HTTP servers supporting Vary gives such objects
  5148. # immediate expiry time with no cache-control header
  5149. # when requested by a HTTP/1.0 client. This option
  5150. # enables Squid to ignore such expiry times until
  5151. # HTTP/1.1 is fully implemented.
  5152. #
  5153. # WARNING: If turned on this may eventually cause some
  5154. # varying objects not intended for caching to get cached.
  5155. #Default:
  5156. # vary_ignore_expire off
  5157.  
  5158. # TAG: request_entities
  5159. # Squid defaults to deny GET and HEAD requests with request entities,
  5160. # as the meaning of such requests are undefined in the HTTP standard
  5161. # even if not explicitly forbidden.
  5162. #
  5163. # Set this directive to on if you have clients which insists
  5164. # on sending request entities in GET or HEAD requests. But be warned
  5165. # that there is server software (both proxies and web servers) which
  5166. # can fail to properly process this kind of request which may make you
  5167. # vulnerable to cache pollution attacks if enabled.
  5168. #Default:
  5169. # request_entities off
  5170.  
  5171. # TAG: request_header_access
  5172. # Usage: request_header_access header_name allow|deny [!]aclname ...
  5173. #
  5174. # WARNING: Doing this VIOLATES the HTTP standard. Enabling
  5175. # this feature could make you liable for problems which it
  5176. # causes.
  5177. #
  5178. # This option replaces the old 'anonymize_headers' and the
  5179. # older 'http_anonymizer' option with something that is much
  5180. # more configurable. A list of ACLs for each header name allows
  5181. # removal of specific header fields under specific conditions.
  5182. #
  5183. # This option only applies to outgoing HTTP request headers (i.e.,
  5184. # headers sent by Squid to the next HTTP hop such as a cache peer
  5185. # or an origin server). The option has no effect during cache hit
  5186. # detection. The equivalent adaptation vectoring point in ICAP
  5187. # terminology is post-cache REQMOD.
  5188. #
  5189. # The option is applied to individual outgoing request header
  5190. # fields. For each request header field F, Squid uses the first
  5191. # qualifying sets of request_header_access rules:
  5192. #
  5193. # 1. Rules with header_name equal to F's name.
  5194. # 2. Rules with header_name 'Other', provided F's name is not
  5195. # on the hard-coded list of commonly used HTTP header names.
  5196. # 3. Rules with header_name 'All'.
  5197. #
  5198. # Within that qualifying rule set, rule ACLs are checked as usual.
  5199. # If ACLs of an "allow" rule match, the header field is allowed to
  5200. # go through as is. If ACLs of a "deny" rule match, the header is
  5201. # removed and request_header_replace is then checked to identify
  5202. # if the removed header has a replacement. If no rules within the
  5203. # set have matching ACLs, the header field is left as is.
  5204. #
  5205. # For example, to achieve the same behavior as the old
  5206. # 'http_anonymizer standard' option, you should use:
  5207. #
  5208. # request_header_access From deny all
  5209. # request_header_access Referer deny all
  5210. # request_header_access User-Agent deny all
  5211. #
  5212. # Or, to reproduce the old 'http_anonymizer paranoid' feature
  5213. # you should use:
  5214. #
  5215. # request_header_access Authorization allow all
  5216. # request_header_access Proxy-Authorization allow all
  5217. # request_header_access Cache-Control allow all
  5218. # request_header_access Content-Length allow all
  5219. # request_header_access Content-Type allow all
  5220. # request_header_access Date allow all
  5221. # request_header_access Host allow all
  5222. # request_header_access If-Modified-Since allow all
  5223. # request_header_access Pragma allow all
  5224. # request_header_access Accept allow all
  5225. # request_header_access Accept-Charset allow all
  5226. # request_header_access Accept-Encoding allow all
  5227. # request_header_access Accept-Language allow all
  5228. # request_header_access Connection allow all
  5229. # request_header_access All deny all
  5230. request_header_access en.wikipedia.org allow all
  5231. #
  5232. # HTTP reply headers are controlled with the reply_header_access directive.
  5233. #
  5234. # By default, all headers are allowed (no anonymizing is performed).
  5235. #Default:
  5236. # No limits.
  5237.  
  5238. # TAG: reply_header_access
  5239. # Usage: reply_header_access header_name allow|deny [!]aclname ...
  5240. #
  5241. # WARNING: Doing this VIOLATES the HTTP standard. Enabling
  5242. # this feature could make you liable for problems which it
  5243. # causes.
  5244. #
  5245. # This option only applies to reply headers, i.e., from the
  5246. # server to the client.
  5247. #
  5248. # This is the same as request_header_access, but in the other
  5249. # direction. Please see request_header_access for detailed
  5250. # documentation.
  5251. #
  5252. # For example, to achieve the same behavior as the old
  5253. # 'http_anonymizer standard' option, you should use:
  5254. #
  5255. # reply_header_access Server deny all
  5256. # reply_header_access WWW-Authenticate deny all
  5257. # reply_header_access Link deny all
  5258. #
  5259. # Or, to reproduce the old 'http_anonymizer paranoid' feature
  5260. # you should use:
  5261. #
  5262. # reply_header_access Allow allow all
  5263. # reply_header_access WWW-Authenticate allow all
  5264. # reply_header_access Proxy-Authenticate allow all
  5265. # reply_header_access Cache-Control allow all
  5266. # reply_header_access Content-Encoding allow all
  5267. # reply_header_access Content-Length allow all
  5268. # reply_header_access Content-Type allow all
  5269. # reply_header_access Date allow all
  5270. # reply_header_access Expires allow all
  5271. # reply_header_access Last-Modified allow all
  5272. # reply_header_access Location allow all
  5273. # reply_header_access Pragma allow all
  5274. # reply_header_access Content-Language allow all
  5275. # reply_header_access Retry-After allow all
  5276. # reply_header_access Title allow all
  5277. # reply_header_access Content-Disposition allow all
  5278. # reply_header_access Connection allow all
  5279. # reply_header_access All deny all
  5280. #
  5281. # HTTP request headers are controlled with the request_header_access directive.
  5282. #
  5283. # By default, all headers are allowed (no anonymizing is
  5284. # performed).
  5285. #Default:
  5286. # No limits.
  5287.  
  5288. # TAG: request_header_replace
  5289. # Usage: request_header_replace header_name message
  5290. # Example: request_header_replace User-Agent Nutscrape/1.0 (CP/M; 8-bit)
  5291. #
  5292. # This option allows you to change the contents of headers
  5293. # denied with request_header_access above, by replacing them
  5294. # with some fixed string.
  5295. #
  5296. # This only applies to request headers, not reply headers.
  5297. #
  5298. # By default, headers are removed if denied.
  5299. #Default:
  5300. # none
  5301.  
  5302. # TAG: reply_header_replace
  5303. # Usage: reply_header_replace header_name message
  5304. # Example: reply_header_replace Server Foo/1.0
  5305. #
  5306. # This option allows you to change the contents of headers
  5307. # denied with reply_header_access above, by replacing them
  5308. # with some fixed string.
  5309. #
  5310. # This only applies to reply headers, not request headers.
  5311. #
  5312. # By default, headers are removed if denied.
  5313. #Default:
  5314. # none
  5315.  
  5316. # TAG: request_header_add
  5317. # Usage: request_header_add field-name field-value acl1 [acl2] ...
  5318. # Example: request_header_add X-Client-CA "CA=%ssl::>cert_issuer" all
  5319. #
  5320. # This option adds header fields to outgoing HTTP requests (i.e.,
  5321. # request headers sent by Squid to the next HTTP hop such as a
  5322. # cache peer or an origin server). The option has no effect during
  5323. # cache hit detection. The equivalent adaptation vectoring point
  5324. # in ICAP terminology is post-cache REQMOD.
  5325. #
  5326. # Field-name is a token specifying an HTTP header name. If a
  5327. # standard HTTP header name is used, Squid does not check whether
  5328. # the new header conflicts with any existing headers or violates
  5329. # HTTP rules. If the request to be modified already contains a
  5330. # field with the same name, the old field is preserved but the
  5331. # header field values are not merged.
  5332. #
  5333. # Field-value is either a token or a quoted string. If quoted
  5334. # string format is used, then the surrounding quotes are removed
  5335. # while escape sequences and %macros are processed.
  5336. #
  5337. # In theory, all of the logformat codes can be used as %macros.
  5338. # However, unlike logging (which happens at the very end of
  5339. # transaction lifetime), the transaction may not yet have enough
  5340. # information to expand a macro when the new header value is needed.
  5341. # And some information may already be available to Squid but not yet
  5342. # committed where the macro expansion code can access it (report
  5343. # such instances!). The macro will be expanded into a single dash
  5344. # ('-') in such cases. Not all macros have been tested.
  5345. #
  5346. # One or more Squid ACLs may be specified to restrict header
  5347. # injection to matching requests. As always in squid.conf, all
  5348. # ACLs in an option ACL list must be satisfied for the insertion
  5349. # to happen. The request_header_add option supports fast ACLs
  5350. # only.
  5351. #Default:
  5352. # none
  5353.  
  5354. # TAG: note
  5355. # This option used to log custom information about the master
  5356. # transaction. For example, an admin may configure Squid to log
  5357. # which "user group" the transaction belongs to, where "user group"
  5358. # will be determined based on a set of ACLs and not [just]
  5359. # authentication information.
  5360. # Values of key/value pairs can be logged using %{key}note macros:
  5361. #
  5362. # note key value acl ...
  5363. # logformat myFormat ... %{key}note ...
  5364. #Default:
  5365. # none
  5366.  
  5367. # TAG: relaxed_header_parser on|off|warn
  5368. # In the default "on" setting Squid accepts certain forms
  5369. # of non-compliant HTTP messages where it is unambiguous
  5370. # what the sending application intended even if the message
  5371. # is not correctly formatted. The messages is then normalized
  5372. # to the correct form when forwarded by Squid.
  5373. #
  5374. # If set to "warn" then a warning will be emitted in cache.log
  5375. # each time such HTTP error is encountered.
  5376. #
  5377. # If set to "off" then such HTTP errors will cause the request
  5378. # or response to be rejected.
  5379. #Default:
  5380. # relaxed_header_parser on
  5381.  
  5382. # TAG: collapsed_forwarding (on|off)
  5383. # When enabled, instead of forwarding each concurrent request for
  5384. # the same URL, Squid just sends the first of them. The other, so
  5385. # called "collapsed" requests, wait for the response to the first
  5386. # request and, if it happens to be cachable, use that response.
  5387. # Here, "concurrent requests" means "received after the first
  5388. # request headers were parsed and before the corresponding response
  5389. # headers were parsed".
  5390. #
  5391. # This feature is disabled by default: enabling collapsed
  5392. # forwarding needlessly delays forwarding requests that look
  5393. # cachable (when they are collapsed) but then need to be forwarded
  5394. # individually anyway because they end up being for uncachable
  5395. # content. However, in some cases, such as acceleration of highly
  5396. # cachable content with periodic or grouped expiration times, the
  5397. # gains from collapsing [large volumes of simultaneous refresh
  5398. # requests] outweigh losses from such delays.
  5399. #
  5400. # Squid collapses two kinds of requests: regular client requests
  5401. # received on one of the listening ports and internal "cache
  5402. # revalidation" requests which are triggered by those regular
  5403. # requests hitting a stale cached object. Revalidation collapsing
  5404. # is currently disabled for Squid instances containing SMP-aware
  5405. # disk or memory caches and for Vary-controlled cached objects.
  5406. #Default:
  5407. # collapsed_forwarding off
  5408.  
  5409. # TIMEOUTS
  5410. # -----------------------------------------------------------------------------
  5411.  
  5412. # TAG: forward_timeout time-units
  5413. # This parameter specifies how long Squid should at most attempt in
  5414. # finding a forwarding path for the request before giving up.
  5415. #Default:
  5416. # forward_timeout 4 minutes
  5417.  
  5418. # TAG: connect_timeout time-units
  5419. # This parameter specifies how long to wait for the TCP connect to
  5420. # the requested server or peer to complete before Squid should
  5421. # attempt to find another path where to forward the request.
  5422. #Default:
  5423. # connect_timeout 1 minute
  5424.  
  5425. # TAG: peer_connect_timeout time-units
  5426. # This parameter specifies how long to wait for a pending TCP
  5427. # connection to a peer cache. The default is 30 seconds. You
  5428. # may also set different timeout values for individual neighbors
  5429. # with the 'connect-timeout' option on a 'cache_peer' line.
  5430. #Default:
  5431. # peer_connect_timeout 30 seconds
  5432.  
  5433. # TAG: read_timeout time-units
  5434. # Applied on peer server connections.
  5435. #
  5436. # After each successful read(), the timeout will be extended by this
  5437. # amount. If no data is read again after this amount of time,
  5438. # the request is aborted and logged with ERR_READ_TIMEOUT.
  5439. #
  5440. # The default is 15 minutes.
  5441. #Default:
  5442. # read_timeout 15 minutes
  5443.  
  5444. # TAG: write_timeout time-units
  5445. # This timeout is tracked for all connections that have data
  5446. # available for writing and are waiting for the socket to become
  5447. # ready. After each successful write, the timeout is extended by
  5448. # the configured amount. If Squid has data to write but the
  5449. # connection is not ready for the configured duration, the
  5450. # transaction associated with the connection is terminated. The
  5451. # default is 15 minutes.
  5452. #Default:
  5453. # write_timeout 15 minutes
  5454.  
  5455. # TAG: request_timeout
  5456. # How long to wait for complete HTTP request headers after initial
  5457. # connection establishment.
  5458. #Default:
  5459. # request_timeout 5 minutes
  5460.  
  5461. # TAG: client_idle_pconn_timeout
  5462. # How long to wait for the next HTTP request on a persistent
  5463. # client connection after the previous request completes.
  5464. #Default:
  5465. # client_idle_pconn_timeout 2 minutes
  5466.  
  5467. # TAG: ftp_client_idle_timeout
  5468. # How long to wait for an FTP request on a connection to Squid ftp_port.
  5469. # Many FTP clients do not deal with idle connection closures well,
  5470. # necessitating a longer default timeout than client_idle_pconn_timeout
  5471. # used for incoming HTTP requests.
  5472. #Default:
  5473. # ftp_client_idle_timeout 30 minutes
  5474.  
  5475. # TAG: client_lifetime time-units
  5476. # The maximum amount of time a client (browser) is allowed to
  5477. # remain connected to the cache process. This protects the Cache
  5478. # from having a lot of sockets (and hence file descriptors) tied up
  5479. # in a CLOSE_WAIT state from remote clients that go away without
  5480. # properly shutting down (either because of a network failure or
  5481. # because of a poor client implementation). The default is one
  5482. # day, 1440 minutes.
  5483. #
  5484. # NOTE: The default value is intended to be much larger than any
  5485. # client would ever need to be connected to your cache. You
  5486. # should probably change client_lifetime only as a last resort.
  5487. # If you seem to have many client connections tying up
  5488. # filedescriptors, we recommend first tuning the read_timeout,
  5489. # request_timeout, persistent_request_timeout and quick_abort values.
  5490. #Default:
  5491. # client_lifetime 1 day
  5492.  
  5493. # TAG: half_closed_clients
  5494. # Some clients may shutdown the sending side of their TCP
  5495. # connections, while leaving their receiving sides open. Sometimes,
  5496. # Squid can not tell the difference between a half-closed and a
  5497. # fully-closed TCP connection.
  5498. #
  5499. # By default, Squid will immediately close client connections when
  5500. # read(2) returns "no more data to read."
  5501. #
  5502. # Change this option to 'on' and Squid will keep open connections
  5503. # until a read(2) or write(2) on the socket returns an error.
  5504. # This may show some benefits for reverse proxies. But if not
  5505. # it is recommended to leave OFF.
  5506. #Default:
  5507. # half_closed_clients off
  5508.  
  5509. # TAG: server_idle_pconn_timeout
  5510. # Timeout for idle persistent connections to servers and other
  5511. # proxies.
  5512. #Default:
  5513. # server_idle_pconn_timeout 1 minute
  5514.  
  5515. # TAG: ident_timeout
  5516. # Maximum time to wait for IDENT lookups to complete.
  5517. #
  5518. # If this is too high, and you enabled IDENT lookups from untrusted
  5519. # users, you might be susceptible to denial-of-service by having
  5520. # many ident requests going at once.
  5521. #Default:
  5522. # ident_timeout 10 seconds
  5523.  
  5524. # TAG: shutdown_lifetime time-units
  5525. # When SIGTERM or SIGHUP is received, the cache is put into
  5526. # "shutdown pending" mode until all active sockets are closed.
  5527. # This value is the lifetime to set for all open descriptors
  5528. # during shutdown mode. Any active clients after this many
  5529. # seconds will receive a 'timeout' message.
  5530. #Default:
  5531. # shutdown_lifetime 30 seconds
  5532.  
  5533. # ADMINISTRATIVE PARAMETERS
  5534. # -----------------------------------------------------------------------------
  5535.  
  5536. # TAG: cache_mgr
  5537. # Email-address of local cache manager who will receive
  5538. # mail if the cache dies. The default is "webmaster".
  5539. #Default:
  5540. # cache_mgr webmaster
  5541.  
  5542. # TAG: mail_from
  5543. # From: email-address for mail sent when the cache dies.
  5544. # The default is to use 'squid@unique_hostname'.
  5545. #
  5546. # See also: unique_hostname directive.
  5547. #Default:
  5548. # none
  5549.  
  5550. # TAG: mail_program
  5551. # Email program used to send mail if the cache dies.
  5552. # The default is "mail". The specified program must comply
  5553. # with the standard Unix mail syntax:
  5554. # mail-program recipient < mailfile
  5555. #
  5556. # Optional command line options can be specified.
  5557. #Default:
  5558. # mail_program mail
  5559.  
  5560. # TAG: cache_effective_user
  5561. # If you start Squid as root, it will change its effective/real
  5562. # UID/GID to the user specified below. The default is to change
  5563. # to UID of proxy.
  5564. # see also; cache_effective_group
  5565. #Default:
  5566. # cache_effective_user proxy
  5567. cache_effective_user proxy
  5568.  
  5569. # TAG: cache_effective_group
  5570. # Squid sets the GID to the effective user's default group ID
  5571. # (taken from the password file) and supplementary group list
  5572. # from the groups membership.
  5573. #
  5574. # If you want Squid to run with a specific GID regardless of
  5575. # the group memberships of the effective user then set this
  5576. # to the group (or GID) you want Squid to run as. When set
  5577. # all other group privileges of the effective user are ignored
  5578. # and only this GID is effective. If Squid is not started as
  5579. # root the user starting Squid MUST be member of the specified
  5580. # group.
  5581. #
  5582. # This option is not recommended by the Squid Team.
  5583. # Our preference is for administrators to configure a secure
  5584. # user account for squid with UID/GID matching system policies.
  5585. #Default:
  5586. # Use system group memberships of the cache_effective_user account
  5587.  
  5588. # TAG: httpd_suppress_version_string on|off
  5589. # Suppress Squid version string info in HTTP headers and HTML error pages.
  5590. #Default:
  5591. # httpd_suppress_version_string off
  5592.  
  5593. # TAG: visible_hostname
  5594. visible_hostname broofiproxy
  5595. # If you want to present a special hostname in error messages, etc,
  5596. # define this. Otherwise, the return value of gethostname()
  5597. # will be used. If you have multiple caches in a cluster and
  5598. # get errors about IP-forwarding you must set them to have individual
  5599. # names with this setting.
  5600. #Default:
  5601. # Automatically detect the system host name
  5602.  
  5603. # TAG: unique_hostname
  5604. # If you want to have multiple machines with the same
  5605. # 'visible_hostname' you must give each machine a different
  5606. # 'unique_hostname' so forwarding loops can be detected.
  5607. #Default:
  5608. # Copy the value from visible_hostname
  5609.  
  5610. # TAG: hostname_aliases
  5611. # A list of other DNS names your cache has.
  5612. #Default:
  5613. # none
  5614.  
  5615. # TAG: umask
  5616. # Minimum umask which should be enforced while the proxy
  5617. # is running, in addition to the umask set at startup.
  5618. #
  5619. # For a traditional octal representation of umasks, start
  5620. # your value with 0.
  5621. #Default:
  5622. # umask 027
  5623.  
  5624. # OPTIONS FOR THE CACHE REGISTRATION SERVICE
  5625. # -----------------------------------------------------------------------------
  5626. #
  5627. # This section contains parameters for the (optional) cache
  5628. # announcement service. This service is provided to help
  5629. # cache administrators locate one another in order to join or
  5630. # create cache hierarchies.
  5631. #
  5632. # An 'announcement' message is sent (via UDP) to the registration
  5633. # service by Squid. By default, the announcement message is NOT
  5634. # SENT unless you enable it with 'announce_period' below.
  5635. #
  5636. # The announcement message includes your hostname, plus the
  5637. # following information from this configuration file:
  5638. #
  5639. # http_port
  5640. # icp_port
  5641. # cache_mgr
  5642. #
  5643. # All current information is processed regularly and made
  5644. # available on the Web at http://www.ircache.net/Cache/Tracker/.
  5645.  
  5646. # TAG: announce_period
  5647. # This is how frequently to send cache announcements.
  5648. #
  5649. # To enable announcing your cache, just set an announce period.
  5650. #
  5651. # Example:
  5652. # announce_period 1 day
  5653. #Default:
  5654. # Announcement messages disabled.
  5655.  
  5656. # TAG: announce_host
  5657. # Set the hostname where announce registration messages will be sent.
  5658. #
  5659. # See also announce_port and announce_file
  5660. #Default:
  5661. # announce_host tracker.ircache.net
  5662.  
  5663. # TAG: announce_file
  5664. # The contents of this file will be included in the announce
  5665. # registration messages.
  5666. #Default:
  5667. # none
  5668.  
  5669. # TAG: announce_port
  5670. # Set the port where announce registration messages will be sent.
  5671. #
  5672. # See also announce_host and announce_file
  5673. #Default:
  5674. # announce_port 3131
  5675.  
  5676. # HTTPD-ACCELERATOR OPTIONS
  5677. # -----------------------------------------------------------------------------
  5678.  
  5679. # TAG: httpd_accel_surrogate_id
  5680. # Surrogates (http://www.esi.org/architecture_spec_1.0.html)
  5681. # need an identification token to allow control targeting. Because
  5682. # a farm of surrogates may all perform the same tasks, they may share
  5683. # an identification token.
  5684. #Default:
  5685. # visible_hostname is used if no specific ID is set.
  5686.  
  5687. # TAG: http_accel_surrogate_remote on|off
  5688. # Remote surrogates (such as those in a CDN) honour the header
  5689. # "Surrogate-Control: no-store-remote".
  5690. #
  5691. # Set this to on to have squid behave as a remote surrogate.
  5692. #Default:
  5693. # http_accel_surrogate_remote off
  5694.  
  5695. # TAG: esi_parser libxml2|expat|custom
  5696. # ESI markup is not strictly XML compatible. The custom ESI parser
  5697. # will give higher performance, but cannot handle non ASCII character
  5698. # encodings.
  5699. #Default:
  5700. # esi_parser custom
  5701.  
  5702. # DELAY POOL PARAMETERS
  5703. # -----------------------------------------------------------------------------
  5704.  
  5705. # TAG: delay_pools
  5706. # This represents the number of delay pools to be used. For example,
  5707. # if you have one class 2 delay pool and one class 3 delays pool, you
  5708. # have a total of 2 delay pools.
  5709. #
  5710. # See also delay_parameters, delay_class, delay_access for pool
  5711. # configuration details.
  5712. #Default:
  5713. # delay_pools 0
  5714.  
  5715. # TAG: delay_class
  5716. # This defines the class of each delay pool. There must be exactly one
  5717. # delay_class line for each delay pool. For example, to define two
  5718. # delay pools, one of class 2 and one of class 3, the settings above
  5719. # and here would be:
  5720. #
  5721. # Example:
  5722. # delay_pools 4 # 4 delay pools
  5723. # delay_class 1 2 # pool 1 is a class 2 pool
  5724. # delay_class 2 3 # pool 2 is a class 3 pool
  5725. # delay_class 3 4 # pool 3 is a class 4 pool
  5726. # delay_class 4 5 # pool 4 is a class 5 pool
  5727. #
  5728. # The delay pool classes are:
  5729. #
  5730. # class 1 Everything is limited by a single aggregate
  5731. # bucket.
  5732. #
  5733. # class 2 Everything is limited by a single aggregate
  5734. # bucket as well as an "individual" bucket chosen
  5735. # from bits 25 through 32 of the IPv4 address.
  5736. #
  5737. # class 3 Everything is limited by a single aggregate
  5738. # bucket as well as a "network" bucket chosen
  5739. # from bits 17 through 24 of the IP address and a
  5740. # "individual" bucket chosen from bits 17 through
  5741. # 32 of the IPv4 address.
  5742. #
  5743. # class 4 Everything in a class 3 delay pool, with an
  5744. # additional limit on a per user basis. This
  5745. # only takes effect if the username is established
  5746. # in advance - by forcing authentication in your
  5747. # http_access rules.
  5748. #
  5749. # class 5 Requests are grouped according their tag (see
  5750. # external_acl's tag= reply).
  5751. #
  5752. #
  5753. # Each pool also requires a delay_parameters directive to configure the pool size
  5754. # and speed limits used whenever the pool is applied to a request. Along with
  5755. # a set of delay_access directives to determine when it is used.
  5756. #
  5757. # NOTE: If an IP address is a.b.c.d
  5758. # -> bits 25 through 32 are "d"
  5759. # -> bits 17 through 24 are "c"
  5760. # -> bits 17 through 32 are "c * 256 + d"
  5761. #
  5762. # NOTE-2: Due to the use of bitmasks in class 2,3,4 pools they only apply to
  5763. # IPv4 traffic. Class 1 and 5 pools may be used with IPv6 traffic.
  5764. #
  5765. # This clause only supports fast acl types.
  5766. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  5767. #
  5768. # See also delay_parameters and delay_access.
  5769. #Default:
  5770. # none
  5771.  
  5772. # TAG: delay_access
  5773. # This is used to determine which delay pool a request falls into.
  5774. #
  5775. # delay_access is sorted per pool and the matching starts with pool 1,
  5776. # then pool 2, ..., and finally pool N. The first delay pool where the
  5777. # request is allowed is selected for the request. If it does not allow
  5778. # the request to any pool then the request is not delayed (default).
  5779. #
  5780. # For example, if you want some_big_clients in delay
  5781. # pool 1 and lotsa_little_clients in delay pool 2:
  5782. #
  5783. # delay_access 1 allow some_big_clients
  5784. # delay_access 1 deny all
  5785. # delay_access 2 allow lotsa_little_clients
  5786. # delay_access 2 deny all
  5787. # delay_access 3 allow authenticated_clients
  5788. #
  5789. # See also delay_parameters and delay_class.
  5790. #
  5791. #Default:
  5792. # Deny using the pool, unless allow rules exist in squid.conf for the pool.
  5793.  
  5794. # TAG: delay_parameters
  5795. # This defines the parameters for a delay pool. Each delay pool has
  5796. # a number of "buckets" associated with it, as explained in the
  5797. # description of delay_class.
  5798. #
  5799. # For a class 1 delay pool, the syntax is:
  5800. # delay_class pool 1
  5801. # delay_parameters pool aggregate
  5802. #
  5803. # For a class 2 delay pool:
  5804. # delay_class pool 2
  5805. # delay_parameters pool aggregate individual
  5806. #
  5807. # For a class 3 delay pool:
  5808. # delay_class pool 3
  5809. # delay_parameters pool aggregate network individual
  5810. #
  5811. # For a class 4 delay pool:
  5812. # delay_class pool 4
  5813. # delay_parameters pool aggregate network individual user
  5814. #
  5815. # For a class 5 delay pool:
  5816. # delay_class pool 5
  5817. # delay_parameters pool tagrate
  5818. #
  5819. # The option variables are:
  5820. #
  5821. # pool a pool number - ie, a number between 1 and the
  5822. # number specified in delay_pools as used in
  5823. # delay_class lines.
  5824. #
  5825. # aggregate the speed limit parameters for the aggregate bucket
  5826. # (class 1, 2, 3).
  5827. #
  5828. # individual the speed limit parameters for the individual
  5829. # buckets (class 2, 3).
  5830. #
  5831. # network the speed limit parameters for the network buckets
  5832. # (class 3).
  5833. #
  5834. # user the speed limit parameters for the user buckets
  5835. # (class 4).
  5836. #
  5837. # tagrate the speed limit parameters for the tag buckets
  5838. # (class 5).
  5839. #
  5840. # A pair of delay parameters is written restore/maximum, where restore is
  5841. # the number of bytes (not bits - modem and network speeds are usually
  5842. # quoted in bits) per second placed into the bucket, and maximum is the
  5843. # maximum number of bytes which can be in the bucket at any time.
  5844. #
  5845. # There must be one delay_parameters line for each delay pool.
  5846. #
  5847. #
  5848. # For example, if delay pool number 1 is a class 2 delay pool as in the
  5849. # above example, and is being used to strictly limit each host to 64Kbit/sec
  5850. # (plus overheads), with no overall limit, the line is:
  5851. #
  5852. # delay_parameters 1 none 8000/8000
  5853. #
  5854. # Note that 8 x 8K Byte/sec -> 64K bit/sec.
  5855. #
  5856. # Note that the word 'none' is used to represent no limit.
  5857. #
  5858. #
  5859. # And, if delay pool number 2 is a class 3 delay pool as in the above
  5860. # example, and you want to limit it to a total of 256Kbit/sec (strict limit)
  5861. # with each 8-bit network permitted 64Kbit/sec (strict limit) and each
  5862. # individual host permitted 4800bit/sec with a bucket maximum size of 64Kbits
  5863. # to permit a decent web page to be downloaded at a decent speed
  5864. # (if the network is not being limited due to overuse) but slow down
  5865. # large downloads more significantly:
  5866. #
  5867. # delay_parameters 2 32000/32000 8000/8000 600/8000
  5868. #
  5869. # Note that 8 x 32K Byte/sec -> 256K bit/sec.
  5870. # 8 x 8K Byte/sec -> 64K bit/sec.
  5871. # 8 x 600 Byte/sec -> 4800 bit/sec.
  5872. #
  5873. #
  5874. # Finally, for a class 4 delay pool as in the example - each user will
  5875. # be limited to 128Kbits/sec no matter how many workstations they are logged into.:
  5876. #
  5877. # delay_parameters 4 32000/32000 8000/8000 600/64000 16000/16000
  5878. #
  5879. #
  5880. # See also delay_class and delay_access.
  5881. #
  5882. #Default:
  5883. # none
  5884.  
  5885. # TAG: delay_initial_bucket_level (percent, 0-100)
  5886. # The initial bucket percentage is used to determine how much is put
  5887. # in each bucket when squid starts, is reconfigured, or first notices
  5888. # a host accessing it (in class 2 and class 3, individual hosts and
  5889. # networks only have buckets associated with them once they have been
  5890. # "seen" by squid).
  5891. #Default:
  5892. # delay_initial_bucket_level 50
  5893.  
  5894. # CLIENT DELAY POOL PARAMETERS
  5895. # -----------------------------------------------------------------------------
  5896.  
  5897. # TAG: client_delay_pools
  5898. # This option specifies the number of client delay pools used. It must
  5899. # preceed other client_delay_* options.
  5900. #
  5901. # Example:
  5902. # client_delay_pools 2
  5903. #
  5904. # See also client_delay_parameters and client_delay_access.
  5905. #Default:
  5906. # client_delay_pools 0
  5907.  
  5908. # TAG: client_delay_initial_bucket_level (percent, 0-no_limit)
  5909. # This option determines the initial bucket size as a percentage of
  5910. # max_bucket_size from client_delay_parameters. Buckets are created
  5911. # at the time of the "first" connection from the matching IP. Idle
  5912. # buckets are periodically deleted up.
  5913. #
  5914. # You can specify more than 100 percent but note that such "oversized"
  5915. # buckets are not refilled until their size goes down to max_bucket_size
  5916. # from client_delay_parameters.
  5917. #
  5918. # Example:
  5919. # client_delay_initial_bucket_level 50
  5920. #Default:
  5921. # client_delay_initial_bucket_level 50
  5922.  
  5923. # TAG: client_delay_parameters
  5924. #
  5925. # This option configures client-side bandwidth limits using the
  5926. # following format:
  5927. #
  5928. # client_delay_parameters pool speed_limit max_bucket_size
  5929. #
  5930. # pool is an integer ID used for client_delay_access matching.
  5931. #
  5932. # speed_limit is bytes added to the bucket per second.
  5933. #
  5934. # max_bucket_size is the maximum size of a bucket, enforced after any
  5935. # speed_limit additions.
  5936. #
  5937. # Please see the delay_parameters option for more information and
  5938. # examples.
  5939. #
  5940. # Example:
  5941. # client_delay_parameters 1 1024 2048
  5942. # client_delay_parameters 2 51200 16384
  5943. #
  5944. # See also client_delay_access.
  5945. #
  5946. #Default:
  5947. # none
  5948.  
  5949. # TAG: client_delay_access
  5950. # This option determines the client-side delay pool for the
  5951. # request:
  5952. #
  5953. # client_delay_access pool_ID allow|deny acl_name
  5954. #
  5955. # All client_delay_access options are checked in their pool ID
  5956. # order, starting with pool 1. The first checked pool with allowed
  5957. # request is selected for the request. If no ACL matches or there
  5958. # are no client_delay_access options, the request bandwidth is not
  5959. # limited.
  5960. #
  5961. # The ACL-selected pool is then used to find the
  5962. # client_delay_parameters for the request. Client-side pools are
  5963. # not used to aggregate clients. Clients are always aggregated
  5964. # based on their source IP addresses (one bucket per source IP).
  5965. #
  5966. # This clause only supports fast acl types.
  5967. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  5968. # Additionally, only the client TCP connection details are available.
  5969. # ACLs testing HTTP properties will not work.
  5970. #
  5971. # Please see delay_access for more examples.
  5972. #
  5973. # Example:
  5974. # client_delay_access 1 allow low_rate_network
  5975. # client_delay_access 2 allow vips_network
  5976. #
  5977. #
  5978. # See also client_delay_parameters and client_delay_pools.
  5979. #Default:
  5980. # Deny use of the pool, unless allow rules exist in squid.conf for the pool.
  5981.  
  5982. # WCCPv1 AND WCCPv2 CONFIGURATION OPTIONS
  5983. # -----------------------------------------------------------------------------
  5984.  
  5985. # TAG: wccp_router
  5986. # Use this option to define your WCCP ``home'' router for
  5987. # Squid.
  5988. #
  5989. # wccp_router supports a single WCCP(v1) router
  5990. #
  5991. # wccp2_router supports multiple WCCPv2 routers
  5992. #
  5993. # only one of the two may be used at the same time and defines
  5994. # which version of WCCP to use.
  5995. #Default:
  5996. # WCCP disabled.
  5997.  
  5998. # TAG: wccp2_router
  5999. # Use this option to define your WCCP ``home'' router for
  6000. # Squid.
  6001. #
  6002. # wccp_router supports a single WCCP(v1) router
  6003. #
  6004. # wccp2_router supports multiple WCCPv2 routers
  6005. #
  6006. # only one of the two may be used at the same time and defines
  6007. # which version of WCCP to use.
  6008. #Default:
  6009. # WCCPv2 disabled.
  6010.  
  6011. # TAG: wccp_version
  6012. # This directive is only relevant if you need to set up WCCP(v1)
  6013. # to some very old and end-of-life Cisco routers. In all other
  6014. # setups it must be left unset or at the default setting.
  6015. # It defines an internal version in the WCCP(v1) protocol,
  6016. # with version 4 being the officially documented protocol.
  6017. #
  6018. # According to some users, Cisco IOS 11.2 and earlier only
  6019. # support WCCP version 3. If you're using that or an earlier
  6020. # version of IOS, you may need to change this value to 3, otherwise
  6021. # do not specify this parameter.
  6022. #Default:
  6023. # wccp_version 4
  6024.  
  6025. # TAG: wccp2_rebuild_wait
  6026. # If this is enabled Squid will wait for the cache dir rebuild to finish
  6027. # before sending the first wccp2 HereIAm packet
  6028. #Default:
  6029. # wccp2_rebuild_wait on
  6030.  
  6031. # TAG: wccp2_forwarding_method
  6032. # WCCP2 allows the setting of forwarding methods between the
  6033. # router/switch and the cache. Valid values are as follows:
  6034. #
  6035. # gre - GRE encapsulation (forward the packet in a GRE/WCCP tunnel)
  6036. # l2 - L2 redirect (forward the packet using Layer 2/MAC rewriting)
  6037. #
  6038. # Currently (as of IOS 12.4) cisco routers only support GRE.
  6039. # Cisco switches only support the L2 redirect assignment method.
  6040. #Default:
  6041. # wccp2_forwarding_method gre
  6042.  
  6043. # TAG: wccp2_return_method
  6044. # WCCP2 allows the setting of return methods between the
  6045. # router/switch and the cache for packets that the cache
  6046. # decides not to handle. Valid values are as follows:
  6047. #
  6048. # gre - GRE encapsulation (forward the packet in a GRE/WCCP tunnel)
  6049. # l2 - L2 redirect (forward the packet using Layer 2/MAC rewriting)
  6050. #
  6051. # Currently (as of IOS 12.4) cisco routers only support GRE.
  6052. # Cisco switches only support the L2 redirect assignment.
  6053. #
  6054. # If the "ip wccp redirect exclude in" command has been
  6055. # enabled on the cache interface, then it is still safe for
  6056. # the proxy server to use a l2 redirect method even if this
  6057. # option is set to GRE.
  6058. #Default:
  6059. # wccp2_return_method gre
  6060.  
  6061. # TAG: wccp2_assignment_method
  6062. # WCCP2 allows the setting of methods to assign the WCCP hash
  6063. # Valid values are as follows:
  6064. #
  6065. # hash - Hash assignment
  6066. # mask - Mask assignment
  6067. #
  6068. # As a general rule, cisco routers support the hash assignment method
  6069. # and cisco switches support the mask assignment method.
  6070. #Default:
  6071. # wccp2_assignment_method hash
  6072.  
  6073. # TAG: wccp2_service
  6074. # WCCP2 allows for multiple traffic services. There are two
  6075. # types: "standard" and "dynamic". The standard type defines
  6076. # one service id - http (id 0). The dynamic service ids can be from
  6077. # 51 to 255 inclusive. In order to use a dynamic service id
  6078. # one must define the type of traffic to be redirected; this is done
  6079. # using the wccp2_service_info option.
  6080. #
  6081. # The "standard" type does not require a wccp2_service_info option,
  6082. # just specifying the service id will suffice.
  6083. #
  6084. # MD5 service authentication can be enabled by adding
  6085. # "password=<password>" to the end of this service declaration.
  6086. #
  6087. # Examples:
  6088. #
  6089. # wccp2_service standard 0 # for the 'web-cache' standard service
  6090. # wccp2_service dynamic 80 # a dynamic service type which will be
  6091. # # fleshed out with subsequent options.
  6092. # wccp2_service standard 0 password=foo
  6093. #Default:
  6094. # Use the 'web-cache' standard service.
  6095.  
  6096. # TAG: wccp2_service_info
  6097. # Dynamic WCCPv2 services require further information to define the
  6098. # traffic you wish to have diverted.
  6099. #
  6100. # The format is:
  6101. #
  6102. # wccp2_service_info <id> protocol=<protocol> flags=<flag>,<flag>..
  6103. # priority=<priority> ports=<port>,<port>..
  6104. #
  6105. # The relevant WCCPv2 flags:
  6106. # + src_ip_hash, dst_ip_hash
  6107. # + source_port_hash, dst_port_hash
  6108. # + src_ip_alt_hash, dst_ip_alt_hash
  6109. # + src_port_alt_hash, dst_port_alt_hash
  6110. # + ports_source
  6111. #
  6112. # The port list can be one to eight entries.
  6113. #
  6114. # Example:
  6115. #
  6116. # wccp2_service_info 80 protocol=tcp flags=src_ip_hash,ports_source
  6117. # priority=240 ports=80
  6118. #
  6119. # Note: the service id must have been defined by a previous
  6120. # 'wccp2_service dynamic <id>' entry.
  6121. #Default:
  6122. # none
  6123.  
  6124. # TAG: wccp2_weight
  6125. # Each cache server gets assigned a set of the destination
  6126. # hash proportional to their weight.
  6127. #Default:
  6128. # wccp2_weight 10000
  6129.  
  6130. # TAG: wccp_address
  6131. # Use this option if you require WCCPv2 to use a specific
  6132. # interface address.
  6133. #
  6134. # The default behavior is to not bind to any specific address.
  6135. #Default:
  6136. # Address selected by the operating system.
  6137.  
  6138. # TAG: wccp2_address
  6139. # Use this option if you require WCCP to use a specific
  6140. # interface address.
  6141. #
  6142. # The default behavior is to not bind to any specific address.
  6143. #Default:
  6144. # Address selected by the operating system.
  6145.  
  6146. # PERSISTENT CONNECTION HANDLING
  6147. # -----------------------------------------------------------------------------
  6148. #
  6149. # Also see "pconn_timeout" in the TIMEOUTS section
  6150.  
  6151. # TAG: client_persistent_connections
  6152. # Persistent connection support for clients.
  6153. # Squid uses persistent connections (when allowed). You can use
  6154. # this option to disable persistent connections with clients.
  6155. #Default:
  6156. # client_persistent_connections on
  6157.  
  6158. # TAG: server_persistent_connections
  6159. # Persistent connection support for servers.
  6160. # Squid uses persistent connections (when allowed). You can use
  6161. # this option to disable persistent connections with servers.
  6162. #Default:
  6163. # server_persistent_connections on
  6164.  
  6165. # TAG: persistent_connection_after_error
  6166. # With this directive the use of persistent connections after
  6167. # HTTP errors can be disabled. Useful if you have clients
  6168. # who fail to handle errors on persistent connections proper.
  6169. #Default:
  6170. # persistent_connection_after_error on
  6171.  
  6172. # TAG: detect_broken_pconn
  6173. # Some servers have been found to incorrectly signal the use
  6174. # of HTTP/1.0 persistent connections even on replies not
  6175. # compatible, causing significant delays. This server problem
  6176. # has mostly been seen on redirects.
  6177. #
  6178. # By enabling this directive Squid attempts to detect such
  6179. # broken replies and automatically assume the reply is finished
  6180. # after 10 seconds timeout.
  6181. #Default:
  6182. # detect_broken_pconn off
  6183.  
  6184. # CACHE DIGEST OPTIONS
  6185. # -----------------------------------------------------------------------------
  6186.  
  6187. # TAG: digest_generation
  6188. # This controls whether the server will generate a Cache Digest
  6189. # of its contents. By default, Cache Digest generation is
  6190. # enabled if Squid is compiled with --enable-cache-digests defined.
  6191. #Default:
  6192. # digest_generation on
  6193.  
  6194. # TAG: digest_bits_per_entry
  6195. # This is the number of bits of the server's Cache Digest which
  6196. # will be associated with the Digest entry for a given HTTP
  6197. # Method and URL (public key) combination. The default is 5.
  6198. #Default:
  6199. # digest_bits_per_entry 5
  6200.  
  6201. # TAG: digest_rebuild_period (seconds)
  6202. # This is the wait time between Cache Digest rebuilds.
  6203. #Default:
  6204. # digest_rebuild_period 1 hour
  6205.  
  6206. # TAG: digest_rewrite_period (seconds)
  6207. # This is the wait time between Cache Digest writes to
  6208. # disk.
  6209. #Default:
  6210. # digest_rewrite_period 1 hour
  6211.  
  6212. # TAG: digest_swapout_chunk_size (bytes)
  6213. # This is the number of bytes of the Cache Digest to write to
  6214. # disk at a time. It defaults to 4096 bytes (4KB), the Squid
  6215. # default swap page.
  6216. #Default:
  6217. # digest_swapout_chunk_size 4096 bytes
  6218.  
  6219. # TAG: digest_rebuild_chunk_percentage (percent, 0-100)
  6220. # This is the percentage of the Cache Digest to be scanned at a
  6221. # time. By default it is set to 10% of the Cache Digest.
  6222. #Default:
  6223. # digest_rebuild_chunk_percentage 10
  6224.  
  6225. # SNMP OPTIONS
  6226. # -----------------------------------------------------------------------------
  6227.  
  6228. # TAG: snmp_port
  6229. # The port number where Squid listens for SNMP requests. To enable
  6230. # SNMP support set this to a suitable port number. Port number
  6231. # 3401 is often used for the Squid SNMP agent. By default it's
  6232. # set to "0" (disabled)
  6233. #
  6234. # Example:
  6235. # snmp_port 3401
  6236. #Default:
  6237. # SNMP disabled.
  6238.  
  6239. # TAG: snmp_access
  6240. # Allowing or denying access to the SNMP port.
  6241. #
  6242. # All access to the agent is denied by default.
  6243. # usage:
  6244. #
  6245. # snmp_access allow|deny [!]aclname ...
  6246. #
  6247. # This clause only supports fast acl types.
  6248. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  6249. #
  6250. #Example:
  6251. # snmp_access allow snmppublic localhost
  6252. # snmp_access deny all
  6253. #Default:
  6254. # Deny, unless rules exist in squid.conf.
  6255.  
  6256. # TAG: snmp_incoming_address
  6257. # Just like 'udp_incoming_address', but for the SNMP port.
  6258. #
  6259. # snmp_incoming_address is used for the SNMP socket receiving
  6260. # messages from SNMP agents.
  6261. #
  6262. # The default snmp_incoming_address is to listen on all
  6263. # available network interfaces.
  6264. #Default:
  6265. # Accept SNMP packets from all machine interfaces.
  6266.  
  6267. # TAG: snmp_outgoing_address
  6268. # Just like 'udp_outgoing_address', but for the SNMP port.
  6269. #
  6270. # snmp_outgoing_address is used for SNMP packets returned to SNMP
  6271. # agents.
  6272. #
  6273. # If snmp_outgoing_address is not set it will use the same socket
  6274. # as snmp_incoming_address. Only change this if you want to have
  6275. # SNMP replies sent using another address than where this Squid
  6276. # listens for SNMP queries.
  6277. #
  6278. # NOTE, snmp_incoming_address and snmp_outgoing_address can not have
  6279. # the same value since they both use the same port.
  6280. #Default:
  6281. # Use snmp_incoming_address or an address selected by the operating system.
  6282.  
  6283. # ICP OPTIONS
  6284. # -----------------------------------------------------------------------------
  6285.  
  6286. # TAG: icp_port
  6287. # The port number where Squid sends and receives ICP queries to
  6288. # and from neighbor caches. The standard UDP port for ICP is 3130.
  6289. #
  6290. # Example:
  6291. # icp_port 3130
  6292. #Default:
  6293. # ICP disabled.
  6294.  
  6295. # TAG: htcp_port
  6296. # The port number where Squid sends and receives HTCP queries to
  6297. # and from neighbor caches. To turn it on you want to set it to
  6298. # 4827.
  6299. #
  6300. # Example:
  6301. # htcp_port 4827
  6302. #Default:
  6303. # HTCP disabled.
  6304.  
  6305. # TAG: log_icp_queries on|off
  6306. # If set, ICP queries are logged to access.log. You may wish
  6307. # do disable this if your ICP load is VERY high to speed things
  6308. # up or to simplify log analysis.
  6309. #Default:
  6310. # log_icp_queries on
  6311.  
  6312. # TAG: udp_incoming_address
  6313. # udp_incoming_address is used for UDP packets received from other
  6314. # caches.
  6315. #
  6316. # The default behavior is to not bind to any specific address.
  6317. #
  6318. # Only change this if you want to have all UDP queries received on
  6319. # a specific interface/address.
  6320. #
  6321. # NOTE: udp_incoming_address is used by the ICP, HTCP, and DNS
  6322. # modules. Altering it will affect all of them in the same manner.
  6323. #
  6324. # see also; udp_outgoing_address
  6325. #
  6326. # NOTE, udp_incoming_address and udp_outgoing_address can not
  6327. # have the same value since they both use the same port.
  6328. #Default:
  6329. # Accept packets from all machine interfaces.
  6330.  
  6331. # TAG: udp_outgoing_address
  6332. # udp_outgoing_address is used for UDP packets sent out to other
  6333. # caches.
  6334. #
  6335. # The default behavior is to not bind to any specific address.
  6336. #
  6337. # Instead it will use the same socket as udp_incoming_address.
  6338. # Only change this if you want to have UDP queries sent using another
  6339. # address than where this Squid listens for UDP queries from other
  6340. # caches.
  6341. #
  6342. # NOTE: udp_outgoing_address is used by the ICP, HTCP, and DNS
  6343. # modules. Altering it will affect all of them in the same manner.
  6344. #
  6345. # see also; udp_incoming_address
  6346. #
  6347. # NOTE, udp_incoming_address and udp_outgoing_address can not
  6348. # have the same value since they both use the same port.
  6349. #Default:
  6350. # Use udp_incoming_address or an address selected by the operating system.
  6351.  
  6352. # TAG: icp_hit_stale on|off
  6353. # If you want to return ICP_HIT for stale cache objects, set this
  6354. # option to 'on'. If you have sibling relationships with caches
  6355. # in other administrative domains, this should be 'off'. If you only
  6356. # have sibling relationships with caches under your control,
  6357. # it is probably okay to set this to 'on'.
  6358. # If set to 'on', your siblings should use the option "allow-miss"
  6359. # on their cache_peer lines for connecting to you.
  6360. #Default:
  6361. # icp_hit_stale off
  6362.  
  6363. # TAG: minimum_direct_hops
  6364. # If using the ICMP pinging stuff, do direct fetches for sites
  6365. # which are no more than this many hops away.
  6366. #Default:
  6367. # minimum_direct_hops 4
  6368.  
  6369. # TAG: minimum_direct_rtt (msec)
  6370. # If using the ICMP pinging stuff, do direct fetches for sites
  6371. # which are no more than this many rtt milliseconds away.
  6372. #Default:
  6373. # minimum_direct_rtt 400
  6374.  
  6375. # TAG: netdb_low
  6376. # The low water mark for the ICMP measurement database.
  6377. #
  6378. # Note: high watermark controlled by netdb_high directive.
  6379. #
  6380. # These watermarks are counts, not percents. The defaults are
  6381. # (low) 900 and (high) 1000. When the high water mark is
  6382. # reached, database entries will be deleted until the low
  6383. # mark is reached.
  6384. #Default:
  6385. # netdb_low 900
  6386.  
  6387. # TAG: netdb_high
  6388. # The high water mark for the ICMP measurement database.
  6389. #
  6390. # Note: low watermark controlled by netdb_low directive.
  6391. #
  6392. # These watermarks are counts, not percents. The defaults are
  6393. # (low) 900 and (high) 1000. When the high water mark is
  6394. # reached, database entries will be deleted until the low
  6395. # mark is reached.
  6396. #Default:
  6397. # netdb_high 1000
  6398.  
  6399. # TAG: netdb_ping_period
  6400. # The minimum period for measuring a site. There will be at
  6401. # least this much delay between successive pings to the same
  6402. # network. The default is five minutes.
  6403. #Default:
  6404. # netdb_ping_period 5 minutes
  6405.  
  6406. # TAG: query_icmp on|off
  6407. # If you want to ask your peers to include ICMP data in their ICP
  6408. # replies, enable this option.
  6409. #
  6410. # If your peer has configured Squid (during compilation) with
  6411. # '--enable-icmp' that peer will send ICMP pings to origin server
  6412. # sites of the URLs it receives. If you enable this option the
  6413. # ICP replies from that peer will include the ICMP data (if available).
  6414. # Then, when choosing a parent cache, Squid will choose the parent with
  6415. # the minimal RTT to the origin server. When this happens, the
  6416. # hierarchy field of the access.log will be
  6417. # "CLOSEST_PARENT_MISS". This option is off by default.
  6418. #Default:
  6419. # query_icmp off
  6420.  
  6421. # TAG: test_reachability on|off
  6422. # When this is 'on', ICP MISS replies will be ICP_MISS_NOFETCH
  6423. # instead of ICP_MISS if the target host is NOT in the ICMP
  6424. # database, or has a zero RTT.
  6425. #Default:
  6426. # test_reachability off
  6427.  
  6428. # TAG: icp_query_timeout (msec)
  6429. # Normally Squid will automatically determine an optimal ICP
  6430. # query timeout value based on the round-trip-time of recent ICP
  6431. # queries. If you want to override the value determined by
  6432. # Squid, set this 'icp_query_timeout' to a non-zero value. This
  6433. # value is specified in MILLISECONDS, so, to use a 2-second
  6434. # timeout (the old default), you would write:
  6435. #
  6436. # icp_query_timeout 2000
  6437. #Default:
  6438. # Dynamic detection.
  6439.  
  6440. # TAG: maximum_icp_query_timeout (msec)
  6441. # Normally the ICP query timeout is determined dynamically. But
  6442. # sometimes it can lead to very large values (say 5 seconds).
  6443. # Use this option to put an upper limit on the dynamic timeout
  6444. # value. Do NOT use this option to always use a fixed (instead
  6445. # of a dynamic) timeout value. To set a fixed timeout see the
  6446. # 'icp_query_timeout' directive.
  6447. #Default:
  6448. # maximum_icp_query_timeout 2000
  6449.  
  6450. # TAG: minimum_icp_query_timeout (msec)
  6451. # Normally the ICP query timeout is determined dynamically. But
  6452. # sometimes it can lead to very small timeouts, even lower than
  6453. # the normal latency variance on your link due to traffic.
  6454. # Use this option to put an lower limit on the dynamic timeout
  6455. # value. Do NOT use this option to always use a fixed (instead
  6456. # of a dynamic) timeout value. To set a fixed timeout see the
  6457. # 'icp_query_timeout' directive.
  6458. #Default:
  6459. # minimum_icp_query_timeout 5
  6460.  
  6461. # TAG: background_ping_rate time-units
  6462. # Controls how often the ICP pings are sent to siblings that
  6463. # have background-ping set.
  6464. #Default:
  6465. # background_ping_rate 10 seconds
  6466.  
  6467. # MULTICAST ICP OPTIONS
  6468. # -----------------------------------------------------------------------------
  6469.  
  6470. # TAG: mcast_groups
  6471. # This tag specifies a list of multicast groups which your server
  6472. # should join to receive multicasted ICP queries.
  6473. #
  6474. # NOTE! Be very careful what you put here! Be sure you
  6475. # understand the difference between an ICP _query_ and an ICP
  6476. # _reply_. This option is to be set only if you want to RECEIVE
  6477. # multicast queries. Do NOT set this option to SEND multicast
  6478. # ICP (use cache_peer for that). ICP replies are always sent via
  6479. # unicast, so this option does not affect whether or not you will
  6480. # receive replies from multicast group members.
  6481. #
  6482. # You must be very careful to NOT use a multicast address which
  6483. # is already in use by another group of caches.
  6484. #
  6485. # If you are unsure about multicast, please read the Multicast
  6486. # chapter in the Squid FAQ (http://www.squid-cache.org/FAQ/).
  6487. #
  6488. # Usage: mcast_groups 239.128.16.128 224.0.1.20
  6489. #
  6490. # By default, Squid doesn't listen on any multicast groups.
  6491. #Default:
  6492. # none
  6493.  
  6494. # TAG: mcast_miss_addr
  6495. # Note: This option is only available if Squid is rebuilt with the
  6496. # -DMULTICAST_MISS_STREAM define
  6497. #
  6498. # If you enable this option, every "cache miss" URL will
  6499. # be sent out on the specified multicast address.
  6500. #
  6501. # Do not enable this option unless you are are absolutely
  6502. # certain you understand what you are doing.
  6503. #Default:
  6504. # disabled.
  6505.  
  6506. # TAG: mcast_miss_ttl
  6507. # Note: This option is only available if Squid is rebuilt with the
  6508. # -DMULTICAST_MISS_STREAM define
  6509. #
  6510. # This is the time-to-live value for packets multicasted
  6511. # when multicasting off cache miss URLs is enabled. By
  6512. # default this is set to 'site scope', i.e. 16.
  6513. #Default:
  6514. # mcast_miss_ttl 16
  6515.  
  6516. # TAG: mcast_miss_port
  6517. # Note: This option is only available if Squid is rebuilt with the
  6518. # -DMULTICAST_MISS_STREAM define
  6519. #
  6520. # This is the port number to be used in conjunction with
  6521. # 'mcast_miss_addr'.
  6522. #Default:
  6523. # mcast_miss_port 3135
  6524.  
  6525. # TAG: mcast_miss_encode_key
  6526. # Note: This option is only available if Squid is rebuilt with the
  6527. # -DMULTICAST_MISS_STREAM define
  6528. #
  6529. # The URLs that are sent in the multicast miss stream are
  6530. # encrypted. This is the encryption key.
  6531. #Default:
  6532. # mcast_miss_encode_key XXXXXXXXXXXXXXXX
  6533.  
  6534. # TAG: mcast_icp_query_timeout (msec)
  6535. # For multicast peers, Squid regularly sends out ICP "probes" to
  6536. # count how many other peers are listening on the given multicast
  6537. # address. This value specifies how long Squid should wait to
  6538. # count all the replies. The default is 2000 msec, or 2
  6539. # seconds.
  6540. #Default:
  6541. # mcast_icp_query_timeout 2000
  6542.  
  6543. # INTERNAL ICON OPTIONS
  6544. # -----------------------------------------------------------------------------
  6545.  
  6546. # TAG: icon_directory
  6547. # Where the icons are stored. These are normally kept in
  6548. # /usr/share/squid/icons
  6549. #Default:
  6550. # icon_directory /usr/share/squid/icons
  6551.  
  6552. # TAG: global_internal_static
  6553. # This directive controls is Squid should intercept all requests for
  6554. # /squid-internal-static/ no matter which host the URL is requesting
  6555. # (default on setting), or if nothing special should be done for
  6556. # such URLs (off setting). The purpose of this directive is to make
  6557. # icons etc work better in complex cache hierarchies where it may
  6558. # not always be possible for all corners in the cache mesh to reach
  6559. # the server generating a directory listing.
  6560. #Default:
  6561. # global_internal_static on
  6562.  
  6563. # TAG: short_icon_urls
  6564. # If this is enabled Squid will use short URLs for icons.
  6565. # If disabled it will revert to the old behavior of including
  6566. # it's own name and port in the URL.
  6567. #
  6568. # If you run a complex cache hierarchy with a mix of Squid and
  6569. # other proxies you may need to disable this directive.
  6570. #Default:
  6571. # short_icon_urls on
  6572.  
  6573. # ERROR PAGE OPTIONS
  6574. # -----------------------------------------------------------------------------
  6575.  
  6576. # TAG: error_directory
  6577. # If you wish to create your own versions of the default
  6578. # error files to customize them to suit your company copy
  6579. # the error/template files to another directory and point
  6580. # this tag at them.
  6581. #
  6582. # WARNING: This option will disable multi-language support
  6583. # on error pages if used.
  6584. #
  6585. # The squid developers are interested in making squid available in
  6586. # a wide variety of languages. If you are making translations for a
  6587. # language that Squid does not currently provide please consider
  6588. # contributing your translation back to the project.
  6589. # http://wiki.squid-cache.org/Translations
  6590. #
  6591. # The squid developers working on translations are happy to supply drop-in
  6592. # translated error files in exchange for any new language contributions.
  6593. #Default:
  6594. # Send error pages in the clients preferred language
  6595.  
  6596. # TAG: error_default_language
  6597. # Set the default language which squid will send error pages in
  6598. # if no existing translation matches the clients language
  6599. # preferences.
  6600. #
  6601. # If unset (default) generic English will be used.
  6602. #
  6603. # The squid developers are interested in making squid available in
  6604. # a wide variety of languages. If you are interested in making
  6605. # translations for any language see the squid wiki for details.
  6606. # http://wiki.squid-cache.org/Translations
  6607. #Default:
  6608. # Generate English language pages.
  6609.  
  6610. # TAG: error_log_languages
  6611. # Log to cache.log what languages users are attempting to
  6612. # auto-negotiate for translations.
  6613. #
  6614. # Successful negotiations are not logged. Only failures
  6615. # have meaning to indicate that Squid may need an upgrade
  6616. # of its error page translations.
  6617. #Default:
  6618. # error_log_languages on
  6619.  
  6620. # TAG: err_page_stylesheet
  6621. # CSS Stylesheet to pattern the display of Squid default error pages.
  6622. #
  6623. # For information on CSS see http://www.w3.org/Style/CSS/
  6624. #Default:
  6625. # err_page_stylesheet /etc/squid/errorpage.css
  6626.  
  6627. # TAG: err_html_text
  6628. # HTML text to include in error messages. Make this a "mailto"
  6629. # URL to your admin address, or maybe just a link to your
  6630. # organizations Web page.
  6631. #
  6632. # To include this in your error messages, you must rewrite
  6633. # the error template files (found in the "errors" directory).
  6634. # Wherever you want the 'err_html_text' line to appear,
  6635. # insert a %L tag in the error template file.
  6636. #Default:
  6637. # none
  6638.  
  6639. # TAG: email_err_data on|off
  6640. # If enabled, information about the occurred error will be
  6641. # included in the mailto links of the ERR pages (if %W is set)
  6642. # so that the email body contains the data.
  6643. # Syntax is <A HREF="mailto:%w%W">%w</A>
  6644. #Default:
  6645. # email_err_data on
  6646.  
  6647. # TAG: deny_info
  6648. # Usage: deny_info err_page_name acl
  6649. # or deny_info http://... acl
  6650. # or deny_info TCP_RESET acl
  6651. #
  6652. # This can be used to return a ERR_ page for requests which
  6653. # do not pass the 'http_access' rules. Squid remembers the last
  6654. # acl it evaluated in http_access, and if a 'deny_info' line exists
  6655. # for that ACL Squid returns a corresponding error page.
  6656. #
  6657. # The acl is typically the last acl on the http_access deny line which
  6658. # denied access. The exceptions to this rule are:
  6659. # - When Squid needs to request authentication credentials. It's then
  6660. # the first authentication related acl encountered
  6661. # - When none of the http_access lines matches. It's then the last
  6662. # acl processed on the last http_access line.
  6663. # - When the decision to deny access was made by an adaptation service,
  6664. # the acl name is the corresponding eCAP or ICAP service_name.
  6665. #
  6666. # NP: If providing your own custom error pages with error_directory
  6667. # you may also specify them by your custom file name:
  6668. # Example: deny_info ERR_CUSTOM_ACCESS_DENIED bad_guys
  6669. #
  6670. # By defaut Squid will send "403 Forbidden". A different 4xx or 5xx
  6671. # may be specified by prefixing the file name with the code and a colon.
  6672. # e.g. 404:ERR_CUSTOM_ACCESS_DENIED
  6673. #
  6674. # Alternatively you can tell Squid to reset the TCP connection
  6675. # by specifying TCP_RESET.
  6676. #
  6677. # Or you can specify an error URL or URL pattern. The browsers will
  6678. # get redirected to the specified URL after formatting tags have
  6679. # been replaced. Redirect will be done with 302 or 307 according to
  6680. # HTTP/1.1 specs. A different 3xx code may be specified by prefixing
  6681. # the URL. e.g. 303:http://example.com/
  6682. #
  6683. # URL FORMAT TAGS:
  6684. # %a - username (if available. Password NOT included)
  6685. # %B - FTP path URL
  6686. # %e - Error number
  6687. # %E - Error description
  6688. # %h - Squid hostname
  6689. # %H - Request domain name
  6690. # %i - Client IP Address
  6691. # %M - Request Method
  6692. # %o - Message result from external ACL helper
  6693. # %p - Request Port number
  6694. # %P - Request Protocol name
  6695. # %R - Request URL path
  6696. # %T - Timestamp in RFC 1123 format
  6697. # %U - Full canonical URL from client
  6698. # (HTTPS URLs terminate with *)
  6699. # %u - Full canonical URL from client
  6700. # %w - Admin email from squid.conf
  6701. # %x - Error name
  6702. # %% - Literal percent (%) code
  6703. #
  6704. #Default:
  6705. # none
  6706.  
  6707. # OPTIONS INFLUENCING REQUEST FORWARDING
  6708. # -----------------------------------------------------------------------------
  6709.  
  6710. # TAG: nonhierarchical_direct
  6711. # By default, Squid will send any non-hierarchical requests
  6712. # (not cacheable request type) direct to origin servers.
  6713. #
  6714. # When this is set to "off", Squid will prefer to send these
  6715. # requests to parents.
  6716. #
  6717. # Note that in most configurations, by turning this off you will only
  6718. # add latency to these request without any improvement in global hit
  6719. # ratio.
  6720. #
  6721. # This option only sets a preference. If the parent is unavailable a
  6722. # direct connection to the origin server may still be attempted. To
  6723. # completely prevent direct connections use never_direct.
  6724. #Default:
  6725. # nonhierarchical_direct on
  6726.  
  6727. # TAG: prefer_direct
  6728. # Normally Squid tries to use parents for most requests. If you for some
  6729. # reason like it to first try going direct and only use a parent if
  6730. # going direct fails set this to on.
  6731. #
  6732. # By combining nonhierarchical_direct off and prefer_direct on you
  6733. # can set up Squid to use a parent as a backup path if going direct
  6734. # fails.
  6735. #
  6736. # Note: If you want Squid to use parents for all requests see
  6737. # the never_direct directive. prefer_direct only modifies how Squid
  6738. # acts on cacheable requests.
  6739. #Default:
  6740. # prefer_direct off
  6741.  
  6742. # TAG: cache_miss_revalidate on|off
  6743. # RFC 7232 defines a conditional request mechanism to prevent
  6744. # response objects being unnecessarily transferred over the network.
  6745. # If that mechanism is used by the client and a cache MISS occurs
  6746. # it can prevent new cache entries being created.
  6747. #
  6748. # This option determines whether Squid on cache MISS will pass the
  6749. # client revalidation request to the server or tries to fetch new
  6750. # content for caching. It can be useful while the cache is mostly
  6751. # empty to more quickly have the cache populated by generating
  6752. # non-conditional GETs.
  6753. #
  6754. # When set to 'on' (default), Squid will pass all client If-* headers
  6755. # to the server. This permits server responses without a cacheable
  6756. # payload to be delivered and on MISS no new cache entry is created.
  6757. #
  6758. # When set to 'off' and if the request is cacheable, Squid will
  6759. # remove the clients If-Modified-Since and If-None-Match headers from
  6760. # the request sent to the server. This requests a 200 status response
  6761. # from the server to create a new cache entry with.
  6762. #Default:
  6763. # cache_miss_revalidate on
  6764.  
  6765. # TAG: always_direct
  6766. # Usage: always_direct allow|deny [!]aclname ...
  6767. #
  6768. # Here you can use ACL elements to specify requests which should
  6769. # ALWAYS be forwarded by Squid to the origin servers without using
  6770. # any peers. For example, to always directly forward requests for
  6771. # local servers ignoring any parents or siblings you may have use
  6772. # something like:
  6773. #
  6774. # acl local-servers dstdomain my.domain.net
  6775. # always_direct allow local-servers
  6776. #
  6777. # To always forward FTP requests directly, use
  6778. #
  6779. # acl FTP proto FTP
  6780. # always_direct allow FTP
  6781. #
  6782. # NOTE: There is a similar, but opposite option named
  6783. # 'never_direct'. You need to be aware that "always_direct deny
  6784. # foo" is NOT the same thing as "never_direct allow foo". You
  6785. # may need to use a deny rule to exclude a more-specific case of
  6786. # some other rule. Example:
  6787. #
  6788. # acl local-external dstdomain external.foo.net
  6789. # acl local-servers dstdomain .foo.net
  6790. # always_direct deny local-external
  6791. # always_direct allow local-servers
  6792. #
  6793. # NOTE: If your goal is to make the client forward the request
  6794. # directly to the origin server bypassing Squid then this needs
  6795. # to be done in the client configuration. Squid configuration
  6796. # can only tell Squid how Squid should fetch the object.
  6797. #
  6798. # NOTE: This directive is not related to caching. The replies
  6799. # is cached as usual even if you use always_direct. To not cache
  6800. # the replies see the 'cache' directive.
  6801. #
  6802. # This clause supports both fast and slow acl types.
  6803. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  6804. #Default:
  6805. # Prevent any cache_peer being used for this request.
  6806.  
  6807. # TAG: never_direct
  6808. # Usage: never_direct allow|deny [!]aclname ...
  6809. #
  6810. # never_direct is the opposite of always_direct. Please read
  6811. # the description for always_direct if you have not already.
  6812. #
  6813. # With 'never_direct' you can use ACL elements to specify
  6814. # requests which should NEVER be forwarded directly to origin
  6815. # servers. For example, to force the use of a proxy for all
  6816. # requests, except those in your local domain use something like:
  6817. #
  6818. # acl local-servers dstdomain .foo.net
  6819. # never_direct deny local-servers
  6820. # never_direct allow all
  6821. #
  6822. # or if Squid is inside a firewall and there are local intranet
  6823. # servers inside the firewall use something like:
  6824. #
  6825. # acl local-intranet dstdomain .foo.net
  6826. # acl local-external dstdomain external.foo.net
  6827. # always_direct deny local-external
  6828. # always_direct allow local-intranet
  6829. # never_direct allow all
  6830. #
  6831. # This clause supports both fast and slow acl types.
  6832. # See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
  6833. #Default:
  6834. # Allow DNS results to be used for this request.
  6835.  
  6836. # ADVANCED NETWORKING OPTIONS
  6837. # -----------------------------------------------------------------------------
  6838.  
  6839. # TAG: incoming_udp_average
  6840. # Heavy voodoo here. I can't even believe you are reading this.
  6841. # Are you crazy? Don't even think about adjusting these unless
  6842. # you understand the algorithms in comm_select.c first!
  6843. #Default:
  6844. # incoming_udp_average 6
  6845.  
  6846. # TAG: incoming_tcp_average
  6847. # Heavy voodoo here. I can't even believe you are reading this.
  6848. # Are you crazy? Don't even think about adjusting these unless
  6849. # you understand the algorithms in comm_select.c first!
  6850. #Default:
  6851. # incoming_tcp_average 4
  6852.  
  6853. # TAG: incoming_dns_average
  6854. # Heavy voodoo here. I can't even believe you are reading this.
  6855. # Are you crazy? Don't even think about adjusting these unless
  6856. # you understand the algorithms in comm_select.c first!
  6857. #Default:
  6858. # incoming_dns_average 4
  6859.  
  6860. # TAG: min_udp_poll_cnt
  6861. # Heavy voodoo here. I can't even believe you are reading this.
  6862. # Are you crazy? Don't even think about adjusting these unless
  6863. # you understand the algorithms in comm_select.c first!
  6864. #Default:
  6865. # min_udp_poll_cnt 8
  6866.  
  6867. # TAG: min_dns_poll_cnt
  6868. # Heavy voodoo here. I can't even believe you are reading this.
  6869. # Are you crazy? Don't even think about adjusting these unless
  6870. # you understand the algorithms in comm_select.c first!
  6871. #Default:
  6872. # min_dns_poll_cnt 8
  6873.  
  6874. # TAG: min_tcp_poll_cnt
  6875. # Heavy voodoo here. I can't even believe you are reading this.
  6876. # Are you crazy? Don't even think about adjusting these unless
  6877. # you understand the algorithms in comm_select.c first!
  6878. #Default:
  6879. # min_tcp_poll_cnt 8
  6880.  
  6881. # TAG: accept_filter
  6882. # FreeBSD:
  6883. #
  6884. # The name of an accept(2) filter to install on Squid's
  6885. # listen socket(s). This feature is perhaps specific to
  6886. # FreeBSD and requires support in the kernel.
  6887. #
  6888. # The 'httpready' filter delays delivering new connections
  6889. # to Squid until a full HTTP request has been received.
  6890. # See the accf_http(9) man page for details.
  6891. #
  6892. # The 'dataready' filter delays delivering new connections
  6893. # to Squid until there is some data to process.
  6894. # See the accf_dataready(9) man page for details.
  6895. #
  6896. # Linux:
  6897. #
  6898. # The 'data' filter delays delivering of new connections
  6899. # to Squid until there is some data to process by TCP_ACCEPT_DEFER.
  6900. # You may optionally specify a number of seconds to wait by
  6901. # 'data=N' where N is the number of seconds. Defaults to 30
  6902. # if not specified. See the tcp(7) man page for details.
  6903. #EXAMPLE:
  6904. ## FreeBSD
  6905. #accept_filter httpready
  6906. ## Linux
  6907. #accept_filter data
  6908. #Default:
  6909. # none
  6910.  
  6911. # TAG: client_ip_max_connections
  6912. # Set an absolute limit on the number of connections a single
  6913. # client IP can use. Any more than this and Squid will begin to drop
  6914. # new connections from the client until it closes some links.
  6915. #
  6916. # Note that this is a global limit. It affects all HTTP, HTCP, Gopher and FTP
  6917. # connections from the client. For finer control use the ACL access controls.
  6918. #
  6919. # Requires client_db to be enabled (the default).
  6920. #
  6921. # WARNING: This may noticably slow down traffic received via external proxies
  6922. # or NAT devices and cause them to rebound error messages back to their clients.
  6923. #Default:
  6924. # No limit.
  6925.  
  6926. # TAG: tcp_recv_bufsize (bytes)
  6927. # Size of receive buffer to set for TCP sockets. Probably just
  6928. # as easy to change your kernel's default.
  6929. # Omit from squid.conf to use the default buffer size.
  6930. #Default:
  6931. # Use operating system TCP defaults.
  6932.  
  6933. # ICAP OPTIONS
  6934. # -----------------------------------------------------------------------------
  6935.  
  6936. # TAG: icap_enable on|off
  6937. # If you want to enable the ICAP module support, set this to on.
  6938. #Default:
  6939. # icap_enable off
  6940.  
  6941. # TAG: icap_connect_timeout
  6942. # This parameter specifies how long to wait for the TCP connect to
  6943. # the requested ICAP server to complete before giving up and either
  6944. # terminating the HTTP transaction or bypassing the failure.
  6945. #
  6946. # The default for optional services is peer_connect_timeout.
  6947. # The default for essential services is connect_timeout.
  6948. # If this option is explicitly set, its value applies to all services.
  6949. #Default:
  6950. # none
  6951.  
  6952. # TAG: icap_io_timeout time-units
  6953. # This parameter specifies how long to wait for an I/O activity on
  6954. # an established, active ICAP connection before giving up and
  6955. # either terminating the HTTP transaction or bypassing the
  6956. # failure.
  6957. #Default:
  6958. # Use read_timeout.
  6959.  
  6960. # TAG: icap_service_failure_limit limit [in memory-depth time-units]
  6961. # The limit specifies the number of failures that Squid tolerates
  6962. # when establishing a new TCP connection with an ICAP service. If
  6963. # the number of failures exceeds the limit, the ICAP service is
  6964. # not used for new ICAP requests until it is time to refresh its
  6965. # OPTIONS.
  6966. #
  6967. # A negative value disables the limit. Without the limit, an ICAP
  6968. # service will not be considered down due to connectivity failures
  6969. # between ICAP OPTIONS requests.
  6970. #
  6971. # Squid forgets ICAP service failures older than the specified
  6972. # value of memory-depth. The memory fading algorithm
  6973. # is approximate because Squid does not remember individual
  6974. # errors but groups them instead, splitting the option
  6975. # value into ten time slots of equal length.
  6976. #
  6977. # When memory-depth is 0 and by default this option has no
  6978. # effect on service failure expiration.
  6979. #
  6980. # Squid always forgets failures when updating service settings
  6981. # using an ICAP OPTIONS transaction, regardless of this option
  6982. # setting.
  6983. #
  6984. # For example,
  6985. # # suspend service usage after 10 failures in 5 seconds:
  6986. # icap_service_failure_limit 10 in 5 seconds
  6987. #Default:
  6988. # icap_service_failure_limit 10
  6989.  
  6990. # TAG: icap_service_revival_delay
  6991. # The delay specifies the number of seconds to wait after an ICAP
  6992. # OPTIONS request failure before requesting the options again. The
  6993. # failed ICAP service is considered "down" until fresh OPTIONS are
  6994. # fetched.
  6995. #
  6996. # The actual delay cannot be smaller than the hardcoded minimum
  6997. # delay of 30 seconds.
  6998. #Default:
  6999. # icap_service_revival_delay 180
  7000.  
  7001. # TAG: icap_preview_enable on|off
  7002. # The ICAP Preview feature allows the ICAP server to handle the
  7003. # HTTP message by looking only at the beginning of the message body
  7004. # or even without receiving the body at all. In some environments,
  7005. # previews greatly speedup ICAP processing.
  7006. #
  7007. # During an ICAP OPTIONS transaction, the server may tell Squid what
  7008. # HTTP messages should be previewed and how big the preview should be.
  7009. # Squid will not use Preview if the server did not request one.
  7010. #
  7011. # To disable ICAP Preview for all ICAP services, regardless of
  7012. # individual ICAP server OPTIONS responses, set this option to "off".
  7013. #Example:
  7014. #icap_preview_enable off
  7015. #Default:
  7016. # icap_preview_enable on
  7017.  
  7018. # TAG: icap_preview_size
  7019. # The default size of preview data to be sent to the ICAP server.
  7020. # This value might be overwritten on a per server basis by OPTIONS requests.
  7021. #Default:
  7022. # No preview sent.
  7023.  
  7024. # TAG: icap_206_enable on|off
  7025. # 206 (Partial Content) responses is an ICAP extension that allows the
  7026. # ICAP agents to optionally combine adapted and original HTTP message
  7027. # content. The decision to combine is postponed until the end of the
  7028. # ICAP response. Squid supports Partial Content extension by default.
  7029. #
  7030. # Activation of the Partial Content extension is negotiated with each
  7031. # ICAP service during OPTIONS exchange. Most ICAP servers should handle
  7032. # negotation correctly even if they do not support the extension, but
  7033. # some might fail. To disable Partial Content support for all ICAP
  7034. # services and to avoid any negotiation, set this option to "off".
  7035. #
  7036. # Example:
  7037. # icap_206_enable off
  7038. #Default:
  7039. # icap_206_enable on
  7040.  
  7041. # TAG: icap_default_options_ttl
  7042. # The default TTL value for ICAP OPTIONS responses that don't have
  7043. # an Options-TTL header.
  7044. #Default:
  7045. # icap_default_options_ttl 60
  7046.  
  7047. # TAG: icap_persistent_connections on|off
  7048. # Whether or not Squid should use persistent connections to
  7049. # an ICAP server.
  7050. #Default:
  7051. # icap_persistent_connections on
  7052.  
  7053. # TAG: adaptation_send_client_ip on|off
  7054. # If enabled, Squid shares HTTP client IP information with adaptation
  7055. # services. For ICAP, Squid adds the X-Client-IP header to ICAP requests.
  7056. # For eCAP, Squid sets the libecap::metaClientIp transaction option.
  7057. #
  7058. # See also: adaptation_uses_indirect_client
  7059. #Default:
  7060. # adaptation_send_client_ip off
  7061.  
  7062. # TAG: adaptation_send_username on|off
  7063. # This sends authenticated HTTP client username (if available) to
  7064. # the adaptation service.
  7065. #
  7066. # For ICAP, the username value is encoded based on the
  7067. # icap_client_username_encode option and is sent using the header
  7068. # specified by the icap_client_username_header option.
  7069. #Default:
  7070. # adaptation_send_username off
  7071.  
  7072. # TAG: icap_client_username_header
  7073. # ICAP request header name to use for adaptation_send_username.
  7074. #Default:
  7075. # icap_client_username_header X-Client-Username
  7076.  
  7077. # TAG: icap_client_username_encode on|off
  7078. # Whether to base64 encode the authenticated client username.
  7079. #Default:
  7080. # icap_client_username_encode off
  7081.  
  7082. # TAG: icap_service
  7083. # Defines a single ICAP service using the following format:
  7084. #
  7085. # icap_service id vectoring_point uri [option ...]
  7086. #
  7087. # id: ID
  7088. # an opaque identifier or name which is used to direct traffic to
  7089. # this specific service. Must be unique among all adaptation
  7090. # services in squid.conf.
  7091. #
  7092. # vectoring_point: reqmod_precache|reqmod_postcache|respmod_precache|respmod_postcache
  7093. # This specifies at which point of transaction processing the
  7094. # ICAP service should be activated. *_postcache vectoring points
  7095. # are not yet supported.
  7096. #
  7097. # uri: icap://servername:port/servicepath
  7098. # ICAP server and service location.
  7099. #
  7100. # ICAP does not allow a single service to handle both REQMOD and RESPMOD
  7101. # transactions. Squid does not enforce that requirement. You can specify
  7102. # services with the same service_url and different vectoring_points. You
  7103. # can even specify multiple identical services as long as their
  7104. # service_names differ.
  7105. #
  7106. # To activate a service, use the adaptation_access directive. To group
  7107. # services, use adaptation_service_chain and adaptation_service_set.
  7108. #
  7109. # Service options are separated by white space. ICAP services support
  7110. # the following name=value options:
  7111. #
  7112. # bypass=on|off|1|0
  7113. # If set to 'on' or '1', the ICAP service is treated as
  7114. # optional. If the service cannot be reached or malfunctions,
  7115. # Squid will try to ignore any errors and process the message as
  7116. # if the service was not enabled. No all ICAP errors can be
  7117. # bypassed. If set to 0, the ICAP service is treated as
  7118. # essential and all ICAP errors will result in an error page
  7119. # returned to the HTTP client.
  7120. #
  7121. # Bypass is off by default: services are treated as essential.
  7122. #
  7123. # routing=on|off|1|0
  7124. # If set to 'on' or '1', the ICAP service is allowed to
  7125. # dynamically change the current message adaptation plan by
  7126. # returning a chain of services to be used next. The services
  7127. # are specified using the X-Next-Services ICAP response header
  7128. # value, formatted as a comma-separated list of service names.
  7129. # Each named service should be configured in squid.conf. Other
  7130. # services are ignored. An empty X-Next-Services value results
  7131. # in an empty plan which ends the current adaptation.
  7132. #
  7133. # Dynamic adaptation plan may cross or cover multiple supported
  7134. # vectoring points in their natural processing order.
  7135. #
  7136. # Routing is not allowed by default: the ICAP X-Next-Services
  7137. # response header is ignored.
  7138. #
  7139. # ipv6=on|off
  7140. # Only has effect on split-stack systems. The default on those systems
  7141. # is to use IPv4-only connections. When set to 'on' this option will
  7142. # make Squid use IPv6-only connections to contact this ICAP service.
  7143. #
  7144. # on-overload=block|bypass|wait|force
  7145. # If the service Max-Connections limit has been reached, do
  7146. # one of the following for each new ICAP transaction:
  7147. # * block: send an HTTP error response to the client
  7148. # * bypass: ignore the "over-connected" ICAP service
  7149. # * wait: wait (in a FIFO queue) for an ICAP connection slot
  7150. # * force: proceed, ignoring the Max-Connections limit
  7151. #
  7152. # In SMP mode with N workers, each worker assumes the service
  7153. # connection limit is Max-Connections/N, even though not all
  7154. # workers may use a given service.
  7155. #
  7156. # The default value is "bypass" if service is bypassable,
  7157. # otherwise it is set to "wait".
  7158. #
  7159. #
  7160. # max-conn=number
  7161. # Use the given number as the Max-Connections limit, regardless
  7162. # of the Max-Connections value given by the service, if any.
  7163. #
  7164. # Older icap_service format without optional named parameters is
  7165. # deprecated but supported for backward compatibility.
  7166. #
  7167. #Example:
  7168. #icap_service svcBlocker reqmod_precache icap://icap1.mydomain.net:1344/reqmod bypass=0
  7169. #icap_service svcLogger reqmod_precache icap://icap2.mydomain.net:1344/respmod routing=on
  7170. #Default:
  7171. # none
  7172.  
  7173. # TAG: icap_class
  7174. # This deprecated option was documented to define an ICAP service
  7175. # chain, even though it actually defined a set of similar, redundant
  7176. # services, and the chains were not supported.
  7177. #
  7178. # To define a set of redundant services, please use the
  7179. # adaptation_service_set directive. For service chains, use
  7180. # adaptation_service_chain.
  7181. #Default:
  7182. # none
  7183.  
  7184. # TAG: icap_access
  7185. # This option is deprecated. Please use adaptation_access, which
  7186. # has the same ICAP functionality, but comes with better
  7187. # documentation, and eCAP support.
  7188. #Default:
  7189. # none
  7190.  
  7191. # eCAP OPTIONS
  7192. # -----------------------------------------------------------------------------
  7193.  
  7194. # TAG: ecap_enable on|off
  7195. # Controls whether eCAP support is enabled.
  7196. #Default:
  7197. # ecap_enable off
  7198.  
  7199. # TAG: ecap_service
  7200. # Defines a single eCAP service
  7201. #
  7202. # ecap_service id vectoring_point uri [option ...]
  7203. #
  7204. # id: ID
  7205. # an opaque identifier or name which is used to direct traffic to
  7206. # this specific service. Must be unique among all adaptation
  7207. # services in squid.conf.
  7208. #
  7209. # vectoring_point: reqmod_precache|reqmod_postcache|respmod_precache|respmod_postcache
  7210. # This specifies at which point of transaction processing the
  7211. # eCAP service should be activated. *_postcache vectoring points
  7212. # are not yet supported.
  7213. #
  7214. # uri: ecap://vendor/service_name?custom&cgi=style&parameters=optional
  7215. # Squid uses the eCAP service URI to match this configuration
  7216. # line with one of the dynamically loaded services. Each loaded
  7217. # eCAP service must have a unique URI. Obtain the right URI from
  7218. # the service provider.
  7219. #
  7220. # To activate a service, use the adaptation_access directive. To group
  7221. # services, use adaptation_service_chain and adaptation_service_set.
  7222. #
  7223. # Service options are separated by white space. eCAP services support
  7224. # the following name=value options:
  7225. #
  7226. # bypass=on|off|1|0
  7227. # If set to 'on' or '1', the eCAP service is treated as optional.
  7228. # If the service cannot be reached or malfunctions, Squid will try
  7229. # to ignore any errors and process the message as if the service
  7230. # was not enabled. No all eCAP errors can be bypassed.
  7231. # If set to 'off' or '0', the eCAP service is treated as essential
  7232. # and all eCAP errors will result in an error page returned to the
  7233. # HTTP client.
  7234. #
  7235. # Bypass is off by default: services are treated as essential.
  7236. #
  7237. # routing=on|off|1|0
  7238. # If set to 'on' or '1', the eCAP service is allowed to
  7239. # dynamically change the current message adaptation plan by
  7240. # returning a chain of services to be used next.
  7241. #
  7242. # Dynamic adaptation plan may cross or cover multiple supported
  7243. # vectoring points in their natural processing order.
  7244. #
  7245. # Routing is not allowed by default.
  7246. #
  7247. # Older ecap_service format without optional named parameters is
  7248. # deprecated but supported for backward compatibility.
  7249. #
  7250. #
  7251. #Example:
  7252. #ecap_service s1 reqmod_precache ecap://filters.R.us/leakDetector?on_error=block bypass=off
  7253. #ecap_service s2 respmod_precache ecap://filters.R.us/virusFilter config=/etc/vf.cfg bypass=on
  7254. #Default:
  7255. # none
  7256.  
  7257. # TAG: loadable_modules
  7258. # Instructs Squid to load the specified dynamic module(s) or activate
  7259. # preloaded module(s).
  7260. #Example:
  7261. #loadable_modules /usr/lib/MinimalAdapter.so
  7262. #Default:
  7263. # none
  7264.  
  7265. # MESSAGE ADAPTATION OPTIONS
  7266. # -----------------------------------------------------------------------------
  7267.  
  7268. # TAG: adaptation_service_set
  7269. #
  7270. # Configures an ordered set of similar, redundant services. This is
  7271. # useful when hot standby or backup adaptation servers are available.
  7272. #
  7273. # adaptation_service_set set_name service_name1 service_name2 ...
  7274. #
  7275. # The named services are used in the set declaration order. The first
  7276. # applicable adaptation service from the set is used first. The next
  7277. # applicable service is tried if and only if the transaction with the
  7278. # previous service fails and the message waiting to be adapted is still
  7279. # intact.
  7280. #
  7281. # When adaptation starts, broken services are ignored as if they were
  7282. # not a part of the set. A broken service is a down optional service.
  7283. #
  7284. # The services in a set must be attached to the same vectoring point
  7285. # (e.g., pre-cache) and use the same adaptation method (e.g., REQMOD).
  7286. #
  7287. # If all services in a set are optional then adaptation failures are
  7288. # bypassable. If all services in the set are essential, then a
  7289. # transaction failure with one service may still be retried using
  7290. # another service from the set, but when all services fail, the master
  7291. # transaction fails as well.
  7292. #
  7293. # A set may contain a mix of optional and essential services, but that
  7294. # is likely to lead to surprising results because broken services become
  7295. # ignored (see above), making previously bypassable failures fatal.
  7296. # Technically, it is the bypassability of the last failed service that
  7297. # matters.
  7298. #
  7299. # See also: adaptation_access adaptation_service_chain
  7300. #
  7301. #Example:
  7302. #adaptation_service_set svcBlocker urlFilterPrimary urlFilterBackup
  7303. #adaptation service_set svcLogger loggerLocal loggerRemote
  7304. #Default:
  7305. # none
  7306.  
  7307. # TAG: adaptation_service_chain
  7308. #
  7309. # Configures a list of complementary services that will be applied
  7310. # one-by-one, forming an adaptation chain or pipeline. This is useful
  7311. # when Squid must perform different adaptations on the same message.
  7312. #
  7313. # adaptation_service_chain chain_name service_name1 svc_name2 ...
  7314. #
  7315. # The named services are used in the chain declaration order. The first
  7316. # applicable adaptation service from the chain is used first. The next
  7317. # applicable service is applied to the successful adaptation results of
  7318. # the previous service in the chain.
  7319. #
  7320. # When adaptation starts, broken services are ignored as if they were
  7321. # not a part of the chain. A broken service is a down optional service.
  7322. #
  7323. # Request satisfaction terminates the adaptation chain because Squid
  7324. # does not currently allow declaration of RESPMOD services at the
  7325. # "reqmod_precache" vectoring point (see icap_service or ecap_service).
  7326. #
  7327. # The services in a chain must be attached to the same vectoring point
  7328. # (e.g., pre-cache) and use the same adaptation method (e.g., REQMOD).
  7329. #
  7330. # A chain may contain a mix of optional and essential services. If an
  7331. # essential adaptation fails (or the failure cannot be bypassed for
  7332. # other reasons), the master transaction fails. Otherwise, the failure
  7333. # is bypassed as if the failed adaptation service was not in the chain.
  7334. #
  7335. # See also: adaptation_access adaptation_service_set
  7336. #
  7337. #Example:
  7338. #adaptation_service_chain svcRequest requestLogger urlFilter leakDetector
  7339. #Default:
  7340. # none
  7341.  
  7342. # TAG: adaptation_access
  7343. # Sends an HTTP transaction to an ICAP or eCAP adaptation service.
  7344. #
  7345. # adaptation_access service_name allow|deny [!]aclname...
  7346. # adaptation_access set_name allow|deny [!]aclname...
  7347. #
  7348. # At each supported vectoring point, the adaptation_access
  7349. # statements are processed in the order they appear in this
  7350. # configuration file. Statements pointing to the following services
  7351. # are ignored (i.e., skipped without checking their ACL):
  7352. #
  7353. # - services serving different vectoring points
  7354. # - "broken-but-bypassable" services
  7355. # - "up" services configured to ignore such transactions
  7356. # (e.g., based on the ICAP Transfer-Ignore header).
  7357. #
  7358. # When a set_name is used, all services in the set are checked
  7359. # using the same rules, to find the first applicable one. See
  7360. # adaptation_service_set for details.
  7361. #
  7362. # If an access list is checked and there is a match, the
  7363. # processing stops: For an "allow" rule, the corresponding
  7364. # adaptation service is used for the transaction. For a "deny"
  7365. # rule, no adaptation service is activated.
  7366. #
  7367. # It is currently not possible to apply more than one adaptation
  7368. # service at the same vectoring point to the same HTTP transaction.
  7369. #
  7370. # See also: icap_service and ecap_service
  7371. #
  7372. #Example:
  7373. #adaptation_access service_1 allow all
  7374. #Default:
  7375. # Allow, unless rules exist in squid.conf.
  7376.  
  7377. # TAG: adaptation_service_iteration_limit
  7378. # Limits the number of iterations allowed when applying adaptation
  7379. # services to a message. If your longest adaptation set or chain
  7380. # may have more than 16 services, increase the limit beyond its
  7381. # default value of 16. If detecting infinite iteration loops sooner
  7382. # is critical, make the iteration limit match the actual number
  7383. # of services in your longest adaptation set or chain.
  7384. #
  7385. # Infinite adaptation loops are most likely with routing services.
  7386. #
  7387. # See also: icap_service routing=1
  7388. #Default:
  7389. # adaptation_service_iteration_limit 16
  7390.  
  7391. # TAG: adaptation_masterx_shared_names
  7392. # For each master transaction (i.e., the HTTP request and response
  7393. # sequence, including all related ICAP and eCAP exchanges), Squid
  7394. # maintains a table of metadata. The table entries are (name, value)
  7395. # pairs shared among eCAP and ICAP exchanges. The table is destroyed
  7396. # with the master transaction.
  7397. #
  7398. # This option specifies the table entry names that Squid must accept
  7399. # from and forward to the adaptation transactions.
  7400. #
  7401. # An ICAP REQMOD or RESPMOD transaction may set an entry in the
  7402. # shared table by returning an ICAP header field with a name
  7403. # specified in adaptation_masterx_shared_names.
  7404. #
  7405. # An eCAP REQMOD or RESPMOD transaction may set an entry in the
  7406. # shared table by implementing the libecap::visitEachOption() API
  7407. # to provide an option with a name specified in
  7408. # adaptation_masterx_shared_names.
  7409. #
  7410. # Squid will store and forward the set entry to subsequent adaptation
  7411. # transactions within the same master transaction scope.
  7412. #
  7413. # Only one shared entry name is supported at this time.
  7414. #
  7415. #Example:
  7416. ## share authentication information among ICAP services
  7417. #adaptation_masterx_shared_names X-Subscriber-ID
  7418. #Default:
  7419. # none
  7420.  
  7421. # TAG: adaptation_meta
  7422. # This option allows Squid administrator to add custom ICAP request
  7423. # headers or eCAP options to Squid ICAP requests or eCAP transactions.
  7424. # Use it to pass custom authentication tokens and other
  7425. # transaction-state related meta information to an ICAP/eCAP service.
  7426. #
  7427. # The addition of a meta header is ACL-driven:
  7428. # adaptation_meta name value [!]aclname ...
  7429. #
  7430. # Processing for a given header name stops after the first ACL list match.
  7431. # Thus, it is impossible to add two headers with the same name. If no ACL
  7432. # lists match for a given header name, no such header is added. For
  7433. # example:
  7434. #
  7435. # # do not debug transactions except for those that need debugging
  7436. # adaptation_meta X-Debug 1 needs_debugging
  7437. #
  7438. # # log all transactions except for those that must remain secret
  7439. # adaptation_meta X-Log 1 !keep_secret
  7440. #
  7441. # # mark transactions from users in the "G 1" group
  7442. # adaptation_meta X-Authenticated-Groups "G 1" authed_as_G1
  7443. #
  7444. # The "value" parameter may be a regular squid.conf token or a "double
  7445. # quoted string". Within the quoted string, use backslash (\) to escape
  7446. # any character, which is currently only useful for escaping backslashes
  7447. # and double quotes. For example,
  7448. # "this string has one backslash (\\) and two \"quotes\""
  7449. #
  7450. # Used adaptation_meta header values may be logged via %note
  7451. # logformat code. If multiple adaptation_meta headers with the same name
  7452. # are used during master transaction lifetime, the header values are
  7453. # logged in the order they were used and duplicate values are ignored
  7454. # (only the first repeated value will be logged).
  7455. #Default:
  7456. # none
  7457.  
  7458. # TAG: icap_retry
  7459. # This ACL determines which retriable ICAP transactions are
  7460. # retried. Transactions that received a complete ICAP response
  7461. # and did not have to consume or produce HTTP bodies to receive
  7462. # that response are usually retriable.
  7463. #
  7464. # icap_retry allow|deny [!]aclname ...
  7465. #
  7466. # Squid automatically retries some ICAP I/O timeouts and errors
  7467. # due to persistent connection race conditions.
  7468. #
  7469. # See also: icap_retry_limit
  7470. #Default:
  7471. # icap_retry deny all
  7472.  
  7473. # TAG: icap_retry_limit
  7474. # Limits the number of retries allowed.
  7475. #
  7476. # Communication errors due to persistent connection race
  7477. # conditions are unavoidable, automatically retried, and do not
  7478. # count against this limit.
  7479. #
  7480. # See also: icap_retry
  7481. #Default:
  7482. # No retries are allowed.
  7483.  
  7484. # DNS OPTIONS
  7485. # -----------------------------------------------------------------------------
  7486.  
  7487. # TAG: check_hostnames
  7488. # For security and stability reasons Squid can check
  7489. # hostnames for Internet standard RFC compliance. If you want
  7490. # Squid to perform these checks turn this directive on.
  7491. #Default:
  7492. # check_hostnames off
  7493.  
  7494. # TAG: allow_underscore
  7495. # Underscore characters is not strictly allowed in Internet hostnames
  7496. # but nevertheless used by many sites. Set this to off if you want
  7497. # Squid to be strict about the standard.
  7498. # This check is performed only when check_hostnames is set to on.
  7499. #Default:
  7500. # allow_underscore on
  7501.  
  7502. # TAG: dns_retransmit_interval
  7503. # Initial retransmit interval for DNS queries. The interval is
  7504. # doubled each time all configured DNS servers have been tried.
  7505. #Default:
  7506. # dns_retransmit_interval 5 seconds
  7507.  
  7508. # TAG: dns_timeout
  7509. # DNS Query timeout. If no response is received to a DNS query
  7510. # within this time all DNS servers for the queried domain
  7511. # are assumed to be unavailable.
  7512. #Default:
  7513. # dns_timeout 30 seconds
  7514.  
  7515. # TAG: dns_packet_max
  7516. # Maximum number of bytes packet size to advertise via EDNS.
  7517. # Set to "none" to disable EDNS large packet support.
  7518. #
  7519. # For legacy reasons DNS UDP replies will default to 512 bytes which
  7520. # is too small for many responses. EDNS provides a means for Squid to
  7521. # negotiate receiving larger responses back immediately without having
  7522. # to failover with repeat requests. Responses larger than this limit
  7523. # will retain the old behaviour of failover to TCP DNS.
  7524. #
  7525. # Squid has no real fixed limit internally, but allowing packet sizes
  7526. # over 1500 bytes requires network jumbogram support and is usually not
  7527. # necessary.
  7528. #
  7529. # WARNING: The RFC also indicates that some older resolvers will reply
  7530. # with failure of the whole request if the extension is added. Some
  7531. # resolvers have already been identified which will reply with mangled
  7532. # EDNS response on occasion. Usually in response to many-KB jumbogram
  7533. # sizes being advertised by Squid.
  7534. # Squid will currently treat these both as an unable-to-resolve domain
  7535. # even if it would be resolvable without EDNS.
  7536. #Default:
  7537. # EDNS disabled
  7538.  
  7539. # TAG: dns_defnames on|off
  7540. # Normally the RES_DEFNAMES resolver option is disabled
  7541. # (see res_init(3)). This prevents caches in a hierarchy
  7542. # from interpreting single-component hostnames locally. To allow
  7543. # Squid to handle single-component names, enable this option.
  7544. #Default:
  7545. # Search for single-label domain names is disabled.
  7546.  
  7547. # TAG: dns_multicast_local on|off
  7548. # When set to on, Squid sends multicast DNS lookups on the local
  7549. # network for domains ending in .local and .arpa.
  7550. # This enables local servers and devices to be contacted in an
  7551. # ad-hoc or zero-configuration network environment.
  7552. #Default:
  7553. # Search for .local and .arpa names is disabled.
  7554.  
  7555. # TAG: dns_nameservers
  7556. # Use this if you want to specify a list of DNS name servers
  7557. # (IP addresses) to use instead of those given in your
  7558. # /etc/resolv.conf file.
  7559. #
  7560. # On Windows platforms, if no value is specified here or in
  7561. # the /etc/resolv.conf file, the list of DNS name servers are
  7562. # taken from the Windows registry, both static and dynamic DHCP
  7563. # configurations are supported.
  7564. #
  7565. # Example: dns_nameservers 10.0.0.1 192.172.0.4
  7566. #Default:
  7567. # Use operating system definitions
  7568.  
  7569. # TAG: hosts_file
  7570. # Location of the host-local IP name-address associations
  7571. # database. Most Operating Systems have such a file on different
  7572. # default locations:
  7573. # - Un*X & Linux: /etc/hosts
  7574. # - Windows NT/2000: %SystemRoot%\system32\drivers\etc\hosts
  7575. # (%SystemRoot% value install default is c:\winnt)
  7576. # - Windows XP/2003: %SystemRoot%\system32\drivers\etc\hosts
  7577. # (%SystemRoot% value install default is c:\windows)
  7578. # - Windows 9x/Me: %windir%\hosts
  7579. # (%windir% value is usually c:\windows)
  7580. # - Cygwin: /etc/hosts
  7581. #
  7582. # The file contains newline-separated definitions, in the
  7583. # form ip_address_in_dotted_form name [name ...] names are
  7584. # whitespace-separated. Lines beginning with an hash (#)
  7585. # character are comments.
  7586. #
  7587. # The file is checked at startup and upon configuration.
  7588. # If set to 'none', it won't be checked.
  7589. # If append_domain is used, that domain will be added to
  7590. # domain-local (i.e. not containing any dot character) host
  7591. # definitions.
  7592. #Default:
  7593. # hosts_file /etc/hosts
  7594.  
  7595. # TAG: append_domain
  7596. # Appends local domain name to hostnames without any dots in
  7597. # them. append_domain must begin with a period.
  7598. #
  7599. # Be warned there are now Internet names with no dots in
  7600. # them using only top-domain names, so setting this may
  7601. # cause some Internet sites to become unavailable.
  7602. #
  7603. #Example:
  7604. # append_domain .yourdomain.com
  7605. #Default:
  7606. # Use operating system definitions
  7607.  
  7608. # TAG: ignore_unknown_nameservers
  7609. # By default Squid checks that DNS responses are received
  7610. # from the same IP addresses they are sent to. If they
  7611. # don't match, Squid ignores the response and writes a warning
  7612. # message to cache.log. You can allow responses from unknown
  7613. # nameservers by setting this option to 'off'.
  7614. #Default:
  7615. # ignore_unknown_nameservers on
  7616.  
  7617. # TAG: dns_v4_first
  7618. # With the IPv6 Internet being as fast or faster than IPv4 Internet
  7619. # for most networks Squid prefers to contact websites over IPv6.
  7620. #
  7621. # This option reverses the order of preference to make Squid contact
  7622. # dual-stack websites over IPv4 first. Squid will still perform both
  7623. # IPv6 and IPv4 DNS lookups before connecting.
  7624. #
  7625. # WARNING:
  7626. # This option will restrict the situations under which IPv6
  7627. # connectivity is used (and tested), potentially hiding network
  7628. # problems which would otherwise be detected and warned about.
  7629. #Default:
  7630. # dns_v4_first off
  7631.  
  7632. # TAG: ipcache_size (number of entries)
  7633. # Maximum number of DNS IP cache entries.
  7634. #Default:
  7635. # ipcache_size 1024
  7636.  
  7637. # TAG: ipcache_low (percent)
  7638. #Default:
  7639. # ipcache_low 90
  7640.  
  7641. # TAG: ipcache_high (percent)
  7642. # The size, low-, and high-water marks for the IP cache.
  7643. #Default:
  7644. # ipcache_high 95
  7645.  
  7646. # TAG: fqdncache_size (number of entries)
  7647. # Maximum number of FQDN cache entries.
  7648. #Default:
  7649. # fqdncache_size 1024
  7650.  
  7651. # MISCELLANEOUS
  7652. # -----------------------------------------------------------------------------
  7653.  
  7654. # TAG: configuration_includes_quoted_values on|off
  7655. # If set, Squid will recognize each "quoted string" after a configuration
  7656. # directive as a single parameter. The quotes are stripped before the
  7657. # parameter value is interpreted or used.
  7658. # See "Values with spaces, quotes, and other special characters"
  7659. # section for more details.
  7660. #Default:
  7661. # configuration_includes_quoted_values off
  7662.  
  7663. # TAG: memory_pools on|off
  7664. # If set, Squid will keep pools of allocated (but unused) memory
  7665. # available for future use. If memory is a premium on your
  7666. # system and you believe your malloc library outperforms Squid
  7667. # routines, disable this.
  7668. #Default:
  7669. # memory_pools on
  7670.  
  7671. # TAG: memory_pools_limit (bytes)
  7672. # Used only with memory_pools on:
  7673. # memory_pools_limit 50 MB
  7674. #
  7675. # If set to a non-zero value, Squid will keep at most the specified
  7676. # limit of allocated (but unused) memory in memory pools. All free()
  7677. # requests that exceed this limit will be handled by your malloc
  7678. # library. Squid does not pre-allocate any memory, just safe-keeps
  7679. # objects that otherwise would be free()d. Thus, it is safe to set
  7680. # memory_pools_limit to a reasonably high value even if your
  7681. # configuration will use less memory.
  7682. #
  7683. # If set to none, Squid will keep all memory it can. That is, there
  7684. # will be no limit on the total amount of memory used for safe-keeping.
  7685. #
  7686. # To disable memory allocation optimization, do not set
  7687. # memory_pools_limit to 0 or none. Set memory_pools to "off" instead.
  7688. #
  7689. # An overhead for maintaining memory pools is not taken into account
  7690. # when the limit is checked. This overhead is close to four bytes per
  7691. # object kept. However, pools may actually _save_ memory because of
  7692. # reduced memory thrashing in your malloc library.
  7693. #Default:
  7694. # memory_pools_limit 5 MB
  7695.  
  7696. # TAG: forwarded_for on|off|transparent|truncate|delete
  7697. # If set to "on", Squid will append your client's IP address
  7698. # in the HTTP requests it forwards. By default it looks like:
  7699. #
  7700. # X-Forwarded-For: 192.1.2.3
  7701. #
  7702. # If set to "off", it will appear as
  7703. #
  7704. # X-Forwarded-For: unknown
  7705. #
  7706. # If set to "transparent", Squid will not alter the
  7707. # X-Forwarded-For header in any way.
  7708. #
  7709. # If set to "delete", Squid will delete the entire
  7710. # X-Forwarded-For header.
  7711. #
  7712. # If set to "truncate", Squid will remove all existing
  7713. # X-Forwarded-For entries, and place the client IP as the sole entry.
  7714. #Default:
  7715. # forwarded_for on
  7716.  
  7717. # TAG: cachemgr_passwd
  7718. # Specify passwords for cachemgr operations.
  7719. #
  7720. # Usage: cachemgr_passwd password action action ...
  7721. #
  7722. # Some valid actions are (see cache manager menu for a full list):
  7723. # 5min
  7724. # 60min
  7725. # asndb
  7726. # authenticator
  7727. # cbdata
  7728. # client_list
  7729. # comm_incoming
  7730. # config *
  7731. # counters
  7732. # delay
  7733. # digest_stats
  7734. # dns
  7735. # events
  7736. # filedescriptors
  7737. # fqdncache
  7738. # histograms
  7739. # http_headers
  7740. # info
  7741. # io
  7742. # ipcache
  7743. # mem
  7744. # menu
  7745. # netdb
  7746. # non_peers
  7747. # objects
  7748. # offline_toggle *
  7749. # pconn
  7750. # peer_select
  7751. # reconfigure *
  7752. # redirector
  7753. # refresh
  7754. # server_list
  7755. # shutdown *
  7756. # store_digest
  7757. # storedir
  7758. # utilization
  7759. # via_headers
  7760. # vm_objects
  7761. #
  7762. # * Indicates actions which will not be performed without a
  7763. # valid password, others can be performed if not listed here.
  7764. #
  7765. # To disable an action, set the password to "disable".
  7766. # To allow performing an action without a password, set the
  7767. # password to "none".
  7768. #
  7769. # Use the keyword "all" to set the same password for all actions.
  7770. #
  7771. #Example:
  7772. # cachemgr_passwd secret shutdown
  7773. # cachemgr_passwd lesssssssecret info stats/objects
  7774. # cachemgr_passwd disable all
  7775. #Default:
  7776. # No password. Actions which require password are denied.
  7777.  
  7778. # TAG: client_db on|off
  7779. # If you want to disable collecting per-client statistics,
  7780. # turn off client_db here.
  7781. #Default:
  7782. # client_db on
  7783.  
  7784. # TAG: refresh_all_ims on|off
  7785. # When you enable this option, squid will always check
  7786. # the origin server for an update when a client sends an
  7787. # If-Modified-Since request. Many browsers use IMS
  7788. # requests when the user requests a reload, and this
  7789. # ensures those clients receive the latest version.
  7790. #
  7791. # By default (off), squid may return a Not Modified response
  7792. # based on the age of the cached version.
  7793. #Default:
  7794. # refresh_all_ims off
  7795.  
  7796. # TAG: reload_into_ims on|off
  7797. # When you enable this option, client no-cache or ``reload''
  7798. # requests will be changed to If-Modified-Since requests.
  7799. # Doing this VIOLATES the HTTP standard. Enabling this
  7800. # feature could make you liable for problems which it
  7801. # causes.
  7802. #
  7803. # see also refresh_pattern for a more selective approach.
  7804. #Default:
  7805. # reload_into_ims off
  7806.  
  7807. # TAG: connect_retries
  7808. # This sets the maximum number of connection attempts made for each
  7809. # TCP connection. The connect_retries attempts must all still
  7810. # complete within the connection timeout period.
  7811. #
  7812. # The default is not to re-try if the first connection attempt fails.
  7813. # The (not recommended) maximum is 10 tries.
  7814. #
  7815. # A warning message will be generated if it is set to a too-high
  7816. # value and the configured value will be over-ridden.
  7817. #
  7818. # Note: These re-tries are in addition to forward_max_tries
  7819. # which limit how many different addresses may be tried to find
  7820. # a useful server.
  7821. #Default:
  7822. # Do not retry failed connections.
  7823.  
  7824. # TAG: retry_on_error
  7825. # If set to ON Squid will automatically retry requests when
  7826. # receiving an error response with status 403 (Forbidden),
  7827. # 500 (Internal Error), 501 or 503 (Service not available).
  7828. # Status 502 and 504 (Gateway errors) are always retried.
  7829. #
  7830. # This is mainly useful if you are in a complex cache hierarchy to
  7831. # work around access control errors.
  7832. #
  7833. # NOTE: This retry will attempt to find another working destination.
  7834. # Which is different from the server which just failed.
  7835. #Default:
  7836. # retry_on_error off
  7837.  
  7838. # TAG: as_whois_server
  7839. # WHOIS server to query for AS numbers. NOTE: AS numbers are
  7840. # queried only when Squid starts up, not for every request.
  7841. #Default:
  7842. # as_whois_server whois.ra.net
  7843.  
  7844. # TAG: offline_mode
  7845. # Enable this option and Squid will never try to validate cached
  7846. # objects.
  7847. #Default:
  7848. # offline_mode off
  7849.  
  7850. # TAG: uri_whitespace
  7851. # What to do with requests that have whitespace characters in the
  7852. # URI. Options:
  7853. #
  7854. # strip: The whitespace characters are stripped out of the URL.
  7855. # This is the behavior recommended by RFC2396 and RFC3986
  7856. # for tolerant handling of generic URI.
  7857. # NOTE: This is one difference between generic URI and HTTP URLs.
  7858. #
  7859. # deny: The request is denied. The user receives an "Invalid
  7860. # Request" message.
  7861. # This is the behaviour recommended by RFC2616 for safe
  7862. # handling of HTTP request URL.
  7863. #
  7864. # allow: The request is allowed and the URI is not changed. The
  7865. # whitespace characters remain in the URI. Note the
  7866. # whitespace is passed to redirector processes if they
  7867. # are in use.
  7868. # Note this may be considered a violation of RFC2616
  7869. # request parsing where whitespace is prohibited in the
  7870. # URL field.
  7871. #
  7872. # encode: The request is allowed and the whitespace characters are
  7873. # encoded according to RFC1738.
  7874. #
  7875. # chop: The request is allowed and the URI is chopped at the
  7876. # first whitespace.
  7877. #
  7878. #
  7879. # NOTE the current Squid implementation of encode and chop violates
  7880. # RFC2616 by not using a 301 redirect after altering the URL.
  7881. #Default:
  7882. # uri_whitespace strip
  7883.  
  7884. # TAG: chroot
  7885. # Specifies a directory where Squid should do a chroot() while
  7886. # initializing. This also causes Squid to fully drop root
  7887. # privileges after initializing. This means, for example, if you
  7888. # use a HTTP port less than 1024 and try to reconfigure, you may
  7889. # get an error saying that Squid can not open the port.
  7890. #Default:
  7891. # none
  7892.  
  7893. # TAG: balance_on_multiple_ip
  7894. # Modern IP resolvers in squid sort lookup results by preferred access.
  7895. # By default squid will use these IP in order and only rotates to
  7896. # the next listed when the most preffered fails.
  7897. #
  7898. # Some load balancing servers based on round robin DNS have been
  7899. # found not to preserve user session state across requests
  7900. # to different IP addresses.
  7901. #
  7902. # Enabling this directive Squid rotates IP's per request.
  7903. #Default:
  7904. # balance_on_multiple_ip off
  7905.  
  7906. # TAG: pipeline_prefetch
  7907. # HTTP clients may send a pipeline of 1+N requests to Squid using a
  7908. # single connection, without waiting for Squid to respond to the first
  7909. # of those requests. This option limits the number of concurrent
  7910. # requests Squid will try to handle in parallel. If set to N, Squid
  7911. # will try to receive and process up to 1+N requests on the same
  7912. # connection concurrently.
  7913. #
  7914. # Defaults to 0 (off) for bandwidth management and access logging
  7915. # reasons.
  7916. #
  7917. # NOTE: pipelining requires persistent connections to clients.
  7918. #
  7919. # WARNING: pipelining breaks NTLM and Negotiate/Kerberos authentication.
  7920. #Default:
  7921. # Do not pre-parse pipelined requests.
  7922.  
  7923. # TAG: high_response_time_warning (msec)
  7924. # If the one-minute median response time exceeds this value,
  7925. # Squid prints a WARNING with debug level 0 to get the
  7926. # administrators attention. The value is in milliseconds.
  7927. #Default:
  7928. # disabled.
  7929.  
  7930. # TAG: high_page_fault_warning
  7931. # If the one-minute average page fault rate exceeds this
  7932. # value, Squid prints a WARNING with debug level 0 to get
  7933. # the administrators attention. The value is in page faults
  7934. # per second.
  7935. #Default:
  7936. # disabled.
  7937.  
  7938. # TAG: high_memory_warning
  7939. # Note: This option is only available if Squid is rebuilt with the
  7940. # GNU Malloc with mstats()
  7941. #
  7942. # If the memory usage (as determined by gnumalloc, if available and used)
  7943. # exceeds this amount, Squid prints a WARNING with debug level 0 to get
  7944. # the administrators attention.
  7945. #Default:
  7946. # disabled.
  7947.  
  7948. # TAG: sleep_after_fork (microseconds)
  7949. # When this is set to a non-zero value, the main Squid process
  7950. # sleeps the specified number of microseconds after a fork()
  7951. # system call. This sleep may help the situation where your
  7952. # system reports fork() failures due to lack of (virtual)
  7953. # memory. Note, however, if you have a lot of child
  7954. # processes, these sleep delays will add up and your
  7955. # Squid will not service requests for some amount of time
  7956. # until all the child processes have been started.
  7957. # On Windows value less then 1000 (1 milliseconds) are
  7958. # rounded to 1000.
  7959. #Default:
  7960. # sleep_after_fork 0
  7961.  
  7962. # TAG: windows_ipaddrchangemonitor on|off
  7963. # Note: This option is only available if Squid is rebuilt with the
  7964. # MS Windows
  7965. #
  7966. # On Windows Squid by default will monitor IP address changes and will
  7967. # reconfigure itself after any detected event. This is very useful for
  7968. # proxies connected to internet with dial-up interfaces.
  7969. # In some cases (a Proxy server acting as VPN gateway is one) it could be
  7970. # desiderable to disable this behaviour setting this to 'off'.
  7971. # Note: after changing this, Squid service must be restarted.
  7972. #Default:
  7973. # windows_ipaddrchangemonitor on
  7974.  
  7975. # TAG: eui_lookup
  7976. # Whether to lookup the EUI or MAC address of a connected client.
  7977. #Default:
  7978. # eui_lookup on
  7979.  
  7980. # TAG: max_filedescriptors
  7981. # Reduce the maximum number of filedescriptors supported below
  7982. # the usual operating system defaults.
  7983. #
  7984. # Remove from squid.conf to inherit the current ulimit setting.
  7985. #
  7986. # Note: Changing this requires a restart of Squid. Also
  7987. # not all I/O types supports large values (eg on Windows).
  7988. #Default:
  7989. # Use operating system limits set by ulimit.
  7990.  
  7991. #acl localnet src
  7992.  
  7993. #192.168.0.100/230 # test computer
  7994.  
  7995. #acl Safe_ports port 123 # Custom port
  7996.  
  7997. #auth_param basic program /usr/lib64/squid/basic_ncsa_auth /etc/squid/passwd
  7998.  
  7999. #auth_param basic children 5
  8000.  
  8001. #auth_param basic realm Squid Basic Authentication
  8002.  
  8003. #auth_param basic credentialsttl 2 hours
  8004.  
  8005. #acl auth_users proxy_auth REQUIRED
  8006.  
  8007. #http_access allow auth_users
  8008.  
  8009. acl blocked_websites dstdomain .msn.com .espn.com .yahoo.com
  8010.  
  8011. #http_access deny blocked_websites
  8012.  
  8013. cache_effective_group proxy
Add Comment
Please, Sign In to add comment