Documentation for 3.0.19, regenerated with the modified tidy changes
[privoxy.git] / doc / webserver / user-manual / config.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
2 "http://www.w3.org/TR/html4/loose.dtd">
3
4 <html>
5 <head>
6   <title>The Main Configuration File</title>
7   <meta name="GENERATOR" content=
8   "Modular DocBook HTML Stylesheet Version 1.79">
9   <link rel="HOME" title="Privoxy 3.0.19 User Manual" href="index.html">
10   <link rel="PREVIOUS" title="Privoxy Configuration" href=
11   "configuration.html">
12   <link rel="NEXT" title="Actions Files" href="actions-file.html">
13   <link rel="STYLESHEET" type="text/css" href="../p_doc.css">
14   <meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
15   <link rel="STYLESHEET" type="text/css" href="p_doc.css">
16 </head>
17
18 <body class="SECT1" bgcolor="#EEEEEE" text="#000000" link="#0000FF" vlink=
19 "#840084" alink="#0000FF">
20   <div class="NAVHEADER">
21     <table summary="Header navigation table" width="100%" border="0"
22     cellpadding="0" cellspacing="0">
23       <tr>
24         <th colspan="3" align="center">Privoxy 3.0.19 User Manual</th>
25       </tr>
26
27       <tr>
28         <td width="10%" align="left" valign="bottom"><a href=
29         "configuration.html" accesskey="P">Prev</a></td>
30
31         <td width="80%" align="center" valign="bottom"></td>
32
33         <td width="10%" align="right" valign="bottom"><a href=
34         "actions-file.html" accesskey="N">Next</a></td>
35       </tr>
36     </table>
37     <hr align="left" width="100%">
38   </div>
39
40   <div class="SECT1">
41     <h1 class="SECT1"><a name="CONFIG" id="CONFIG">7. The Main Configuration
42     File</a></h1>
43
44     <p>By default, the main configuration file is named <tt class=
45     "FILENAME">config</tt>, with the exception of Windows, where it is named
46     <tt class="FILENAME">config.txt</tt>. Configuration lines consist of an
47     initial keyword followed by a list of values, all separated by whitespace
48     (any number of spaces or tabs). For example:</p>
49
50     <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
51     "emphasis"><i class="EMPHASIS">confdir /etc/privoxy</i></span></tt></p>
52
53     <p>Assigns the value <tt class="LITERAL">/etc/privoxy</tt> to the option
54     <tt class="LITERAL">confdir</tt> and thus indicates that the
55     configuration directory is named <span class=
56     "QUOTE">"/etc/privoxy/"</span>.</p>
57
58     <p>All options in the config file except for <tt class=
59     "LITERAL">confdir</tt> and <tt class="LITERAL">logdir</tt> are optional.
60     Watch out in the below description for what happens if you leave them
61     unset.</p>
62
63     <p>The main config file controls all aspects of <span class=
64     "APPLICATION">Privoxy</span>'s operation that are not location dependent
65     (i.e. they apply universally, no matter where you may be surfing). Like
66     the filter and action files, the config file is a plain text file and can
67     be modified with a text editor like emacs, vim or notepad.exe.</p>
68
69     <div class="SECT2">
70       <h2 class="SECT2"><a name="LOCAL-SET-UP" id="LOCAL-SET-UP">7.1. Local
71       Set-up Documentation</a></h2>
72
73       <p>If you intend to operate <span class="APPLICATION">Privoxy</span>
74       for more users than just yourself, it might be a good idea to let them
75       know how to reach you, what you block and why you do that, your
76       policies, etc.</p>
77
78       <div class="SECT3">
79         <h4 class="SECT3"><a name="USER-MANUAL" id="USER-MANUAL">7.1.1.
80         user-manual</a></h4>
81
82         <div class="VARIABLELIST">
83           <dl>
84             <dt>Specifies:</dt>
85
86             <dd>
87               <p>Location of the <span class="APPLICATION">Privoxy</span>
88               User Manual.</p>
89             </dd>
90
91             <dt>Type of value:</dt>
92
93             <dd>
94               <p>A fully qualified URI</p>
95             </dd>
96
97             <dt>Default value:</dt>
98
99             <dd>
100               <p><span class="emphasis"><i class=
101               "EMPHASIS">Unset</i></span></p>
102             </dd>
103
104             <dt>Effect if unset:</dt>
105
106             <dd>
107               <p><a href="http://www.privoxy.org/user-manual/" target=
108               "_top">http://www.privoxy.org/<tt class=
109               "REPLACEABLE"><i>version</i></tt>/user-manual/</a> will be
110               used, where <tt class="REPLACEABLE"><i>version</i></tt> is the
111               <span class="APPLICATION">Privoxy</span> version.</p>
112             </dd>
113
114             <dt>Notes:</dt>
115
116             <dd>
117               <p>The User Manual URI is the single best source of information
118               on <span class="APPLICATION">Privoxy</span>, and is used for
119               help links from some of the internal CGI pages. The manual
120               itself is normally packaged with the binary distributions, so
121               you probably want to set this to a locally installed copy.</p>
122
123               <p>Examples:</p>
124
125               <p>The best all purpose solution is simply to put the full
126               local <tt class="LITERAL">PATH</tt> to where the <i class=
127               "CITETITLE">User Manual</i> is located:</p>
128
129               <table border="0" bgcolor="#E0E0E0" width="90%">
130                 <tr>
131                   <td>
132                     <pre class="SCREEN">
133   user-manual  /usr/share/doc/privoxy/user-manual
134 </pre>
135                   </td>
136                 </tr>
137               </table>
138
139               <p>The User Manual is then available to anyone with access to
140               <span class="APPLICATION">Privoxy</span>, by following the
141               built-in URL: <tt class=
142               "LITERAL">http://config.privoxy.org/user-manual/</tt> (or the
143               shortcut: <tt class=
144               "LITERAL">http://p.p/user-manual/</tt>).</p>
145
146               <p>If the documentation is not on the local system, it can be
147               accessed from a remote server, as:</p>
148
149               <table border="0" bgcolor="#E0E0E0" width="90%">
150                 <tr>
151                   <td>
152                     <pre class="SCREEN">
153   user-manual  http://example.com/privoxy/user-manual/
154 </pre>
155                   </td>
156                 </tr>
157               </table>
158
159               <div class="WARNING">
160                 <table class="WARNING" border="1" width="90%">
161                   <tr>
162                     <td align="center"><b>Warning</b></td>
163                   </tr>
164
165                   <tr>
166                     <td align="left">
167                       <p>If set, this option should be <span class=
168                       "emphasis"><i class="EMPHASIS">the first option in the
169                       config file</i></span>, because it is used while the
170                       config file is being read on start-up.</p>
171                     </td>
172                   </tr>
173                 </table>
174               </div>
175             </dd>
176           </dl>
177         </div>
178       </div>
179
180       <div class="SECT3">
181         <h4 class="SECT3"><a name="TRUST-INFO-URL" id="TRUST-INFO-URL">7.1.2.
182         trust-info-url</a></h4>
183
184         <div class="VARIABLELIST">
185           <dl>
186             <dt>Specifies:</dt>
187
188             <dd>
189               <p>A URL to be displayed in the error page that users will see
190               if access to an untrusted page is denied.</p>
191             </dd>
192
193             <dt>Type of value:</dt>
194
195             <dd>
196               <p>URL</p>
197             </dd>
198
199             <dt>Default value:</dt>
200
201             <dd>
202               <p><span class="emphasis"><i class=
203               "EMPHASIS">Unset</i></span></p>
204             </dd>
205
206             <dt>Effect if unset:</dt>
207
208             <dd>
209               <p>No links are displayed on the "untrusted" error page.</p>
210             </dd>
211
212             <dt>Notes:</dt>
213
214             <dd>
215               <p>The value of this option only matters if the experimental
216               trust mechanism has been activated. (See <a href=
217               "config.html#TRUSTFILE"><span class="emphasis"><i class=
218               "EMPHASIS">trustfile</i></span></a> below.)</p>
219
220               <p>If you use the trust mechanism, it is a good idea to write
221               up some on-line documentation about your trust policy and to
222               specify the URL(s) here. Use multiple times for multiple
223               URLs.</p>
224
225               <p>The URL(s) should be added to the trustfile as well, so
226               users don't end up locked out from the information on why they
227               were locked out in the first place!</p>
228             </dd>
229           </dl>
230         </div>
231       </div>
232
233       <div class="SECT3">
234         <h4 class="SECT3"><a name="ADMIN-ADDRESS" id="ADMIN-ADDRESS">7.1.3.
235         admin-address</a></h4>
236
237         <div class="VARIABLELIST">
238           <dl>
239             <dt>Specifies:</dt>
240
241             <dd>
242               <p>An email address to reach the <span class=
243               "APPLICATION">Privoxy</span> administrator.</p>
244             </dd>
245
246             <dt>Type of value:</dt>
247
248             <dd>
249               <p>Email address</p>
250             </dd>
251
252             <dt>Default value:</dt>
253
254             <dd>
255               <p><span class="emphasis"><i class=
256               "EMPHASIS">Unset</i></span></p>
257             </dd>
258
259             <dt>Effect if unset:</dt>
260
261             <dd>
262               <p>No email address is displayed on error pages and the CGI
263               user interface.</p>
264             </dd>
265
266             <dt>Notes:</dt>
267
268             <dd>
269               <p>If both <tt class="LITERAL">admin-address</tt> and
270               <tt class="LITERAL">proxy-info-url</tt> are unset, the whole
271               "Local Privoxy Support" box on all generated pages will not be
272               shown.</p>
273             </dd>
274           </dl>
275         </div>
276       </div>
277
278       <div class="SECT3">
279         <h4 class="SECT3"><a name="PROXY-INFO-URL" id="PROXY-INFO-URL">7.1.4.
280         proxy-info-url</a></h4>
281
282         <div class="VARIABLELIST">
283           <dl>
284             <dt>Specifies:</dt>
285
286             <dd>
287               <p>A URL to documentation about the local <span class=
288               "APPLICATION">Privoxy</span> setup, configuration or
289               policies.</p>
290             </dd>
291
292             <dt>Type of value:</dt>
293
294             <dd>
295               <p>URL</p>
296             </dd>
297
298             <dt>Default value:</dt>
299
300             <dd>
301               <p><span class="emphasis"><i class=
302               "EMPHASIS">Unset</i></span></p>
303             </dd>
304
305             <dt>Effect if unset:</dt>
306
307             <dd>
308               <p>No link to local documentation is displayed on error pages
309               and the CGI user interface.</p>
310             </dd>
311
312             <dt>Notes:</dt>
313
314             <dd>
315               <p>If both <tt class="LITERAL">admin-address</tt> and
316               <tt class="LITERAL">proxy-info-url</tt> are unset, the whole
317               "Local Privoxy Support" box on all generated pages will not be
318               shown.</p>
319
320               <p>This URL shouldn't be blocked ;-)</p>
321             </dd>
322           </dl>
323         </div>
324       </div>
325     </div>
326
327     <div class="SECT2">
328       <h2 class="SECT2"><a name="CONF-LOG-LOC" id="CONF-LOG-LOC">7.2.
329       Configuration and Log File Locations</a></h2>
330
331       <p><span class="APPLICATION">Privoxy</span> can (and normally does) use
332       a number of other files for additional configuration, help and logging.
333       This section of the configuration file tells <span class=
334       "APPLICATION">Privoxy</span> where to find those other files.</p>
335
336       <p>The user running <span class="APPLICATION">Privoxy</span>, must have
337       read permission for all configuration files, and write permission to
338       any files that would be modified, such as log files and actions
339       files.</p>
340
341       <div class="SECT3">
342         <h4 class="SECT3"><a name="CONFDIR" id="CONFDIR">7.2.1.
343         confdir</a></h4>
344
345         <div class="VARIABLELIST">
346           <dl>
347             <dt>Specifies:</dt>
348
349             <dd>
350               <p>The directory where the other configuration files are
351               located.</p>
352             </dd>
353
354             <dt>Type of value:</dt>
355
356             <dd>
357               <p>Path name</p>
358             </dd>
359
360             <dt>Default value:</dt>
361
362             <dd>
363               <p>/etc/privoxy (Unix) <span class="emphasis"><i class=
364               "EMPHASIS">or</i></span> <span class=
365               "APPLICATION">Privoxy</span> installation dir (Windows)</p>
366             </dd>
367
368             <dt>Effect if unset:</dt>
369
370             <dd>
371               <p><span class="emphasis"><i class=
372               "EMPHASIS">Mandatory</i></span></p>
373             </dd>
374
375             <dt>Notes:</dt>
376
377             <dd>
378               <p>No trailing <span class="QUOTE">"<tt class=
379               "LITERAL">/</tt>"</span>, please.</p>
380             </dd>
381           </dl>
382         </div>
383       </div>
384
385       <div class="SECT3">
386         <h4 class="SECT3"><a name="TEMPLDIR" id="TEMPLDIR">7.2.2.
387         templdir</a></h4>
388
389         <div class="VARIABLELIST">
390           <dl>
391             <dt>Specifies:</dt>
392
393             <dd>
394               <p>An alternative directory where the templates are loaded
395               from.</p>
396             </dd>
397
398             <dt>Type of value:</dt>
399
400             <dd>
401               <p>Path name</p>
402             </dd>
403
404             <dt>Default value:</dt>
405
406             <dd>
407               <p>unset</p>
408             </dd>
409
410             <dt>Effect if unset:</dt>
411
412             <dd>
413               <p>The templates are assumed to be located in
414               confdir/template.</p>
415             </dd>
416
417             <dt>Notes:</dt>
418
419             <dd>
420               <p><span class="APPLICATION">Privoxy's</span> original
421               templates are usually overwritten with each update. Use this
422               option to relocate customized templates that should be kept. As
423               template variables might change between updates, you shouldn't
424               expect templates to work with <span class=
425               "APPLICATION">Privoxy</span> releases other than the one they
426               were part of, though.</p>
427             </dd>
428           </dl>
429         </div>
430       </div>
431
432       <div class="SECT3">
433         <h4 class="SECT3"><a name="LOGDIR" id="LOGDIR">7.2.3. logdir</a></h4>
434
435         <div class="VARIABLELIST">
436           <dl>
437             <dt>Specifies:</dt>
438
439             <dd>
440               <p>The directory where all logging takes place (i.e. where the
441               <tt class="FILENAME">logfile</tt> is located).</p>
442             </dd>
443
444             <dt>Type of value:</dt>
445
446             <dd>
447               <p>Path name</p>
448             </dd>
449
450             <dt>Default value:</dt>
451
452             <dd>
453               <p>/var/log/privoxy (Unix) <span class="emphasis"><i class=
454               "EMPHASIS">or</i></span> <span class=
455               "APPLICATION">Privoxy</span> installation dir (Windows)</p>
456             </dd>
457
458             <dt>Effect if unset:</dt>
459
460             <dd>
461               <p><span class="emphasis"><i class=
462               "EMPHASIS">Mandatory</i></span></p>
463             </dd>
464
465             <dt>Notes:</dt>
466
467             <dd>
468               <p>No trailing <span class="QUOTE">"<tt class=
469               "LITERAL">/</tt>"</span>, please.</p>
470             </dd>
471           </dl>
472         </div>
473       </div>
474
475       <div class="SECT3">
476         <h4 class="SECT3"><a name="ACTIONSFILE" id="ACTIONSFILE">7.2.4.
477         actionsfile</a></h4><a name="DEFAULT.ACTION" id=
478         "DEFAULT.ACTION"></a><a name="STANDARD.ACTION" id=
479         "STANDARD.ACTION"></a><a name="USER.ACTION" id="USER.ACTION"></a>
480
481         <div class="VARIABLELIST">
482           <dl>
483             <dt>Specifies:</dt>
484
485             <dd>
486               <p>The <a href="actions-file.html">actions file(s)</a> to
487               use</p>
488             </dd>
489
490             <dt>Type of value:</dt>
491
492             <dd>
493               <p>Complete file name, relative to <tt class=
494               "LITERAL">confdir</tt></p>
495             </dd>
496
497             <dt>Default values:</dt>
498
499             <dd>
500               <table border="0">
501                 <tbody>
502                   <tr>
503                     <td>
504                       <p class="LITERALLAYOUT">
505                       &nbsp;&nbsp;match-all.action&nbsp;#&nbsp;Actions&nbsp;that&nbsp;are&nbsp;applied&nbsp;to&nbsp;all&nbsp;sites&nbsp;and&nbsp;maybe&nbsp;overruled&nbsp;later&nbsp;on.</p>
506                     </td>
507                   </tr>
508
509                   <tr>
510                     <td>
511                       <p class="LITERALLAYOUT">
512                       &nbsp;&nbsp;default.action&nbsp;&nbsp;&nbsp;#&nbsp;Main&nbsp;actions&nbsp;file</p>
513                     </td>
514                   </tr>
515
516                   <tr>
517                     <td>
518                       <p class="LITERALLAYOUT">
519                       &nbsp;&nbsp;user.action&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#&nbsp;User&nbsp;customizations</p>
520                     </td>
521                   </tr>
522                 </tbody>
523               </table>
524             </dd>
525
526             <dt>Effect if unset:</dt>
527
528             <dd>
529               <p>No actions are taken at all. More or less neutral
530               proxying.</p>
531             </dd>
532
533             <dt>Notes:</dt>
534
535             <dd>
536               <p>Multiple <tt class="LITERAL">actionsfile</tt> lines are
537               permitted, and are in fact recommended!</p>
538
539               <p>The default values are <tt class=
540               "FILENAME">default.action</tt>, which is the <span class=
541               "QUOTE">"main"</span> actions file maintained by the
542               developers, and <tt class="FILENAME">user.action</tt>, where
543               you can make your personal additions.</p>
544
545               <p>Actions files contain all the per site and per URL
546               configuration for ad blocking, cookie management, privacy
547               considerations, etc. There is no point in using <span class=
548               "APPLICATION">Privoxy</span> without at least one actions
549               file.</p>
550
551               <p>Note that since Privoxy 3.0.7, the complete filename,
552               including the <span class="QUOTE">".action"</span> extension
553               has to be specified. The syntax change was necessary to be
554               consistent with the other file options and to allow previously
555               forbidden characters.</p>
556             </dd>
557           </dl>
558         </div>
559       </div>
560
561       <div class="SECT3">
562         <h4 class="SECT3"><a name="FILTERFILE" id="FILTERFILE">7.2.5.
563         filterfile</a></h4><a name="DEFAULT.FILTER" id="DEFAULT.FILTER"></a>
564
565         <div class="VARIABLELIST">
566           <dl>
567             <dt>Specifies:</dt>
568
569             <dd>
570               <p>The <a href="filter-file.html">filter file(s)</a> to use</p>
571             </dd>
572
573             <dt>Type of value:</dt>
574
575             <dd>
576               <p>File name, relative to <tt class="LITERAL">confdir</tt></p>
577             </dd>
578
579             <dt>Default value:</dt>
580
581             <dd>
582               <p>default.filter (Unix) <span class="emphasis"><i class=
583               "EMPHASIS">or</i></span> default.filter.txt (Windows)</p>
584             </dd>
585
586             <dt>Effect if unset:</dt>
587
588             <dd>
589               <p>No textual content filtering takes place, i.e. all
590               <tt class="LITERAL">+<a href=
591               "actions-file.html#FILTER">filter</a>{<tt class=
592               "REPLACEABLE"><i>name</i></tt>}</tt> actions in the actions
593               files are turned neutral.</p>
594             </dd>
595
596             <dt>Notes:</dt>
597
598             <dd>
599               <p>Multiple <tt class="LITERAL">filterfile</tt> lines are
600               permitted.</p>
601
602               <p>The <a href="filter-file.html">filter files</a> contain
603               content modification rules that use <a href=
604               "appendix.html#REGEX">regular expressions</a>. These rules
605               permit powerful changes on the content of Web pages, and
606               optionally the headers as well, e.g., you could try to disable
607               your favorite JavaScript annoyances, re-write the actual
608               displayed text, or just have some fun playing buzzword bingo
609               with web pages.</p>
610
611               <p>The <tt class="LITERAL">+<a href=
612               "actions-file.html#FILTER">filter</a>{<tt class=
613               "REPLACEABLE"><i>name</i></tt>}</tt> actions rely on the
614               relevant filter (<tt class="REPLACEABLE"><i>name</i></tt>) to
615               be defined in a filter file!</p>
616
617               <p>A pre-defined filter file called <tt class=
618               "FILENAME">default.filter</tt> that contains a number of useful
619               filters for common problems is included in the distribution.
620               See the section on the <tt class="LITERAL"><a href=
621               "actions-file.html#FILTER">filter</a></tt> action for a
622               list.</p>
623
624               <p>It is recommended to place any locally adapted filters into
625               a separate file, such as <tt class=
626               "FILENAME">user.filter</tt>.</p>
627             </dd>
628           </dl>
629         </div>
630       </div>
631
632       <div class="SECT3">
633         <h4 class="SECT3"><a name="LOGFILE" id="LOGFILE">7.2.6.
634         logfile</a></h4>
635
636         <div class="VARIABLELIST">
637           <dl>
638             <dt>Specifies:</dt>
639
640             <dd>
641               <p>The log file to use</p>
642             </dd>
643
644             <dt>Type of value:</dt>
645
646             <dd>
647               <p>File name, relative to <tt class="LITERAL">logdir</tt></p>
648             </dd>
649
650             <dt>Default value:</dt>
651
652             <dd>
653               <p><span class="emphasis"><i class="EMPHASIS">Unset (commented
654               out)</i></span>. When activated: logfile (Unix) <span class=
655               "emphasis"><i class="EMPHASIS">or</i></span> privoxy.log
656               (Windows).</p>
657             </dd>
658
659             <dt>Effect if unset:</dt>
660
661             <dd>
662               <p>No logfile is written.</p>
663             </dd>
664
665             <dt>Notes:</dt>
666
667             <dd>
668               <p>The logfile is where all logging and error messages are
669               written. The level of detail and number of messages are set
670               with the <tt class="LITERAL">debug</tt> option (see below). The
671               logfile can be useful for tracking down a problem with
672               <span class="APPLICATION">Privoxy</span> (e.g., it's not
673               blocking an ad you think it should block) and it can help you
674               to monitor what your browser is doing.</p>
675
676               <p>Depending on the debug options below, the logfile may be a
677               privacy risk if third parties can get access to it. As most
678               users will never look at it, <span class=
679               "APPLICATION">Privoxy</span> 3.0.7 and later only log fatal
680               errors by default.</p>
681
682               <p>For most troubleshooting purposes, you will have to change
683               that, please refer to the debugging section for details.</p>
684
685               <p>Your logfile will grow indefinitely, and you will probably
686               want to periodically remove it. On Unix systems, you can do
687               this with a cron job (see <span class="QUOTE">"man
688               cron"</span>). For Red Hat based Linux distributions, a
689               <b class="COMMAND">logrotate</b> script has been included.</p>
690
691               <p>Any log files must be writable by whatever user <span class=
692               "APPLICATION">Privoxy</span> is being run as (on Unix, default
693               user id is <span class="QUOTE">"privoxy"</span>).</p>
694             </dd>
695           </dl>
696         </div>
697       </div>
698
699       <div class="SECT3">
700         <h4 class="SECT3"><a name="TRUSTFILE" id="TRUSTFILE">7.2.7.
701         trustfile</a></h4>
702
703         <div class="VARIABLELIST">
704           <dl>
705             <dt>Specifies:</dt>
706
707             <dd>
708               <p>The name of the trust file to use</p>
709             </dd>
710
711             <dt>Type of value:</dt>
712
713             <dd>
714               <p>File name, relative to <tt class="LITERAL">confdir</tt></p>
715             </dd>
716
717             <dt>Default value:</dt>
718
719             <dd>
720               <p><span class="emphasis"><i class="EMPHASIS">Unset (commented
721               out)</i></span>. When activated: trust (Unix) <span class=
722               "emphasis"><i class="EMPHASIS">or</i></span> trust.txt
723               (Windows)</p>
724             </dd>
725
726             <dt>Effect if unset:</dt>
727
728             <dd>
729               <p>The entire trust mechanism is disabled.</p>
730             </dd>
731
732             <dt>Notes:</dt>
733
734             <dd>
735               <p>The trust mechanism is an experimental feature for building
736               white-lists and should be used with care. It is <span class=
737               "emphasis"><i class="EMPHASIS">NOT</i></span> recommended for
738               the casual user.</p>
739
740               <p>If you specify a trust file, <span class=
741               "APPLICATION">Privoxy</span> will only allow access to sites
742               that are specified in the trustfile. Sites can be listed in one
743               of two ways:</p>
744
745               <p>Prepending a <tt class="LITERAL">~</tt> character limits
746               access to this site only (and any sub-paths within this site),
747               e.g. <tt class="LITERAL">~www.example.com</tt> allows access to
748               <tt class="LITERAL">~www.example.com/features/news.html</tt>,
749               etc.</p>
750
751               <p>Or, you can designate sites as <span class=
752               "emphasis"><i class="EMPHASIS">trusted referrers</i></span>, by
753               prepending the name with a <tt class="LITERAL">+</tt>
754               character. The effect is that access to untrusted sites will be
755               granted -- but only if a link from this trusted referrer was
756               used to get there. The link target will then be added to the
757               <span class="QUOTE">"trustfile"</span> so that future, direct
758               accesses will be granted. Sites added via this mechanism do not
759               become trusted referrers themselves (i.e. they are added with a
760               <tt class="LITERAL">~</tt> designation). There is a limit of
761               512 such entries, after which new entries will not be made.</p>
762
763               <p>If you use the <tt class="LITERAL">+</tt> operator in the
764               trust file, it may grow considerably over time.</p>
765
766               <p>It is recommended that <span class=
767               "APPLICATION">Privoxy</span> be compiled with the <tt class=
768               "LITERAL">--disable-force</tt>, <tt class=
769               "LITERAL">--disable-toggle</tt> and <tt class=
770               "LITERAL">--disable-editor</tt> options, if this feature is to
771               be used.</p>
772
773               <p>Possible applications include limiting Internet access for
774               children.</p>
775             </dd>
776           </dl>
777         </div>
778       </div>
779     </div>
780
781     <div class="SECT2">
782       <h2 class="SECT2"><a name="DEBUGGING" id="DEBUGGING">7.3.
783       Debugging</a></h2>
784
785       <p>These options are mainly useful when tracing a problem. Note that
786       you might also want to invoke <span class="APPLICATION">Privoxy</span>
787       with the <tt class="LITERAL">--no-daemon</tt> command line option when
788       debugging.</p>
789
790       <div class="SECT3">
791         <h4 class="SECT3"><a name="DEBUG" id="DEBUG">7.3.1. debug</a></h4>
792
793         <div class="VARIABLELIST">
794           <dl>
795             <dt>Specifies:</dt>
796
797             <dd>
798               <p>Key values that determine what information gets logged.</p>
799             </dd>
800
801             <dt>Type of value:</dt>
802
803             <dd>
804               <p>Integer values</p>
805             </dd>
806
807             <dt>Default value:</dt>
808
809             <dd>
810               <p>0 (i.e.: only fatal errors (that cause Privoxy to exit) are
811               logged)</p>
812             </dd>
813
814             <dt>Effect if unset:</dt>
815
816             <dd>
817               <p>Default value is used (see above).</p>
818             </dd>
819
820             <dt>Notes:</dt>
821
822             <dd>
823               <p>The available debug levels are:</p>
824
825               <table border="0" bgcolor="#E0E0E0" width="90%">
826                 <tr>
827                   <td>
828                     <pre class="PROGRAMLISTING">
829   debug     1 # Log the destination for each request <span class=
830 "APPLICATION">Privoxy</span> let through. See also debug 1024.
831   debug     2 # show each connection status
832   debug     4 # show I/O status
833   debug     8 # show header parsing
834   debug    16 # log all data written to the network
835   debug    32 # debug force feature
836   debug    64 # debug regular expression filters
837   debug   128 # debug redirects
838   debug   256 # debug GIF de-animation
839   debug   512 # Common Log Format
840   debug  1024 # Log the destination for requests <span class=
841 "APPLICATION">Privoxy</span> didn't let through, and the reason why.
842   debug  2048 # CGI user interface
843   debug  4096 # Startup banner and warnings.
844   debug  8192 # Non-fatal errors
845   debug 32768 # log all data read from the network
846 </pre>
847                   </td>
848                 </tr>
849               </table>
850
851               <p>To select multiple debug levels, you can either add them or
852               use multiple <tt class="LITERAL">debug</tt> lines.</p>
853
854               <p>A debug level of 1 is informative because it will show you
855               each request as it happens. <span class="emphasis"><i class=
856               "EMPHASIS">1, 1024, 4096 and 8192 are recommended</i></span> so
857               that you will notice when things go wrong. The other levels are
858               probably only of interest if you are hunting down a specific
859               problem. They can produce a hell of an output (especially
860               16).</p>
861
862               <p><span class="APPLICATION">Privoxy</span> used to ship with
863               the debug levels recommended above enabled by default, but due
864               to privacy concerns 3.0.7 and later are configured to only log
865               fatal errors.</p>
866
867               <p>If you are used to the more verbose settings, simply enable
868               the debug lines below again.</p>
869
870               <p>If you want to use pure CLF (Common Log Format), you should
871               set <span class="QUOTE">"debug 512"</span> <span class=
872               "emphasis"><i class="EMPHASIS">ONLY</i></span> and not enable
873               anything else.</p>
874
875               <p><span class="APPLICATION">Privoxy</span> has a hard-coded
876               limit for the length of log messages. If it's reached, messages
877               are logged truncated and marked with <span class="QUOTE">"...
878               [too long, truncated]"</span>.</p>
879
880               <p>Please don't file any support requests without trying to
881               reproduce the problem with increased debug level first. Once
882               you read the log messages, you may even be able to solve the
883               problem on your own.</p>
884             </dd>
885           </dl>
886         </div>
887       </div>
888
889       <div class="SECT3">
890         <h4 class="SECT3"><a name="SINGLE-THREADED" id=
891         "SINGLE-THREADED">7.3.2. single-threaded</a></h4>
892
893         <div class="VARIABLELIST">
894           <dl>
895             <dt>Specifies:</dt>
896
897             <dd>
898               <p>Whether to run only one server thread.</p>
899             </dd>
900
901             <dt>Type of value:</dt>
902
903             <dd>
904               <p><span class="emphasis"><i class=
905               "EMPHASIS">None</i></span></p>
906             </dd>
907
908             <dt>Default value:</dt>
909
910             <dd>
911               <p><span class="emphasis"><i class=
912               "EMPHASIS">Unset</i></span></p>
913             </dd>
914
915             <dt>Effect if unset:</dt>
916
917             <dd>
918               <p>Multi-threaded (or, where unavailable: forked) operation,
919               i.e. the ability to serve multiple requests simultaneously.</p>
920             </dd>
921
922             <dt>Notes:</dt>
923
924             <dd>
925               <p>This option is only there for debugging purposes.
926               <span class="emphasis"><i class="EMPHASIS">It will drastically
927               reduce performance.</i></span></p>
928             </dd>
929           </dl>
930         </div>
931       </div>
932
933       <div class="SECT3">
934         <h4 class="SECT3"><a name="HOSTNAME" id="HOSTNAME">7.3.3.
935         hostname</a></h4>
936
937         <div class="VARIABLELIST">
938           <dl>
939             <dt>Specifies:</dt>
940
941             <dd>
942               <p>The hostname shown on the CGI pages.</p>
943             </dd>
944
945             <dt>Type of value:</dt>
946
947             <dd>
948               <p>Text</p>
949             </dd>
950
951             <dt>Default value:</dt>
952
953             <dd>
954               <p><span class="emphasis"><i class=
955               "EMPHASIS">Unset</i></span></p>
956             </dd>
957
958             <dt>Effect if unset:</dt>
959
960             <dd>
961               <p>The hostname provided by the operating system is used.</p>
962             </dd>
963
964             <dt>Notes:</dt>
965
966             <dd>
967               <p>On some misconfigured systems resolving the hostname fails
968               or takes too much time and slows Privoxy down. Setting a fixed
969               hostname works around the problem.</p>
970
971               <p>In other circumstances it might be desirable to show a
972               hostname other than the one returned by the operating system.
973               For example if the system has several different hostnames and
974               you don't want to use the first one.</p>
975
976               <p>Note that Privoxy does not validate the specified hostname
977               value.</p>
978             </dd>
979           </dl>
980         </div>
981       </div>
982     </div>
983
984     <div class="SECT2">
985       <h2 class="SECT2"><a name="ACCESS-CONTROL" id="ACCESS-CONTROL">7.4.
986       Access Control and Security</a></h2>
987
988       <p>This section of the config file controls the security-relevant
989       aspects of <span class="APPLICATION">Privoxy</span>'s
990       configuration.</p>
991
992       <div class="SECT3">
993         <h4 class="SECT3"><a name="LISTEN-ADDRESS" id="LISTEN-ADDRESS">7.4.1.
994         listen-address</a></h4>
995
996         <div class="VARIABLELIST">
997           <dl>
998             <dt>Specifies:</dt>
999
1000             <dd>
1001               <p>The address and TCP port on which <span class=
1002               "APPLICATION">Privoxy</span> will listen for client
1003               requests.</p>
1004             </dd>
1005
1006             <dt>Type of value:</dt>
1007
1008             <dd>
1009               <p>[<tt class="REPLACEABLE"><i>IP-Address</i></tt>]:<tt class=
1010               "REPLACEABLE"><i>Port</i></tt></p>
1011
1012               <p>[<tt class="REPLACEABLE"><i>Hostname</i></tt>]:<tt class=
1013               "REPLACEABLE"><i>Port</i></tt></p>
1014             </dd>
1015
1016             <dt>Default value:</dt>
1017
1018             <dd>
1019               <p>127.0.0.1:8118</p>
1020             </dd>
1021
1022             <dt>Effect if unset:</dt>
1023
1024             <dd>
1025               <p>Bind to 127.0.0.1 (IPv4 localhost), port 8118. This is
1026               suitable and recommended for home users who run <span class=
1027               "APPLICATION">Privoxy</span> on the same machine as their
1028               browser.</p>
1029             </dd>
1030
1031             <dt>Notes:</dt>
1032
1033             <dd>
1034               <p>You will need to configure your browser(s) to this proxy
1035               address and port.</p>
1036
1037               <p>If you already have another service running on port 8118, or
1038               if you want to serve requests from other machines (e.g. on your
1039               local network) as well, you will need to override the
1040               default.</p>
1041
1042               <p>You can use this statement multiple times to make
1043               <span class="APPLICATION">Privoxy</span> listen on more ports
1044               or more <abbr class="ABBREV">IP</abbr> addresses. Suitable if
1045               your operating system does not support sharing <abbr class=
1046               "ABBREV">IPv6</abbr> and <abbr class="ABBREV">IPv4</abbr>
1047               protocols on the same socket.</p>
1048
1049               <p>If a hostname is used instead of an IP address, <span class=
1050               "APPLICATION">Privoxy</span> will try to resolve it to an IP
1051               address and if there are multiple, use the first one
1052               returned.</p>
1053
1054               <p>If the address for the hostname isn't already known on the
1055               system (for example because it's in /etc/hostname), this may
1056               result in DNS traffic.</p>
1057
1058               <p>If the specified address isn't available on the system, or
1059               if the hostname can't be resolved, <span class=
1060               "APPLICATION">Privoxy</span> will fail to start.</p>
1061
1062               <p>IPv6 addresses containing colons have to be quoted by
1063               brackets. They can only be used if <span class=
1064               "APPLICATION">Privoxy</span> has been compiled with IPv6
1065               support. If you aren't sure if your version supports it, have a
1066               look at <tt class=
1067               "LITERAL">http://config.privoxy.org/show-status</tt>.</p>
1068
1069               <p>Some operating systems will prefer IPv6 to IPv4 addresses
1070               even if the system has no IPv6 connectivity which is usually
1071               not expected by the user. Some even rely on DNS to resolve
1072               localhost which mean the "localhost" address used may not
1073               actually be local.</p>
1074
1075               <p>It is therefore recommended to explicitly configure the
1076               intended IP address instead of relying on the operating system,
1077               unless there's a strong reason not to.</p>
1078
1079               <p>If you leave out the address, <span class=
1080               "APPLICATION">Privoxy</span> will bind to all IPv4 interfaces
1081               (addresses) on your machine and may become reachable from the
1082               Internet and/or the local network. Be aware that some GNU/Linux
1083               distributions modify that behaviour without updating the
1084               documentation. Check for non-standard patches if your
1085               <span class="APPLICATION">Privoxy</span>version behaves
1086               differently.</p>
1087
1088               <p>If you configure <span class="APPLICATION">Privoxy</span>to
1089               be reachable from the network, consider using <a href=
1090               "config.html#ACLS">access control lists</a> (ACL's, see below),
1091               and/or a firewall.</p>
1092
1093               <p>If you open <span class="APPLICATION">Privoxy</span> to
1094               untrusted users, you will also want to make sure that the
1095               following actions are disabled: <tt class="LITERAL"><a href=
1096               "config.html#ENABLE-EDIT-ACTIONS">enable-edit-actions</a></tt>
1097               and <tt class="LITERAL"><a href=
1098               "config.html#ENABLE-REMOTE-TOGGLE">enable-remote-toggle</a></tt></p>
1099
1100               <p>With the exception noted above, listening on multiple
1101               addresses is currently not supported by <span class=
1102               "APPLICATION">Privoxy</span> directly. It can be done on most
1103               operating systems by letting a packet filter redirect request
1104               for certain addresses to Privoxy, though.</p>
1105             </dd>
1106
1107             <dt>Example:</dt>
1108
1109             <dd>
1110               <p>Suppose you are running <span class=
1111               "APPLICATION">Privoxy</span> on a machine which has the address
1112               192.168.0.1 on your local private network (192.168.0.0) and has
1113               another outside connection with a different address. You want
1114               it to serve requests from inside only:</p>
1115
1116               <table border="0" bgcolor="#E0E0E0" width="90%">
1117                 <tr>
1118                   <td>
1119                     <pre class="PROGRAMLISTING">
1120   listen-address  192.168.0.1:8118
1121 </pre>
1122                   </td>
1123                 </tr>
1124               </table>
1125
1126               <p>Suppose you are running <span class=
1127               "APPLICATION">Privoxy</span> on an IPv6-capable machine and you
1128               want it to listen on the IPv6 address of the loopback
1129               device:</p>
1130
1131               <table border="0" bgcolor="#E0E0E0" width="90%">
1132                 <tr>
1133                   <td>
1134                     <pre class="PROGRAMLISTING">
1135   listen-address [::1]:8118
1136 </pre>
1137                   </td>
1138                 </tr>
1139               </table>
1140             </dd>
1141           </dl>
1142         </div>
1143       </div>
1144
1145       <div class="SECT3">
1146         <h4 class="SECT3"><a name="TOGGLE" id="TOGGLE">7.4.2. toggle</a></h4>
1147
1148         <div class="VARIABLELIST">
1149           <dl>
1150             <dt>Specifies:</dt>
1151
1152             <dd>
1153               <p>Initial state of "toggle" status</p>
1154             </dd>
1155
1156             <dt>Type of value:</dt>
1157
1158             <dd>
1159               <p>1 or 0</p>
1160             </dd>
1161
1162             <dt>Default value:</dt>
1163
1164             <dd>
1165               <p>1</p>
1166             </dd>
1167
1168             <dt>Effect if unset:</dt>
1169
1170             <dd>
1171               <p>Act as if toggled on</p>
1172             </dd>
1173
1174             <dt>Notes:</dt>
1175
1176             <dd>
1177               <p>If set to 0, <span class="APPLICATION">Privoxy</span> will
1178               start in <span class="QUOTE">"toggled off"</span> mode, i.e.
1179               mostly behave like a normal, content-neutral proxy with both ad
1180               blocking and content filtering disabled. See <tt class=
1181               "LITERAL">enable-remote-toggle</tt> below.</p>
1182
1183               <p>The windows version will only display the toggle icon in the
1184               system tray if this option is present.</p>
1185             </dd>
1186           </dl>
1187         </div>
1188       </div>
1189
1190       <div class="SECT3">
1191         <h4 class="SECT3"><a name="ENABLE-REMOTE-TOGGLE" id=
1192         "ENABLE-REMOTE-TOGGLE">7.4.3. enable-remote-toggle</a></h4>
1193
1194         <div class="VARIABLELIST">
1195           <dl>
1196             <dt>Specifies:</dt>
1197
1198             <dd>
1199               <p>Whether or not the <a href=
1200               "http://config.privoxy.org/toggle" target="_top">web-based
1201               toggle feature</a> may be used</p>
1202             </dd>
1203
1204             <dt>Type of value:</dt>
1205
1206             <dd>
1207               <p>0 or 1</p>
1208             </dd>
1209
1210             <dt>Default value:</dt>
1211
1212             <dd>
1213               <p>0</p>
1214             </dd>
1215
1216             <dt>Effect if unset:</dt>
1217
1218             <dd>
1219               <p>The web-based toggle feature is disabled.</p>
1220             </dd>
1221
1222             <dt>Notes:</dt>
1223
1224             <dd>
1225               <p>When toggled off, <span class="APPLICATION">Privoxy</span>
1226               mostly acts like a normal, content-neutral proxy, i.e. doesn't
1227               block ads or filter content.</p>
1228
1229               <p>Access to the toggle feature can <span class=
1230               "emphasis"><i class="EMPHASIS">not</i></span> be controlled
1231               separately by <span class="QUOTE">"ACLs"</span> or HTTP
1232               authentication, so that everybody who can access <span class=
1233               "APPLICATION">Privoxy</span> (see <span class=
1234               "QUOTE">"ACLs"</span> and <tt class=
1235               "LITERAL">listen-address</tt> above) can toggle it for all
1236               users. So this option is <span class="emphasis"><i class=
1237               "EMPHASIS">not recommended</i></span> for multi-user
1238               environments with untrusted users.</p>
1239
1240               <p>Note that malicious client side code (e.g Java) is also
1241               capable of using this option.</p>
1242
1243               <p>As a lot of <span class="APPLICATION">Privoxy</span> users
1244               don't read documentation, this feature is disabled by
1245               default.</p>
1246
1247               <p>Note that you must have compiled <span class=
1248               "APPLICATION">Privoxy</span> with support for this feature,
1249               otherwise this option has no effect.</p>
1250             </dd>
1251           </dl>
1252         </div>
1253       </div>
1254
1255       <div class="SECT3">
1256         <h4 class="SECT3"><a name="ENABLE-REMOTE-HTTP-TOGGLE" id=
1257         "ENABLE-REMOTE-HTTP-TOGGLE">7.4.4. enable-remote-http-toggle</a></h4>
1258
1259         <div class="VARIABLELIST">
1260           <dl>
1261             <dt>Specifies:</dt>
1262
1263             <dd>
1264               <p>Whether or not Privoxy recognizes special HTTP headers to
1265               change its behaviour.</p>
1266             </dd>
1267
1268             <dt>Type of value:</dt>
1269
1270             <dd>
1271               <p>0 or 1</p>
1272             </dd>
1273
1274             <dt>Default value:</dt>
1275
1276             <dd>
1277               <p>0</p>
1278             </dd>
1279
1280             <dt>Effect if unset:</dt>
1281
1282             <dd>
1283               <p>Privoxy ignores special HTTP headers.</p>
1284             </dd>
1285
1286             <dt>Notes:</dt>
1287
1288             <dd>
1289               <p>When toggled on, the client can change <span class=
1290               "APPLICATION">Privoxy's</span> behaviour by setting special
1291               HTTP headers. Currently the only supported special header is
1292               <span class="QUOTE">"X-Filter: No"</span>, to disable filtering
1293               for the ongoing request, even if it is enabled in one of the
1294               action files.</p>
1295
1296               <p>This feature is disabled by default. If you are using
1297               <span class="APPLICATION">Privoxy</span> in a environment with
1298               trusted clients, you may enable this feature at your
1299               discretion. Note that malicious client side code (e.g Java) is
1300               also capable of using this feature.</p>
1301
1302               <p>This option will be removed in future releases as it has
1303               been obsoleted by the more general header taggers.</p>
1304             </dd>
1305           </dl>
1306         </div>
1307       </div>
1308
1309       <div class="SECT3">
1310         <h4 class="SECT3"><a name="ENABLE-EDIT-ACTIONS" id=
1311         "ENABLE-EDIT-ACTIONS">7.4.5. enable-edit-actions</a></h4>
1312
1313         <div class="VARIABLELIST">
1314           <dl>
1315             <dt>Specifies:</dt>
1316
1317             <dd>
1318               <p>Whether or not the <a href=
1319               "http://config.privoxy.org/show-status" target="_top">web-based
1320               actions file editor</a> may be used</p>
1321             </dd>
1322
1323             <dt>Type of value:</dt>
1324
1325             <dd>
1326               <p>0 or 1</p>
1327             </dd>
1328
1329             <dt>Default value:</dt>
1330
1331             <dd>
1332               <p>0</p>
1333             </dd>
1334
1335             <dt>Effect if unset:</dt>
1336
1337             <dd>
1338               <p>The web-based actions file editor is disabled.</p>
1339             </dd>
1340
1341             <dt>Notes:</dt>
1342
1343             <dd>
1344               <p>Access to the editor can <span class="emphasis"><i class=
1345               "EMPHASIS">not</i></span> be controlled separately by
1346               <span class="QUOTE">"ACLs"</span> or HTTP authentication, so
1347               that everybody who can access <span class=
1348               "APPLICATION">Privoxy</span> (see <span class=
1349               "QUOTE">"ACLs"</span> and <tt class=
1350               "LITERAL">listen-address</tt> above) can modify its
1351               configuration for all users.</p>
1352
1353               <p>This option is <span class="emphasis"><i class=
1354               "EMPHASIS">not recommended</i></span> for environments with
1355               untrusted users and as a lot of <span class=
1356               "APPLICATION">Privoxy</span> users don't read documentation,
1357               this feature is disabled by default.</p>
1358
1359               <p>Note that malicious client side code (e.g Java) is also
1360               capable of using the actions editor and you shouldn't enable
1361               this options unless you understand the consequences and are
1362               sure your browser is configured correctly.</p>
1363
1364               <p>Note that you must have compiled <span class=
1365               "APPLICATION">Privoxy</span> with support for this feature,
1366               otherwise this option has no effect.</p>
1367             </dd>
1368           </dl>
1369         </div>
1370       </div>
1371
1372       <div class="SECT3">
1373         <h4 class="SECT3"><a name="ENFORCE-BLOCKS" id="ENFORCE-BLOCKS">7.4.6.
1374         enforce-blocks</a></h4>
1375
1376         <div class="VARIABLELIST">
1377           <dl>
1378             <dt>Specifies:</dt>
1379
1380             <dd>
1381               <p>Whether the user is allowed to ignore blocks and can
1382               <span class="QUOTE">"go there anyway"</span>.</p>
1383             </dd>
1384
1385             <dt>Type of value:</dt>
1386
1387             <dd>
1388               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
1389             </dd>
1390
1391             <dt>Default value:</dt>
1392
1393             <dd>
1394               <p><span class="emphasis"><i class="EMPHASIS">0</i></span></p>
1395             </dd>
1396
1397             <dt>Effect if unset:</dt>
1398
1399             <dd>
1400               <p>Blocks are not enforced.</p>
1401             </dd>
1402
1403             <dt>Notes:</dt>
1404
1405             <dd>
1406               <p><span class="APPLICATION">Privoxy</span> is mainly used to
1407               block and filter requests as a service to the user, for example
1408               to block ads and other junk that clogs the pipes. <span class=
1409               "APPLICATION">Privoxy's</span> configuration isn't perfect and
1410               sometimes innocent pages are blocked. In this situation it
1411               makes sense to allow the user to enforce the request and have
1412               <span class="APPLICATION">Privoxy</span> ignore the block.</p>
1413
1414               <p>In the default configuration <span class=
1415               "APPLICATION">Privoxy's</span> <span class=
1416               "QUOTE">"Blocked"</span> page contains a <span class=
1417               "QUOTE">"go there anyway"</span> link to adds a special string
1418               (the force prefix) to the request URL. If that link is used,
1419               <span class="APPLICATION">Privoxy</span> will detect the force
1420               prefix, remove it again and let the request pass.</p>
1421
1422               <p>Of course <span class="APPLICATION">Privoxy</span> can also
1423               be used to enforce a network policy. In that case the user
1424               obviously should not be able to bypass any blocks, and that's
1425               what the <span class="QUOTE">"enforce-blocks"</span> option is
1426               for. If it's enabled, <span class="APPLICATION">Privoxy</span>
1427               hides the <span class="QUOTE">"go there anyway"</span> link. If
1428               the user adds the force prefix by hand, it will not be accepted
1429               and the circumvention attempt is logged.</p>
1430             </dd>
1431
1432             <dt>Examples:</dt>
1433
1434             <dd>
1435               <p>enforce-blocks 1</p>
1436             </dd>
1437           </dl>
1438         </div>
1439       </div>
1440
1441       <div class="SECT3">
1442         <h4 class="SECT3"><a name="ACLS" id="ACLS">7.4.7. ACLs: permit-access
1443         and deny-access</a></h4><a name="PERMIT-ACCESS" id=
1444         "PERMIT-ACCESS"></a><a name="DENY-ACCESS" id="DENY-ACCESS"></a>
1445
1446         <div class="VARIABLELIST">
1447           <dl>
1448             <dt>Specifies:</dt>
1449
1450             <dd>
1451               <p>Who can access what.</p>
1452             </dd>
1453
1454             <dt>Type of value:</dt>
1455
1456             <dd>
1457               <p><tt class="REPLACEABLE"><i>src_addr</i></tt>[:<tt class=
1458               "REPLACEABLE"><i>port</i></tt>][/<tt class=
1459               "REPLACEABLE"><i>src_masklen</i></tt>] [<tt class=
1460               "REPLACEABLE"><i>dst_addr</i></tt>[:<tt class=
1461               "REPLACEABLE"><i>port</i></tt>][/<tt class=
1462               "REPLACEABLE"><i>dst_masklen</i></tt>]]</p>
1463
1464               <p>Where <tt class="REPLACEABLE"><i>src_addr</i></tt> and
1465               <tt class="REPLACEABLE"><i>dst_addr</i></tt> are IPv4 addresses
1466               in dotted decimal notation or valid DNS names, <tt class=
1467               "REPLACEABLE"><i>port</i></tt> is a port number, and <tt class=
1468               "REPLACEABLE"><i>src_masklen</i></tt> and <tt class=
1469               "REPLACEABLE"><i>dst_masklen</i></tt> are subnet masks in CIDR
1470               notation, i.e. integer values from 2 to 30 representing the
1471               length (in bits) of the network address. The masks and the
1472               whole destination part are optional.</p>
1473
1474               <p>If your system implements <a href=
1475               "http://tools.ietf.org/html/rfc3493" target="_top">RFC
1476               3493</a>, then <tt class="REPLACEABLE"><i>src_addr</i></tt> and
1477               <tt class="REPLACEABLE"><i>dst_addr</i></tt> can be IPv6
1478               addresses delimeted by brackets, <tt class=
1479               "REPLACEABLE"><i>port</i></tt> can be a number or a service
1480               name, and <tt class="REPLACEABLE"><i>src_masklen</i></tt> and
1481               <tt class="REPLACEABLE"><i>dst_masklen</i></tt> can be a number
1482               from 0 to 128.</p>
1483             </dd>
1484
1485             <dt>Default value:</dt>
1486
1487             <dd>
1488               <p><span class="emphasis"><i class=
1489               "EMPHASIS">Unset</i></span></p>
1490
1491               <p>If no <tt class="REPLACEABLE"><i>port</i></tt> is specified,
1492               any port will match. If no <tt class=
1493               "REPLACEABLE"><i>src_masklen</i></tt> or <tt class=
1494               "REPLACEABLE"><i>src_masklen</i></tt> is given, the complete IP
1495               address has to match (i.e. 32 bits for IPv4 and 128 bits for
1496               IPv6).</p>
1497             </dd>
1498
1499             <dt>Effect if unset:</dt>
1500
1501             <dd>
1502               <p>Don't restrict access further than implied by <tt class=
1503               "LITERAL">listen-address</tt></p>
1504             </dd>
1505
1506             <dt>Notes:</dt>
1507
1508             <dd>
1509               <p>Access controls are included at the request of ISPs and
1510               systems administrators, and <span class="emphasis"><i class=
1511               "EMPHASIS">are not usually needed by individual
1512               users</i></span>. For a typical home user, it will normally
1513               suffice to ensure that <span class="APPLICATION">Privoxy</span>
1514               only listens on the localhost (127.0.0.1) or internal (home)
1515               network address by means of the <a href=
1516               "config.html#LISTEN-ADDRESS"><span class="emphasis"><i class=
1517               "EMPHASIS">listen-address</i></span></a> option.</p>
1518
1519               <p>Please see the warnings in the FAQ that <span class=
1520               "APPLICATION">Privoxy</span> is not intended to be a substitute
1521               for a firewall or to encourage anyone to defer addressing basic
1522               security weaknesses.</p>
1523
1524               <p>Multiple ACL lines are OK. If any ACLs are specified,
1525               <span class="APPLICATION">Privoxy</span> only talks to IP
1526               addresses that match at least one <tt class=
1527               "LITERAL">permit-access</tt> line and don't match any
1528               subsequent <tt class="LITERAL">deny-access</tt> line. In other
1529               words, the last match wins, with the default being <tt class=
1530               "LITERAL">deny-access</tt>.</p>
1531
1532               <p>If <span class="APPLICATION">Privoxy</span> is using a
1533               forwarder (see <tt class="LITERAL">forward</tt> below) for a
1534               particular destination URL, the <tt class=
1535               "REPLACEABLE"><i>dst_addr</i></tt> that is examined is the
1536               address of the forwarder and <span class="emphasis"><i class=
1537               "EMPHASIS">NOT</i></span> the address of the ultimate target.
1538               This is necessary because it may be impossible for the local
1539               <span class="APPLICATION">Privoxy</span> to determine the IP
1540               address of the ultimate target (that's often what gateways are
1541               used for).</p>
1542
1543               <p>You should prefer using IP addresses over DNS names, because
1544               the address lookups take time. All DNS names must resolve! You
1545               can <span class="emphasis"><i class="EMPHASIS">not</i></span>
1546               use domain patterns like <span class="QUOTE">"*.org"</span> or
1547               partial domain names. If a DNS name resolves to multiple IP
1548               addresses, only the first one is used.</p>
1549
1550               <p>Some systems allow IPv4 clients to connect to IPv6 server
1551               sockets. Then the client's IPv4 address will be translated by
1552               the system into IPv6 address space with special prefix
1553               ::ffff:0:0/96 (so called IPv4 mapped IPv6 address).
1554               <span class="APPLICATION">Privoxy</span> can handle it and maps
1555               such ACL addresses automatically.</p>
1556
1557               <p>Denying access to particular sites by ACL may have undesired
1558               side effects if the site in question is hosted on a machine
1559               which also hosts other sites (most sites are).</p>
1560             </dd>
1561
1562             <dt>Examples:</dt>
1563
1564             <dd>
1565               <p>Explicitly define the default behavior if no ACL and
1566               <tt class="LITERAL">listen-address</tt> are set: <span class=
1567               "QUOTE">"localhost"</span> is OK. The absence of a <tt class=
1568               "REPLACEABLE"><i>dst_addr</i></tt> implies that <span class=
1569               "emphasis"><i class="EMPHASIS">all</i></span> destination
1570               addresses are OK:</p>
1571
1572               <table border="0" bgcolor="#E0E0E0" width="90%">
1573                 <tr>
1574                   <td>
1575                     <pre class="SCREEN">
1576   permit-access  localhost
1577 </pre>
1578                   </td>
1579                 </tr>
1580               </table>
1581
1582               <p>Allow any host on the same class C subnet as www.privoxy.org
1583               access to nothing but www.example.com (or other domains hosted
1584               on the same system):</p>
1585
1586               <table border="0" bgcolor="#E0E0E0" width="90%">
1587                 <tr>
1588                   <td>
1589                     <pre class="SCREEN">
1590   permit-access  www.privoxy.org/24 www.example.com/32
1591 </pre>
1592                   </td>
1593                 </tr>
1594               </table>
1595
1596               <p>Allow access from any host on the 26-bit subnet
1597               192.168.45.64 to anywhere, with the exception that
1598               192.168.45.73 may not access the IP address behind
1599               www.dirty-stuff.example.com:</p>
1600
1601               <table border="0" bgcolor="#E0E0E0" width="90%">
1602                 <tr>
1603                   <td>
1604                     <pre class="SCREEN">
1605   permit-access  192.168.45.64/26
1606   deny-access    192.168.45.73    www.dirty-stuff.example.com
1607 </pre>
1608                   </td>
1609                 </tr>
1610               </table>
1611
1612               <p>Allow access from the IPv4 network 192.0.2.0/24 even if
1613               listening on an IPv6 wild card address (not supported on all
1614               platforms):</p>
1615
1616               <table border="0" bgcolor="#E0E0E0" width="90%">
1617                 <tr>
1618                   <td>
1619                     <pre class="PROGRAMLISTING">
1620   permit-access  192.0.2.0/24
1621 </pre>
1622                   </td>
1623                 </tr>
1624               </table>
1625
1626               <p>This is equivalent to the following line even if listening
1627               on an IPv4 address (not supported on all platforms):</p>
1628
1629               <table border="0" bgcolor="#E0E0E0" width="90%">
1630                 <tr>
1631                   <td>
1632                     <pre class="PROGRAMLISTING">
1633   permit-access  [::ffff:192.0.2.0]/120
1634 </pre>
1635                   </td>
1636                 </tr>
1637               </table>
1638             </dd>
1639           </dl>
1640         </div>
1641       </div>
1642
1643       <div class="SECT3">
1644         <h4 class="SECT3"><a name="BUFFER-LIMIT" id="BUFFER-LIMIT">7.4.8.
1645         buffer-limit</a></h4>
1646
1647         <div class="VARIABLELIST">
1648           <dl>
1649             <dt>Specifies:</dt>
1650
1651             <dd>
1652               <p>Maximum size of the buffer for content filtering.</p>
1653             </dd>
1654
1655             <dt>Type of value:</dt>
1656
1657             <dd>
1658               <p>Size in Kbytes</p>
1659             </dd>
1660
1661             <dt>Default value:</dt>
1662
1663             <dd>
1664               <p>4096</p>
1665             </dd>
1666
1667             <dt>Effect if unset:</dt>
1668
1669             <dd>
1670               <p>Use a 4MB (4096 KB) limit.</p>
1671             </dd>
1672
1673             <dt>Notes:</dt>
1674
1675             <dd>
1676               <p>For content filtering, i.e. the <tt class=
1677               "LITERAL">+filter</tt> and <tt class=
1678               "LITERAL">+deanimate-gif</tt> actions, it is necessary that
1679               <span class="APPLICATION">Privoxy</span> buffers the entire
1680               document body. This can be potentially dangerous, since a
1681               server could just keep sending data indefinitely and wait for
1682               your RAM to exhaust -- with nasty consequences. Hence this
1683               option.</p>
1684
1685               <p>When a document buffer size reaches the <tt class=
1686               "LITERAL">buffer-limit</tt>, it is flushed to the client
1687               unfiltered and no further attempt to filter the rest of the
1688               document is made. Remember that there may be multiple threads
1689               running, which might require up to <tt class=
1690               "LITERAL">buffer-limit</tt> Kbytes <span class=
1691               "emphasis"><i class="EMPHASIS">each</i></span>, unless you have
1692               enabled <span class="QUOTE">"single-threaded"</span> above.</p>
1693             </dd>
1694           </dl>
1695         </div>
1696       </div>
1697     </div>
1698
1699     <div class="SECT2">
1700       <h2 class="SECT2"><a name="FORWARDING" id="FORWARDING">7.5.
1701       Forwarding</a></h2>
1702
1703       <p>This feature allows routing of HTTP requests through a chain of
1704       multiple proxies.</p>
1705
1706       <p>Forwarding can be used to chain Privoxy with a caching proxy to
1707       speed up browsing. Using a parent proxy may also be necessary if the
1708       machine that <span class="APPLICATION">Privoxy</span> runs on has no
1709       direct Internet access.</p>
1710
1711       <p>Note that parent proxies can severely decrease your privacy level.
1712       For example a parent proxy could add your IP address to the request
1713       headers and if it's a caching proxy it may add the <span class=
1714       "QUOTE">"Etag"</span> header to revalidation requests again, even
1715       though you configured Privoxy to remove it. It may also ignore
1716       Privoxy's header time randomization and use the original values which
1717       could be used by the server as cookie replacement to track your steps
1718       between visits.</p>
1719
1720       <p>Also specified here are SOCKS proxies. <span class=
1721       "APPLICATION">Privoxy</span> supports the SOCKS 4 and SOCKS 4A
1722       protocols.</p>
1723
1724       <div class="SECT3">
1725         <h4 class="SECT3"><a name="FORWARD" id="FORWARD">7.5.1.
1726         forward</a></h4>
1727
1728         <div class="VARIABLELIST">
1729           <dl>
1730             <dt>Specifies:</dt>
1731
1732             <dd>
1733               <p>To which parent HTTP proxy specific requests should be
1734               routed.</p>
1735             </dd>
1736
1737             <dt>Type of value:</dt>
1738
1739             <dd>
1740               <p><tt class="REPLACEABLE"><i>target_pattern</i></tt>
1741               <tt class="REPLACEABLE"><i>http_parent</i></tt>[:<tt class=
1742               "REPLACEABLE"><i>port</i></tt>]</p>
1743
1744               <p>where <tt class="REPLACEABLE"><i>target_pattern</i></tt> is
1745               a <a href="actions-file.html#AF-PATTERNS">URL pattern</a> that
1746               specifies to which requests (i.e. URLs) this forward rule shall
1747               apply. Use <tt class="LITERAL">/</tt> to denote <span class=
1748               "QUOTE">"all URLs"</span>. <tt class=
1749               "REPLACEABLE"><i>http_parent</i></tt>[:<tt class=
1750               "REPLACEABLE"><i>port</i></tt>] is the DNS name or IP address
1751               of the parent HTTP proxy through which the requests should be
1752               forwarded, optionally followed by its listening port (default:
1753               8000). Use a single dot (<tt class="LITERAL">.</tt>) to denote
1754               <span class="QUOTE">"no forwarding"</span>.</p>
1755             </dd>
1756
1757             <dt>Default value:</dt>
1758
1759             <dd>
1760               <p><span class="emphasis"><i class=
1761               "EMPHASIS">Unset</i></span></p>
1762             </dd>
1763
1764             <dt>Effect if unset:</dt>
1765
1766             <dd>
1767               <p>Don't use parent HTTP proxies.</p>
1768             </dd>
1769
1770             <dt>Notes:</dt>
1771
1772             <dd>
1773               <p>If <tt class="REPLACEABLE"><i>http_parent</i></tt> is
1774               <span class="QUOTE">"."</span>, then requests are not forwarded
1775               to another HTTP proxy but are made directly to the web
1776               servers.</p>
1777
1778               <p><tt class="REPLACEABLE"><i>http_parent</i></tt> can be a
1779               numerical IPv6 address (if <a href=
1780               "http://tools.ietf.org/html/rfc3493" target="_top">RFC 3493</a>
1781               is implemented). To prevent clashes with the port delimiter,
1782               the whole IP address has to be put into brackets. On the other
1783               hand a <tt class="REPLACEABLE"><i>target_pattern</i></tt>
1784               containing an IPv6 address has to be put into angle brackets
1785               (normal brackets are reserved for regular expressions
1786               already).</p>
1787
1788               <p>Multiple lines are OK, they are checked in sequence, and the
1789               last match wins.</p>
1790             </dd>
1791
1792             <dt>Examples:</dt>
1793
1794             <dd>
1795               <p>Everything goes to an example parent proxy, except SSL on
1796               port 443 (which it doesn't handle):</p>
1797
1798               <table border="0" bgcolor="#E0E0E0" width="90%">
1799                 <tr>
1800                   <td>
1801                     <pre class="SCREEN">
1802   forward   /      parent-proxy.example.org:8080
1803   forward   :443   .
1804 </pre>
1805                   </td>
1806                 </tr>
1807               </table>
1808
1809               <p>Everything goes to our example ISP's caching proxy, except
1810               for requests to that ISP's sites:</p>
1811
1812               <table border="0" bgcolor="#E0E0E0" width="90%">
1813                 <tr>
1814                   <td>
1815                     <pre class="SCREEN">
1816   forward   /                  caching-proxy.isp.example.net:8000
1817   forward   .isp.example.net   .
1818 </pre>
1819                   </td>
1820                 </tr>
1821               </table>
1822
1823               <p>Parent proxy specified by an IPv6 address:</p>
1824
1825               <table border="0" bgcolor="#E0E0E0" width="90%">
1826                 <tr>
1827                   <td>
1828                     <pre class="PROGRAMLISTING">
1829   forward   /                   [2001:DB8::1]:8000
1830 </pre>
1831                   </td>
1832                 </tr>
1833               </table>
1834
1835               <p>Suppose your parent proxy doesn't support IPv6:</p>
1836
1837               <table border="0" bgcolor="#E0E0E0" width="90%">
1838                 <tr>
1839                   <td>
1840                     <pre class="PROGRAMLISTING">
1841   forward  /                        parent-proxy.example.org:8000
1842   forward  ipv6-server.example.org  .
1843   forward  &lt;[2-3][0-9a-f][0-9a-f][0-9a-f]:*&gt;   .
1844 </pre>
1845                   </td>
1846                 </tr>
1847               </table>
1848             </dd>
1849           </dl>
1850         </div>
1851       </div>
1852
1853       <div class="SECT3">
1854         <h4 class="SECT3"><a name="SOCKS" id="SOCKS">7.5.2. forward-socks4,
1855         forward-socks4a and forward-socks5</a></h4><a name="FORWARD-SOCKS4"
1856         id="FORWARD-SOCKS4"></a><a name="FORWARD-SOCKS4A" id=
1857         "FORWARD-SOCKS4A"></a>
1858
1859         <div class="VARIABLELIST">
1860           <dl>
1861             <dt>Specifies:</dt>
1862
1863             <dd>
1864               <p>Through which SOCKS proxy (and optionally to which parent
1865               HTTP proxy) specific requests should be routed.</p>
1866             </dd>
1867
1868             <dt>Type of value:</dt>
1869
1870             <dd>
1871               <p><tt class="REPLACEABLE"><i>target_pattern</i></tt>
1872               <tt class="REPLACEABLE"><i>socks_proxy</i></tt>[:<tt class=
1873               "REPLACEABLE"><i>port</i></tt>] <tt class=
1874               "REPLACEABLE"><i>http_parent</i></tt>[:<tt class=
1875               "REPLACEABLE"><i>port</i></tt>]</p>
1876
1877               <p>where <tt class="REPLACEABLE"><i>target_pattern</i></tt> is
1878               a <a href="actions-file.html#AF-PATTERNS">URL pattern</a> that
1879               specifies to which requests (i.e. URLs) this forward rule shall
1880               apply. Use <tt class="LITERAL">/</tt> to denote <span class=
1881               "QUOTE">"all URLs"</span>. <tt class=
1882               "REPLACEABLE"><i>http_parent</i></tt> and <tt class=
1883               "REPLACEABLE"><i>socks_proxy</i></tt> are IP addresses in
1884               dotted decimal notation or valid DNS names (<tt class=
1885               "REPLACEABLE"><i>http_parent</i></tt> may be <span class=
1886               "QUOTE">"."</span> to denote <span class="QUOTE">"no HTTP
1887               forwarding"</span>), and the optional <tt class=
1888               "REPLACEABLE"><i>port</i></tt> parameters are TCP ports, i.e.
1889               integer values from 1 to 65535</p>
1890             </dd>
1891
1892             <dt>Default value:</dt>
1893
1894             <dd>
1895               <p><span class="emphasis"><i class=
1896               "EMPHASIS">Unset</i></span></p>
1897             </dd>
1898
1899             <dt>Effect if unset:</dt>
1900
1901             <dd>
1902               <p>Don't use SOCKS proxies.</p>
1903             </dd>
1904
1905             <dt>Notes:</dt>
1906
1907             <dd>
1908               <p>Multiple lines are OK, they are checked in sequence, and the
1909               last match wins.</p>
1910
1911               <p>The difference between <tt class=
1912               "LITERAL">forward-socks4</tt> and <tt class=
1913               "LITERAL">forward-socks4a</tt> is that in the SOCKS 4A
1914               protocol, the DNS resolution of the target hostname happens on
1915               the SOCKS server, while in SOCKS 4 it happens locally.</p>
1916
1917               <p>With <tt class="LITERAL">forward-socks5</tt> the DNS
1918               resolution will happen on the remote server as well.</p>
1919
1920               <p><tt class="REPLACEABLE"><i>socks_proxy</i></tt> and
1921               <tt class="REPLACEABLE"><i>http_parent</i></tt> can be a
1922               numerical IPv6 address (if <a href=
1923               "http://tools.ietf.org/html/rfc3493" target="_top">RFC 3493</a>
1924               is implemented). To prevent clashes with the port delimiter,
1925               the whole IP address has to be put into brackets. On the other
1926               hand a <tt class="REPLACEABLE"><i>target_pattern</i></tt>
1927               containing an IPv6 address has to be put into angle brackets
1928               (normal brackets are reserved for regular expressions
1929               already).</p>
1930
1931               <p>If <tt class="REPLACEABLE"><i>http_parent</i></tt> is
1932               <span class="QUOTE">"."</span>, then requests are not forwarded
1933               to another HTTP proxy but are made (HTTP-wise) directly to the
1934               web servers, albeit through a SOCKS proxy.</p>
1935             </dd>
1936
1937             <dt>Examples:</dt>
1938
1939             <dd>
1940               <p>From the company example.com, direct connections are made to
1941               all <span class="QUOTE">"internal"</span> domains, but
1942               everything outbound goes through their ISP's proxy by way of
1943               example.com's corporate SOCKS 4A gateway to the Internet.</p>
1944
1945               <table border="0" bgcolor="#E0E0E0" width="90%">
1946                 <tr>
1947                   <td>
1948                     <pre class="SCREEN">
1949   forward-socks4a   /              socks-gw.example.com:1080  www-cache.isp.example.net:8080
1950   forward           .example.com   .
1951 </pre>
1952                   </td>
1953                 </tr>
1954               </table>
1955
1956               <p>A rule that uses a SOCKS 4 gateway for all destinations but
1957               no HTTP parent looks like this:</p>
1958
1959               <table border="0" bgcolor="#E0E0E0" width="90%">
1960                 <tr>
1961                   <td>
1962                     <pre class="SCREEN">
1963   forward-socks4   /               socks-gw.example.com:1080  .
1964 </pre>
1965                   </td>
1966                 </tr>
1967               </table>
1968
1969               <p>To chain Privoxy and Tor, both running on the same system,
1970               you would use something like:</p>
1971
1972               <table border="0" bgcolor="#E0E0E0" width="90%">
1973                 <tr>
1974                   <td>
1975                     <pre class="SCREEN">
1976   forward-socks5   /               127.0.0.1:9050 .
1977 </pre>
1978                   </td>
1979                 </tr>
1980               </table>
1981
1982               <p>The public <span class="APPLICATION">Tor</span> network
1983               can't be used to reach your local network, if you need to
1984               access local servers you therefore might want to make some
1985               exceptions:</p>
1986
1987               <table border="0" bgcolor="#E0E0E0" width="90%">
1988                 <tr>
1989                   <td>
1990                     <pre class="SCREEN">
1991   forward         192.168.*.*/     .
1992   forward            10.*.*.*/     .
1993   forward           127.*.*.*/     .
1994 </pre>
1995                   </td>
1996                 </tr>
1997               </table>
1998
1999               <p>Unencrypted connections to systems in these address ranges
2000               will be as (un)secure as the local network is, but the
2001               alternative is that you can't reach the local network through
2002               <span class="APPLICATION">Privoxy</span> at all. Of course this
2003               may actually be desired and there is no reason to make these
2004               exceptions if you aren't sure you need them.</p>
2005
2006               <p>If you also want to be able to reach servers in your local
2007               network by using their names, you will need additional
2008               exceptions that look like this:</p>
2009
2010               <table border="0" bgcolor="#E0E0E0" width="90%">
2011                 <tr>
2012                   <td>
2013                     <pre class="SCREEN">
2014  forward           localhost/     .
2015 </pre>
2016                   </td>
2017                 </tr>
2018               </table>
2019             </dd>
2020           </dl>
2021         </div>
2022       </div>
2023
2024       <div class="SECT3">
2025         <h4 class="SECT3"><a name="ADVANCED-FORWARDING-EXAMPLES" id=
2026         "ADVANCED-FORWARDING-EXAMPLES">7.5.3. Advanced Forwarding
2027         Examples</a></h4>
2028
2029         <p>If you have links to multiple ISPs that provide various special
2030         content only to their subscribers, you can configure multiple
2031         <span class="APPLICATION">Privoxies</span> which have connections to
2032         the respective ISPs to act as forwarders to each other, so that
2033         <span class="emphasis"><i class="EMPHASIS">your</i></span> users can
2034         see the internal content of all ISPs.</p>
2035
2036         <p>Assume that host-a has a PPP connection to isp-a.example.net. And
2037         host-b has a PPP connection to isp-b.example.org. Both run
2038         <span class="APPLICATION">Privoxy</span>. Their forwarding
2039         configuration can look like this:</p>
2040
2041         <p>host-a:</p>
2042
2043         <table border="0" bgcolor="#E0E0E0" width="100%">
2044           <tr>
2045             <td>
2046               <pre class="SCREEN">
2047   forward    /           .
2048   forward    .isp-b.example.net  host-b:8118
2049 </pre>
2050             </td>
2051           </tr>
2052         </table>
2053
2054         <p>host-b:</p>
2055
2056         <table border="0" bgcolor="#E0E0E0" width="100%">
2057           <tr>
2058             <td>
2059               <pre class="SCREEN">
2060   forward    /           .
2061   forward    .isp-a.example.org  host-a:8118
2062 </pre>
2063             </td>
2064           </tr>
2065         </table>
2066
2067         <p>Now, your users can set their browser's proxy to use either host-a
2068         or host-b and be able to browse the internal content of both isp-a
2069         and isp-b.</p>
2070
2071         <p>If you intend to chain <span class="APPLICATION">Privoxy</span>
2072         and <span class="APPLICATION">squid</span> locally, then chaining as
2073         <tt class="LITERAL">browser -&gt; squid -&gt; privoxy</tt> is the
2074         recommended way.</p>
2075
2076         <p>Assuming that <span class="APPLICATION">Privoxy</span> and
2077         <span class="APPLICATION">squid</span> run on the same box, your
2078         <span class="APPLICATION">squid</span> configuration could then look
2079         like this:</p>
2080
2081         <table border="0" bgcolor="#E0E0E0" width="100%">
2082           <tr>
2083             <td>
2084               <pre class="SCREEN">
2085   # Define Privoxy as parent proxy (without ICP)
2086   cache_peer 127.0.0.1 parent 8118 7 no-query
2087
2088   # Define ACL for protocol FTP
2089   acl ftp proto FTP
2090
2091   # Do not forward FTP requests to Privoxy
2092   always_direct allow ftp
2093
2094   # Forward all the rest to Privoxy
2095   never_direct allow all
2096 </pre>
2097             </td>
2098           </tr>
2099         </table>
2100
2101         <p>You would then need to change your browser's proxy settings to
2102         <span class="APPLICATION">squid</span>'s address and port. Squid
2103         normally uses port 3128. If unsure consult <tt class=
2104         "LITERAL">http_port</tt> in <tt class="FILENAME">squid.conf</tt>.</p>
2105
2106         <p>You could just as well decide to only forward requests you suspect
2107         of leading to Windows executables through a virus-scanning parent
2108         proxy, say, on <tt class="LITERAL">antivir.example.com</tt>, port
2109         8010:</p>
2110
2111         <table border="0" bgcolor="#E0E0E0" width="100%">
2112           <tr>
2113             <td>
2114               <pre class="SCREEN">
2115   forward   /                          .
2116   forward   /.*\.(exe|com|dll|zip)$    antivir.example.com:8010
2117 </pre>
2118             </td>
2119           </tr>
2120         </table>
2121       </div>
2122
2123       <div class="SECT3">
2124         <h4 class="SECT3"><a name="FORWARDED-CONNECT-RETRIES" id=
2125         "FORWARDED-CONNECT-RETRIES">7.5.4. forwarded-connect-retries</a></h4>
2126
2127         <div class="VARIABLELIST">
2128           <dl>
2129             <dt>Specifies:</dt>
2130
2131             <dd>
2132               <p>How often Privoxy retries if a forwarded connection request
2133               fails.</p>
2134             </dd>
2135
2136             <dt>Type of value:</dt>
2137
2138             <dd>
2139               <p><tt class="REPLACEABLE"><i>Number of retries.</i></tt></p>
2140             </dd>
2141
2142             <dt>Default value:</dt>
2143
2144             <dd>
2145               <p><span class="emphasis"><i class="EMPHASIS">0</i></span></p>
2146             </dd>
2147
2148             <dt>Effect if unset:</dt>
2149
2150             <dd>
2151               <p>Connections forwarded through other proxies are treated like
2152               direct connections and no retry attempts are made.</p>
2153             </dd>
2154
2155             <dt>Notes:</dt>
2156
2157             <dd>
2158               <p><tt class=
2159               "REPLACEABLE"><i>forwarded-connect-retries</i></tt> is mainly
2160               interesting for socks4a connections, where <span class=
2161               "APPLICATION">Privoxy</span> can't detect why the connections
2162               failed. The connection might have failed because of a DNS
2163               timeout in which case a retry makes sense, but it might also
2164               have failed because the server doesn't exist or isn't
2165               reachable. In this case the retry will just delay the
2166               appearance of Privoxy's error message.</p>
2167
2168               <p>Note that in the context of this option, <span class=
2169               "QUOTE">"forwarded connections"</span> includes all connections
2170               that Privoxy forwards through other proxies. This option is not
2171               limited to the HTTP CONNECT method.</p>
2172
2173               <p>Only use this option, if you are getting lots of
2174               forwarding-related error messages that go away when you try
2175               again manually. Start with a small value and check Privoxy's
2176               logfile from time to time, to see how many retries are usually
2177               needed.</p>
2178             </dd>
2179
2180             <dt>Examples:</dt>
2181
2182             <dd>
2183               <p>forwarded-connect-retries 1</p>
2184             </dd>
2185           </dl>
2186         </div>
2187       </div>
2188     </div>
2189
2190     <div class="SECT2">
2191       <h2 class="SECT2"><a name="MISC" id="MISC">7.6. Miscellaneous</a></h2>
2192
2193       <div class="SECT3">
2194         <h4 class="SECT3"><a name="ACCEPT-INTERCEPTED-REQUESTS" id=
2195         "ACCEPT-INTERCEPTED-REQUESTS">7.6.1.
2196         accept-intercepted-requests</a></h4>
2197
2198         <div class="VARIABLELIST">
2199           <dl>
2200             <dt>Specifies:</dt>
2201
2202             <dd>
2203               <p>Whether intercepted requests should be treated as valid.</p>
2204             </dd>
2205
2206             <dt>Type of value:</dt>
2207
2208             <dd>
2209               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
2210             </dd>
2211
2212             <dt>Default value:</dt>
2213
2214             <dd>
2215               <p><span class="emphasis"><i class="EMPHASIS">0</i></span></p>
2216             </dd>
2217
2218             <dt>Effect if unset:</dt>
2219
2220             <dd>
2221               <p>Only proxy requests are accepted, intercepted requests are
2222               treated as invalid.</p>
2223             </dd>
2224
2225             <dt>Notes:</dt>
2226
2227             <dd>
2228               <p>If you don't trust your clients and want to force them to
2229               use <span class="APPLICATION">Privoxy</span>, enable this
2230               option and configure your packet filter to redirect outgoing
2231               HTTP connections into <span class=
2232               "APPLICATION">Privoxy</span>.</p>
2233
2234               <p>Make sure that <span class="APPLICATION">Privoxy's</span>
2235               own requests aren't redirected as well. Additionally take care
2236               that <span class="APPLICATION">Privoxy</span> can't
2237               intentionally connect to itself, otherwise you could run into
2238               redirection loops if <span class="APPLICATION">Privoxy's</span>
2239               listening port is reachable by the outside or an attacker has
2240               access to the pages you visit.</p>
2241             </dd>
2242
2243             <dt>Examples:</dt>
2244
2245             <dd>
2246               <p>accept-intercepted-requests 1</p>
2247             </dd>
2248           </dl>
2249         </div>
2250       </div>
2251
2252       <div class="SECT3">
2253         <h4 class="SECT3"><a name="ALLOW-CGI-REQUEST-CRUNCHING" id=
2254         "ALLOW-CGI-REQUEST-CRUNCHING">7.6.2.
2255         allow-cgi-request-crunching</a></h4>
2256
2257         <div class="VARIABLELIST">
2258           <dl>
2259             <dt>Specifies:</dt>
2260
2261             <dd>
2262               <p>Whether requests to <span class=
2263               "APPLICATION">Privoxy's</span> CGI pages can be blocked or
2264               redirected.</p>
2265             </dd>
2266
2267             <dt>Type of value:</dt>
2268
2269             <dd>
2270               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
2271             </dd>
2272
2273             <dt>Default value:</dt>
2274
2275             <dd>
2276               <p><span class="emphasis"><i class="EMPHASIS">0</i></span></p>
2277             </dd>
2278
2279             <dt>Effect if unset:</dt>
2280
2281             <dd>
2282               <p><span class="APPLICATION">Privoxy</span> ignores block and
2283               redirect actions for its CGI pages.</p>
2284             </dd>
2285
2286             <dt>Notes:</dt>
2287
2288             <dd>
2289               <p>By default <span class="APPLICATION">Privoxy</span> ignores
2290               block or redirect actions for its CGI pages. Intercepting these
2291               requests can be useful in multi-user setups to implement
2292               fine-grained access control, but it can also render the
2293               complete web interface useless and make debugging problems
2294               painful if done without care.</p>
2295
2296               <p>Don't enable this option unless you're sure that you really
2297               need it.</p>
2298             </dd>
2299
2300             <dt>Examples:</dt>
2301
2302             <dd>
2303               <p>allow-cgi-request-crunching 1</p>
2304             </dd>
2305           </dl>
2306         </div>
2307       </div>
2308
2309       <div class="SECT3">
2310         <h4 class="SECT3"><a name="SPLIT-LARGE-FORMS" id=
2311         "SPLIT-LARGE-FORMS">7.6.3. split-large-forms</a></h4>
2312
2313         <div class="VARIABLELIST">
2314           <dl>
2315             <dt>Specifies:</dt>
2316
2317             <dd>
2318               <p>Whether the CGI interface should stay compatible with broken
2319               HTTP clients.</p>
2320             </dd>
2321
2322             <dt>Type of value:</dt>
2323
2324             <dd>
2325               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
2326             </dd>
2327
2328             <dt>Default value:</dt>
2329
2330             <dd>
2331               <p><span class="emphasis"><i class="EMPHASIS">0</i></span></p>
2332             </dd>
2333
2334             <dt>Effect if unset:</dt>
2335
2336             <dd>
2337               <p>The CGI form generate long GET URLs.</p>
2338             </dd>
2339
2340             <dt>Notes:</dt>
2341
2342             <dd>
2343               <p><span class="APPLICATION">Privoxy's</span> CGI forms can
2344               lead to rather long URLs. This isn't a problem as far as the
2345               HTTP standard is concerned, but it can confuse clients with
2346               arbitrary URL length limitations.</p>
2347
2348               <p>Enabling split-large-forms causes <span class=
2349               "APPLICATION">Privoxy</span> to divide big forms into smaller
2350               ones to keep the URL length down. It makes editing a lot less
2351               convenient and you can no longer submit all changes at once,
2352               but at least it works around this browser bug.</p>
2353
2354               <p>If you don't notice any editing problems, there is no reason
2355               to enable this option, but if one of the submit buttons appears
2356               to be broken, you should give it a try.</p>
2357             </dd>
2358
2359             <dt>Examples:</dt>
2360
2361             <dd>
2362               <p>split-large-forms 1</p>
2363             </dd>
2364           </dl>
2365         </div>
2366       </div>
2367
2368       <div class="SECT3">
2369         <h4 class="SECT3"><a name="KEEP-ALIVE-TIMEOUT" id=
2370         "KEEP-ALIVE-TIMEOUT">7.6.4. keep-alive-timeout</a></h4>
2371
2372         <div class="VARIABLELIST">
2373           <dl>
2374             <dt>Specifies:</dt>
2375
2376             <dd>
2377               <p>Number of seconds after which an open connection will no
2378               longer be reused.</p>
2379             </dd>
2380
2381             <dt>Type of value:</dt>
2382
2383             <dd>
2384               <p><tt class="REPLACEABLE"><i>Time in seconds.</i></tt></p>
2385             </dd>
2386
2387             <dt>Default value:</dt>
2388
2389             <dd>
2390               <p>None</p>
2391             </dd>
2392
2393             <dt>Effect if unset:</dt>
2394
2395             <dd>
2396               <p>Connections are not kept alive.</p>
2397             </dd>
2398
2399             <dt>Notes:</dt>
2400
2401             <dd>
2402               <p>This option allows clients to keep the connection to
2403               <span class="APPLICATION">Privoxy</span> alive. If the server
2404               supports it, <span class="APPLICATION">Privoxy</span> will keep
2405               the connection to the server alive as well. Under certain
2406               circumstances this may result in speed-ups.</p>
2407
2408               <p>By default, <span class="APPLICATION">Privoxy</span> will
2409               close the connection to the server if the client connection
2410               gets closed, or if the specified timeout has been reached
2411               without a new request coming in. This behaviour can be changed
2412               with the <a href="#CONNECTION-SHARING" target=
2413               "_top">connection-sharing</a> option.</p>
2414
2415               <p>This option has no effect if <span class=
2416               "APPLICATION">Privoxy</span> has been compiled without
2417               keep-alive support.</p>
2418
2419               <p>Note that a timeout of five seconds as used in the default
2420               configuration file significantly decreases the number of
2421               connections that will be reused. The value is used because some
2422               browsers limit the number of connections they open to a single
2423               host and apply the same limit to proxies. This can result in a
2424               single website <span class="QUOTE">"grabbing"</span> all the
2425               connections the browser allows, which means connections to
2426               other websites can't be opened until the connections currently
2427               in use time out.</p>
2428
2429               <p>Several users have reported this as a Privoxy bug, so the
2430               default value has been reduced. Consider increasing it to 300
2431               seconds or even more if you think your browser can handle it.
2432               If your browser appears to be hanging it can't.</p>
2433             </dd>
2434
2435             <dt>Examples:</dt>
2436
2437             <dd>
2438               <p>keep-alive-timeout 300</p>
2439             </dd>
2440           </dl>
2441         </div>
2442       </div>
2443
2444       <div class="SECT3">
2445         <h4 class="SECT3"><a name="DEFAULT-SERVER-TIMEOUT" id=
2446         "DEFAULT-SERVER-TIMEOUT">7.6.5. default-server-timeout</a></h4>
2447
2448         <div class="VARIABLELIST">
2449           <dl>
2450             <dt>Specifies:</dt>
2451
2452             <dd>
2453               <p>Assumed server-side keep-alive timeout if not specified by
2454               the server.</p>
2455             </dd>
2456
2457             <dt>Type of value:</dt>
2458
2459             <dd>
2460               <p><tt class="REPLACEABLE"><i>Time in seconds.</i></tt></p>
2461             </dd>
2462
2463             <dt>Default value:</dt>
2464
2465             <dd>
2466               <p>None</p>
2467             </dd>
2468
2469             <dt>Effect if unset:</dt>
2470
2471             <dd>
2472               <p>Connections for which the server didn't specify the
2473               keep-alive timeout are not reused.</p>
2474             </dd>
2475
2476             <dt>Notes:</dt>
2477
2478             <dd>
2479               <p>Enabling this option significantly increases the number of
2480               connections that are reused, provided the <a href=
2481               "#KEEP-ALIVE-TIMEOUT" target="_top">keep-alive-timeout</a>
2482               option is also enabled.</p>
2483
2484               <p>While it also increases the number of connections problems
2485               when <span class="APPLICATION">Privoxy</span> tries to reuse a
2486               connection that already has been closed on the server side, or
2487               is closed while <span class="APPLICATION">Privoxy</span> is
2488               trying to reuse it, this should only be a problem if it happens
2489               for the first request sent by the client. If it happens for
2490               requests on reused client connections, <span class=
2491               "APPLICATION">Privoxy</span> will simply close the connection
2492               and the client is supposed to retry the request without
2493               bothering the user.</p>
2494
2495               <p>Enabling this option is therefore only recommended if the
2496               <a href="#CONNECTION-SHARING" target=
2497               "_top">connection-sharing</a> option is disabled.</p>
2498
2499               <p>It is an error to specify a value larger than the <a href=
2500               "#KEEP-ALIVE-TIMEOUT" target="_top">keep-alive-timeout</a>
2501               value.</p>
2502
2503               <p>This option has no effect if <span class=
2504               "APPLICATION">Privoxy</span> has been compiled without
2505               keep-alive support.</p>
2506             </dd>
2507
2508             <dt>Examples:</dt>
2509
2510             <dd>
2511               <p>default-server-timeout 60</p>
2512             </dd>
2513           </dl>
2514         </div>
2515       </div>
2516
2517       <div class="SECT3">
2518         <h4 class="SECT3"><a name="CONNECTION-SHARING" id=
2519         "CONNECTION-SHARING">7.6.6. connection-sharing</a></h4>
2520
2521         <div class="VARIABLELIST">
2522           <dl>
2523             <dt>Specifies:</dt>
2524
2525             <dd>
2526               <p>Whether or not outgoing connections that have been kept
2527               alive should be shared between different incoming
2528               connections.</p>
2529             </dd>
2530
2531             <dt>Type of value:</dt>
2532
2533             <dd>
2534               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
2535             </dd>
2536
2537             <dt>Default value:</dt>
2538
2539             <dd>
2540               <p>None</p>
2541             </dd>
2542
2543             <dt>Effect if unset:</dt>
2544
2545             <dd>
2546               <p>Connections are not shared.</p>
2547             </dd>
2548
2549             <dt>Notes:</dt>
2550
2551             <dd>
2552               <p>This option has no effect if <span class=
2553               "APPLICATION">Privoxy</span> has been compiled without
2554               keep-alive support, or if it's disabled.</p>
2555             </dd>
2556
2557             <dt>Notes:</dt>
2558
2559             <dd>
2560               <p>Note that reusing connections doesn't necessary cause
2561               speedups. There are also a few privacy implications you should
2562               be aware of.</p>
2563
2564               <p>If this option is effective, outgoing connections are shared
2565               between clients (if there are more than one) and closing the
2566               browser that initiated the outgoing connection does no longer
2567               affect the connection between <span class=
2568               "APPLICATION">Privoxy</span> and the server unless the client's
2569               request hasn't been completed yet.</p>
2570
2571               <p>If the outgoing connection is idle, it will not be closed
2572               until either <span class="APPLICATION">Privoxy's</span> or the
2573               server's timeout is reached. While it's open, the server knows
2574               that the system running <span class=
2575               "APPLICATION">Privoxy</span> is still there.</p>
2576
2577               <p>If there are more than one client (maybe even belonging to
2578               multiple users), they will be able to reuse each others
2579               connections. This is potentially dangerous in case of
2580               authentication schemes like NTLM where only the connection is
2581               authenticated, instead of requiring authentication for each
2582               request.</p>
2583
2584               <p>If there is only a single client, and if said client can
2585               keep connections alive on its own, enabling this option has
2586               next to no effect. If the client doesn't support connection
2587               keep-alive, enabling this option may make sense as it allows
2588               <span class="APPLICATION">Privoxy</span> to keep outgoing
2589               connections alive even if the client itself doesn't support
2590               it.</p>
2591
2592               <p>You should also be aware that enabling this option increases
2593               the likelihood of getting the "No server or forwarder data"
2594               error message, especially if you are using a slow connection to
2595               the Internet.</p>
2596
2597               <p>This option should only be used by experienced users who
2598               understand the risks and can weight them against the
2599               benefits.</p>
2600             </dd>
2601
2602             <dt>Examples:</dt>
2603
2604             <dd>
2605               <p>connection-sharing 1</p>
2606             </dd>
2607           </dl>
2608         </div>
2609       </div>
2610
2611       <div class="SECT3">
2612         <h4 class="SECT3"><a name="SOCKET-TIMEOUT" id="SOCKET-TIMEOUT">7.6.7.
2613         socket-timeout</a></h4>
2614
2615         <div class="VARIABLELIST">
2616           <dl>
2617             <dt>Specifies:</dt>
2618
2619             <dd>
2620               <p>Number of seconds after which a socket times out if no data
2621               is received.</p>
2622             </dd>
2623
2624             <dt>Type of value:</dt>
2625
2626             <dd>
2627               <p><tt class="REPLACEABLE"><i>Time in seconds.</i></tt></p>
2628             </dd>
2629
2630             <dt>Default value:</dt>
2631
2632             <dd>
2633               <p>None</p>
2634             </dd>
2635
2636             <dt>Effect if unset:</dt>
2637
2638             <dd>
2639               <p>A default value of 300 seconds is used.</p>
2640             </dd>
2641
2642             <dt>Notes:</dt>
2643
2644             <dd>
2645               <p>The default is quite high and you probably want to reduce
2646               it. If you aren't using an occasionally slow proxy like Tor,
2647               reducing it to a few seconds should be fine.</p>
2648             </dd>
2649
2650             <dt>Examples:</dt>
2651
2652             <dd>
2653               <p>socket-timeout 300</p>
2654             </dd>
2655           </dl>
2656         </div>
2657       </div>
2658
2659       <div class="SECT3">
2660         <h4 class="SECT3"><a name="MAX-CLIENT-CONNECTIONS" id=
2661         "MAX-CLIENT-CONNECTIONS">7.6.8. max-client-connections</a></h4>
2662
2663         <div class="VARIABLELIST">
2664           <dl>
2665             <dt>Specifies:</dt>
2666
2667             <dd>
2668               <p>Maximum number of client connections that will be
2669               served.</p>
2670             </dd>
2671
2672             <dt>Type of value:</dt>
2673
2674             <dd>
2675               <p><tt class="REPLACEABLE"><i>Positive number.</i></tt></p>
2676             </dd>
2677
2678             <dt>Default value:</dt>
2679
2680             <dd>
2681               <p>None</p>
2682             </dd>
2683
2684             <dt>Effect if unset:</dt>
2685
2686             <dd>
2687               <p>Connections are served until a resource limit is
2688               reached.</p>
2689             </dd>
2690
2691             <dt>Notes:</dt>
2692
2693             <dd>
2694               <p><span class="APPLICATION">Privoxy</span> creates one thread
2695               (or process) for every incoming client connection that isn't
2696               rejected based on the access control settings.</p>
2697
2698               <p>If the system is powerful enough, <span class=
2699               "APPLICATION">Privoxy</span> can theoretically deal with
2700               several hundred (or thousand) connections at the same time, but
2701               some operating systems enforce resource limits by shutting down
2702               offending processes and their default limits may be below the
2703               ones <span class="APPLICATION">Privoxy</span> would require
2704               under heavy load.</p>
2705
2706               <p>Configuring <span class="APPLICATION">Privoxy</span> to
2707               enforce a connection limit below the thread or process limit
2708               used by the operating system makes sure this doesn't happen.
2709               Simply increasing the operating system's limit would work too,
2710               but if <span class="APPLICATION">Privoxy</span> isn't the only
2711               application running on the system, you may actually want to
2712               limit the resources used by <span class=
2713               "APPLICATION">Privoxy</span>.</p>
2714
2715               <p>If <span class="APPLICATION">Privoxy</span> is only used by
2716               a single trusted user, limiting the number of client
2717               connections is probably unnecessary. If there are multiple
2718               possibly untrusted users you probably still want to
2719               additionally use a packet filter to limit the maximal number of
2720               incoming connections per client. Otherwise a malicious user
2721               could intentionally create a high number of connections to
2722               prevent other users from using <span class=
2723               "APPLICATION">Privoxy</span>.</p>
2724
2725               <p>Obviously using this option only makes sense if you choose a
2726               limit below the one enforced by the operating system.</p>
2727             </dd>
2728
2729             <dt>Examples:</dt>
2730
2731             <dd>
2732               <p>max-client-connections 256</p>
2733             </dd>
2734           </dl>
2735         </div>
2736       </div>
2737
2738       <div class="SECT3">
2739         <h4 class="SECT3"><a name="HANDLE-AS-EMPTY-DOC-RETURNS-OK" id=
2740         "HANDLE-AS-EMPTY-DOC-RETURNS-OK">7.6.9.
2741         handle-as-empty-doc-returns-ok</a></h4>
2742
2743         <div class="VARIABLELIST">
2744           <dl>
2745             <dt>Specifies:</dt>
2746
2747             <dd>
2748               <p>The status code Privoxy returns for pages blocked with
2749               <tt class="LITERAL"><a href=
2750               "actions-file.html#HANDLE-AS-EMPTY-DOCUMENT" target=
2751               "_top">+handle-as-empty-document</a></tt>.</p>
2752             </dd>
2753
2754             <dt>Type of value:</dt>
2755
2756             <dd>
2757               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
2758             </dd>
2759
2760             <dt>Default value:</dt>
2761
2762             <dd>
2763               <p>0</p>
2764             </dd>
2765
2766             <dt>Effect if unset:</dt>
2767
2768             <dd>
2769               <p>Privoxy returns a status 403(forbidden) for all blocked
2770               pages.</p>
2771             </dd>
2772
2773             <dt>Effect if set:</dt>
2774
2775             <dd>
2776               <p>Privoxy returns a status 200(OK) for pages blocked with
2777               +handle-as-empty-document and a status 403(Forbidden) for all
2778               other blocked pages.</p>
2779             </dd>
2780
2781             <dt>Notes:</dt>
2782
2783             <dd>
2784               <p>This is a work-around for Firefox bug 492459: <span class=
2785               "QUOTE">" Websites are no longer rendered if SSL requests for
2786               JavaScripts are blocked by a proxy. "</span> (<a href=
2787               "https://bugzilla.mozilla.org/show_bug.cgi?id=492459" target=
2788               "_top">https://bugzilla.mozilla.org/show_bug.cgi?id=492459</a>)
2789               As the bug has been fixed for quite some time this option
2790               should no longer be needed and will be removed in a future
2791               release. Please speak up if you have a reason why the option
2792               should be kept around.</p>
2793             </dd>
2794           </dl>
2795         </div>
2796       </div>
2797
2798       <div class="SECT3">
2799         <h4 class="SECT3"><a name="ENABLE-COMPRESSION" id=
2800         "ENABLE-COMPRESSION">7.6.10. enable-compression</a></h4>
2801
2802         <div class="VARIABLELIST">
2803           <dl>
2804             <dt>Specifies:</dt>
2805
2806             <dd>
2807               <p>Whether or not buffered content is compressed before
2808               delivery.</p>
2809             </dd>
2810
2811             <dt>Type of value:</dt>
2812
2813             <dd>
2814               <p><tt class="REPLACEABLE"><i>0 or 1</i></tt></p>
2815             </dd>
2816
2817             <dt>Default value:</dt>
2818
2819             <dd>
2820               <p>0</p>
2821             </dd>
2822
2823             <dt>Effect if unset:</dt>
2824
2825             <dd>
2826               <p>Privoxy does not compress buffered content.</p>
2827             </dd>
2828
2829             <dt>Effect if set:</dt>
2830
2831             <dd>
2832               <p>Privoxy compresses buffered content before delivering it to
2833               the client, provided the client supports it.</p>
2834             </dd>
2835
2836             <dt>Notes:</dt>
2837
2838             <dd>
2839               <p>This directive is only supported if Privoxy has been
2840               compiled with FEATURE_COMPRESSION, which should not to be
2841               confused with FEATURE_ZLIB.</p>
2842
2843               <p>Compressing buffered content is mainly useful if Privoxy and
2844               the client are running on different systems. If they are
2845               running on the same system, enabling compression is likely to
2846               slow things down. If you didn't measure otherwise, you should
2847               assume that it does and keep this option disabled.</p>
2848
2849               <p>Privoxy will not compress buffered content below a certain
2850               length.</p>
2851             </dd>
2852           </dl>
2853         </div>
2854       </div>
2855
2856       <div class="SECT3">
2857         <h4 class="SECT3"><a name="COMPRESSION-LEVEL" id=
2858         "COMPRESSION-LEVEL">7.6.11. compression-level</a></h4>
2859
2860         <div class="VARIABLELIST">
2861           <dl>
2862             <dt>Specifies:</dt>
2863
2864             <dd>
2865               <p>The compression level that is passed to the zlib library
2866               when compressing buffered content.</p>
2867             </dd>
2868
2869             <dt>Type of value:</dt>
2870
2871             <dd>
2872               <p><tt class="REPLACEABLE"><i>Positive number ranging from 0 to
2873               9.</i></tt></p>
2874             </dd>
2875
2876             <dt>Default value:</dt>
2877
2878             <dd>
2879               <p>1</p>
2880             </dd>
2881
2882             <dt>Notes:</dt>
2883
2884             <dd>
2885               <p>Compressing the data more takes usually longer than
2886               compressing it less or not compressing it at all. Which level
2887               is best depends on the connection between Privoxy and the
2888               client. If you can't be bothered to benchmark it for yourself,
2889               you should stick with the default and keep compression
2890               disabled.</p>
2891
2892               <p>If compression is disabled, the compression level is
2893               irrelevant.</p>
2894             </dd>
2895
2896             <dt>Examples:</dt>
2897
2898             <dd>
2899               <table border="0" bgcolor="#E0E0E0" width="90%">
2900                 <tr>
2901                   <td>
2902                     <pre class="SCREEN">
2903     # Best speed (compared to the other levels)
2904     compression-level 1
2905     # Best compression
2906     compression-level 9
2907     # No compression. Only useful for testing as the added header
2908     # slightly increases the amount of data that has to be sent.
2909     # If your benchmark shows that using this compression level
2910     # is superior to using no compression at all, the benchmark
2911     # is likely to be flawed.
2912     compression-level 0
2913
2914 </pre>
2915                   </td>
2916                 </tr>
2917               </table>
2918             </dd>
2919           </dl>
2920         </div>
2921       </div>
2922     </div>
2923
2924     <div class="SECT2">
2925       <h2 class="SECT2"><a name="WINDOWS-GUI" id="WINDOWS-GUI">7.7. Windows
2926       GUI Options</a></h2>
2927
2928       <p><span class="APPLICATION">Privoxy</span> has a number of options
2929       specific to the Windows GUI interface:</p><a name="ACTIVITY-ANIMATION"
2930       id="ACTIVITY-ANIMATION"></a>
2931
2932       <p>If <span class="QUOTE">"activity-animation"</span> is set to 1, the
2933       <span class="APPLICATION">Privoxy</span> icon will animate when
2934       <span class="QUOTE">"Privoxy"</span> is active. To turn off, set to
2935       0.</p>
2936
2937       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2938       "emphasis"><i class="EMPHASIS">activity-animation 1</i></span><br>
2939       &nbsp;&nbsp;&nbsp;</tt></p><a name="LOG-MESSAGES" id=
2940       "LOG-MESSAGES"></a>
2941
2942       <p>If <span class="QUOTE">"log-messages"</span> is set to 1,
2943       <span class="APPLICATION">Privoxy</span> will log messages to the
2944       console window:</p>
2945
2946       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2947       "emphasis"><i class="EMPHASIS">log-messages 1</i></span><br>
2948       &nbsp;&nbsp;&nbsp;</tt></p><a name="LOG-BUFFER-SIZE" id=
2949       "LOG-BUFFER-SIZE"></a>
2950
2951       <p>If <span class="QUOTE">"log-buffer-size"</span> is set to 1, the
2952       size of the log buffer, i.e. the amount of memory used for the log
2953       messages displayed in the console window, will be limited to
2954       <span class="QUOTE">"log-max-lines"</span> (see below).</p>
2955
2956       <p>Warning: Setting this to 0 will result in the buffer to grow
2957       infinitely and eat up all your memory!</p>
2958
2959       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2960       "emphasis"><i class="EMPHASIS">log-buffer-size 1</i></span><br>
2961       &nbsp;&nbsp;&nbsp;</tt></p><a name="LOG-MAX-LINES" id=
2962       "LOG-MAX-LINES"></a>
2963
2964       <p><span class="APPLICATION">log-max-lines</span> is the maximum number
2965       of lines held in the log buffer. See above.</p>
2966
2967       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2968       "emphasis"><i class="EMPHASIS">log-max-lines 200</i></span><br>
2969       &nbsp;&nbsp;&nbsp;</tt></p><a name="LOG-HIGHLIGHT-MESSAGES" id=
2970       "LOG-HIGHLIGHT-MESSAGES"></a>
2971
2972       <p>If <span class="QUOTE">"log-highlight-messages"</span> is set to 1,
2973       <span class="APPLICATION">Privoxy</span> will highlight portions of the
2974       log messages with a bold-faced font:</p>
2975
2976       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2977       "emphasis"><i class="EMPHASIS">log-highlight-messages 1</i></span><br>
2978       &nbsp;&nbsp;&nbsp;</tt></p><a name="LOG-FONT-NAME" id=
2979       "LOG-FONT-NAME"></a>
2980
2981       <p>The font used in the console window:</p>
2982
2983       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2984       "emphasis"><i class="EMPHASIS">log-font-name Comic Sans
2985       MS</i></span><br>
2986       &nbsp;&nbsp;&nbsp;</tt></p><a name="LOG-FONT-SIZE" id=
2987       "LOG-FONT-SIZE"></a>
2988
2989       <p>Font size used in the console window:</p>
2990
2991       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
2992       "emphasis"><i class="EMPHASIS">log-font-size 8</i></span><br>
2993       &nbsp;&nbsp;&nbsp;</tt></p><a name="SHOW-ON-TASK-BAR" id=
2994       "SHOW-ON-TASK-BAR"></a>
2995
2996       <p><span class="QUOTE">"show-on-task-bar"</span> controls whether or
2997       not <span class="APPLICATION">Privoxy</span> will appear as a button on
2998       the Task bar when minimized:</p>
2999
3000       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
3001       "emphasis"><i class="EMPHASIS">show-on-task-bar 0</i></span><br>
3002       &nbsp;&nbsp;&nbsp;</tt></p><a name="CLOSE-BUTTON-MINIMIZES" id=
3003       "CLOSE-BUTTON-MINIMIZES"></a>
3004
3005       <p>If <span class="QUOTE">"close-button-minimizes"</span> is set to 1,
3006       the Windows close button will minimize <span class=
3007       "APPLICATION">Privoxy</span> instead of closing the program (close with
3008       the exit option on the File menu).</p>
3009
3010       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;<span class=
3011       "emphasis"><i class="EMPHASIS">close-button-minimizes 1</i></span><br>
3012       &nbsp;&nbsp;&nbsp;</tt></p><a name="HIDE-CONSOLE" id=
3013       "HIDE-CONSOLE"></a>
3014
3015       <p>The <span class="QUOTE">"hide-console"</span> option is specific to
3016       the MS-Win console version of <span class="APPLICATION">Privoxy</span>.
3017       If this option is used, <span class="APPLICATION">Privoxy</span> will
3018       disconnect from and hide the command console.</p>
3019
3020       <p class="LITERALLAYOUT"><tt class="LITERAL">&nbsp;&nbsp;#<span class=
3021       "emphasis"><i class="EMPHASIS">hide-console</i></span><br>
3022       &nbsp;&nbsp;&nbsp;</tt></p>
3023     </div>
3024   </div>
3025
3026   <div class="NAVFOOTER">
3027     <hr align="left" width="100%">
3028
3029     <table summary="Footer navigation table" width="100%" border="0"
3030     cellpadding="0" cellspacing="0">
3031       <tr>
3032         <td width="33%" align="left" valign="top"><a href=
3033         "configuration.html" accesskey="P">Prev</a></td>
3034
3035         <td width="34%" align="center" valign="top"><a href="index.html"
3036         accesskey="H">Home</a></td>
3037
3038         <td width="33%" align="right" valign="top"><a href=
3039         "actions-file.html" accesskey="N">Next</a></td>
3040       </tr>
3041
3042       <tr>
3043         <td width="33%" align="left" valign="top">Privoxy Configuration</td>
3044
3045         <td width="34%" align="center" valign="top">&nbsp;</td>
3046
3047         <td width="33%" align="right" valign="top">Actions Files</td>
3048       </tr>
3049     </table>
3050   </div>
3051 </body>
3052 </html>