7 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+
10 TITLE="Privoxy 3.0.7 User Manual"
11 HREF="index.html"><LINK
13 TITLE="The Main Configuration File"
14 HREF="config.html"><LINK
17 HREF="filter-file.html"><LINK
21 <LINK REL="STYLESHEET" TYPE="text/css" HREF="p_doc.css">
33 SUMMARY="Header navigation table"
42 >Privoxy 3.0.7 User Manual</TH
64 HREF="filter-file.html"
82 > The actions files are used to define what <SPAN
92 > takes for which URLs, and thus determines
93 how ad images, cookies and various other aspects of HTTP content and
94 transactions are handled, and on which sites (or even parts thereof).
95 There are a number of such actions, with a wide range of functionality.
96 Each action does something a little different.
97 These actions give us a veritable arsenal of tools with which to exert
98 our control, preferences and independence. Actions can be combined so that
99 their effects are aggregated when applied against a given set of URLs.</P
102 are three action files included with <SPAN
117 > - is the primary action file
118 that sets the initial values for all actions. It is intended to
119 provide a base level of functionality for
123 > array of features. So it is
124 a set of broad rules that should work reasonably well as-is for most users.
125 This is the file that the developers are keeping updated, and <A
126 HREF="installation.html#INSTALLATION-KEEPUPDATED"
127 >making available to users</A
129 The user's preferences as set in <TT
152 > - is intended to be for local site
153 preferences and exceptions. As an example, if your ISP or your bank
154 has specific requirements, and need special handling, this kind of
155 thing should go here. This file will not be upgraded.
163 > - is used only by the web based editor
165 HREF="http://config.privoxy.org/edit-actions-list?f=default"
167 > http://config.privoxy.org/edit-actions-list?f=default</A
169 to set various pre-defined sets of rules for the default actions section
181 >Set to Cautious</SPAN
187 >Set to Advanced</SPAN
191 > These have increasing levels of aggressiveness <SPAN
196 influence on your browsing unless you select them explicitly in the
199 >. A default installation should be pre-set to
203 > (versions prior to 3.0.5 were set to
207 >). New users should try this for a while before
208 adjusting the settings to more aggressive levels. The more aggressive
209 the settings, then the more likelihood there is of problems such as sites
210 not working as they should.
216 > button allows you to turn each
217 action on/off individually for fine-tuning. The <SPAN
221 button changes the actions list to low/safe settings which will activate
222 ad blocking and a minimal set of <SPAN
225 >'s features, and subsequently
226 there will be less of a chance for accidental problems. The
230 > button sets the list to a medium level of
231 other features and a low level set of privacy features. The
235 > button sets the list to a high level of
236 ad blocking and medium level of privacy. See the chart below. The latter
237 three buttons over-ride any changes via with the
241 > button. More fine-tuning can be done in the
242 lower sections of this internal page.
245 > It is not recommend to edit the <TT
252 > The default profiles, and their associated actions, as pre-defined in
266 >Table 1. Default Configurations</B
301 >Ad-blocking Aggressiveness</TD
323 >Ad-filtering by size</TD
345 >Ad-filtering by link</TD
389 >Privacy Features</TD
455 >GIF de-animation</TD
521 >JavaScript taming</TD
565 >Image tag reordering</TD
592 > The list of actions files to be used are defined in the main configuration
593 file, and are processed in the order they are defined (e.g.
597 > is typically processed before
601 >). The content of these can all be viewed and
603 HREF="http://config.privoxy.org/show-status"
605 >http://config.privoxy.org/show-status</A
607 The over-riding principle when applying actions, is that the last action that
608 matches a given URL, wins. The broadest, most general rules go first
613 followed by any exceptions (typically also in
617 >), which are then followed lastly by any
618 local preferences (typically in <SPAN
634 > An actions file typically has multiple sections. If you want to use
638 > in an actions file, you have to place the (optional)
640 HREF="actions-file.html#ALIASES"
642 > at the top of that file.
643 Then comes the default set of rules which will apply universally to all
644 sites and pages (be <SPAN
654 > or any other actions file after
658 >, because it will override the result
659 from consulting any previous file). And then below that,
660 exceptions to the defined universal policies. You can regard
664 > as an appendix to <TT
668 with the advantage that is a separate file, which makes preserving your
669 personal settings across <SPAN
672 > upgrades easier.</P
675 Actions can be used to block anything you want, including ads, banners, or
676 just some obnoxious URL that you would rather not see. Cookies can be accepted
677 or rejected, or accepted only during the current browser session (i.e. not
678 written to disk), content can be modified, JavaScripts tamed, user-tracking
679 fooled, and much more. See below for a <A
680 HREF="actions-file.html#ACTIONS"
691 >8.1. Finding the Right Mix</H2
694 HREF="actions-file.html#ACTIONS"
696 >, like cookie suppression
697 or script disabling, may render some sites unusable that rely on these
698 techniques to work properly. Finding the right mix of actions is not always easy and
699 certainly a matter of personal taste. And, things can always change, requiring
700 refinements in the configuration. In general, it can be said that the more
704 > your default settings (in the top section of the
705 actions file) are, the more exceptions for <SPAN
709 will have to make later. If, for example, you want to crunch all cookies per
710 default, you'll have to make exceptions from that rule for sites that you
711 regularly use and that require cookies for actually useful purposes, like maybe
712 your bank, favorite shop, or newspaper. </P
714 > We have tried to provide you with reasonable rules to start from in the
715 distribution actions files. But there is no general rule of thumb on these
716 things. There just are too many variables, and sites are constantly changing.
717 Sooner or later you will want to change the rules (and read this chapter again :).</P
726 >8.2. How to Edit</H2
728 > The easiest way to edit the actions files is with a browser by
729 using our browser-based editor, which can be reached from <A
730 HREF="http://config.privoxy.org/show-status"
732 >http://config.privoxy.org/show-status</A
734 The editor allows both fine-grained control over every single feature on a
735 per-URL basis, and easy choosing from wholesale sets of defaults like
749 > setting is more aggressive, and
750 will be more likely to cause problems for some sites. Experienced users only!</P
752 > If you prefer plain text editing to GUIs, you can of course also directly edit the
753 the actions files with your favorite text editor. Look at
757 > which is richly commented with many
767 >8.3. How Actions are Applied to Requests</H2
769 > Actions files are divided into sections. There are special sections,
773 HREF="actions-file.html#ALIASES"
776 > sections which will
777 be discussed later. For now let's concentrate on regular sections: They have a
778 heading line (often split up to multiple lines for readability) which consist
779 of a list of actions, separated by whitespace and enclosed in curly braces.
780 Below that, there is a list of URL and tag patterns, each on a separate line.</P
782 > To determine which actions apply to a request, the URL of the request is
783 compared to all URL patterns in each <SPAN
787 Every time it matches, the list of applicable actions for the request is
788 incrementally updated, using the heading of the section in which the
789 pattern is located. The same is done again for tags and tag patterns later on.</P
791 > If multiple applying sections set the same action differently,
792 the last match wins. If not, the effects are aggregated.
793 E.g. a URL might match a regular section with a heading line of <TT
797 HREF="actions-file.html#HANDLE-AS-IMAGE"
801 then later another one with just <TT
805 HREF="actions-file.html#BLOCK"
815 > actions to apply. And there may well be
816 cases where you will want to combine actions together. Such a section then
834 # Block these as if they were images. Send no block page.
836 media.example.com/.*banners
837 .example.com/images/ads/</PRE
844 > You can trace this process for URL patterns and any given URL by visiting <A
845 HREF="http://config.privoxy.org/show-url-info"
847 >http://config.privoxy.org/show-url-info</A
850 > Examples and more detail on this is provided in the Appendix, <A
851 HREF="appendix.html#ACTIONSANAT"
852 > Troubleshooting: Anatomy of an Action</A
872 to determine what <SPAN
878 > might apply to which sites and
879 pages your browser attempts to access. These <SPAN
889 > matching to achieve a high degree of
890 flexibility. This allows one expression to be expanded and potentially match
891 against many similar patterns.</P
893 > Generally, a URL pattern has the form
896 ><domain>/<path></TT
900 ><domain></TT
905 optional. (This is why the special <TT
908 > pattern matches all
909 URLs). Note that the protocol portion of the URL pattern (e.g.
920 the pattern. This is assumed already!</P
922 > The pattern matching syntax is different for the domain and path parts of
923 the URL. The domain part uses a simple globbing type matching technique,
924 while the path part uses a more flexible
926 HREF="http://en.wikipedia.org/wiki/Regular_expressions"
931 Expressions (PCRE)"</SPAN
942 >www.example.com/</TT
946 > is a domain-only pattern and will match any request to <TT
950 regardless of which document on that server is requested. So ALL pages in
951 this domain would be covered by the scope of this action. Note that a
955 > is different and would NOT match.
965 > means exactly the same. For domain-only patterns, the trailing <TT
975 >www.example.com/index.html</TT
979 > matches only the single document <TT
996 > matches the document <TT
999 >, regardless of the domain,
1006 > web server anywhere.
1016 > matches nothing, since it would be interpreted as a domain name and
1017 there is no top-level domain called <TT
1033 >8.4.1. The Domain Pattern</H3
1035 > The matching of the domain part offers some flexible options: if the
1036 domain starts or ends with a dot, it becomes unanchored at that end.
1041 CLASS="VARIABLELIST"
1050 > matches any domain that <SPAN
1070 > matches any domain that <SPAN
1090 > matches any domain that <SPAN
1100 And, by the way, also included would be any files or documents that exist
1101 within that domain since no path limitations are specified. (Correctly
1102 speaking: It matches any FQDN that contains <TT
1106 a domain.) This might be <TT
1108 >www.example.com</TT
1112 >news.example.de</TT
1116 >www.example.net/cgi/testing.pl</TT
1117 > for instance. All these
1124 > Additionally, there are wild-cards that you can use in the domain names
1125 themselves. These work similarly to shell globbing type wild-cards:
1129 > represents zero or more arbitrary characters (this is
1132 HREF="http://en.wikipedia.org/wiki/Regular_expressions"
1139 > based syntax of <SPAN
1146 > represents any single character (this is equivalent to the
1147 regular expression syntax of a simple <SPAN
1150 >), and you can define
1153 >"character classes"</SPAN
1154 > in square brackets which is similar to
1155 the same regular expression technique. All of this can be freely mixed:</P
1159 CLASS="VARIABLELIST"
1164 >ad*.example.com</TT
1170 >"adserver.example.com"</SPAN
1174 >"ads.example.com"</SPAN
1175 >, etc but not <SPAN
1177 >"sfads.example.com"</SPAN
1184 >*ad*.example.com</TT
1188 > matches all of the above, and then some.
1204 >pictures.epix.com</TT
1207 >a.b.c.d.e.upix.com</TT
1214 >www[1-9a-ez].example.c*</TT
1220 >www1.example.com</TT
1224 >www4.example.cc</TT
1227 >wwwd.example.cy</TT
1231 >wwwz.example.com</TT
1241 >wwww.example.com</TT
1248 > While flexible, this is not the sophistication of full regular expression based syntax.</P
1257 >8.4.2. The Path Pattern</H3
1262 > uses Perl compatible (PCRE)
1264 HREF="http://en.wikipedia.org/wiki/Regular_expressions"
1273 HREF="http://www.pcre.org/"
1277 matching the path portion (after the slash), and is thus more flexible.</P
1280 HREF="appendix.html#REGEX"
1282 > with a brief quick-start into regular
1283 expressions, and full (very technical) documentation on PCRE regex syntax is available on-line
1285 HREF="http://www.pcre.org/man.txt"
1287 >http://www.pcre.org/man.txt</A
1289 You might also find the Perl man page on regular expressions (<TT
1293 useful, which is available on-line at <A
1294 HREF="http://perldoc.perl.org/perlre.html"
1296 >http://perldoc.perl.org/perlre.html</A
1299 > Note that the path pattern is automatically left-anchored at the <SPAN
1303 i.e. it matches as if it would start with a <SPAN
1306 > (regular expression speak
1307 for the beginning of a line).</P
1309 > Please also note that matching in the path is <SPAN
1313 >CASE INSENSITIVE</I
1316 by default, but you can switch to case sensitive at any point in the pattern by using the
1322 >www.example.com/(?-i)PaTtErN.*</TT
1324 only documents whose path starts with <TT
1334 > this capitalization.</P
1338 CLASS="VARIABLELIST"
1343 >.example.com/.*</TT
1347 > Is equivalent to just <SPAN
1349 >".example.com"</SPAN
1350 >, since any documents
1351 within that domain are matched with or without the <SPAN
1355 regular expression. This is redundant
1361 >.example.com/.*/index.html</TT
1365 > Will match any page in the domain of <SPAN
1367 >"example.com"</SPAN
1372 >, and that is part of some path. For
1373 example, it matches <SPAN
1375 >"www.example.com/testing/index.html"</SPAN
1379 >"www.example.com/index.html"</SPAN
1380 > because the regular
1381 expression called for at least two <SPAN
1385 requirement. It also would match
1388 >"www.example.com/testing/index_html"</SPAN
1390 special meta-character <SPAN
1399 >.example.com/(.*/)?index\.html</TT
1403 > This regular expression is conditional so it will match any page
1407 > regardless of path which in this case can
1408 have one or more <SPAN
1411 >. And this one must contain exactly
1415 > (but does not have to end with that!).
1421 >.example.com/(.*/)(ads|banners?|junk)</TT
1425 > This regular expression will match any path of <SPAN
1427 >"example.com"</SPAN
1429 that contains any of the words <SPAN
1439 > (because of the <SPAN
1446 The path does not have to end in these words, just contain them.
1452 >.example.com/(.*/)(ads|banners?|junk)/.*\.(jpe?g|gif|png)$</TT
1456 > This is very much the same as above, except now it must end in either
1470 one is limited to common image formats.
1476 > There are many, many good examples to be found in <TT
1480 and more tutorials below in <A
1481 HREF="appendix.html#REGEX"
1482 >Appendix on regular expressions</A
1492 >8.4.3. The Tag Pattern</H3
1494 > Tag patterns are used to change the applying actions based on the
1495 request's tags. Tags can be created with either the
1497 HREF="actions-file.html#CLIENT-HEADER-FILTER"
1498 >client-header-tagger</A
1501 HREF="actions-file.html#SERVER-HEADER-FILTER"
1502 >server-header-tagger</A
1505 > Tag patterns have to start with <SPAN
1512 can tell them apart from URL patterns. Everything after the colon
1513 including white space, is interpreted as a regular expression with
1514 path patterns syntax, except that tag patterns aren't left-anchored
1515 automatically (Privoxy doesn't silently add a <SPAN
1519 you have to do it yourself if you need it).</P
1521 > To match all requests that are tagged with <SPAN
1525 your pattern line should be <SPAN
1532 > would work as well, but it would also
1533 match requests whose tags contain <SPAN
1538 > Sections can contain URL and tag patterns at the same time,
1539 but tag patterns are checked after the URL patterns and thus
1540 always overrule them, even if they are located before the URL patterns.</P
1542 > Once a new tag is added, Privoxy checks right away if it's matched by one
1543 of the tag patterns and updates the action settings accordingly. As a result
1544 tags can be used to activate other tagger actions, as long as these other
1545 taggers look for headers that haven't already be parsed.</P
1547 > For example you could tag client requests which use the POST method,
1548 use this tag to activate another tagger that adds a tag if cookies
1549 are send, and then block based on the cookie tag. However if you'd
1550 reverse the position of the described taggers, and activated the method
1551 tagger based on the cookie tagger, no method tags would be created.
1552 The method tagger would look for the request line, but at the time
1553 the cookie tag is created the request line has already been parsed.</P
1555 > While this is a limitation you should be aware of, this kind of
1556 indirection is seldom needed anyway and even the example doesn't
1557 make too much sense.</P
1569 > All actions are disabled by default, until they are explicitly enabled
1570 somewhere in an actions file. Actions are turned on if preceded with a
1574 >, and turned off if preceded with a <SPAN
1583 >"do that action"</SPAN
1590 >"please block URLs that match the
1591 following patterns"</SPAN
1598 block URLs that match the following patterns, even if <TT
1602 previously applied."</SPAN
1606 Again, actions are invoked by placing them on a line, enclosed in curly braces and
1607 separated by whitespace, like in
1610 >{+some-action -some-other-action{some-parameter}}</TT
1612 followed by a list of URL patterns, one per line, to which they apply.
1613 Together, the actions line and the following pattern lines make up a section
1614 of the actions file. </P
1617 Actions fall into three categories:</P
1625 Boolean, i.e the action can only be <SPAN
1648 > # enable action <TT
1659 > # disable action <TT
1681 Parameterized, where some value is required in order to enable this type of action.
1703 >} # enable action and set parameter to <TT
1709 # overwriting parameter from previous match if necessary
1715 > # disable action. The parameter can be omitted</PRE
1722 > Note that if the URL matches multiple positive forms of a parameterized action,
1723 the last match wins, i.e. the params from earlier matches are simply ignored.
1729 >+hide-user-agent{ Mozilla 1.0 }</TT
1736 Multi-value. These look exactly like parameterized actions,
1737 but they behave differently: If the action applies multiple times to the
1738 same URL, but with different parameters, <SPAN
1751 > matches are remembered. This is used for actions
1752 that can be executed for the same request repeatedly, like adding multiple
1753 headers, or filtering through multiple filters. Syntax:
1774 >} # enable action and add <TT
1779 > to the list of parameters
1790 >} # remove the parameter <TT
1795 > from the list of parameters
1796 # If it was the last one left, disable the action.
1802 > # disable this action completely and remove all parameters from the list</PRE
1812 >+add-header{X-Fun-Header: Some text}</TT
1816 >+filter{html-annoyances}</TT
1823 > If nothing is specified in any actions file, no <SPAN
1827 taken. So in this case <SPAN
1831 normal, non-blocking, non-anonymizing proxy. You must specifically enable the
1832 privacy and blocking features you need (although the provided default actions
1833 files will give a good starting point).</P
1835 > Later defined actions always over-ride earlier ones. So exceptions
1836 to any rules you make, should come in the latter part of the file (or
1837 in a file that is processed later when using multiple actions files such
1841 >). For multi-valued actions, the actions
1842 are applied in the order they are specified. Actions files are processed in
1843 the order they are defined in <TT
1847 installation has three actions files). It also quite possible for any given
1848 URL to match more than one <SPAN
1851 > (because of wildcards and
1852 regular expressions), and thus to trigger more than one set of actions! Last
1855 > The list of valid <SPAN
1866 >8.5.1. add-header</H4
1870 CLASS="VARIABLELIST"
1876 >Confuse log analysis, custom applications</P
1882 > Sends a user defined HTTP header to the web server.
1895 > Any string value is possible. Validity of the defined HTTP headers is not checked.
1896 It is recommended that you use the <SPAN
1910 > This action may be specified multiple times, in order to define multiple
1911 headers. This is rarely needed for the typical user. If you don't know what
1914 >"HTTP headers"</SPAN
1915 > are, you definitely don't need to worry about this
1931 >+add-header{X-User-Tracking: sucks}</PRE
1952 CLASS="VARIABLELIST"
1958 >Block ads or other unwanted content</P
1964 > Requests for URLs to which this action applies are blocked, i.e. the
1965 requests are trapped by <SPAN
1968 > and the requested URL is never retrieved,
1969 but is answered locally with a substitute page or image, as determined by
1973 HREF="actions-file.html#HANDLE-AS-IMAGE"
1980 HREF="actions-file.html#SET-IMAGE-BLOCKER"
1981 >set-image-blocker</A
1987 HREF="actions-file.html#HANDLE-AS-EMPTY-DOCUMENT"
1988 >handle-as-empty-document</A
2013 > sends a special <SPAN
2017 for requests to blocked pages. This page contains links to find out why the request
2018 was blocked, and a click-through to the blocked content (the latter only if compiled with the
2019 force feature enabled). The <SPAN
2022 > page adapts to the available
2023 screen space -- it displays full-blown if space allows, or miniaturized and text-only
2024 if loaded into a small frame or window. If you are using <SPAN
2028 right now, you can take a look at the
2030 HREF="http://ads.bannerserver.example.com/nasty-ads/sponsor.html"
2041 A very important exception occurs if <SPAN
2054 HREF="actions-file.html#HANDLE-AS-IMAGE"
2058 apply to the same request: it will then be replaced by an image. If
2062 HREF="actions-file.html#SET-IMAGE-BLOCKER"
2063 >set-image-blocker</A
2066 (see below) also applies, the type of image will be determined by its parameter,
2067 if not, the standard checkerboard pattern is sent.
2070 > It is important to understand this process, in order
2071 to understand how <SPAN
2075 ads and other unwanted content. Blocking is a core feature, and one
2076 upon which various other features depend.
2082 HREF="actions-file.html#FILTER"
2086 action can perform a very similar task, by <SPAN
2090 banner images and other content through rewriting the relevant URLs in the
2091 document's HTML source, so they don't get requested in the first place.
2092 Note that this is a totally different technique, and it's easy to confuse the two.
2096 >Example usage (section):</DT
2108 # Block and replace with "blocked" page
2109 .nasty-stuff.example.com
2111 {+block +handle-as-image}
2112 # Block and replace with image
2116 {+block +handle-as-empty-document}
2117 # Block and then ignore
2118 adserver.exampleclick.net/.*\.js$</PRE
2133 NAME="CLIENT-HEADER-FILTER"
2135 >8.5.3. client-header-filter</H4
2139 CLASS="VARIABLELIST"
2145 > Rewrite or remove single client headers.
2152 > All client headers to which this action applies are filtered on-the-fly through
2153 the specified regular expression based substitutions.
2166 > The name of a client-header filter, as defined in one of the
2168 HREF="filter-file.html"
2177 > Client-header filters are applied to each header on its own, not to
2178 all at once. This makes it easier to diagnose problems, but on the downside
2179 you can't write filters that only change header x if header y's value is z.
2180 You can do that by using tags though.
2183 > Client-header filters are executed after the other header actions have finished
2184 and use their output as input.
2187 > Please refer to the <A
2188 HREF="filter-file.html"
2189 >filter file chapter</A
2191 to learn which client-header filters are available by default, and how to
2196 >Example usage (section):</DT
2207 >{+client-header-filter{hide-tor-exit-notation}}
2224 NAME="CLIENT-HEADER-TAGGER"
2226 >8.5.4. client-header-tagger</H4
2230 CLASS="VARIABLELIST"
2236 > Block requests based on their headers.
2243 > Client headers to which this action applies are filtered on-the-fly through
2244 the specified regular expression based substitutions, the result is used as
2258 > The name of a client-header tagger, as defined in one of the
2260 HREF="filter-file.html"
2269 > Client-header taggers are applied to each header on its own,
2270 and as the header isn't modified, each tagger <SPAN
2277 > Client-header taggers are the first actions that are executed
2278 and their tags can be used to control every other action.
2282 >Example usage (section):</DT
2293 ># Tag every request with the User-Agent header
2294 {+client-header-filter{user-agent}}
2311 NAME="CONTENT-TYPE-OVERWRITE"
2313 >8.5.5. content-type-overwrite</H4
2317 CLASS="VARIABLELIST"
2323 >Stop useless download menus from popping up, or change the browser's rendering mode</P
2329 > Replaces the <SPAN
2331 >"Content-Type:"</SPAN
2332 > HTTP server header.
2354 >"Content-Type:"</SPAN
2355 > HTTP server header is used by the
2356 browser to decide what to do with the document. The value of this
2357 header can cause the browser to open a download menu instead of
2358 displaying the document by itself, even if the document's format is
2359 supported by the browser.
2362 > The declared content type can also affect which rendering mode
2363 the browser chooses. If XHTML is delivered as <SPAN
2367 many browsers treat it as yet another broken HTML document.
2368 If it is send as <SPAN
2370 >"application/xml"</SPAN
2372 XHTML support will only display it, if the syntax is correct.
2375 > If you see a web site that proudly uses XHTML buttons, but sets
2378 >"Content-Type: text/html"</SPAN
2379 >, you can use <SPAN
2383 to overwrite it with <SPAN
2385 >"application/xml"</SPAN
2387 the web master's claim inside your XHTML-supporting browser.
2388 If the syntax is incorrect, the browser will complain loudly.
2391 > You can also go the opposite direction: if your browser prints
2392 error messages instead of rendering a document falsely declared
2393 as XHTML, you can overwrite the content type with
2397 > and have it rendered as broken HTML document.
2402 >content-type-overwrite</TT
2406 >"Content-Type:"</SPAN
2407 > headers that look like some kind of text.
2408 If you want to overwrite it unconditionally, you have to combine it with
2412 HREF="actions-file.html#FORCE-TEXT-MODE"
2416 This limitation exists for a reason, think twice before circumventing it.
2419 > Most of the time it's easier to replace this action with a custom
2423 HREF="actions-file.html#SERVER-HEADER-FILTER"
2424 >server-header filter</A
2427 It allows you to activate it for every document of a certain site and it will still
2428 only replace the content types you aimed at.
2431 > Of course you can apply <TT
2433 >content-type-overwrite</TT
2435 to a whole site and then make URL based exceptions, but it's a lot
2436 more work to get the same precision.
2440 >Example usage (sections):</DT
2451 ># Check if www.example.net/ really uses valid XHTML
2452 { +content-type-overwrite{application/xml} }
2455 # but leave the content type unmodified if the URL looks like a style sheet
2456 {-content-type-overwrite}
2457 www.example.net/.*\.css$
2458 www.example.net/.*style</PRE
2473 NAME="CRUNCH-CLIENT-HEADER"
2475 >8.5.6. crunch-client-header</H4
2479 CLASS="VARIABLELIST"
2485 >Remove a client header <SPAN
2488 > has no dedicated action for.</P
2494 > Deletes every header sent by the client that contains the string the user supplied as parameter.
2514 > This action allows you to block client headers for which no dedicated
2522 > will remove every client header that
2523 contains the string you supplied as parameter.
2526 > Regular expressions are <SPAN
2533 use this action to block different headers in the same request, unless
2534 they contain the same string.
2539 >crunch-client-header</TT
2540 > is only meant for quick tests.
2541 If you have to block several different headers, or only want to modify
2542 parts of them, you should use a
2546 HREF="actions-file.html#CLIENT-HEADER-FILTER"
2547 >client-header filter</A
2570 > Don't block any header without understanding the consequences.
2578 >Example usage (section):</DT
2589 ># Block the non-existent "Privacy-Violation:" client header
2590 { +crunch-client-header{Privacy-Violation:} }
2607 NAME="CRUNCH-IF-NONE-MATCH"
2609 >8.5.7. crunch-if-none-match</H4
2613 CLASS="VARIABLELIST"
2619 >Prevent yet another way to track the user's steps between sessions.</P
2627 >"If-None-Match:"</SPAN
2628 > HTTP client header.
2648 > Removing the <SPAN
2650 >"If-None-Match:"</SPAN
2651 > HTTP client header
2652 is useful for filter testing, where you want to force a real
2653 reload instead of getting status code <SPAN
2657 would cause the browser to use a cached copy of the page.
2660 > It is also useful to make sure the header isn't used as a cookie
2664 > Blocking the <SPAN
2666 >"If-None-Match:"</SPAN
2667 > header shouldn't cause any
2668 caching problems, as long as the <SPAN
2670 >"If-Modified-Since:"</SPAN
2672 isn't blocked as well.
2675 > It is recommended to use this action together with
2679 HREF="actions-file.html#HIDE-IF-MODIFIED-SINCE"
2680 >hide-if-modified-since</A
2687 HREF="actions-file.html#OVERWRITE-LAST-MODIFIED"
2688 >overwrite-last-modified</A
2694 >Example usage (section):</DT
2705 ># Let the browser revalidate cached documents without being tracked across sessions
2706 { +hide-if-modified-since{-60} \
2707 +overwrite-last-modified{randomize} \
2708 +crunch-if-none-match}
2724 NAME="CRUNCH-INCOMING-COOKIES"
2726 >8.5.8. crunch-incoming-cookies</H4
2730 CLASS="VARIABLELIST"
2736 > Prevent the web server from setting any cookies on your system
2745 >"Set-Cookie:"</SPAN
2746 > HTTP headers from server replies.
2766 > This action is only concerned with <SPAN
2783 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
2784 >crunch-outgoing-cookies</A
2793 > to disable cookies completely.
2802 > to use this action in conjunction
2806 HREF="actions-file.html#SESSION-COOKIES-ONLY"
2807 >session-cookies-only</A
2810 since it would prevent the session cookies from being set. See also
2814 HREF="actions-file.html#FILTER-CONTENT-COOKIES"
2815 >filter-content-cookies</A
2832 >+crunch-incoming-cookies</PRE
2847 NAME="CRUNCH-SERVER-HEADER"
2849 >8.5.9. crunch-server-header</H4
2853 CLASS="VARIABLELIST"
2859 >Remove a server header <SPAN
2862 > has no dedicated action for.</P
2868 > Deletes every header sent by the server that contains the string the user supplied as parameter.
2888 > This action allows you to block server headers for which no dedicated
2892 > action exists. <SPAN
2896 will remove every server header that contains the string you supplied as parameter.
2899 > Regular expressions are <SPAN
2906 use this action to block different headers in the same request, unless
2907 they contain the same string.
2912 >crunch-server-header</TT
2913 > is only meant for quick tests.
2914 If you have to block several different headers, or only want to modify
2915 parts of them, you should use a custom
2919 HREF="actions-file.html#SERVER-HEADER-FILTER"
2920 >server-header filter</A
2943 > Don't block any header without understanding the consequences.
2951 >Example usage (section):</DT
2962 ># Crunch server headers that try to prevent caching
2963 { +crunch-server-header{no-cache} }
2979 NAME="CRUNCH-OUTGOING-COOKIES"
2981 >8.5.10. crunch-outgoing-cookies</H4
2985 CLASS="VARIABLELIST"
2991 > Prevent the web server from reading any cookies from your system
3001 > HTTP headers from client requests.
3021 > This action is only concerned with <SPAN
3038 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
3039 >crunch-incoming-cookies</A
3048 > to disable cookies completely.
3057 > to use this action in conjunction
3061 HREF="actions-file.html#SESSION-COOKIES-ONLY"
3062 >session-cookies-only</A
3065 since it would prevent the session cookies from being read.
3080 >+crunch-outgoing-cookies</PRE
3095 NAME="DEANIMATE-GIFS"
3097 >8.5.11. deanimate-gifs</H4
3101 CLASS="VARIABLELIST"
3107 >Stop those annoying, distracting animated GIF images.</P
3113 > De-animate GIF animations, i.e. reduce them to their first or last image.
3139 > This will also shrink the images considerably (in bytes, not pixels!). If
3143 > is given, the first frame of the animation
3144 is used as the replacement. If <SPAN
3147 > is given, the last
3148 frame of the animation is used instead, which probably makes more sense for
3149 most banner animations, but also has the risk of not showing the entire
3150 last frame (if it is only a delta to an earlier frame).
3153 > You can safely use this action with patterns that will also match non-GIF
3154 objects, because no attempt will be made at anything that doesn't look like
3170 >+deanimate-gifs{last}</PRE
3185 NAME="DOWNGRADE-HTTP-VERSION"
3187 >8.5.12. downgrade-http-version</H4
3191 CLASS="VARIABLELIST"
3197 >Work around (very rare) problems with HTTP/1.1</P
3203 > Downgrades HTTP/1.1 client requests and server replies to HTTP/1.0.
3223 > This is a left-over from the time when <SPAN
3227 didn't support important HTTP/1.1 features well. It is left here for the
3228 unlikely case that you experience HTTP/1.1 related problems with some server
3229 out there. Not all (optional) HTTP/1.1 features are supported yet, so there
3230 is a chance you might need this action.
3234 >Example usage (section):</DT
3245 >{+downgrade-http-version}
3246 problem-host.example.com</PRE
3261 NAME="FAST-REDIRECTS"
3263 >8.5.13. fast-redirects</H4
3267 CLASS="VARIABLELIST"
3273 >Fool some click-tracking scripts and speed up indirect links.</P
3279 > Detects redirection URLs and redirects the browser without contacting
3280 the redirection server first.
3299 >"simple-check"</SPAN
3300 > to just search for the string <SPAN
3304 to detect redirection URLs.
3311 >"check-decoded-url"</SPAN
3312 > to decode URLs (if necessary) before searching
3313 for redirection URLs.
3323 Many sites, like yahoo.com, don't just link to other sites. Instead, they
3324 will link to some script on their own servers, giving the destination as a
3325 parameter, which will then redirect you to the final target. URLs
3326 resulting from this scheme typically look like:
3329 >"http://www.example.org/click-tracker.cgi?target=http%3a//www.example.net/"</SPAN
3333 > Sometimes, there are even multiple consecutive redirects encoded in the
3334 URL. These redirections via scripts make your web browsing more traceable,
3335 since the server from which you follow such a link can see where you go
3336 to. Apart from that, valuable bandwidth and time is wasted, while your
3337 browser asks the server for one redirect after the other. Plus, it feeds
3341 > This feature is currently not very smart and is scheduled for improvement.
3342 If it is enabled by default, you will have to create some exceptions to
3343 this action. It can lead to failures in several ways:
3346 > Not every URLs with other URLs as parameters is evil.
3347 Some sites offer a real service that requires this information to work.
3348 For example a validation service needs to know, which document to validate.
3352 > assumes that every URL parameter that
3353 looks like another URL is a redirection target, and will always redirect to
3354 the last one. Most of the time the assumption is correct, but if it isn't,
3355 the user gets redirected anyway.
3358 > Another failure occurs if the URL contains other parameters after the URL parameter.
3362 >"http://www.example.org/?redirect=http%3a//www.example.net/&foo=bar"</SPAN
3364 contains the redirection URL <SPAN
3366 >"http://www.example.net/"</SPAN
3368 followed by another parameter. <TT
3372 and will cause a redirect to <SPAN
3374 >"http://www.example.net/&foo=bar"</SPAN
3376 Depending on the target server configuration, the parameter will be silently ignored
3379 >"page not found"</SPAN
3380 > error. You can prevent this problem by
3384 HREF="actions-file.html#REDIRECT"
3388 to remove the last part of the URL, but it requires a little effort.
3391 > To detect a redirection URL, <TT
3395 looks for the string <SPAN
3398 >, either in plain text
3399 (invalid but often used) or encoded as <SPAN
3403 Some sites use their own URL encoding scheme, encrypt the address
3404 of the target server or replace it with a database id. In theses cases
3408 > is fooled and the request reaches the
3409 redirection server where it probably gets logged.
3424 > { +fast-redirects{simple-check} }
3427 { +fast-redirects{check-decoded-url} }
3428 another.example.com/testing</PRE
3449 CLASS="VARIABLELIST"
3455 >Get rid of HTML and JavaScript annoyances, banner advertisements (by size),
3456 do fun text replacements, add personalized effects, etc.</P
3462 > All instances of text-based type, most notably HTML and JavaScript, to which
3463 this action applies, can be filtered on-the-fly through the specified regular
3464 expression based substitutions. (Note: as of version 3.0.3 plain text documents
3465 are exempted from filtering, because web servers often use the
3469 > MIME type for all files whose type they don't know.)
3482 > The name of a content filter, as defined in the <A
3483 HREF="filter-file.html"
3486 Filters can be defined in one or more files as defined by the
3490 HREF="config.html#FILTERFILE"
3501 > is the collection of filters
3502 supplied by the developers. Locally defined filters should go
3503 in their own file, such as <TT
3509 > When used in its negative form,
3510 and without parameters, <SPAN
3516 > filtering is completely disabled.
3523 > For your convenience, there are a number of pre-defined filters available
3524 in the distribution filter file that you can use. See the examples below for
3528 > Filtering requires buffering the page content, which may appear to
3529 slow down page rendering since nothing is displayed until all content has
3530 passed the filters. (It does not really take longer, but seems that way
3531 since the page is not incrementally displayed.) This effect will be more
3532 noticeable on slower connections.
3537 >"Rolling your own"</SPAN
3539 filters requires a knowledge of
3541 HREF="http://en.wikipedia.org/wiki/Regular_expressions"
3550 HREF="http://en.wikipedia.org/wiki/Html"
3557 This is very powerful feature, and potentially very intrusive.
3558 Filters should be used with caution, and where an equivalent
3565 > The amount of data that can be filtered is limited to the
3569 HREF="config.html#BUFFER-LIMIT"
3573 option in the main <A
3577 default is 4096 KB (4 Megs). Once this limit is exceeded, the buffered
3578 data, and all pending data, is passed through unfiltered.
3581 > Inappropriate MIME types, such as zipped files, are not filtered at all.
3582 (Again, only text-based types except plain text). Encrypted SSL data
3583 (from HTTPS servers) cannot be filtered either, since this would violate
3584 the integrity of the secure transaction. In some situations it might
3585 be necessary to protect certain text, like source code, from filtering
3586 by defining appropriate <TT
3592 > Compressed content can't be filtered either, unless <SPAN
3596 is compiled with zlib support (requires at least <SPAN
3603 > will decompress the content before filtering
3607 > If you use a <SPAN
3610 > version without zlib support, but want filtering to work on
3611 as much documents as possible, even those that would normally be sent compressed,
3612 you must use the <TT
3615 HREF="actions-file.html#PREVENT-COMPRESSION"
3616 >prevent-compression</A
3619 action in conjunction with <TT
3625 > Content filtering can achieve some of the same effects as the
3629 HREF="actions-file.html#BLOCK"
3633 action, i.e. it can be used to block ads and banners. But the mechanism
3634 works quite differently. One effective use, is to block ad banners
3635 based on their size (see below), since many of these seem to be somewhat
3642 > with suggestions for new or
3643 improved filters is particularly welcome!
3646 > The below list has only the names and a one-line description of each
3647 predefined filter. There are <A
3648 HREF="filter-file.html#PREDEFINED-FILTERS"
3650 verbose explanations</A
3651 > of what these filters do in the <A
3652 HREF="filter-file.html"
3653 >filter file chapter</A
3658 >Example usage (with filters from the distribution <TT
3663 HREF="filter-file.html#PREDEFINED-FILTERS"
3664 >the Predefined Filters section</A
3666 more explanation on each:</DT
3670 NAME="FILTER-JS-ANNOYANCES"
3681 >+filter{js-annoyances} # Get rid of particularly annoying JavaScript abuse</PRE
3689 NAME="FILTER-JS-EVENTS"
3700 >+filter{js-events} # Kill all JS event bindings (Radically destructive! Only for extra nasty sites)</PRE
3708 NAME="FILTER-HTML-ANNOYANCES"
3719 >+filter{html-annoyances} # Get rid of particularly annoying HTML abuse</PRE
3727 NAME="FILTER-CONTENT-COOKIES"
3738 >+filter{content-cookies} # Kill cookies that come in the HTML or JS content</PRE
3746 NAME="FILTER-REFRESH-TAGS"
3757 >+filter{refresh-tags} # Kill automatic refresh tags (for dial-on-demand setups)</PRE
3765 NAME="FILTER-UNSOLICITED-POPUPS"
3776 >+filter{unsolicited-popups} # Disable only unsolicited pop-up windows. Useful if your browser lacks this ability.</PRE
3784 NAME="FILTER-ALL-POPUPS"
3795 >+filter{all-popups} # Kill all popups in JavaScript and HTML. Useful if your browser lacks this ability.</PRE
3803 NAME="FILTER-IMG-REORDER"
3814 >+filter{img-reorder} # Reorder attributes in <img> tags to make the banners-by-* filters more effective</PRE
3822 NAME="FILTER-BANNERS-BY-SIZE"
3833 >+filter{banners-by-size} # Kill banners by size</PRE
3841 NAME="FILTER-BANNERS-BY-LINK"
3852 >+filter{banners-by-link} # Kill banners by their links to known clicktrackers</PRE
3860 NAME="FILTER-WEBBUGS"
3871 >+filter{webbugs} # Squish WebBugs (1x1 invisible GIFs used for user tracking)</PRE
3879 NAME="FILTER-TINY-TEXTFORMS"
3890 >+filter{tiny-textforms} # Extend those tiny textareas up to 40x80 and kill the hard wrap</PRE
3898 NAME="FILTER-JUMPING-WINDOWS"
3909 >+filter{jumping-windows} # Prevent windows from resizing and moving themselves</PRE
3917 NAME="FILTER-FRAMESET-BORDERS"
3928 >+filter{frameset-borders} # Give frames a border and make them resizeable</PRE
3936 NAME="FILTER-DEMORONIZER"
3947 >+filter{demoronizer} # Fix MS's non-standard use of standard charsets</PRE
3955 NAME="FILTER-SHOCKWAVE-FLASH"
3966 >+filter{shockwave-flash} # Kill embedded Shockwave Flash objects</PRE
3974 NAME="FILTER-QUICKTIME-KIOSKMODE"
3985 >+filter{quicktime-kioskmode} # Make Quicktime movies savable</PRE
4004 >+filter{fun} # Text replacements for subversive browsing fun!</PRE
4012 NAME="FILTER-CRUDE-PARENTAL"
4023 >+filter{crude-parental} # Crude parental filtering (demo only)</PRE
4031 NAME="FILTER-IE-EXPLOITS"
4042 >+filter{ie-exploits} # Disable some known Internet Explorer bug exploits</PRE
4050 NAME="FILTER-SITE-SPECIFICS"
4061 >+filter{site-specifics} # Custom filters for specific site related problems</PRE
4069 NAME="FILTER-GOOGLE"
4080 >+filter{google} # Removes text ads and other Google specific improvements</PRE
4099 >+filter{yahoo} # Removes text ads and other Yahoo specific improvements</PRE
4118 >+filter{msn} # Removes text ads and other MSN specific improvements</PRE
4126 NAME="FILTER-BLOGSPOT"
4137 >+filter{blogspot} # Cleans up Blogspot blogs</PRE
4145 NAME="FILTER-NO-PING"
4156 >+filter{no-ping} # Removes non-standard ping attributes from anchor and area tags</PRE
4171 NAME="FORCE-TEXT-MODE"
4173 >8.5.15. force-text-mode</H4
4177 CLASS="VARIABLELIST"
4186 > to treat a document as if it was in some kind of <SPAN
4198 > Declares a document as text, even if the <SPAN
4200 >"Content-Type:"</SPAN
4201 > isn't detected as such.
4224 HREF="actions-file.html#FILTER"
4231 > tries to only filter files that are
4232 in some kind of text format. The same restrictions apply to
4236 HREF="actions-file.html#CONTENT-TYPE-OVERWRITE"
4237 >content-type-overwrite</A
4242 >force-text-mode</TT
4243 > declares a document as text,
4244 without looking at the <SPAN
4246 >"Content-Type:"</SPAN
4268 > Think twice before activating this action. Filtering binary data
4269 with regular expressions can cause file damage.
4304 NAME="FORWARD-OVERRIDE"
4306 >8.5.16. forward-override</H4
4310 CLASS="VARIABLELIST"
4316 >Change the forwarding settings based on User-Agent or request origin</P
4322 > Overrules the forward directives in the configuration files.
4342 > to use a direct connection without any additional proxies.</P
4348 >"forward 127.0.0.1:8123"</SPAN
4349 > to use the HTTP proxy listening at 127.0.0.1 port 8123.
4356 >"forward-socks4a 127.0.0.1:9050 ."</SPAN
4357 > to use the socks4a proxy listening at 127.0.0.1 port 9050.
4360 >"forward-socks4a"</SPAN
4363 >"forward-socks4"</SPAN
4364 > to use a socks4 connection (with local DNS
4365 resolution) instead.
4372 >"forward-socks4a 127.0.0.1:9050 proxy.example.org:8000"</SPAN
4373 > to use the socks4a proxy
4374 listening at 127.0.0.1 port 9050 to reach the HTTP proxy listening at proxy.example.org port 8000.
4377 >"forward-socks4a"</SPAN
4380 >"forward-socks4"</SPAN
4381 > to use a socks4 connection (with local DNS
4382 resolution) instead.
4391 > This action takes parameters similar to the
4393 HREF="config.html#FORWARDING"
4395 > directives in the configuration
4396 file, but without the URL pattern. It can be used as replacement, but normally it's only
4397 used in cases where matching based on the request URL isn't sufficient.
4418 > Please read the description for the <A
4419 HREF="config.html#FORWARDING"
4422 using this action. Forwarding to the wrong people will reduce your privacy and increase the
4423 chances of man-in-the-middle attacks.
4426 > If the ports are missing or invalid, default values will be used. This might change
4427 in the future and you shouldn't rely on it. Otherwise incorrect syntax causes Privoxy
4432 HREF="http://config.privoxy.org/show-url-info"
4434 >show-url-info CGI page</A
4436 to verify that your forward settings do what you thought the do.
4455 ># Always use direct connections for requests previously tagged as
4458 >"User-Agent: fetch libfetch/2.0"</SPAN
4460 # resuming downloads continues to work.
4461 # This way you can continue to use Tor for your normal browsing,
4462 # without overloading the Tor network with your FreeBSD ports updates
4463 # or downloads of bigger files like ISOs.
4464 {+forward-override{forward .} \
4465 -hide-if-modified-since \
4466 -overwrite-last-modified \
4468 TAG:^User-Agent: fetch libfetch/2.0$
4484 NAME="HANDLE-AS-EMPTY-DOCUMENT"
4486 >8.5.17. handle-as-empty-document</H4
4490 CLASS="VARIABLELIST"
4496 >Mark URLs that should be replaced by empty documents <SPAN
4500 >if they get blocked</I
4508 > This action alone doesn't do anything noticeable. It just marks URLs.
4512 HREF="actions-file.html#BLOCK"
4522 the presence or absence of this mark decides whether an HTML <SPAN
4526 page, or an empty document will be sent to the client as a substitute for the blocked content.
4533 > document isn't literally empty, but actually contains a single space.
4553 > Some browsers complain about syntax errors if JavaScript documents
4554 are blocked with <SPAN
4558 default HTML page; this option can be used to silence them.
4559 And of course this action can also be used to eliminate the <SPAN
4563 BLOCKED message in frames.
4566 > The content type for the empty document can be specified with
4570 HREF="actions-file.html#CONTENT-TYPE-OVERWRITE"
4571 >content-type-overwrite{}</A
4574 but usually this isn't necessary.
4589 ># Block all documents on example.org that end with ".js",
4590 # but send an empty document instead of the usual HTML message.
4591 {+block +handle-as-empty-document}
4608 NAME="HANDLE-AS-IMAGE"
4610 >8.5.18. handle-as-image</H4
4614 CLASS="VARIABLELIST"
4620 >Mark URLs as belonging to images (so they'll be replaced by images <SPAN
4624 >if they do get blocked</I
4626 >, rather than HTML pages)</P
4632 > This action alone doesn't do anything noticeable. It just marks URLs as images.
4636 HREF="actions-file.html#BLOCK"
4646 the presence or absence of this mark decides whether an HTML <SPAN
4650 page, or a replacement image (as determined by the <TT
4653 HREF="actions-file.html#SET-IMAGE-BLOCKER"
4654 >set-image-blocker</A
4656 > action) will be sent to the
4657 client as a substitute for the blocked content.
4677 > The below generic example section is actually part of <TT
4681 It marks all URLs with well-known image file name extensions as images and should
4685 > Users will probably only want to use the handle-as-image action in conjunction with
4689 HREF="actions-file.html#BLOCK"
4692 >, to block sources of banners, whose URLs don't
4693 reflect the file type, like in the second example section.
4696 > Note that you cannot treat HTML pages as images in most cases. For instance, (in-line) ad
4697 frames require an HTML page to be sent, or they won't display properly.
4700 >handle-as-image</TT
4701 > in this situation will not replace the
4702 ad frame with an image, but lead to error messages.
4706 >Example usage (sections):</DT
4717 ># Generic image extensions:
4720 /.*\.(gif|jpg|jpeg|png|bmp|ico)$
4722 # These don't look like images, but they're banners and should be
4723 # blocked as images:
4725 {+block +handle-as-image}
4726 some.nasty-banner-server.com/junk.cgi?output=trash
4728 # Banner source! Who cares if they also have non-image content?
4729 ad.doubleclick.net </PRE
4744 NAME="HIDE-ACCEPT-LANGUAGE"
4746 >8.5.19. hide-accept-language</H4
4750 CLASS="VARIABLELIST"
4756 >Pretend to use different language settings.</P
4762 > Deletes or replaces the <SPAN
4764 >"Accept-Language:"</SPAN
4765 > HTTP header in client requests.
4781 >, or any user defined value.
4788 > Faking the browser's language settings can be useful to make a
4789 foreign User-Agent set with
4793 HREF="actions-file.html#HIDE-USER-AGENT"
4800 > However some sites with content in different languages check the
4803 >"Accept-Language:"</SPAN
4804 > to decide which one to take by default.
4805 Sometimes it isn't possible to later switch to another language without
4808 >"Accept-Language:"</SPAN
4812 > Therefore it's a good idea to either only change the
4815 >"Accept-Language:"</SPAN
4816 > header to languages you understand,
4817 or to languages that aren't wide spread.
4820 > Before setting the <SPAN
4822 >"Accept-Language:"</SPAN
4824 to a rare language, you should consider that it helps to
4825 make your requests unique and thus easier to trace.
4826 If you don't plan to change this header frequently,
4827 you should stick to a common language.
4831 >Example usage (section):</DT
4842 ># Pretend to use Canadian language settings.
4843 {+hide-accept-language{en-ca} \
4844 +hide-user-agent{Mozilla/5.0 (X11; U; OpenBSD i386; en-CA; rv:1.8.0.4) Gecko/20060628 Firefox/1.5.0.4} \
4861 NAME="HIDE-CONTENT-DISPOSITION"
4863 >8.5.20. hide-content-disposition</H4
4867 CLASS="VARIABLELIST"
4873 >Prevent download menus for content you prefer to view inside the browser.</P
4879 > Deletes or replaces the <SPAN
4881 >"Content-Disposition:"</SPAN
4882 > HTTP header set by some servers.
4898 >, or any user defined value.
4905 > Some servers set the <SPAN
4907 >"Content-Disposition:"</SPAN
4909 documents they assume you want to save locally before viewing them.
4912 >"Content-Disposition:"</SPAN
4913 > header contains the file name
4914 the browser is supposed to use by default.
4917 > In most browsers that understand this header, it makes it impossible to
4924 > the document, without downloading it first,
4925 even if it's just a simple text file or an image.
4928 > Removing the <SPAN
4930 >"Content-Disposition:"</SPAN
4932 to prevent this annoyance, but some browsers additionally check the
4935 >"Content-Type:"</SPAN
4936 > header, before they decide if they can
4937 display a document without saving it first. In these cases, you have
4938 to change this header as well, before the browser stops displaying
4942 > It is also possible to change the server's file name suggestion
4943 to another one, but in most cases it isn't worth the time to set
4959 ># Disarm the download link in Sourceforge's patch tracker
4961 +content-type-overwrite{text/plain}\
4962 +hide-content-disposition{block} }
4963 .sourceforge.net/tracker/download\.php</PRE
4978 NAME="HIDE-IF-MODIFIED-SINCE"
4980 >8.5.21. hide-if-modified-since</H4
4984 CLASS="VARIABLELIST"
4990 >Prevent yet another way to track the user's steps between sessions.</P
4998 >"If-Modified-Since:"</SPAN
4999 > HTTP client header or modifies its value.
5015 >, or a user defined value that specifies a range of hours.
5022 > Removing this header is useful for filter testing, where you want to force a real
5023 reload instead of getting status code <SPAN
5026 >, which would cause the
5027 browser to use a cached copy of the page.
5030 > Instead of removing the header, <TT
5032 >hide-if-modified-since</TT
5034 also add or subtract a random amount of time to/from the header's value.
5035 You specify a range of minutes where the random factor should be chosen from and
5039 > does the rest. A negative value means
5040 subtracting, a positive value adding.
5043 > Randomizing the value of the <SPAN
5045 >"If-Modified-Since:"</SPAN
5047 sure it isn't used as a cookie replacement, but you will run into
5048 caching problems if the random range is too high.
5051 > It is a good idea to only use a small negative value and let
5055 HREF="actions-file.html#OVERWRITE-LAST-MODIFIED"
5056 >overwrite-last-modified</A
5059 handle the greater changes.
5062 > It is also recommended to use this action together with
5066 HREF="actions-file.html#CRUNCH-IF-NONE-MATCH"
5067 >crunch-if-none-match</A
5073 >Example usage (section):</DT
5084 ># Let the browser revalidate without being tracked across sessions
5085 { +hide-if-modified-since{-60} \
5086 +overwrite-last-modified{randomize} \
5087 +crunch-if-none-match}
5103 NAME="HIDE-FORWARDED-FOR-HEADERS"
5105 >8.5.22. hide-forwarded-for-headers</H4
5109 CLASS="VARIABLELIST"
5115 >Improve privacy by hiding the true source of the request</P
5121 > Deletes any existing <SPAN
5123 >"X-Forwarded-for:"</SPAN
5124 > HTTP header from client requests,
5125 and prevents adding a new one.
5145 > It is fairly safe to leave this on.
5148 > This action is scheduled for improvement: It should be able to generate forged
5151 >"X-Forwarded-for:"</SPAN
5152 > headers using random IP addresses from a specified network,
5153 to make successive requests from the same client look like requests from a pool of different
5154 users sharing the same proxy.
5169 >+hide-forwarded-for-headers</PRE
5184 NAME="HIDE-FROM-HEADER"
5186 >8.5.23. hide-from-header</H4
5190 CLASS="VARIABLELIST"
5196 >Keep your (old and ill) browser from telling web servers your email address</P
5202 > Deletes any existing <SPAN
5205 > HTTP header, or replaces it with the
5222 >, or any user defined value.
5232 > will completely remove the header
5233 (not to be confused with the <TT
5236 HREF="actions-file.html#BLOCK"
5243 > Alternately, you can specify any value you prefer to be sent to the web
5244 server. If you do, it is a matter of fairness not to use any address that
5245 is actually used by a real person.
5248 > This action is rarely needed, as modern web browsers don't send
5267 >+hide-from-header{block}</PRE
5280 >+hide-from-header{spam-me-senseless@sittingduck.example.com}</PRE
5295 NAME="HIDE-REFERRER"
5297 >8.5.24. hide-referrer</H4
5304 CLASS="VARIABLELIST"
5310 >Conceal which link you followed to get to a particular site</P
5319 > (sic) HTTP header from the client request,
5320 or replaces it with a forged one.
5339 >"conditional-block"</SPAN
5340 > to delete the header completely if the host has changed.</P
5347 > to delete the header unconditionally.</P
5354 > to pretend to be coming from the homepage of the server we are talking to.</P
5358 >Any other string to set a user defined referrer.</P
5368 >conditional-block</TT
5369 > is the only parameter,
5370 that isn't easily detected in the server's log file. If it blocks the
5371 referrer, the request will look like the visitor used a bookmark or
5372 typed in the address directly.
5375 > Leaving the referrer unmodified for requests on the same host
5376 allows the server owner to see the visitor's <SPAN
5380 but in most cases she could also get that information by comparing
5381 other parts of the log file: for example the User-Agent if it isn't
5382 a very common one, or the user's IP address if it doesn't change between
5386 > Always blocking the referrer, or using a custom one, can lead to
5387 failures on servers that check the referrer before they answer any
5388 requests, in an attempt to prevent their valuable content from being
5389 embedded or linked to elsewhere.
5394 >conditional-block</TT
5399 will work with referrer checks, as long as content and valid referring page
5400 are on the same host. Most of the time that's the case.
5407 > is an alternate spelling of
5411 > and the two can be can be freely
5412 substituted with each other. (<SPAN
5416 correct English spelling, however the HTTP specification has a bug - it
5417 requires it to be spelled as <SPAN
5435 >+hide-referrer{forge}</PRE
5448 >+hide-referrer{http://www.yahoo.com/}</PRE
5463 NAME="HIDE-USER-AGENT"
5465 >8.5.25. hide-user-agent</H4
5469 CLASS="VARIABLELIST"
5475 >Conceal your type of browser and client operating system</P
5481 > Replaces the value of the <SPAN
5483 >"User-Agent:"</SPAN
5485 in client requests with the specified value.
5498 > Any user-defined string.
5523 > This can lead to problems on web sites that depend on looking at this header in
5524 order to customize their content for different browsers (which, by the
5531 > the right thing to do: good web sites
5532 work browser-independently).
5540 > Using this action in multi-user setups or wherever different types of
5541 browsers will access the same <SPAN
5551 >. In single-user, single-browser
5552 setups, you might use it to delete your OS version information from
5553 the headers, because it is an invitation to exploit known bugs for your
5554 OS. It is also occasionally useful to forge this in order to access
5555 sites that won't let you in otherwise (though there may be a good
5556 reason in some cases). Example of this: some MSN sites will not
5560 > enter, yet forging to a
5564 > user-agent works just fine.
5565 (Must be just a silly MS goof, I'm sure :-).
5568 > This action is scheduled for improvement.
5583 >+hide-user-agent{Netscape 6.1 (X11; I; Linux 2.4.18 i686)}</PRE
5598 NAME="INSPECT-JPEGS"
5600 >8.5.26. inspect-jpegs</H4
5604 CLASS="VARIABLELIST"
5610 >To protect against the MS buffer over-run in JPEG processing</P
5616 > Protect against a known exploit
5636 > See Microsoft Security Bulletin MS04-028. JPEG images are one of the most
5637 common image types found across the Internet. The exploit as described can
5638 allow execution of code on the target system, giving an attacker access
5639 to the system in question by merely planting an altered JPEG image, which
5640 would have no obvious indications of what lurks inside. This action
5641 prevents unwanted intrusion.
5656 >+inspect-jpegs</PRE
5672 >8.5.27. kill-popups<A
5679 CLASS="VARIABLELIST"
5685 >Eliminate those annoying pop-up windows (deprecated)</P
5691 > While loading the document, replace JavaScript code that opens
5692 pop-up windows with (syntactically neutral) dummy code on the fly.
5712 > This action is basically a built-in, hardwired special-purpose filter
5713 action, but there are important differences: For <TT
5717 the document need not be buffered, so it can be incrementally rendered while
5718 downloading. But <TT
5721 > doesn't catch as many pop-ups as
5725 HREF="actions-file.html#FILTER-ALL-POPUPS"
5734 does and is not as smart as <TT
5737 HREF="actions-file.html#FILTER-UNSOLICITED-POPUPS"
5741 >unsolicited-popups</I
5749 > Think of it as a fast and efficient replacement for a filter that you
5750 can use if you don't want any filtering at all. Note that it doesn't make
5751 sense to combine it with any <TT
5754 HREF="actions-file.html#FILTER"
5758 since as soon as one <TT
5761 HREF="actions-file.html#FILTER"
5765 the whole document needs to be buffered anyway, which destroys the advantage of
5769 > action over its filter equivalent.
5772 > Killing all pop-ups unconditionally is problematic. Many shops and banks rely on
5773 pop-ups to display forms, shopping carts etc, and the <TT
5776 HREF="actions-file.html#FILTER-UNSOLICITED-POPUPS"
5780 >unsolicited-popups</I
5785 > does a better job of catching only the unwanted ones.
5788 > If the only kind of pop-ups that you want to kill are exit consoles (those
5795 > windows that appear when you close an other
5796 one), you might want to use
5800 HREF="actions-file.html#FILTER"
5812 > This action is most appropriate for browsers that don't have any controls
5813 for unwanted pop-ups. Not recommended for general usage.
5842 NAME="LIMIT-CONNECT"
5844 >8.5.28. limit-connect</H4
5848 CLASS="VARIABLELIST"
5854 >Prevent abuse of <SPAN
5857 > as a TCP proxy relay or disable SSL for untrusted sites</P
5863 > Specifies to which ports HTTP CONNECT requests are allowable.
5876 > A comma-separated list of ports or port ranges (the latter using dashes, with the minimum
5877 defaulting to 0 and the maximum to 65K).
5884 > By default, i.e. if no <TT
5891 > only allows HTTP CONNECT
5892 requests to port 443 (the standard, secure HTTPS port). Use
5896 > if more fine-grained control is desired
5897 for some or all destinations.
5900 > The CONNECT methods exists in HTTP to allow access to secure websites
5904 > URLs) through proxies. It works very simply:
5905 the proxy connects to the server on the specified port, and then
5906 short-circuits its connections to the client and to the remote server.
5907 This can be a big security hole, since CONNECT-enabled proxies can be
5908 abused as TCP relays very easily.
5914 > relays HTTPS traffic without seeing
5915 the decoded content. Websites can leverage this limitation to circumvent <SPAN
5919 filters. By specifying an invalid port range you can disable HTTPS entirely.
5920 If you plan to disable SSL by default, consider enabling
5924 HREF="actions-file.html#TREAT-FORBIDDEN-CONNECTS-LIKE-BLOCKS"
5925 >treat-forbidden-connects-like-blocks</A
5928 as well, to be able to quickly create exceptions.
5932 >Example usages:</DT
5943 >+limit-connect{443} # This is the default and need not be specified.
5944 +limit-connect{80,443} # Ports 80 and 443 are OK.
5945 +limit-connect{-3, 7, 20-100, 500-} # Ports less than 3, 7, 20 to 100 and above 500 are OK.
5946 +limit-connect{-} # All ports are OK
5947 +limit-connect{,} # No HTTPS/SSL traffic is allowed</PRE
5962 NAME="PREVENT-COMPRESSION"
5964 >8.5.29. prevent-compression</H4
5968 CLASS="VARIABLELIST"
5974 > Ensure that servers send the content uncompressed, so it can be
5978 HREF="actions-file.html#FILTER"
5988 > Removes the Accept-Encoding header which can be used to ask for compressed transfer.
6008 > More and more websites send their content compressed by default, which
6009 is generally a good idea and saves bandwidth. But the <TT
6012 HREF="actions-file.html#FILTER"
6018 HREF="actions-file.html#DEANIMATE-GIFS"
6025 HREF="actions-file.html#KILL-POPUPS"
6029 access to the uncompressed data.
6032 > When compiled with zlib support (available since <SPAN
6035 > 3.0.7), content that should be
6036 filtered is decompressed on-the-fly and you don't have to worry about this action.
6037 If you are using an older <SPAN
6040 > version, or one that hasn't been compiled with zlib
6041 support, this action can be used to convince the server to send the content uncompressed.
6044 > Most text-based instances compress very well, the size is seldom decreased by less than 50%,
6045 for markup-heavy instances like news feeds saving more than 90% of the original size isn't
6049 > Not using compression will therefore slow down the transfer, and you should only
6050 enable this action if you really need it. As of <SPAN
6053 > 3.0.7 it's disabled in all
6054 predefined action settings.
6057 > Note that some (rare) ill-configured sites don't handle requests for uncompressed
6058 documents correctly. Broken PHP applications tend to send an empty document body,
6059 some IIS versions only send the beginning of the content. If you enable
6062 >prevent-compression</TT
6063 > per default, you might want to add
6064 exceptions for those sites. See the example for how to do that.
6068 >Example usage (sections):</DT
6079 ># Selectively turn off compression, and enable a filter
6081 { +filter{tiny-textforms} +prevent-compression }
6082 # Match only these sites
6087 # Or instead, we could set a universal default:
6089 { +prevent-compression }
6092 # Then maybe make exceptions for broken sites:
6094 { -prevent-compression }
6110 NAME="OVERWRITE-LAST-MODIFIED"
6112 >8.5.30. overwrite-last-modified</H4
6116 CLASS="VARIABLELIST"
6122 >Prevent yet another way to track the user's steps between sessions.</P
6130 >"Last-Modified:"</SPAN
6131 > HTTP server header or modifies its value.
6144 > One of the keywords: <SPAN
6149 >"reset-to-request-time"</SPAN
6161 > Removing the <SPAN
6163 >"Last-Modified:"</SPAN
6164 > header is useful for filter
6165 testing, where you want to force a real reload instead of getting status
6169 >, which would cause the browser to reuse the old
6170 version of the page.
6176 > option overwrites the value of the
6179 >"Last-Modified:"</SPAN
6180 > header with a randomly chosen time
6181 between the original value and the current time. In theory the server
6182 could send each document with a different <SPAN
6184 >"Last-Modified:"</SPAN
6186 header to track visits without using cookies. <SPAN
6190 makes it impossible and the browser can still revalidate cached documents.
6195 >"reset-to-request-time"</SPAN
6196 > overwrites the value of the
6199 >"Last-Modified:"</SPAN
6200 > header with the current time. You could use
6201 this option together with
6205 HREF="actions-file.html#HIDE-IF-MODIFIED-SINCE"
6206 >hided-if-modified-since</A
6209 to further customize your random range.
6212 > The preferred parameter here is <SPAN
6216 to use, as long as the time settings are more or less correct.
6217 If the server sets the <SPAN
6219 >"Last-Modified:"</SPAN
6220 > header to the time
6221 of the request, the random range becomes zero and the value stays the same.
6222 Therefore you should later randomize it a second time with
6226 HREF="actions-file.html#HIDE-IF-MODIFIED-SINCE"
6227 >hided-if-modified-since</A
6233 > It is also recommended to use this action together with
6237 HREF="actions-file.html#CRUNCH-IF-NONE-MATCH"
6238 >crunch-if-none-match</A
6255 ># Let the browser revalidate without being tracked across sessions
6256 { +hide-if-modified-since{-60} \
6257 +overwrite-last-modified{randomize} \
6258 +crunch-if-none-match}
6276 >8.5.31. redirect</H4
6280 CLASS="VARIABLELIST"
6286 > Redirect requests to other sites.
6293 > Convinces the browser that the requested document has been moved
6294 to another location and the browser should get it from there.
6307 > An absolute URL or a single pcrs command.
6314 > Requests to which this action applies are answered with a
6315 HTTP redirect to URLs of your choosing. The new URL is
6316 either provided as parameter, or derived by applying a
6317 single pcrs command to the original URL.
6320 > This action will be ignored if you use it together with
6324 HREF="actions-file.html#BLOCK"
6328 It can be combined with
6332 HREF="actions-file.html#FAST-REDIRECTS"
6333 >fast-redirects{check-decoded-url}</A
6336 to redirect to a decoded version of a rewritten URL.
6339 > Use this action carefully, make sure not to create redirection loops
6340 and be aware that using your own redirects might make it
6341 possible to fingerprint your requests.
6345 >Example usages:</DT
6356 ># Replace example.com's style sheet with another one
6357 { +redirect{http://localhost/css-replacements/example.com.css} }
6358 example.com/stylesheet\.css
6360 # Create a short, easy to remember nickname for a favorite site
6361 # (relies on the browser accept and forward invalid URLs to <SPAN
6365 { +redirect{http://www.privoxy.org/user-manual/actions-file.html} }
6368 # Always use the expanded view for Undeadly.org articles
6369 # (Note the $ at the end of the URL pattern to make sure
6370 # the request for the rewritten URL isn't redirected as well)
6371 {+redirect{s@$@&mode=expanded@}}
6372 undeadly.org/cgi\?action=article&sid=\d*$</PRE
6387 NAME="SEND-VANILLA-WAFER"
6389 >8.5.32. send-vanilla-wafer</H4
6393 CLASS="VARIABLELIST"
6399 > Feed log analysis scripts with useless data.
6406 > Sends a cookie with each request stating that you do not accept any copyright
6407 on cookies sent to you, and asking the site operator not to track you.
6427 > The vanilla wafer is a (relatively) unique header and could conceivably be used to track you.
6430 > This action is rarely used and not enabled in the default configuration.
6445 >+send-vanilla-wafer</PRE
6462 >8.5.33. send-wafer</H4
6466 CLASS="VARIABLELIST"
6472 > Send custom cookies or feed log analysis scripts with even more useless data.
6479 > Sends a custom, user-defined cookie with each request.
6492 > A string of the form <SPAN
6512 > Being multi-valued, multiple instances of this action can apply to the same request,
6513 resulting in multiple cookies being sent.
6516 > This action is rarely used and not enabled in the default configuration.
6520 >Example usage (section):</DT
6531 >{+send-wafer{UsingPrivoxy=true}}
6532 my-internal-testing-server.void</PRE
6547 NAME="SERVER-HEADER-FILTER"
6549 >8.5.34. server-header-filter</H4
6553 CLASS="VARIABLELIST"
6559 > Rewrite or remove single server headers.
6566 > All server headers to which this action applies are filtered on-the-fly
6567 through the specified regular expression based substitutions.
6580 > The name of a server-header filter, as defined in one of the
6582 HREF="filter-file.html"
6591 > Server-header filters are applied to each header on its own, not to
6592 all at once. This makes it easier to diagnose problems, but on the downside
6593 you can't write filters that only change header x if header y's value is z.
6594 You can do that by using tags though.
6597 > Server-header filters are executed after the other header actions have finished
6598 and use their output as input.
6601 > Please refer to the <A
6602 HREF="filter-file.html"
6603 >filter file chapter</A
6605 to learn which server-header filters are available by default, and how to
6610 >Example usage (section):</DT
6621 >{+server-header-filter{html-to-xml}}
6622 example.org/xml-instance-that-is-delivered-as-html
6624 {+server-header-filter{xml-to-html}}
6625 example.org/instance-that-is-delivered-as-xml-but-is-not
6641 NAME="SERVER-HEADER-TAGGER"
6643 >8.5.35. server-header-tagger</H4
6647 CLASS="VARIABLELIST"
6653 > Disable or disable filters based on the Content-Type header.
6660 > Server headers to which this action applies are filtered on-the-fly through
6661 the specified regular expression based substitutions, the result is used as
6675 > The name of a server-header tagger, as defined in one of the
6677 HREF="filter-file.html"
6686 > Server-header taggers are applied to each header on its own,
6687 and as the header isn't modified, each tagger <SPAN
6694 > Server-header taggers are executed before all other header actions
6695 that modify server headers. Their tags can be used to control
6696 all of the other server-header actions, the content filters
6697 and the crunch actions (<A
6698 HREF="actions-file.html#REDIRECT"
6702 HREF="actions-file.html#BLOCK"
6707 > Obviously crunching based on tags created by server-header taggers
6708 doesn't prevent the request from showing up in the server's log file.
6712 >Example usage (section):</DT
6723 ># Tag every request with the declared content type
6724 {+client-header-filter{content-type}}
6741 NAME="SESSION-COOKIES-ONLY"
6743 >8.5.36. session-cookies-only</H4
6747 CLASS="VARIABLELIST"
6753 > Allow only temporary <SPAN
6756 > cookies (for the current
6757 browser session <SPAN
6775 >"Set-Cookie:"</SPAN
6777 server headers. Most browsers will not store such cookies permanently and
6778 forget them in between sessions.
6798 > This is less strict than <TT
6801 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
6802 >crunch-incoming-cookies</A
6808 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
6809 >crunch-outgoing-cookies</A
6811 > and allows you to browse
6812 websites that insist or rely on setting cookies, without compromising your privacy too badly.
6815 > Most browsers will not permanently store cookies that have been processed by
6818 >session-cookies-only</TT
6819 > and will forget about them between sessions.
6820 This makes profiling cookies useless, but won't break sites which require cookies so
6821 that you can log in for transactions. This is generally turned on for all
6822 sites, and is the recommended setting.
6833 >session-cookies-only</TT
6838 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
6839 >crunch-incoming-cookies</A
6845 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
6846 >crunch-outgoing-cookies</A
6848 >. If you do, cookies
6849 will be plainly killed.
6852 > Note that it is up to the browser how it handles such cookies without an <SPAN
6856 field. If you use an exotic browser, you might want to try it out to be sure.
6859 > This setting also has no effect on cookies that may have been stored
6860 previously by the browser before starting <SPAN
6864 These would have to be removed manually.
6872 HREF="actions-file.html#FILTER-CONTENT-COOKIES"
6873 >content-cookies filter</A
6875 to block some types of cookies. Content cookies are not effected by
6878 >session-cookies-only</TT
6894 >+session-cookies-only</PRE
6909 NAME="SET-IMAGE-BLOCKER"
6911 >8.5.37. set-image-blocker</H4
6915 CLASS="VARIABLELIST"
6921 >Choose the replacement for blocked images</P
6927 > This action alone doesn't do anything noticeable. If <SPAN
6937 HREF="actions-file.html#BLOCK"
6949 HREF="actions-file.html#HANDLE-AS-IMAGE"
6959 apply, i.e. if the request is to be blocked as an image,
6966 > the parameter of this action decides what will be
6967 sent as a replacement.
6987 > to send a built-in checkerboard pattern image. The image is visually
6988 decent, scales very well, and makes it obvious where banners were busted.
6996 > to send a built-in transparent image. This makes banners disappear
6997 completely, but makes it hard to detect where <SPAN
7001 images on a given page and complicates troubleshooting if <SPAN
7005 has blocked innocent images, like navigation icons.
7019 send a redirect to <TT
7025 to any image anywhere, even in your local filesystem via <SPAN
7029 (But note that not all browsers support redirecting to a local file system).
7032 > A good application of redirects is to use special <SPAN
7036 URLs, which send the built-in images, as <TT
7042 This has the same visual effect as specifying <SPAN
7049 the first place, but enables your browser to cache the replacement image, instead of requesting
7050 it over and over again.
7059 > The URLs for the built-in images are <SPAN
7061 >"http://config.privoxy.org/send-banner?type=<TT
7082 > There is a third (advanced) type, called <SPAN
7094 >set-image-blocker</TT
7095 >, but meant for use from <A
7096 HREF="filter-file.html"
7099 Auto will select the type of image that would have applied to the referring page, had it been an image.
7117 >+set-image-blocker{pattern}</PRE
7124 > Redirect to the BSD daemon:
7135 >+set-image-blocker{http://www.freebsd.org/gifs/dae_up3.gif}</PRE
7142 > Redirect to the built-in pattern for better caching:
7153 >+set-image-blocker{http://config.privoxy.org/send-banner?type=pattern}</PRE
7168 NAME="TREAT-FORBIDDEN-CONNECTS-LIKE-BLOCKS"
7170 >8.5.38. treat-forbidden-connects-like-blocks</H4
7174 CLASS="VARIABLELIST"
7180 >Block forbidden connects with an easy to find error message.</P
7186 > If this action is enabled, <SPAN
7190 makes a difference between forbidden connects and ordinary blocks.
7214 HREF="actions-file.html#LIMIT-CONNECT"
7220 with a short error message inside the headers. If the browser doesn't display
7221 headers (most don't), you just see an empty page.
7224 > With this action enabled, <SPAN
7228 the message that is used for ordinary blocks instead. If you decide
7229 to make an exception for the page in question, you can do so by
7239 > requests the clients tell
7243 > which host they are interested
7244 in, but not which document they plan to get later. As a result, the
7247 >"Go there anyway"</SPAN
7248 > wouldn't work and is therefore suppressed.
7263 >+treat-forbidden-connects-like-blocks</PRE
7280 >8.5.39. Summary</H3
7282 > Note that many of these actions have the potential to cause a page to
7283 misbehave, possibly even not to display at all. There are many ways
7284 a site designer may choose to design his site, and what HTTP header
7285 content, and other criteria, he may depend on. There is no way to have hard
7286 and fast rules for all sites. See the <A
7287 HREF="appendix.html#ACTIONSANAT"
7289 > for a brief example on troubleshooting
7312 >, can be defined by combining other actions.
7313 These can in turn be invoked just like the built-in actions.
7314 Currently, an alias name can contain any character except space, tab,
7332 > that you only use <SPAN
7352 Alias names are not case sensitive, and are not required to start with a
7359 > sign, since they are merely textually
7362 > Aliases can be used throughout the actions file, but they <SPAN
7367 defined in a special section at the top of the file!</I
7370 And there can only be one such section per actions file. Each actions file may
7371 have its own alias section, and the aliases defined in it are only visible
7372 within that file.</P
7374 > There are two main reasons to use aliases: One is to save typing for frequently
7375 used combinations of actions, the other one is a gain in flexibility: If you
7376 decide once how you want to handle shops by defining an alias called
7380 >, you can later change your policy on shops in
7387 > place, and your changes will take effect everywhere
7388 in the actions file where the <SPAN
7391 > alias is used. Calling aliases
7392 by their purpose also makes your actions files more readable.</P
7394 > Currently, there is one big drawback to using aliases, though:
7398 >'s built-in web-based action file
7399 editor honors aliases when reading the actions files, but it expands
7400 them before writing. So the effects of your aliases are of course preserved,
7401 but the aliases themselves are lost when you edit sections that use aliases
7404 > Now let's define some aliases...</P
7414 > # Useful custom aliases we can use later.
7416 # Note the (required!) section header line and that this section
7417 # must be at the top of the actions file!
7421 # These aliases just save typing later:
7422 # (Note that some already use other aliases!)
7424 +crunch-all-cookies = +<A
7425 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
7426 >crunch-incoming-cookies</A
7428 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
7429 >crunch-outgoing-cookies</A
7431 -crunch-all-cookies = -<A
7432 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
7433 >crunch-incoming-cookies</A
7435 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
7436 >crunch-outgoing-cookies</A
7438 +block-as-image = +block +handle-as-image
7439 allow-all-cookies = -crunch-all-cookies -<A
7440 HREF="actions-file.html#SESSION-COOKIES-ONLY"
7441 >session-cookies-only</A
7443 HREF="actions-file.html#FILTER-CONTENT-COOKIES"
7444 >filter{content-cookies}</A
7447 # These aliases define combinations of actions
7448 # that are useful for certain types of sites:
7451 HREF="actions-file.html#BLOCK"
7454 HREF="actions-file.html#FILTER"
7456 > -crunch-all-cookies -<A
7457 HREF="actions-file.html#FAST-REDIRECTS"
7460 HREF="actions-file.html#HIDE-REFERER"
7463 HREF="actions-file.html#KILL-POPUPS"
7466 HREF="actions-file.html#PREVENT-COMPRESSION"
7467 >prevent-compression</A
7470 shop = -crunch-all-cookies -<A
7471 HREF="actions-file.html#FILTER-ALL-POPUPS"
7472 >filter{all-popups}</A
7474 HREF="actions-file.html#KILL-POPUPS"
7478 # Short names for other aliases, for really lazy people ;-)
7480 c0 = +crunch-all-cookies
7481 c1 = -crunch-all-cookies</PRE
7487 > ...and put them to use. These sections would appear in the lower part of an
7488 actions file and define exceptions to the default actions (as specified further
7502 > # These sites are either very complex or very keen on
7503 # user data and require minimal interference to work:
7506 .office.microsoft.com
7507 .windowsupdate.microsoft.com
7508 # Gmail is really mail.google.com, not gmail.com
7512 # Allow cookies (for setting and retrieving your customer data)
7516 .worldpay.com # for quietpc.com
7519 # These shops require pop-ups:
7521 {-kill-popups -filter{all-popups} -filter{unsolicited-popups}}
7523 .overclockers.co.uk</PRE
7529 > Aliases like <SPAN
7535 > are typically used for
7539 > sites that require more than one action to be disabled
7540 in order to function properly.</P
7549 >8.7. Actions Files Tutorial</H2
7551 > The above chapters have shown <A
7552 HREF="actions-file.html"
7553 >which actions files
7554 there are and how they are organized</A
7555 >, how actions are <A
7556 HREF="actions-file.html#ACTIONS"
7559 HREF="actions-file.html#ACTIONS-APPLY"
7563 HREF="actions-file.html#AF-PATTERNS"
7567 HREF="actions-file.html#ALIASES"
7569 >. Now, let's look at an
7577 file and see how all these pieces come together:</P
7585 >8.7.1. default.action</H3
7587 >Every config file should start with a short comment stating its purpose:</P
7597 ># Sample default.action file <ijbswa-developers@lists.sourceforge.net></PRE
7603 >Then, since this is the <TT
7607 first section is a special section for internal use that you needn't
7608 change or worry about:</P
7618 >##########################################################################
7619 # Settings -- Don't change! For internal Privoxy use ONLY.
7620 ##########################################################################
7623 for-privoxy-version=3.0</PRE
7629 >After that comes the (optional) alias section. We'll use the example
7630 section from the above <A
7631 HREF="actions-file.html#ALIASES"
7632 >chapter on aliases</A
7634 that also explains why and how aliases are used:</P
7644 >##########################################################################
7646 ##########################################################################
7649 # These aliases just save typing later:
7650 # (Note that some already use other aliases!)
7652 +crunch-all-cookies = +<A
7653 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
7654 >crunch-incoming-cookies</A
7656 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
7657 >crunch-outgoing-cookies</A
7659 -crunch-all-cookies = -<A
7660 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
7661 >crunch-incoming-cookies</A
7663 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
7664 >crunch-outgoing-cookies</A
7666 +block-as-image = +block +handle-as-image
7667 mercy-for-cookies = -crunch-all-cookies -<A
7668 HREF="actions-file.html#SESSION-COOKIES-ONLY"
7669 >session-cookies-only</A
7671 HREF="actions-file.html#FILTER-CONTENT-COOKIES"
7672 >filter{content-cookies}</A
7675 # These aliases define combinations of actions
7676 # that are useful for certain types of sites:
7679 HREF="actions-file.html#BLOCK"
7682 HREF="actions-file.html#FILTER"
7684 > -crunch-all-cookies -<A
7685 HREF="actions-file.html#FAST-REDIRECTS"
7688 HREF="actions-file.html#HIDE-REFERER"
7691 HREF="actions-file.html#KILL-POPUPS"
7694 shop = -crunch-all-cookies -<A
7695 HREF="actions-file.html#FILTER-ALL-POPUPS"
7696 >filter{all-popups}</A
7698 HREF="actions-file.html#KILL-POPUPS"
7706 > Now come the regular sections, i.e. sets of actions, accompanied
7707 by URL patterns to which they apply. Remember <SPAN
7712 are disabled when matching starts</I
7714 >, so we have to explicitly
7715 enable the ones we want.</P
7717 > The first regular section is probably the most important. It has only
7726 HREF="actions-file.html#AF-PATTERNS"
7727 >matches all URLs</A
7729 set of actions used in this <SPAN
7737 be applied to all requests as a start</I
7739 >. It can be partly or
7740 wholly overridden by later matches further down this file, or in user.action,
7741 but it will still be largely responsible for your overall browsing
7744 > Again, at the start of matching, all actions are disabled, so there is
7745 no real need to disable any actions here, but we will do that nonetheless,
7746 to have a complete listing for your reference. (Remember: a <SPAN
7750 preceding the action name enables the action, a <SPAN
7754 Also note how this long line has been made more readable by splitting it into
7755 multiple lines with line continuation.</P
7765 >##########################################################################
7766 # "Defaults" section:
7767 ##########################################################################
7770 HREF="actions-file.html#ADD-HEADER"
7774 HREF="actions-file.html#CLIENT-HEADER-FILTER"
7775 >client-header-filter{hide-tor-exit-notation}</A
7778 HREF="actions-file.html#BLOCK"
7782 HREF="actions-file.html#CONTENT-TYPE-OVERWRITE"
7783 >content-type-overwrite</A
7786 HREF="actions-file.html#CRUNCH-CLIENT-HEADER"
7787 >crunch-client-header</A
7790 HREF="actions-file.html#CRUNCH-IF-NONE-MATCH"
7791 >crunch-if-none-match</A
7794 HREF="actions-file.html#CRUNCH-INCOMING-COOKIES"
7795 >crunch-incoming-cookies</A
7798 HREF="actions-file.html#CRUNCH-SERVER-HEADER"
7799 >crunch-server-header</A
7802 HREF="actions-file.html#CRUNCH-OUTGOING-COOKIES"
7803 >crunch-outgoing-cookies</A
7806 HREF="actions-file.html#DEANIMATE-GIFS"
7810 HREF="actions-file.html#DOWNGRADE-HTTP-VERSION"
7811 >downgrade-http-version</A
7814 HREF="actions-file.html#FAST-REDIRECTS"
7815 >fast-redirects{check-decoded-url}</A
7818 HREF="actions-file.html#FILTER-JS-ANNOYANCES"
7819 >filter{js-annoyances}</A
7822 HREF="actions-file.html#FILTER-JS-EVENTS"
7823 >filter{js-events}</A
7826 HREF="actions-file.html#FILTER-HTML-ANNOYANCES"
7827 >filter{html-annoyances}</A
7830 HREF="actions-file.html#FILTER-CONTENT-COOKIES"
7831 >filter{content-cookies}</A
7834 HREF="actions-file.html#FILTER-REFRESH-TAGS"
7835 >filter{refresh-tags}</A
7838 HREF="actions-file.html#FILTER-UNSOLICITED-POPUPS"
7839 >filter{unsolicited-popups}</A
7842 HREF="actions-file.html#FILTER-ALL-POPUPS"
7843 >filter{all-popups}</A
7846 HREF="actions-file.html#FILTER-IMG-REORDER"
7847 >filter{img-reorder}</A
7850 HREF="actions-file.html#FILTER-BANNERS-BY-SIZE"
7851 >filter{banners-by-size}</A
7854 HREF="actions-file.html#FILTER-BANNERS-BY-LINK"
7855 >filter{banners-by-link}</A
7858 HREF="actions-file.html#FILTER-WEBBUGS"
7862 HREF="actions-file.html#FILTER-TINY-TEXTFORMS"
7863 >filter{tiny-textforms}</A
7866 HREF="actions-file.html#FILTER-JUMPING-WINDOWS"
7867 >filter{jumping-windows}</A
7870 HREF="actions-file.html#FILTER-FRAMESET-BORDERS"
7871 >filter{frameset-borders}</A
7874 HREF="actions-file.html#FILTER-DEMORONIZER"
7875 >filter{demoronizer}</A
7878 HREF="actions-file.html#FILTER-SHOCKWAVE-FLASH"
7879 >filter{shockwave-flash}</A
7882 HREF="actions-file.html#FILTER-QUICKTIME-KIOSKMODE"
7883 >filter{quicktime-kioskmode}</A
7886 HREF="actions-file.html#FILTER-FUN"
7890 HREF="actions-file.html#FILTER-CRUDE-PARENTAL"
7891 >filter{crude-parental}</A
7894 HREF="actions-file.html#FILTER-IE-EXPLOITS"
7895 >filter{ie-exploits}</A
7898 HREF="actions-file.html#FILTER-GOOGLE"
7902 HREF="actions-file.html#FILTER-YAHOO"
7906 HREF="actions-file.html#FILTER-MSN"
7910 HREF="actions-file.html#FILTER-BLOGSPOT"
7911 >filter{blogspot}</A
7914 HREF="actions-file.html#FILTER-NO-PING"
7918 HREF="actions-file.html#FORCE-TEXT-MODE"
7922 HREF="actions-file.html#HANDLE-AS-EMPTY-DOCUMENT"
7923 >handle-as-empty-document</A
7926 HREF="actions-file.html#HANDLE-AS-IMAGE"
7930 HREF="actions-file.html#HIDE-ACCEPT-LANGUAGE"
7931 >hide-accept-language</A
7934 HREF="actions-file.html#HIDE-CONTENT-DISPOSITION"
7935 >hide-content-disposition</A
7938 HREF="actions-file.html#HIDE-IF-MODIFIED-SINCE"
7939 >hide-if-modified-since</A
7942 HREF="actions-file.html#HIDE-FORWARDED-FOR-HEADERS"
7943 >hide-forwarded-for-headers</A
7946 HREF="actions-file.html#HIDE-FROM-HEADER"
7947 >hide-from-header{block}</A
7950 HREF="actions-file.html#HIDE-REFERER"
7951 >hide-referrer{forge}</A
7954 HREF="actions-file.html#HIDE-USER-AGENT"
7958 HREF="actions-file.html#INSPECT-JPEGS"
7962 HREF="actions-file.html#KILL-POPUPS"
7966 HREF="actions-file.html#LIMIT-CONNECT"
7970 HREF="actions-file.html#PREVENT-COMPRESSION"
7971 >prevent-compression</A
7974 HREF="actions-file.html#OVERWRITE-LAST-MODIFIED"
7975 >overwrite-last-modified</A
7978 HREF="actions-file.html#REDIRECT"
7982 HREF="actions-file.html#SEND-VANILLA-WAFER"
7983 >send-vanilla-wafer</A
7986 HREF="actions-file.html#SEND-WAFER"
7990 HREF="actions-file.html#SERVER-HEADER-FILTER"
7991 >server-header-filter{xml-to-html}</A
7994 HREF="actions-file.html#SERVER-HEADER-FILTER"
7995 >server-header-filter{html-to-xml}</A
7998 HREF="actions-file.html#SESSION-COOKIES-ONLY"
7999 >session-cookies-only</A
8002 HREF="actions-file.html#SET-IMAGE-BLOCKER"
8003 >set-image-blocker{pattern}</A
8006 HREF="actions-file.html#TREAT-FORBIDDEN-CONNECTS-LIKE-BLOCKS"
8007 >treat-forbidden-connects-like-blocks</A
8010 / # forward slash will match *all* potential URL patterns.</PRE
8016 > The default behavior is now set. Note that some actions, like not hiding
8017 the user agent, are part of a <SPAN
8019 >"general policy"</SPAN
8021 universally and won't get any exceptions defined later. Other choices,
8022 like not blocking (which is <SPAN
8029 default!) need exceptions, i.e. we need to specify explicitly what we
8030 want to block in later sections.</P
8032 > The first of our specialized sections is concerned with <SPAN
8036 sites, i.e. sites that require minimum interference, because they are either
8037 very complex or very keen on tracking you (and have mechanisms in place that
8038 make them unusable for people who avoid being tracked). We will simply use
8042 > alias instead of stating the list
8043 of actions explicitly:</P
8053 >##########################################################################
8054 # Exceptions for sites that'll break under the default action set:
8055 ##########################################################################
8057 # "Fragile" Use a minimum set of actions for these sites (see alias above):
8060 .office.microsoft.com # surprise, surprise!
8061 .windowsupdate.microsoft.com
8062 mail.google.com</PRE
8068 > Shopping sites are not as fragile, but they typically
8069 require cookies to log in, and pop-up windows for shopping
8070 carts or item details. Again, we'll use a pre-defined alias:</P
8084 .worldpay.com # for quietpc.com
8095 HREF="actions-file.html#FAST-REDIRECTS"
8099 action, which we enabled per default above, breaks some sites. So disable
8100 it for popular sites where we know it misbehaves:</P
8111 HREF="actions-file.html#FAST-REDIRECTS"
8117 .altavista.com/.*(like|url|link):http
8118 .altavista.com/trans.*urltext=http
8125 > It is important that <SPAN
8129 URLs belong to images, so that <SPAN
8136 be blocked, a substitute image can be sent, rather than an HTML page.
8137 Contacting the remote site to find out is not an option, since it
8138 would destroy the loading time advantage of banner blocking, and it
8139 would feed the advertisers (in terms of money <SPAN
8146 information). We can mark any URL as an image with the <TT
8149 HREF="actions-file.html#HANDLE-AS-IMAGE"
8153 and marking all URLs that end in a known image file extension is a
8164 >##########################################################################
8166 ##########################################################################
8168 # Define which file types will be treated as images, in case they get
8169 # blocked further down this file:
8172 HREF="actions-file.html#HANDLE-AS-IMAGE"
8175 /.*\.(gif|jpe?g|png|bmp|ico)$</PRE
8181 > And then there are known banner sources. They often use scripts to
8182 generate the banners, so it won't be visible from the URL that the
8183 request is for an image. Hence we block them <SPAN
8190 mark them as images in one go, with the help of our
8193 >+block-as-image</TT
8194 > alias defined above. (We could of
8195 course just as well use <TT
8198 HREF="actions-file.html#BLOCK"
8202 HREF="actions-file.html#HANDLE-AS-IMAGE"
8206 Remember that the type of the replacement image is chosen by the
8210 HREF="actions-file.html#SET-IMAGE-BLOCKER"
8211 >set-image-blocker</A
8214 action. Since all URLs have matched the default section with its
8218 HREF="actions-file.html#SET-IMAGE-BLOCKER"
8219 >set-image-blocker</A
8222 action before, it still applies and needn't be repeated:</P
8232 ># Known ad generators:
8237 .ad.*.doubleclick.net
8238 .a.yimg.com/(?:(?!/i/).)*$
8239 .a[0-9].yimg.com/(?:(?!/i/).)*$
8247 > One of the most important jobs of <SPAN
8251 is to block banners. Many of these can be <SPAN
8258 HREF="actions-file.html#FILTER"
8260 >{banners-by-size}</TT
8262 action, which we enabled above, and which deletes the references to banner
8263 images from the pages while they are loaded, so the browser doesn't request
8264 them anymore, and hence they don't need to be blocked here. But this naturally
8265 doesn't catch all banners, and some people choose not to use filters, so we
8266 need a comprehensive list of patterns for banner URLs here, and apply the
8270 HREF="actions-file.html#BLOCK"
8273 > action to them.</P
8275 > First comes many generic patterns, which do most of the work, by
8276 matching typical domain and path name components of banners. Then comes
8277 a list of individual patterns for specific sites, which is omitted here
8278 to keep the example short:</P
8288 >##########################################################################
8289 # Block these fine banners:
8290 ##########################################################################
8292 HREF="actions-file.html#BLOCK"
8302 /.*count(er)?\.(pl|cgi|exe|dll|asp|php[34]?)
8303 /(?:.*/)?(publicite|werbung|rekla(ma|me|am)|annonse|maino(kset|nta|s)?)/
8305 # Site-specific patterns (abbreviated):
8313 > It's quite remarkable how many advertisers actually call their banner
8319 >.com, or call the directory
8320 in which the banners are stored simply <SPAN
8324 generic patterns are surprisingly effective.</P
8326 > But being very generic, they necessarily also catch URLs that we don't want
8327 to block. The pattern <TT
8339 >.nasty-corp.com"</SPAN
8349 >.sourcefroge.net"</SPAN
8359 >l.some-provider.net."</SPAN
8361 well-known exceptions to the <TT
8364 HREF="actions-file.html#BLOCK"
8370 > Note that these are exceptions to exceptions from the default! Consider the URL
8373 >"downloads.sourcefroge.net"</SPAN
8374 >: Initially, all actions are deactivated,
8375 so it wouldn't get blocked. Then comes the defaults section, which matches the
8376 URL, but just deactivates the <TT
8379 HREF="actions-file.html#BLOCK"
8383 action once again. Then it matches <TT
8386 >, an exception to the
8387 general non-blocking policy, and suddenly
8391 HREF="actions-file.html#BLOCK"
8394 > applies. And now, it'll match
8401 HREF="actions-file.html#BLOCK"
8405 applies, so (unless it matches <SPAN
8411 > further down) it ends up
8415 HREF="actions-file.html#BLOCK"
8418 > action applying.</P
8428 >##########################################################################
8429 # Save some innocent victims of the above generic block patterns:
8430 ##########################################################################
8435 HREF="actions-file.html#BLOCK"
8438 adv[io]*. # (for advogato.org and advice.*)
8439 adsl. # (has nothing to do with ads)
8440 adobe. # (has nothing to do with ads either)
8441 ad[ud]*. # (adult.* and add.*)
8442 .edu # (universities don't host banners (yet!))
8443 .*loads. # (downloads, uploads etc)
8451 www.globalintersec.com/adv # (adv = advanced)
8452 www.ugu.com/sui/ugu/adv</PRE
8458 > Filtering source code can have nasty side effects,
8459 so make an exception for our friends at sourceforge.net,
8460 and all paths with <SPAN
8463 > in them. Note that
8467 HREF="actions-file.html#FILTER"
8477 > filters in one fell swoop!</P
8487 ># Don't filter code!
8490 HREF="actions-file.html#FILTER"
8497 .sourceforge.net</PRE
8506 > is of course much more
8507 comprehensive, but we hope this example made clear how it works.</P
8516 >8.7.2. user.action</H3
8518 > So far we are painting with a broad brush by setting general policies,
8519 which would be a reasonable starting point for many people. Now,
8520 you might want to be more specific and have customized rules that
8521 are more suitable to your personal habits and preferences. These would
8522 be for narrowly defined situations like your ISP or your bank, and should
8526 >, which is parsed after all other
8527 actions files and hence has the last word, over-riding any previously
8528 defined actions. <TT
8538 > place for your personal settings, since
8542 > is actively maintained by the
8546 > developers and you'll probably want
8547 to install updated versions from time to time.</P
8549 > So let's look at a few examples of things that one might typically do in
8563 ># My user.action file. <fred@foobar.com></PRE
8570 HREF="actions-file.html#ALIASES"
8572 > are local to the actions
8573 file that they are defined in, you can't use the ones from
8577 >, unless you repeat them here:</P
8587 ># Aliases are local to the file they are defined in.
8588 # (Re-)define aliases for this file:
8592 # These aliases just save typing later, and the alias names should
8593 # be self explanatory.
8595 +crunch-all-cookies = +crunch-incoming-cookies +crunch-outgoing-cookies
8596 -crunch-all-cookies = -crunch-incoming-cookies -crunch-outgoing-cookies
8597 allow-all-cookies = -crunch-all-cookies -session-cookies-only
8598 allow-popups = -filter{all-popups} -kill-popups
8599 +block-as-image = +block +handle-as-image
8600 -block-as-image = -block
8602 # These aliases define combinations of actions that are useful for
8603 # certain types of sites:
8605 fragile = -block -crunch-all-cookies -filter -fast-redirects -hide-referrer -kill-popups
8606 shop = -crunch-all-cookies allow-popups
8608 # Allow ads for selected useful free sites:
8610 allow-ads = -block -filter{banners-by-size} -filter{banners-by-link}
8612 # Alias for specific file types that are text, but might have conflicting
8613 # MIME types. We want the browser to force these to be text documents.
8614 handle-as-text = -<A
8615 HREF="actions-file.html#FILTER"
8618 HREF="actions-file.html#CONTENT-TYPE-OVERWRITE"
8619 >content-type-overwrite{text/plain}</A
8621 HREF="actions-file.html#FORCE-TEXT-MODE"
8624 HREF="actions-file.html#HIDE-CONTENT-DISPOSITION"
8625 >hide-content-disposition</A
8632 > Say you have accounts on some sites that you visit regularly, and
8633 you don't want to have to log in manually each time. So you'd like
8634 to allow persistent cookies for these sites. The
8637 >allow-all-cookies</TT
8638 > alias defined above does exactly
8639 that, i.e. it disables crunching of cookies in any direction, and the
8640 processing of cookies to make them only temporary.</P
8650 >{ allow-all-cookies }
8660 > Your bank is allergic to some filter, but you don't know which, so you disable them all:</P
8671 HREF="actions-file.html#FILTER"
8674 .your-home-banking-site.com</PRE
8680 > Some file types you may not want to filter for various reasons:</P
8690 ># Technical documentation is likely to contain strings that might
8691 # erroneously get altered by the JavaScript-oriented filters:
8696 # And this stupid host sends streaming video with a wrong MIME type,
8697 # so that Privoxy thinks it is getting HTML and starts filtering:
8699 stupid-server.example.com/</PRE
8705 > Example of a simple <A
8706 HREF="actions-file.html#BLOCK"
8708 > action. Say you've
8709 seen an ad on your favourite page on example.com that you want to get rid of.
8710 You have right-clicked the image, selected <SPAN
8712 >"copy image location"</SPAN
8714 and pasted the URL below while removing the leading http://, into a
8718 > section. Note that <TT
8722 > need not be specified, since all URLs ending in
8726 > will be tagged as images by the general rules as set
8727 in default.action anyway:</P
8738 HREF="actions-file.html#BLOCK"
8741 www.example.com/nasty-ads/sponsor\.gif
8742 another.popular.site.net/more/junk/here/</PRE
8748 > The URLs of dynamically generated banners, especially from large banner
8749 farms, often don't use the well-known image file name extensions, which
8750 makes it impossible for <SPAN
8754 the file type just by looking at the URL.
8757 >+block-as-image</TT
8758 > alias defined above for
8760 Note that objects which match this rule but then turn out NOT to be an
8761 image are typically rendered as a <SPAN
8763 >"broken image"</SPAN
8765 browser. Use cautiously.</P
8775 >{ +block-as-image }
8785 > Now you noticed that the default configuration breaks Forbes Magazine,
8786 but you were too lazy to find out which action is the culprit, and you
8787 were again too lazy to give <A
8791 you just used the <TT
8794 > alias on the site, and
8801 > -- it worked. The <TT
8805 aliases disables those actions that are most likely to break a site. Also,
8806 good for testing purposes to see if it is <SPAN
8810 that is causing the problem or not. We later find other regular sites
8811 that misbehave, and add those to our personalized list of troublemakers:</P
8830 > You like the <SPAN
8833 > text replacements in <TT
8837 but it is disabled in the distributed actions file. (My colleagues on the team just
8838 don't have a sense of humour, that's why! ;-). So you'd like to turn it on in your private,
8839 update-safe config, once and for all:</P
8850 HREF="actions-file.html#FILTER-FUN"
8853 / # For ALL sites!</PRE
8859 > Note that the above is not really a good idea: There are exceptions
8860 to the filters in <TT
8864 really shouldn't be filtered, like code on CVS->Web interfaces. Since
8868 > has the last word, these exceptions
8869 won't be valid for the <SPAN
8872 > filtering specified here.</P
8874 > You might also worry about how your favourite free websites are
8875 funded, and find that they rely on displaying banner advertisements
8876 to survive. So you might want to specifically allow banners for those
8877 sites that you feel provide value to you:</P
8899 > has been aliased to
8903 HREF="actions-file.html#BLOCK"
8910 HREF="actions-file.html#FILTER-BANNERS-BY-SIZE"
8911 >filter{banners-by-size}</A
8917 HREF="actions-file.html#FILTER-BANNERS-BY-LINK"
8918 >filter{banners-by-link}</A
8922 > Invoke another alias here to force an over-ride of the MIME type <TT
8924 > application/x-sh</TT
8925 > which typically would open a download type
8926 dialog. In my case, I want to look at the shell script, and then I can save
8927 it should I choose to.</P
8947 > is generally the best place to define
8948 exceptions and additions to the default policies of
8952 >. Some actions are safe to have their
8953 default policies set here though. So let's set a default policy to have a
8957 > image as opposed to the checkerboard pattern for
8967 > of course matches all URL
8968 paths and patterns:</P
8979 HREF="actions-file.html#SET-IMAGE-BLOCKER"
8980 >set-image-blocker{blank}</A
8995 SUMMARY="Footer navigation table"
9024 HREF="filter-file.html"
9034 >The Main Configuration File</TD