renamed some filters
[privoxy.git] / default.action
1 #############################################################################
2 #
3 # Bare-bones actions file for Privoxy pre release testdrive
4 #
5 # For information, see http://www.oesterhelt.org/testdrive
6 #
7 #############################################################################
8
9 ######################################################################
10
11 #  File        :  $Source: /cvsroot/ijbswa/current/default.action,v $
12
13 #  $Id: default.action,v 1.18 2002/04/16 13:34:51 oes Exp $
14 #
15 #  Purpose     :  Default actions file, see
16 #                 http://www.privoxy.org/faq/questions.html#CONFIGFILES
17 #
18 #  Copyright   :  Written by and Copyright
19 #                 Privoxy team. http://www.privoxy.org/
20 #
21 #                 Based on the Internet Junkbuster originally written
22 #                 by and Copyright (C) 1997 Anonymous Coders and
23 #                 Junkbusters Corporation.  http://www.junkbusters.com
24
25 # We value your feedback. However, to provide you with the best support,
26 # please note:
27 #  
28 #  * Use the support forum to get help:
29 #    http://sourceforge.net/tracker/?group_id=11118&atid=211118
30 #  * Submit feedback for this actions file only through our
31 #    actions file feedback script: http://www.privoxy.org/actions
32 #  * Submit bugs only through our bug forum:
33 #    http://sourceforge.net/tracker/?group_id=11118&atid=111118 
34 #    Make sure that the bug has not already been submitted. Please try
35 #    to verify that it is a Privoxy bug, and not a browser or site
36 #    bug first. If you are using your own custom configuration, please
37 #    try the stock configs to see if the problem is a configuration
38 #    related bug. And if not using the latest development snapshot,
39 #    please try the latest one. Or even better, CVS sources.
40 #  * Submit feature requests only through our feature request forum:
41 #    http://sourceforge.net/tracker/?atid=361118&group_id=11118&func=browse
42 #      
43 # For any other issues, feel free to use the mailing lists:
44 # http://sourceforge.net/mail/?group_id=11118
45 #    
46 # Anyone interested in actively participating in development and related
47 # discussions can join the appropriate mailing list here:
48 # http://sourceforge.net/mail/?group_id=11118. Archives are available
49 # here too.
50
51 #############################################################################
52 # Syntax
53 #############################################################################
54
55 # To determine which actions apply to a request, the URL of the request is
56 # compared to all patterns in this file. Every time it matches, the list of
57 # applicable actions for this URL is incrementally updated. You can trace
58 # this process by visiting http://i.j.b/show-url-info
59 #
60 # There are 4 types of lines in this file: comments (like this line),
61 # actions, aliases and patterns, all of which are explained below.
62 #
63 #############################################################################
64 # Pattern Syntax
65 #############################################################################
66
67 # 1. On Domains and Paths
68 # -----------------------
69 #
70 # Generally, a pattern has the form <domain>/<path>, where both the <domain>
71 # and <path> part are optional. If you only specify a domain part, the "/"
72 # can be left out:
73
74 # www.example.com 
75 #   is a domain-only pattern and will match any request to www.yahoo.com
76
77 # www.example.com/
78 #   means exactly the same (but is slightly less efficient)
79
80 # www.example.com/index.html
81 #   matches only the document /index.html on www.example.com
82
83 # /index.html
84 #   matches the document /index.html, regardless of the domain
85
86 # index.html
87 #   matches nothing, since it would be interpreted as a domain name and
88 #   there is no top-level domain called ".html".
89
90 # 2. Domain Syntax
91 # ----------------
92
93 # The matching of the domain part offers some flexible options: If the
94 # domain starts or ends with a dot, it becomes unanchored at that end:
95
96 # www.example.com
97 #   matches only www.example.com
98
99 # .example.com
100 #   matches any domain that ENDS in .example.com
101
102 # www.
103 #   matches any domain that STARTS with www.
104
105 # Additionally, there are wildcards that you can use in the domain names
106 # themselves. They work pretty similar to shell wildcards: "*" stands for
107 # zero or more arbitrary characters, "?" stands for one, and you can define
108 # charachter classes in square brackets and they can be freely mixed:
109
110 # ad*.example.com
111 #   matches adserver.example.com, ads.example.com, etc but not sfads.example.com
112
113 # *ad*.example.com
114 #   matches all of the above
115
116 # .?pix.com
117 #   matches www.ipix.com, pictures.epix.com, a.b.c.d.e.upix.com etc
118
119 # www[1-9a-ez].example.com
120 #   matches www1.example.com, www4.example.com, wwwd.example.com, 
121 #   wwwz.example.com etc, but not wwww.example.com
122
123 # You get the idea?
124
125 # 2. Path Syntax
126 # --------------
127
128 # Paths are specified as regular expressions. A comprehensive discussion of
129 # regular expressions wouldn't fit here, but (FIXME) someone should paste
130 # a concise intro to the regex language here.
131
132 # If Privoxy was compiled with pcre support (default), Perl compatible
133 # regular expressions are used. See the pcre/docs/ direcory or man perlre
134 # (also available on http://www.perldoc.com/perl5.6/pod/perlre.html) for
135 # details.
136
137 # Please note that matching in the path is CASE INSENSITIVE by default, but
138 # you can switch to case sensitive by starting the pattern with the "(?-i)"
139 # switch:
140
141 # www.example.com/(?-i)PaTtErN.*
142 #   will match only documents whose path starts with PaTtErN in exactly this
143 #   capitalization.
144 #
145 # Partially case-sensetive and partially case-insensitive patterns are
146 # possible, but the rules about splitting them up are extremely complex
147 # - see the PCRE documentation for more information.
148
149 #############################################################################
150 # Action Syntax
151 #############################################################################
152 #
153 # There are 3 kinds of action:
154 #
155 # Boolean (e.g. "block"):
156 #   +name  # enable
157 #   -name  # disable
158 #
159 # Parameterized (e.g. "hide-user-agent"):
160 #   +name{param}  # enable and set parameter to "param"
161 #   -name         # disable
162 #
163 # Multi-value (e.g. "add-header", "wafer"):
164 #   +name{param}  # enable and add parameter "param"
165 #   -name{param}  # remove the parameter "param"
166 #   -name         # disable totally
167 #
168 # The default (if you don't specify anything in this file) is not to take
169 # any actions - i.e completely disabled, so Privoxy will just be a
170 # normal, non-blocking, non-anonymizing proxy.  You must specifically
171 # enable the privacy and blocking features you need (although the 
172 # provided default actions file will do that for you).
173 #
174 # Later actions always override earlier ones.  For multi-valued actions,
175 # the actions are applied in the order they are specified.
176 #
177 #############################################################################
178 # Valid actions are:
179 #############################################################################
180 #
181 # +add-header{Name: value}
182 #    Adds the specified HTTP header, which is not checked for validity.
183 #    You may specify this many times to specify many headers.
184 #
185 # +block
186 #    Block this URL
187 #
188 # +deanimate-gifs{last}
189 # +deanimate-gifs{first}
190 #    Deanimate all animated GIF images, i.e. reduce them to their last
191 #    frame. This will also shrink the images considerably. (In bytes,
192 #    not pixels!) 
193 #    If the option "first" is given, the first frame of the animation
194 #    is used as the replacement. If "last" is given, the last frame of
195 #    the animation is used instead, which propably makes more sense for
196 #    most banner animations, but also has the risk of not showing the
197 #    entire last frame (if it is only a delta to an earlier frame).
198 #
199 # +downgrade
200 #    Downgrade HTTP/1.1 client requests to HTTP/1.0 and downgrade the
201 #    responses as well. Use this action for servers that use HTTP/1.1
202 #    protocol features that Privoxy currently can't handle yet.
203 #
204 # +fast-redirects
205 #    Many sites, like yahoo.com, don't just link to other sites.
206 #    Instead, they will link to some script on their own server,
207 #    giving the destination as a parameter, which will then redirect
208 #    you to the final target. 
209 #
210 #    URLs resulting from this scheme typically look like:
211 #    http://some.place/some_script?http://some.where-else
212 #
213 #    Sometimes, there are even multiple consecutive redirects encoded
214 #    in the URL. These redirections via scripts make your web browing
215 #    more traceable, since the server from which you follow such a link
216 #    can see where you go to. Apart from that, valuable bandwidth and
217 #    time is wasted, while your browser aks the server for one redirect
218 #    after the other. Plus, it feeds the advertisers.
219 #
220 #    The +fast-redirects option enables interception of these requests
221 #    by Privoxy, who will cut off all but the last valid URL in the
222 #    request and send a local redirect back to your browser without
223 #    contacting the intermediate sites.
224 #
225 # +filter{name}
226 #    Filter the website through one or more regular expression filters.
227 #    Repeat for multiple filters.
228 #   
229 #    Filters predefined in the supplied re_filterfile include:
230 #
231 #     html-annoyances:  Get rid of particularly annoying HTML abuse
232 #     js-annoyances:    Get rid of particularly annoying JavaScript abuse
233 #     content-cookies:  Kill cookies that come in the HTML or JS content
234 #     poups:            Kill all popups in JS and HTML
235 #     frameset-borders: Give frames a border
236 #     webbugs:          Squish WebBugs (1x1 invisible GIFs used for user tracking)
237 #     refresh-tags:     Kill automatic refresh tags (for dial-on-demand setups)
238 #     fun:              Text replacements  for subversive browsing fun!
239 #     nimda:            Remove Nimda (virus) code.
240 #     banners-by-size:  Kill banners by size (very efficient!)
241 #     shockwave-flash:  Kill embedded Shockwave Flash objects
242 #     crude-parental:   Kill all web pages that contain the words "sex" or "warez"
243 #
244 #
245 # +hide-forwarded
246 #    Block any existing X-Forwarded-for header, and do not add a new one.
247 #
248 # +hide-from{block}
249 # +hide-from{spam@sittingduck.xqq}
250 #    If the browser sends a "From:" header containing your e-mail address, 
251 #    either completely removes the header ("block"), or change it to the
252 #    specified e-mail address.
253 #
254 # +hide-referer{block}
255 # +hide-referer{forge}
256 # +hide-referer{http://nowhere.com}
257 #    Don't send the "Referer:" (sic) header to the web site.  You can
258 #    block it, forge a URL to the same server as the request (which is
259 #    preferred because some sites will not send images otherwise) or
260 #    set it to a constant string.
261 #
262 # +hide-referrer{...}
263 #    Alternative spelling of +hide-referer.  Has the same parameters,
264 #    and can be freely mixed with, "+hide-referer".  ("referrer" is the 
265 #    correct English spelling, however the HTTP specification has a 
266 #    bug - it requires it to be spelt "referer").
267 #
268 # +hide-user-agent{browser-type}
269 #    Change the "User-Agent:" header so web servers can't tell your
270 #    browser type.  (Breaks many web sites).  Specify the user-agent
271 #    value you want - e.g., to pretend to be using Netscape on Linux:
272 #      +hide-user-agent{Mozilla (X11; I; Linux 2.0.32 i586)}
273 #    Or to identify yourself explicitly as a Privoxy user:
274 #      +hide-user-agent{Privoxy/1.0}
275 #    (Don't change the version number from 1.0 - after all, why tell them?)
276 #
277 # +image
278 #    Treat this URL as an image.  This only matters if it's also "+block"ed,
279 #    in which case a "blocked" image can be sent rather than a HTML page.
280 #    See +image-blocker{} for the control over what is actually sent.
281 #
282 # +image-blocker{blank}
283 # +image-blocker{pattern}
284 # +image-blocker{<URL>} with <url> being any valid image URL
285 #    Decides what to do with URLs that end up tagged with {+block +image}.
286 #    There are 4 options:
287 #      * "-image-blocker" will send a HTML "blocked" page, usually
288 #        resulting in a "broken image" icon.
289 #      * "+image-blocker{blank}" will send a 1x1 transparent image
290 #      * "+image-blocker{pattern}" will send a 4x4 grey/white pattern
291 #        which is less intrusive than the logo but easier to recognize
292 #        than the transparent one.
293 #      * "+image-blocker{<URL>}" will send a HTTP temporary redirect
294 #        to the specified image URL.
295 #
296 #
297 # +limit-connect{portlist}
298 #   The CONNECT methods exists in HTTP to allow access to secure websites
299 #   (https:// URLs) through proxies. It works very simply: The proxy
300 #   connects to the server on the specified port, and then short-circuits
301 #   its connections to the cliant and to the remote proxy.
302 #   This can be a big security hole, since CONNECT-enabled proxies can
303 #   be abused as TCP relays very easily.
304 #   By default, i.e. in the absence of a +limit-connect action, Privoxy
305 #   will only allow CONNECT requests to port 443, which is the standard port
306 #   for https.
307 #   If you want to allow CONNECT for more ports than that, or want to forbid
308 #   CONNECT altogether, you can specify a comma separated list of ports and port
309 #   ranges (the latter using dashes, with the minimum defaulting to 0 and max to 65K):
310 #
311 #   +limit-connect{443} # This is the default and need no be specified.
312 #   +limit-connect{80,443} # Ports 80 and 443 are OK.
313 #   +limit-connect{-3, 7, 20-100, 500-} # Port less than 3, 7, 20 to 100, and above 500 are OK.
314 #
315 # +no-compression
316 #    Prevent the website from compressing the data. Some websites do
317 #    that, which is a problem for Privoxy, since +filter, +no-popup
318 #    and +gif-deanimate will not work on compressed data. Will slow down
319 #    connections to those websites, though.
320 #
321 # +no-cookies-keep
322 #    If the website sets cookies, make sure they are erased when you exit
323 #    and restart your web browser.  This makes profiling cookies useless,
324 #    but won't break sites which require cookies so that you can log in
325 #    or for transactions.
326 #
327 # +no-cookies-read
328 #    Prevent the website from reading cookies
329 #
330 # +no-cookies-set
331 #    Prevent the website from setting cookies
332 #
333 # +no-popup
334 # +no-popups
335 #    Filter the website through a built-in filter to disable
336 #    1;''.concat() etc.  The two alternative spellings are
337 #    equivalent.
338 #
339 # +vanilla-wafer
340 #    This action only applies if you are using a jarfile.  It sends a
341 #    cookie to every site stating that you do not accept any copyright
342 #    on cookies sent to you, and asking them not to track you.  Of
343 #    course, this is a (relatively) unique header they could use to 
344 #    track you.
345 #
346 # +wafer{name=value}
347 #    This allows you to add an arbitrary cookie.  Specify it multiple
348 #    times in order to add several cookies.
349 #
350 #############################################################################
351
352
353 #############################################################################
354 # Aliases
355 #############################################################################
356 {{alias}}
357 #############################################################################
358 #
359 # You can define a short form for a list of permissions - e.g., instead
360 # of "-no-cookies-set -no-cookies-read -filter -fast-redirects", you can
361 # just write "shop".  This is called an alias.
362 #
363 # Currently, an alias can contain any character except space, tab, '=', '{'
364 # or '}'.
365 # But please use only 'a'-'z', '0'-'9', '+', and '-'.
366 #
367 # Alias names are not case sensitive.
368 #
369 # Aliases beginning with '+' or '-' may be used for system permission names 
370 # in future releases - so try to avoid alias names like this.  (e.g. 
371 # "+no-cookies" below is not a good name)
372 #
373 # Aliases must be defined before they are used.
374
375
376 # Useful aliases
377 +no-cookies = +no-cookies-set +no-cookies-read
378 -no-cookies = -no-cookies-set -no-cookies-read
379 +imageblock = +block +image
380
381 # Fragile sites should have the minimum changes
382 fragile     = -block -deanimate-gifs -fast-redirects -filter -hide-referer -no-cookies -no-popups
383
384 # Shops should be allowed to set persistent cookies
385 shop        = -filter -no-cookies -no-cookies-keep
386
387 # Your favourite blend of filters:
388 #
389 myfilters   = +filter{html-annoyances} +filter{js-annoyances} +filter{no-popups}\
390               +filter{webbugs} +filter{nimda} +filter{banners-by-size} #+filter{fun}
391
392 #... etc.  Customize to your heart's content.
393
394 #############################################################################
395 # Defaults
396 #############################################################################
397 {\
398 -add-header \
399 -block \
400 +deanimate-gifs{last} \
401 -downgrade \
402 +filter{html-annoyances} \
403 +filter{content-cookies} \
404 +filter{js-annoyances} \
405 +filter{popups} \
406 +filter{webbugs} \
407 +filter{nimda} \
408 +filter{banners-by-size} \
409 +hide-forwarded \
410 +hide-from{block} \
411 +hide-referer{forge} \
412 -hide-user-agent \
413 -image \
414 +image-blocker{pattern} \
415 +no-compression \
416 +no-cookies-keep \
417 -no-cookies-read \
418 -no-cookies-set \
419 +no-popups \
420 -vanilla-wafer \
421 -wafer \
422 }
423 / # Match all URLs
424
425
426 #############################################################################
427 # Needed for automatic feedback evaluation; Please don't delete!
428 #############################################################################
429 {+add-header{X-Actions-File-Version: 1.2} -filter -no-popups}
430 .privoxy.org/actions
431 .oesterhelt.org/actions
432
433
434 #############################################################################
435 # These sites are very complex and require
436 # minimal interference.
437 #############################################################################
438 {fragile}
439 .office.microsoft.com
440 .windowsupdate.microsoft.com
441
442 #############################################################################
443 # Shopping sites - still want to block ads.
444 #############################################################################
445 {shop}
446 .quietpc.com
447 .worldpay.com   # for quietpc.com
448 .jungle.com
449 .scan.co.uk
450
451 #############################################################################
452 # These shops require pop-ups
453 #############################################################################
454 {shop -no-popups -filter{poups}}
455 .dabs.com
456 .overclockers.co.uk
457
458 #############################################################################
459 # Sometimes fast-redirects catches things by mistake
460 #############################################################################
461 {-fast-redirects}
462 www.ukc.ac.uk/cgi-bin/wac\.cgi\?
463 login.yahoo.com
464 edit.europe.yahoo.com
465 .google.com
466 .altavista.com/.*(like|url|link):http
467 .altavista.com/trans.*urltext=http
468 .speedfind.de
469 .nytimes.com
470
471 #############################################################################
472 # Don't filter code!
473 #############################################################################
474 {-filter}
475 .cvs.sourceforge.net
476
477 #############################################################################
478 # Imagelist:
479 #############################################################################
480 {+image}
481 #############################################################################
482 /.*\.(gif|jpe?g|png|bmp|ico)
483
484 #############################################################################
485 {+imageblock}
486 #############################################################################
487 #BLOCK-REFERRER: http://www.cnn.com/
488 #BLOCK-REFERRER: http://www.aol.com/
489 ar.atwola.com 
490
491 #BLOCK-REFERRER: http://www.altavista.com/
492 .ad.doubleclick.net
493
494 .a.yimg.com/(?:(?!/i/).)*$
495 .a[0-9].yimg.com/(?:(?!/i/).)*$
496
497
498
499 #BLOCK-REFERRER: 
500 bs*.gsanet.com
501 bs*.einets.com
502
503 #BLOCK-REFERRER: Opera browser built-in
504 .qkimg.net
505
506 #BLOCK-REFERRER: http://www.tecchannel.de/index.html
507 #BLOCK-REFERRER: and thousands more
508 ad.*.doubleclick.net
509
510 #############################################################################
511 # Blocklist:
512 #############################################################################
513 {+block}
514 #############################################################################
515 #BLOCK-GENERIC:
516 ad*.
517 .*ads.
518 banner?.
519 count*.
520
521 /(?:.*/)?(ads(erver?|tream)?|.*?ads|adv(ert(s|enties|is(ing|e?ments)?)?)?|(ad)?[-_]?banner(s|ads?|farm)?)/
522 /.*count(er)?\.(pl|cgi|exe|dll|asp|php[34]?)
523 /(?:.*/)?(publicite|werbung|rekla(ma|me|am)|annonse|maino(kset|nta|s)?)/
524
525 #BLOCK-REFERRER: http://www.brooksbrothers.com
526 #BLOCK-REFERRER: http://www.autodesk.com
527 .hitbox.com 
528
529 #############################################################################
530 {-block}
531 #############################################################################
532 include.ebay.com
533 advogato.org
534 adsl.
535 ad[ud]*.
536 advice.
537 .edu
538 .ac.uk
539 .uni-*.de
540 www.ugu.com/sui/ugu/adv
541 .*downloads.