+ </P
+></DD
+></DL
+></DIV
+></DIV
+><DIV
+CLASS="SECT3"
+><H4
+CLASS="SECT3"
+><A
+NAME="FAST-REDIRECTS"
+>8.5.14. fast-redirects</A
+></H4
+><P
+></P
+><DIV
+CLASS="VARIABLELIST"
+><DL
+><DT
+>Typical use:</DT
+><DD
+><P
+>Fool some click-tracking scripts and speed up indirect links.</P
+></DD
+><DT
+>Effect:</DT
+><DD
+><P
+> Detects redirection URLs and redirects the browser without contacting
+ the redirection server first.
+ </P
+></DD
+><DT
+>Type:</DT
+><DD
+><P
+>Parameterized.</P
+></DD
+><DT
+>Parameter:</DT
+><DD
+><P
+></P
+><UL
+><LI
+><P
+> <SPAN
+CLASS="QUOTE"
+>"simple-check"</SPAN
+> to just search for the string <SPAN
+CLASS="QUOTE"
+>"http://"</SPAN
+>
+ to detect redirection URLs.
+ </P
+></LI
+><LI
+><P
+> <SPAN
+CLASS="QUOTE"
+>"check-decoded-url"</SPAN
+> to decode URLs (if necessary) before searching
+ for redirection URLs.
+ </P
+></LI
+></UL
+></DD
+><DT
+>Notes:</DT
+><DD
+><P
+>
+ Many sites, like yahoo.com, don't just link to other sites. Instead, they
+ will link to some script on their own servers, giving the destination as a
+ parameter, which will then redirect you to the final target. URLs
+ resulting from this scheme typically look like:
+ <SPAN
+CLASS="QUOTE"
+>"http://www.example.org/click-tracker.cgi?target=http%3a//www.example.net/"</SPAN
+>.
+ </P
+><P
+> Sometimes, there are even multiple consecutive redirects encoded in the
+ URL. These redirections via scripts make your web browsing more traceable,
+ since the server from which you follow such a link can see where you go
+ to. Apart from that, valuable bandwidth and time is wasted, while your
+ browser asks the server for one redirect after the other. Plus, it feeds
+ the advertisers.
+ </P
+><P
+> This feature is currently not very smart and is scheduled for improvement.
+ If it is enabled by default, you will have to create some exceptions to
+ this action. It can lead to failures in several ways:
+ </P
+><P
+> Not every URLs with other URLs as parameters is evil.
+ Some sites offer a real service that requires this information to work.
+ For example a validation service needs to know, which document to validate.
+ <TT
+CLASS="LITERAL"
+>fast-redirects</TT
+> assumes that every URL parameter that
+ looks like another URL is a redirection target, and will always redirect to
+ the last one. Most of the time the assumption is correct, but if it isn't,
+ the user gets redirected anyway.
+ </P
+><P
+> Another failure occurs if the URL contains other parameters after the URL parameter.
+ The URL:
+ <SPAN
+CLASS="QUOTE"
+>"http://www.example.org/?redirect=http%3a//www.example.net/&foo=bar"</SPAN
+>.
+ contains the redirection URL <SPAN
+CLASS="QUOTE"
+>"http://www.example.net/"</SPAN
+>,
+ followed by another parameter. <TT
+CLASS="LITERAL"
+>fast-redirects</TT
+> doesn't know that
+ and will cause a redirect to <SPAN
+CLASS="QUOTE"
+>"http://www.example.net/&foo=bar"</SPAN
+>.
+ Depending on the target server configuration, the parameter will be silently ignored
+ or lead to a <SPAN
+CLASS="QUOTE"
+>"page not found"</SPAN
+> error. You can prevent this problem by
+ first using the <TT
+CLASS="LITERAL"
+><A
+HREF="actions-file.html#REDIRECT"
+>redirect</A
+></TT
+> action
+ to remove the last part of the URL, but it requires a little effort.
+ </P
+><P
+> To detect a redirection URL, <TT
+CLASS="LITERAL"
+>fast-redirects</TT
+> only
+ looks for the string <SPAN
+CLASS="QUOTE"
+>"http://"</SPAN
+>, either in plain text
+ (invalid but often used) or encoded as <SPAN
+CLASS="QUOTE"
+>"http%3a//"</SPAN
+>.
+ Some sites use their own URL encoding scheme, encrypt the address
+ of the target server or replace it with a database id. In theses cases
+ <TT
+CLASS="LITERAL"
+>fast-redirects</TT
+> is fooled and the request reaches the
+ redirection server where it probably gets logged.
+ </P
+></DD
+><DT
+>Example usage:</DT
+><DD
+><P
+> <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+> { +fast-redirects{simple-check} }
+ one.example.com
+
+ { +fast-redirects{check-decoded-url} }
+ another.example.com/testing</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+></DD
+></DL
+></DIV
+></DIV
+><DIV
+CLASS="SECT3"
+><H4
+CLASS="SECT3"
+><A
+NAME="FILTER"
+>8.5.15. filter</A
+></H4
+><P
+></P
+><DIV
+CLASS="VARIABLELIST"
+><DL
+><DT
+>Typical use:</DT
+><DD
+><P
+>Get rid of HTML and JavaScript annoyances, banner advertisements (by size),
+ do fun text replacements, add personalized effects, etc.</P
+></DD
+><DT
+>Effect:</DT
+><DD
+><P
+> All instances of text-based type, most notably HTML and JavaScript, to which
+ this action applies, can be filtered on-the-fly through the specified regular
+ expression based substitutions. (Note: as of version 3.0.3 plain text documents
+ are exempted from filtering, because web servers often use the
+ <TT
+CLASS="LITERAL"
+>text/plain</TT
+> MIME type for all files whose type they don't know.)
+ </P
+></DD
+><DT
+>Type:</DT
+><DD
+><P
+>Parameterized.</P
+></DD
+><DT
+>Parameter:</DT
+><DD
+><P
+> The name of a content filter, as defined in the <A
+HREF="filter-file.html"
+>filter file</A
+>.
+ Filters can be defined in one or more files as defined by the
+ <TT
+CLASS="LITERAL"
+><A
+HREF="config.html#FILTERFILE"
+>filterfile</A
+></TT
+>
+ option in the <A
+HREF="config.html"
+>config file</A
+>.
+ <TT
+CLASS="FILENAME"
+>default.filter</TT
+> is the collection of filters
+ supplied by the developers. Locally defined filters should go
+ in their own file, such as <TT
+CLASS="FILENAME"
+>user.filter</TT
+>.
+ </P
+><P
+> When used in its negative form,
+ and without parameters, <SPAN
+CLASS="emphasis"
+><I
+CLASS="EMPHASIS"
+>all</I
+></SPAN
+> filtering is completely disabled.
+ </P
+></DD
+><DT
+>Notes:</DT
+><DD
+><P
+> For your convenience, there are a number of pre-defined filters available
+ in the distribution filter file that you can use. See the examples below for
+ a list.
+ </P
+><P
+> Filtering requires buffering the page content, which may appear to
+ slow down page rendering since nothing is displayed until all content has
+ passed the filters. (It does not really take longer, but seems that way
+ since the page is not incrementally displayed.) This effect will be more
+ noticeable on slower connections.
+ </P
+><P
+> <SPAN
+CLASS="QUOTE"
+>"Rolling your own"</SPAN
+>
+ filters requires a knowledge of
+ <A
+HREF="http://en.wikipedia.org/wiki/Regular_expressions"
+TARGET="_top"
+><SPAN
+CLASS="QUOTE"
+>"Regular
+ Expressions"</SPAN
+></A
+> and
+ <A
+HREF="http://en.wikipedia.org/wiki/Html"
+TARGET="_top"
+><SPAN
+CLASS="QUOTE"
+>"HTML"</SPAN
+></A
+>.
+ This is very powerful feature, and potentially very intrusive.
+ Filters should be used with caution, and where an equivalent
+ <SPAN
+CLASS="QUOTE"
+>"action"</SPAN
+> is not available.
+ </P
+><P
+> The amount of data that can be filtered is limited to the
+ <TT
+CLASS="LITERAL"
+><A
+HREF="config.html#BUFFER-LIMIT"
+>buffer-limit</A
+></TT
+>
+ option in the main <A
+HREF="config.html"
+>config file</A
+>. The
+ default is 4096 KB (4 Megs). Once this limit is exceeded, the buffered
+ data, and all pending data, is passed through unfiltered.
+ </P
+><P
+> Inappropriate MIME types, such as zipped files, are not filtered at all.
+ (Again, only text-based types except plain text). Encrypted SSL data
+ (from HTTPS servers) cannot be filtered either, since this would violate
+ the integrity of the secure transaction. In some situations it might
+ be necessary to protect certain text, like source code, from filtering
+ by defining appropriate <TT
+CLASS="LITERAL"
+>-filter</TT
+> exceptions.
+ </P
+><P
+> Compressed content can't be filtered either, unless <SPAN
+CLASS="APPLICATION"
+>Privoxy</SPAN
+>
+ is compiled with zlib support (requires at least <SPAN
+CLASS="APPLICATION"
+>Privoxy</SPAN
+> 3.0.7),
+ in which case <SPAN
+CLASS="APPLICATION"
+>Privoxy</SPAN
+> will decompress the content before filtering
+ it.
+ </P
+><P
+> If you use a <SPAN
+CLASS="APPLICATION"
+>Privoxy</SPAN
+> version without zlib support, but want filtering to work on
+ as much documents as possible, even those that would normally be sent compressed,
+ you must use the <TT
+CLASS="LITERAL"
+><A
+HREF="actions-file.html#PREVENT-COMPRESSION"
+>prevent-compression</A
+></TT
+>
+ action in conjunction with <TT
+CLASS="LITERAL"
+>filter</TT
+>.
+ </P
+><P
+> Content filtering can achieve some of the same effects as the
+ <TT
+CLASS="LITERAL"
+><A
+HREF="actions-file.html#BLOCK"
+>block</A
+></TT
+>
+ action, i.e. it can be used to block ads and banners. But the mechanism
+ works quite differently. One effective use, is to block ad banners
+ based on their size (see below), since many of these seem to be somewhat
+ standardized.
+ </P
+><P
+> <A
+HREF="contact.html"
+>Feedback</A
+> with suggestions for new or
+ improved filters is particularly welcome!
+ </P
+><P
+> The below list has only the names and a one-line description of each
+ predefined filter. There are <A
+HREF="filter-file.html#PREDEFINED-FILTERS"
+>more
+ verbose explanations</A
+> of what these filters do in the <A
+HREF="filter-file.html"
+>filter file chapter</A
+>.
+ </P
+></DD
+><DT
+>Example usage (with filters from the distribution <TT
+CLASS="FILENAME"
+>default.filter</TT
+> file).
+ See <A
+HREF="filter-file.html#PREDEFINED-FILTERS"
+>the Predefined Filters section</A
+> for
+ more explanation on each:</DT
+><DD
+><P
+> <A
+NAME="FILTER-JS-ANNOYANCES"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{js-annoyances} # Get rid of particularly annoying JavaScript abuse.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-JS-EVENTS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{js-events} # Kill all JS event bindings and timers (Radically destructive! Only for extra nasty sites).</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-HTML-ANNOYANCES"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{html-annoyances} # Get rid of particularly annoying HTML abuse.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-CONTENT-COOKIES"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{content-cookies} # Kill cookies that come in the HTML or JS content.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-REFRESH-TAGS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{refresh-tags} # Kill automatic refresh tags (for dial-on-demand setups).</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-UNSOLICITED-POPUPS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{unsolicited-popups} # Disable only unsolicited pop-up windows. Useful if your browser lacks this ability.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-ALL-POPUPS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{all-popups} # Kill all popups in JavaScript and HTML. Useful if your browser lacks this ability.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-IMG-REORDER"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{img-reorder} # Reorder attributes in <img> tags to make the banners-by-* filters more effective.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-BANNERS-BY-SIZE"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{banners-by-size} # Kill banners by size.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-BANNERS-BY-LINK"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{banners-by-link} # Kill banners by their links to known clicktrackers.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-WEBBUGS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{webbugs} # Squish WebBugs (1x1 invisible GIFs used for user tracking).</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-TINY-TEXTFORMS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{tiny-textforms} # Extend those tiny textareas up to 40x80 and kill the hard wrap.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-JUMPING-WINDOWS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{jumping-windows} # Prevent windows from resizing and moving themselves.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-FRAMESET-BORDERS"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{frameset-borders} # Give frames a border and make them resizable.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-DEMORONIZER"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{demoronizer} # Fix MS's non-standard use of standard charsets.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-SHOCKWAVE-FLASH"
+></A
+>
+ <TABLE
+BORDER="0"
+BGCOLOR="#E0E0E0"
+WIDTH="90%"
+><TR
+><TD
+><PRE
+CLASS="SCREEN"
+>+filter{shockwave-flash} # Kill embedded Shockwave Flash objects.</PRE
+></TD
+></TR
+></TABLE
+>
+ </P
+><P
+> <A
+NAME="FILTER-QUICKTIME-KIOSKMODE"