Make it harder to think the forwarded-connect-retries
[privoxy.git] / doc / source / p-config.sgml
index cdea871..62979eb 100644 (file)
@@ -3,9 +3,9 @@
 
  Purpose     :  Used with other docs and files only.
 
- $Id: p-config.sgml,v 2.10 2006/09/07 02:02:56 hal9 Exp $
+ $Id: p-config.sgml,v 2.14 2007/03/22 14:10:59 fabiankeil Exp $
 
- Copyright (C) 2001-2006 Privoxy Developers <developers@privoxy.org>
+ Copyright (C) 2001-2007 Privoxy Developers http://www.privoxy.org/
  See LICENSE.
 
  ========================================================================
  Sample Configuration File for Privoxy v&p-version;
 </title>
 <para>
- $Id: p-config.sgml,v 2.10 2006/09/07 02:02:56 hal9 Exp $
+ $Id: p-config.sgml,v 2.14 2007/03/22 14:10:59 fabiankeil Exp $
 </para>
 <para>
-Copyright (C) 2001-2006 Privoxy Developers http://privoxy.org
+Copyright (C) 2001-2007 Privoxy Developers http://www.privoxy.org/
 </para>
 
 <para>
@@ -125,15 +125,21 @@ Copyright (C) 2001-2006 Privoxy Developers http://privoxy.org
  ===============  <!-- fuck this madness --></literallayout>
 
 <para>
- This file holds the Privoxy configuration.  If you modify this
- file, you will need to send a couple of requests (of any kind) to the proxy
before any changes take effect.
+ This file holds Privoxy's main configuration.  Privoxy detects
+ configuration changes automatically, so you don't have to restart it
unless you want to load a different configuration file.
 </para>
 <para>
- When starting Privoxy on Unix systems, give the name of this
- file as an argument.  On Windows systems, Privoxy will look for
- this file with the name 'config.txt' in the same directory where
- Privoxy is installed.
+ The configuration will be reloaded with the first request after the
+ change was done, this request itself will still use the old configuration,
+ though. In other words: it takes two requests before you see the result of
+ your changes. Requests that are dropped due to ACL don't trigger reloads.
+</para>
+<para>
+ When starting Privoxy on Unix systems, give the location of this
+ file as last argument.  On Windows systems, Privoxy will look for
+ this file with the name 'config.txt' in the current working directory
+ of the Privoxy process.
 </para>
 
 <para>
@@ -160,10 +166,11 @@ II. FORMAT OF THE CONFIGURATION FILE
 <para>
  Thus, by placing a # at the start of an existing configuration line,
  you can make it a comment and it will be treated as if it weren't there. 
- This is called "commenting out" an option and can be useful.
+ This is called "commenting out" an option and can be useful. Removing
+ the # again is called "uncommenting".
 </para>
 <para>
- Note that commenting out and option and leaving it at its default
+ Note that commenting out an option and leaving it at its default
  are two completely different things! Most options behave very
  differently when unset. See the the "Effect if unset" explanation
  in each option's description for details.
@@ -523,6 +530,8 @@ II. FORMAT OF THE CONFIGURATION FILE
    <para>
     No trailing <quote><literal>/</literal></quote>, please
    </para>
+  <!-- 
+   This is really outdated and not likely to happen. HB 09/20/06
    <para>
     When development goes modular and multi-user, the blocker, filter, and
     per-user config will be stored in subdirectories of <quote>confdir</quote>.
@@ -530,6 +539,7 @@ II. FORMAT OF THE CONFIGURATION FILE
     <filename>confdir/templates</filename>, where the HTML templates for CGI 
     output reside (e.g. <application>Privoxy's</application> 404 error page). 
    </para>
+  --> 
   </listitem>
  </varlistentry>
 </variablelist>
@@ -537,6 +547,50 @@ II. FORMAT OF THE CONFIGURATION FILE
 <![%config-file;[<literallayout>@@confdir .</literallayout>]]>
 </sect3>
 
+<!--   ~~~~~       New section      ~~~~~     -->
+<sect3 renderas="sect4" id="templdir"><title>templdir</title>
+
+<variablelist>
+ <varlistentry>
+  <term>Specifies:</term>
+  <listitem>
+   <para>An alternative directory where the templates are loaded from</para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Type of value:</term>
+  <listitem>
+   <para>Path name</para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Default value:</term>
+  <listitem>
+   <para>unset</para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Effect if unset:</term>
+  <listitem>
+   <para>The templates are assumed to be located in confdir/template.</para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Notes:</term>
+  <listitem>
+   <para>
+    Privoxy's original templates are usually overwritten
+    with each update. Use this option to relocate customized templates
+    that should be kept. Note that you might be missing new features
+    if you use outdated templates.
+   </para>
+  </listitem>
+ </varlistentry>
+</variablelist>
+
+<![%config-file;[<literallayout>@@#templdir .</literallayout>]]>
+</sect3>
+
 
 <!--   ~~~~~       New section      ~~~~~     -->
 <sect3 renderas="sect4" id="logdir"><title>logdir</title>
@@ -862,7 +916,7 @@ actionsfile
   <term>Specifies:</term>
   <listitem>
    <para>
-    The trust file to use
+    The name of the trust file to use
    </para>
   </listitem>
  </varlistentry>
@@ -882,7 +936,7 @@ actionsfile
   <term>Effect if unset:</term>
   <listitem>
    <para>
-    The entire trust mechanism is turned off.
+    The entire trust mechanism is disabled.
    </para>
   </listitem>
  </varlistentry>
@@ -901,16 +955,19 @@ actionsfile
    <para>
     Prepending a <literal>~</literal> character limits access to this site 
     only (and any sub-paths within this site), e.g. 
-    <literal>~www.example.com</literal>. 
+    <literal>~www.example.com</literal> allows access to
+    <literal>~www.example.com/features/news.html</literal>, etc. 
    </para>
    <para>
     Or, you can designate sites as <emphasis>trusted referrers</emphasis>, by
     prepending the name with a <literal>+</literal> character. The effect is that
     access to untrusted sites will be granted -- but only if a link from this
-    trusted referrer was used. The link target will then be added to the
-    <quote>trustfile</quote> so that future, direct accesses will be granted.
-    Sites added via this mechanism do not become trusted referrers themselves
-    (i.e. they are added with a <literal>~</literal> designation).
+    trusted referrer was used to get there. The link target will then be added
+    to the <quote>trustfile</quote> so that future, direct accesses will be
+    granted. Sites added via this mechanism do not become trusted referrers
+    themselves (i.e. they are added with a <literal>~</literal> designation).
+    There is a limit of 512 such entries, after which new entries will not be
+    made.
    </para>
    <para>
     If you use the <literal>+</literal> operator in the trust file, it may grow 
@@ -991,10 +1048,10 @@ actionsfile
   debug         2 # show each connection status
   debug         4 # show I/O status
   debug         8 # show header parsing
-  debug        16 # log all data into the logfile
+  debug        16 # log all data written to the network into the logfile
   debug        32 # debug force feature
-  debug        64 # debug regular expression filter
-  debug       128 # debug fast redirects
+  debug        64 # debug regular expression filters
+  debug       128 # debug redirects
   debug       256 # debug GIF de-animation
   debug       512 # Common Log Format
   debug      1024 # debug kill pop-ups
@@ -1016,13 +1073,18 @@ actionsfile
     <!-- LOL -->
    </para>
    <para>
-    The reporting of <emphasis>fatal</emphasis> errors (i.e. ones which crash 
-    <application>Privoxy</application>) is always on and cannot be disabled.
+    The reporting of <emphasis>fatal</emphasis> errors (i.e. ones which causes 
+    <application>Privoxy</application> to exit) is always on and cannot be disabled.
    </para>
    <para>
     If you want to use CLF (Common Log Format), you should set <quote>debug
     512</quote> <emphasis>ONLY</emphasis> and not enable anything else.
    </para>
+   <para>
+    <application>Privoxy</application> has a hard-coded limit for the
+    length of log messages. If it's reached, messages are logged truncated
+    and marked with <quote>... [too long, truncated]</quote>.
+   </para>
   </listitem>
  </varlistentry>
 </variablelist>
@@ -1217,8 +1279,8 @@ actionsfile
   <listitem>
    <para>
     If set to 0, <application>Privoxy</application> will start in
-    <quote>toggled off</quote> mode, i.e. behave like a normal, content-neutral
-    proxy where all ad blocking, filtering, etc are disabled. See
+    <quote>toggled off</quote> mode, i.e. mostly behave like a normal,
+    content-neutral proxy where all ad blocking, filtering, etc are disabled. See
     <literal>enable-remote-toggle</literal> below. This is not really useful
     anymore, since toggling is much easier via <ulink
     url="http://config.privoxy.org/toggle">the web interface</ulink> than via
@@ -1272,7 +1334,7 @@ actionsfile
   <term>Notes:</term>
   <listitem>
    <para>
-    When toggled off, <application>Privoxy</application> acts like a normal,
+    When toggled off, <application>Privoxy</application> mostly acts like a normal,
     content-neutral proxy, i.e. it acts as if none of the actions applied to
     any URL.
    </para>
@@ -1404,6 +1466,81 @@ actionsfile
 <![%config-file;[<literallayout>@@enable-edit-actions 1</literallayout>]]>
 </sect3>
 
+
+<sect3 renderas="sect4" id="enforce-blocks"><title>enforce-blocks</title>
+<variablelist>
+ <varlistentry>
+  <term>Specifies:</term>
+  <listitem>
+   <para>
+    Whether the user is allowed to ignore blocks and can <quote>go there anyway</quote>.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Type of value:</term>
+  <listitem>
+   <para>
+    <replaceable>0 or 1</replaceable>
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Default value:</term>
+  <listitem>
+   <para><emphasis>0</emphasis></para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Effect if unset:</term>
+  <listitem>
+   <para>
+    Blocks are not enforced.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Notes:</term>
+  <listitem>
+   <para>
+    <application>Privoxy</application> is mainly used to block and filter
+    requests as a service to the user, for example to block ads and other
+    junk that clogs the pipes. <application>Privoxy's</application> configuration
+    isn't perfect and sometimes innocent pages are blocked. In this situation it
+    makes sense to allow the user to enforce the request and have
+    <application>Privoxy</application> ignore the block.
+   </para>
+   <para>
+    In the default configuration <application>Privoxy's</application>
+    <quote>Blocked</quote> page contains a <quote>go there anyway</quote>
+    link to adds a special string (the force prefix) to the request URL.
+    If that link is used, <application>Privoxy</application> will
+    detect the force prefix, remove it again and let the request pass.
+   </para>
+   <para>
+    Of course <application>Privoxy</application> can also be used to enforce
+    a network policy. In that case the user obviously should not be able to
+    bypass any blocks, and that's what the <quote>enforce-blocks</quote>
+    option is for. If it's enabled, <application>Privoxy</application> hides
+    the <quote>go there anyway</quote> link. If the user adds the force
+    prefix by hand, it will not be accepted and the circumvention attempt
+    is logged.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Examples:</term>
+  <listitem>
+   <para>
+    enforce-blocks 1
+   </para>
+  </listitem>
+ </varlistentry>
+</variablelist>
+<![%config-file;[<literallayout>@@enforce-blocks 0</literallayout>]]>
+</sect3>
+
+
 <!--   ~~~~~       New section      ~~~~~     -->
 <sect3 renderas="sect4" id="acls"><title>
 ACLs: permit-access and deny-access</title>
@@ -1469,8 +1606,8 @@ ACLs: permit-access and deny-access</title>
    </para>
    <para>
     Multiple ACL lines are OK.
-    If any ACLs are specified, then the <application>Privoxy</application>
-    talks only to IP addresses that match at least one <literal>permit-access</literal> line
+    If any ACLs are specified, <application>Privoxy</application> only talks
+    to IP addresses that match at least one <literal>permit-access</literal> line
     and don't match any subsequent <literal>deny-access</literal> line. In other words, the
     last match wins, with the default being <literal>deny-access</literal>.
    </para>
@@ -1490,7 +1627,8 @@ ACLs: permit-access and deny-access</title>
    </para>
    <para>
     Denying access to particular sites by ACL may have undesired side effects
-    if the site in question is hosted on a machine which also hosts other sites.
+    if the site in question is hosted on a machine which also hosts other sites
+    (most sites are).
    </para>
   </listitem>
  </varlistentry>
@@ -1510,7 +1648,7 @@ ACLs: permit-access and deny-access</title>
    </para>
    <para>
     Allow any host on the same class C subnet as www.privoxy.org access to
-    nothing but www.example.com:
+    nothing but www.example.com (or other domains hosted on the same system):
    </para>
    <para>
     <screen>
@@ -1519,7 +1657,8 @@ ACLs: permit-access and deny-access</title>
    </para>
    <para>
     Allow access from any host on the 26-bit subnet 192.168.45.64 to anywhere,
-    with the exception that 192.168.45.73 may not access www.dirty-stuff.example.com:
+    with the exception that 192.168.45.73 may not access the IP address behind
+    www.dirty-stuff.example.com:
    </para>
    <para>
     <screen>
@@ -1604,13 +1743,20 @@ ACLs: permit-access and deny-access</title>
 <para>
  This feature allows routing of HTTP requests through a chain of
  multiple proxies.
- It can be used to better protect privacy and confidentiality when
- accessing specific domains by routing requests to those domains
- through an anonymous public proxy (see e.g. <ulink
- url="http://www.multiproxy.org/anon_list.htm">http://www.multiproxy.org/anon_list.htm</ulink>)
- Or to use a caching proxy to speed up browsing. Or chaining to a parent
- proxy may be necessary because the machine that <application>Privoxy</application>
- runs on has no direct Internet access.
+</para>
+<para>
+ Forwarding can be used to chain Privoxy with a caching proxy to speed
+ up browsing. Using a parent proxy may also be necessary if the machine
+ that <application>Privoxy</application> runs on has no direct Internet access.
+</para>
+<para>
+ Note that parent proxies can severely decrease your privacy level.
+ For example a parent proxy could add your IP address to the request
+ headers and if it's a caching proxy it may add the <quote>Etag</quote>
+ header to revalidation requests again, even though you configured Privoxy
+ to remove it. It may also ignore Privoxy's header time randomization and use the
+ original values which could be used by the server as cookie replacement
+ to track your steps between visits.
 </para>
 
 <para>
@@ -1676,11 +1822,11 @@ ACLs: permit-access and deny-access</title>
   <term>Examples:</term>
   <listitem>
    <para>
-    Everything goes to an example anonymizing proxy, except SSL on port 443 (which it doesn't handle):
+    Everything goes to an example parent proxy, except SSL on port 443 (which it doesn't handle):
    </para>
    <para>
     <screen>
-  forward   /      anon-proxy.example.org:8080
+  forward   /      parent-proxy.example.org:8080
   forward   :443   .
 </screen>
    </para>
@@ -1711,7 +1857,7 @@ forward-socks4 and forward-socks4a</title>
   <term>Specifies:</term>
   <listitem>
    <para>
-    Through which SOCKS proxy (and to which parent HTTP proxy) specific requests should be routed.
+    Through which SOCKS proxy (and optionally to which parent HTTP proxy) specific requests should be routed.
    </para>
   </listitem>
  </varlistentry>
@@ -1950,7 +2096,7 @@ forward-socks4 and forward-socks4a</title>
   <term>Effect if unset:</term>
   <listitem>
    <para>
-    Forwarded connections are treated like direct connections and no retry attempts are made.
+    Connections forwarded through other proxies are treated like direct connections and no retry attempts are made.
    </para>
   </listitem>
  </varlistentry>
@@ -1959,11 +2105,15 @@ forward-socks4 and forward-socks4a</title>
   <listitem>
    <para>
     <replaceable class="parameter">forwarded-connect-retries</replaceable> is mainly interesting
-    for socks4a connections, where Privoxy can't detect why the connections failed.
+    for socks4a connections, where <application>Privoxy</application> can't detect why the connections failed.
     The connection might have failed because of a DNS timeout in which case a retry makes sense,
     but it might also have failed because the server doesn't exist or isn't reachable. In this
     case the retry will just delay the appearance of Privoxy's error message.
    </para>
+   <para>
+    Note that in the context of this option, <quote>forwarded connections</quote> includes all connections
+    that Privoxy forwards through other proxies. This option is not limited to the HTTP CONNECT method.
+   </para>
    <para>
     Only use this option, if you are getting many forwarding related error messages,
     that go away when you try again manually. Start with a small value and check Privoxy's
@@ -1983,6 +2133,136 @@ forward-socks4 and forward-socks4a</title>
 <![%config-file;[<literallayout>@@forwarded-connect-retries  0</literallayout>]]>
 </sect3>
 
+<sect3 renderas="sect4" id="accept-intercepted-requests"><title>accept-intercepted-requests</title>
+<variablelist>
+ <varlistentry>
+  <term>Specifies:</term>
+  <listitem>
+   <para>
+    Whether intercepted requests should be treated as valid.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Type of value:</term>
+  <listitem>
+   <para>
+    <replaceable>0 or 1</replaceable>
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Default value:</term>
+  <listitem>
+   <para><emphasis>0</emphasis></para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Effect if unset:</term>
+  <listitem>
+   <para>
+    Only proxy requests are accepted, intercepted requests are treated as invalid.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Notes:</term>
+  <listitem>
+   <para>
+    If you don't trust your clients and want to force them
+    to use <application>Privoxy</application>, enable this
+    option and configure your packet filter to redirect outgoing
+    HTTP connections into <application>Privoxy</application>. 
+   </para>
+   <para>
+    Make sure that <application>Privoxy's</application> own requests
+    aren't redirected as well. Additionally take care that
+    <application>Privoxy</application> can't intentionally connect
+    to itself, otherwise you could run into redirection loops if
+    <application>Privoxy's</application> listening port is reachable
+    by the outside or an attacker has access to the pages you visit.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Examples:</term>
+  <listitem>
+   <para>
+    accept-intercepted-requests 1
+   </para>
+  </listitem>
+ </varlistentry>
+</variablelist>
+<![%config-file;[<literallayout>@@accept-intercepted-requests 0</literallayout>]]>
+</sect3>
+
+<sect3 renderas="sect4" id="split-large-forms"><title>split-large-forms</title>
+<variablelist>
+ <varlistentry>
+  <term>Specifies:</term>
+  <listitem>
+   <para>
+    Whether the CGI interface should stay compatible with broken HTTP clients.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Type of value:</term>
+  <listitem>
+   <para>
+    <replaceable>0 or 1</replaceable>
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Default value:</term>
+  <listitem>
+   <para><emphasis>0</emphasis></para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Effect if unset:</term>
+  <listitem>
+   <para>
+    The CGI form generate long GET URLs.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Notes:</term>
+  <listitem>
+   <para>
+    <application>Privoxy's</application> CGI forms can lead to
+    rather long URLs. This isn't a problem as far as the HTTP
+    standard is concerned, but it can confuse clients with arbitrary
+    URL lenght limitations.
+   </para>
+   <para>
+    Enabling split-large-forms causes <application>Privoxy</application>
+    to devide big forms into smaller ones to keep the URL length down.
+    It makes editing a lot less convenient and you can no longer
+    submit all changes at once, but at least it works around this
+    browser bug.
+   </para>
+   <para>
+    If you don't notice any editing problems, there is no reason
+    to enable this option, but if one of the submit buttons appears
+    to be broken, you should give it a try.
+   </para>
+  </listitem>
+ </varlistentry>
+ <varlistentry>
+  <term>Examples:</term>
+  <listitem>
+   <para>
+    split-large-forms 1
+   </para>
+  </listitem>
+ </varlistentry>
+</variablelist>
+<![%config-file;[<literallayout>@@split-large-forms 0</literallayout>]]>
+</sect3>
+
 </sect2>
 
 <!--  ~  End section  ~  -->