Let the msn filter hide elements with the id 's_notf_div'.
[privoxy.git] / regression-tests.action
1 #############################################################################
2 # $Id: regression-tests.action,v 1.34 2011/03/08 18:33:28 fabiankeil Exp $
3 #############################################################################
4 #
5 # This is a configuration file for Privoxy-Regression-Test
6 # (included in the source tarball's tools directory).
7 #
8 # After referencing it in your Privoxy configuration both Privoxy and
9 # Privoxy-Regression-Test should be good to go.
10 #
11 #############################################################################
12 #
13 # Copyright (c) 2007-2011 Fabian Keil <fk@fabiankeil.de>
14 #
15 # Permission to use, copy, modify, and distribute this software for any
16 # purpose with or without fee is hereby granted, provided that the above
17 # copyright notice and this permission notice appear in all copies.
18 #
19 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
20 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
21 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
22 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
23 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
24 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
25 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
26 #
27 #############################################################################
28
29 {{settings}}
30 for-privoxy-version=3.0.14
31
32 # Some dependencies Privoxy-Regression-Test should know about:
33 #
34 # Level  9 needs = config line user-manual\s+(\.?\.?/|[A-Za-z]:)
35 # Level 12 needs = config line enable-edit-actions\s+1
36 # Level 13 needs = feature status FEATURE_CONNECTION_KEEP_ALIVE Yes
37 # Level 13 needs = config line keep-alive-timeout\s+[1-9]+
38 # Level 14 needs = feature status FEATURE_CONNECTION_KEEP_ALIVE No
39 # Level 15 needs = config line connection-sharing\s+0
40 # Level 16 needs = feature status FEATURE_CONNECTION_KEEP_ALIVE Yes
41 # Level 16 needs = config line connection-sharing\s+1
42 # Level 17 needs = feature status FEATURE_PTHREAD Yes
43 # Level 18 needs = feature status FEATURE_GRACEFUL_TERMINATION No
44 # Level 19 needs = feature status FEATURE_GRACEFUL_TERMINATION Yes
45
46 #######################################################
47 # Enable taggers to activate the tests on demand
48 # and suppress hiding the User-Agent for
49 # Privoxy-Regression-Test to save log space.
50 #######################################################
51 {\
52  +client-header-tagger{user-agent} \
53  +client-header-tagger{privoxy-control} \
54  +client-header-filter{privoxy-control} \
55 }
56 config.privoxy.org/
57 p.p/
58 127.0.0.1/
59
60 {-hide-user-agent}
61 TAG:^User-Agent: Privoxy-Regression-Test
62
63 #######################################################
64 # Test accept-language{}.
65 #######################################################
66
67 # Set Header    = Accept-Language: de-de
68 # Expect Header = Accept-Language: en-gb
69 {+hide-accept-language{en-gb}}
70 TAG:^hide-accept-language\{en-gb\}$
71
72 # Set Header    = Accept-Language: de-de
73 # Expect Header = REMOVAL
74 {+hide-accept-language{block}}
75 TAG:^hide-accept-language\{block\}$
76
77 #######################################################
78 # Sections for hide-referrer{} to test:
79 #
80 # 1) conditional-block
81 # 2) conditional-forge
82 # 3) forge
83 # 4) block
84 # 5) a parameter that looks like a valid fake referrer 
85 # 6) a parameter that looks like an invalid fake referrer
86 #######################################################
87
88 # Set Header    = Referer: http://www.example.org/foo 
89 # Expect Header = REMOVAL
90 #
91 # Set Header    = Referer: http://p.p/foo
92 # Expect Header = NO CHANGE
93 #
94 # Set Header    = Referer: p.p/
95 # Expect Header = REMOVAL
96 #
97 # Set Header    = Referer: p
98 # Expect Header = REMOVAL
99 #
100 # Set Header    = Referer: http://
101 # Expect Header = REMOVAL
102 #
103 # Set Header    = Referer: https://p.p/
104 # Expect Header = REMOVAL
105 {+hide-referrer{conditional-block}}
106 TAG:^hide-referrer\{conditional-block\}$
107
108 # Set Header    = Referer: http://www.example.org/foo 
109 # Expect Header = Referer: http://p.p/
110 #
111 # Set Header    = Referer: http://p.p/foo
112 # Expect Header = NO CHANGE
113 #
114 # Set Header    = Referer: p.p/
115 # Expect Header = Referer: http://p.p/
116 #
117 # Set Header    = Referer: p
118 # Expect Header = Referer: http://p.p/
119 #
120 # Set Header    = Referer: http://
121 # Expect Header = Referer: http://p.p/
122 #
123 # Set Header    = Referer: https://p.p/
124 # Expect Header = Referer: http://p.p/
125 {+hide-referrer{conditional-forge}}
126 TAG:^hide-referrer\{conditional-forge\}$
127
128 # Set Header    = Referer: http://www.example.org/foo 
129 # Expect Header = Referer: http://p.p/
130 {+hide-referrer{forge}}
131 TAG:^hide-referrer\{forge\}$
132
133 # Set Header    = Referer: http://www.example.org/foo 
134 # Expect Header = REMOVAL
135 {+hide-referrer{block}}
136 TAG:^hide-referrer\{block\}$
137
138 # Set Header    = Referer: http://www.example.org/foo 
139 # Expect Header = Referer: invalid
140 {+hide-referrer{invalid}}
141 TAG:^hide-referrer\{invalid\}$
142
143 # Set Header    = Referer: http://www.example.org/asdf
144 # Expect Header = Referer: http://www.privoxy.org/
145 {+hide-referrer{http://www.privoxy.org/}}
146 TAG:^hide-referrer\{http://www.privoxy.org/\}$
147
148 #{+hide-referrer{}}
149 #TAG:^hide-referrer\{\}$
150
151 #######################################################
152 # Test hide-user-agent{}.
153 #######################################################
154
155 # Set Header    = User-Agent: Mozilla/5.0 (X11; U; NetBSD i386; de-CH; rv:1.8.1.6) Gecko/20070806 Firefox/2.0.0.6
156 # Expect Header = User-Agent: Mozilla/5.0 (X11; U; FreeBSD alpha; en-GB; rv:1.8.1.6) Gecko/20070913 Firefox/2.0.0.6
157 {+hide-user-agent{Mozilla/5.0 (X11; U; FreeBSD alpha; en-GB; rv:1.8.1.6) Gecko/20070913 Firefox/2.0.0.6}}
158 TAG:^hide-user-agent\{Mozilla/5\.0 \(X11; U; FreeBSD alpha; en-GB; rv:1\.8\.1\.6\) Gecko/20070913 Firefox/2\.0\.0\.6\}$
159
160 # XXX: Check the code that is tested here.
161 # Set Header = ua-blah: blah
162 # Expect Header = REMOVAL
163 {+hide-user-agent{block}}
164 TAG:^hide-user-agent{block}$
165
166 # Set Header = ua-blah: blah
167 # Expect Header = NO CHANGE
168 {-hide-user-agent{}}
169 TAG:^-hide-user-agent{block}$
170
171
172 #######################################################
173 # Test add-header{}.
174 #######################################################
175
176 # Set Header    = X-Whatever: foo
177 # Expect Header = X-Custom-Header: yes, please
178
179 {+add-header{X-Custom-Header: yes, please}}
180 TAG:^add-header\{X-Custom-Header: yes, please\}$
181
182 #######################################################
183 # Test client-header-filter{hide-tor-exit-notation}.
184 #######################################################
185
186 # Set Header    = Referer: http://p.p.zwiebelsuppe.exit/
187 # Expect Header = Referer: http://p.p/
188 #
189 # Set Header    = Referer: http://p.p.zwiebelsuppe.exit/foo/bar/baaz/
190 # Expect Header = Referer: http://p.p/foo/bar/baaz/
191 #
192 # Set Header    = Referer: http://p.p/
193 # Expect Header = NO CHANGE
194 #
195 # Set Header    = Referer: http://config.privoxy.org.zwiebelsuppe.exit/foo/bar/baaz.html
196 # Expect Header = Referer: http://config.privoxy.org/foo/bar/baaz.html
197 #
198 # Set Header    = Host: p.p.zwiebelsuppe.exit
199 # Expect Header = Host: p.p
200 #
201 # Set Header    = Host: p.p
202 # Expect Header = NO CHANGE
203 #
204 # Set Header    = Referer: http://config.privoxy.org.ad356ef8e87a89e6c898b74500d58607ac691178.exit/foo/baaz.html
205 # Expect Header = Referer: http://config.privoxy.org/foo/baaz.html
206
207 {+client-header-filter{hide-tor-exit-notation} -hide-referer}
208 TAG:^client-header-filter\{hide-tor-exit-notation\}$
209
210 #######################################################
211 # Test crunch-client-header{}.
212 #######################################################
213
214 # Set Header    = Content-Type: text/html
215 # Expect Header = REMOVAL
216 #
217 # Set Header    = Content-Type: text/html; charset=4711
218 # Expect Header = REMOVAL
219 #
220 # Set Header    = Content-Type: text/plain
221 # Expect Header = NO CHANGE
222
223 {+crunch-client-header{text/html}}
224 TAG:^crunch-client-header\{text/plain\}$
225
226
227 #######################################################
228 # Test crunch-if-none-match.
229 #######################################################
230
231 # Set Header    = If-None-Match: 8987afd239d2093kd2309kd
232 # Expect Header = REMOVAL
233
234 # Set Header    = If-None-Match: 82c3cb50c984ef11b1fed749949b2a16
235 # Expect Header = REMOVAL
236
237 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
238 # Expect Header = NO CHANGE
239
240 {+crunch-if-none-match -hide-if-modified-since}
241 TAG:^crunch-if-none-match$
242
243 #######################################################
244 # Test hide-if-modified-since
245 #######################################################
246
247 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
248 # Expect Header = REMOVAL
249 #
250 # Set Header    = If-None-Match: 82c3cb50c984ef11b1fed749949b2a16
251 # Expect Header = NO CHANGE
252
253 {+hide-if-modified-since{block} -crunch-if-none-match}
254 TAG:^hide-if-modified-since\{block\}$
255
256 # Set Header    = If-Modified-Since: Gee, this date is invalid
257 # Expect Header = REMOVAL
258 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
259 # Expect Header = SOME CHANGE
260 # Set Header    = If-Modified-Since: Thu, 1 Jan 1970 00:00:00 GMT
261 # Expect Header = SOME CHANGE
262 # Level = 17
263 # Set Header    = If-Modified-Since: Thu, 1 Jan 123456789 00:00:00 GMT
264 # Expect Header = REMOVAL
265 # Set Header    = If-Modified-Since: Mon, 1 Jan 2525 00:00:00 GMT
266 # Expect Header = SOME CHANGE
267 # Level = 17
268 # Set Header    = If-Modified-Since: Thu, 1 Jan 1970 02:00:00 GMT
269 # Expect Header = SOME CHANGE
270
271 {+hide-if-modified-since{-60} -crunch-if-none-match}
272 TAG:^hide-if-modified-since\{-60\}$
273
274 # Set Header    = If-Modified-Since: Gee, this date is invalid
275 # Expect Header = REMOVAL
276 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
277 # Expect Header = SOME CHANGE
278 # Set Header    = If-Modified-Since: Wed, 31 Dec 1969 23:59:59 GMT
279 # Expect Header = SOME CHANGE
280
281 {+hide-if-modified-since{+60} -crunch-if-none-match}
282 TAG:^hide-if-modified-since\{\+60\}$
283
284 # Set Header    = If-Modified-Since: Gee, this date is invalid
285 # Expect Header = REMOVAL
286 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
287 # Expect Header = SOME CHANGE
288
289 {+hide-if-modified-since{60} -crunch-if-none-match}
290 TAG:^hide-if-modified-since\{60\}$
291
292 # Set Header    = If-Modified-Since: Gee, this date is invalid
293 # Expect Header = REMOVAL
294 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
295 # Expect Header = NO CHANGE
296
297 {+hide-if-modified-since{+0} -crunch-if-none-match}
298 TAG:^hide-if-modified-since\{\+0\}$
299
300 # Set Header    = If-Modified-Since: Gee, this date is invalid
301 # Expect Header = REMOVAL
302 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
303 # Expect Header = NO CHANGE
304
305 {+hide-if-modified-since{-0} -crunch-if-none-match}
306 TAG:^hide-if-modified-since\{-0\}$
307
308 # Set Header    = If-Modified-Since: Gee, this date is invalid
309 # Expect Header = REMOVAL
310 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
311 # Expect Header = NO CHANGE
312
313 {+hide-if-modified-since{0} -crunch-if-none-match}
314 TAG:^hide-if-modified-since\{0\}$
315
316 # Set Header    = If-Modified-Since: Gee, this date is invalid
317 # Expect Header = REMOVAL
318 # Set Header    = If-Modified-Since: Thu, 04 Oct 2007 09:56:35 GMT
319 # Expect Header = NO CHANGE
320
321 {+hide-if-modified-since{NaN} -crunch-if-none-match}
322 TAG:^hide-if-modified-since\{NaN\}$
323
324
325 #######################################################
326 # Test crunch-outgoing-cookies
327 #######################################################
328
329 # Set Header    = If-Modified-Since: Gee, this date is invalid
330 # Expect Header = NO CHANGE
331 #
332 # Set Header    = Cookie: PREF=ID=6cf0abd34262:TM=117335617:LM=1617:S=jZypyJ7LPiwFi1_
333 # Expect Header = REMOVAL
334 {\
335  +crunch-outgoing-cookies \
336  -crunch-incoming-cookies \
337  -session-cookies-only    \
338  -hide-if-modified-since  \
339 }
340 TAG:^crunch-outgoing-cookies$
341
342 #######################################################
343 # Test session-cookies-only
344 #
345 # XXX: pretty useless as session-cookies-only doesn't
346 # affect client headers.
347 #######################################################
348
349 # Set Header    = Cookie: NSC_gffe-iuuq-mc-wtfswfs=8efb330d3660;expires=Thu, 04-Oct-07 19:11:34 GMT;path=/
350 # Expect Header = NO CHANGE
351 #
352 # Set Header    = Cookie: PREF=ID=6cf0abd34262:TM=117335617:LM=1617:S=jZypyJ7LPiwFi1_
353 # Expect Header = NO CHANGE
354 {\
355  -crunch-outgoing-cookies \
356  -crunch-incoming-cookies \
357  +session-cookies-only    \
358  -hide-if-modified-since  \
359 }
360 TAG:^session-cookies-only$
361
362 #######################################################
363 # Test change-x-forwarded-for
364 #######################################################
365
366 # Set Header    = X-Forwarded-For: 10.0.0.1
367 # Expect Header = NO CHANGE
368 {\
369  -change-x-forwarded-for \
370 }
371 TAG:^-change-x-forwarded-for$
372
373 # Set Header    = X-Forwarded-For: 10.0.0.1
374 # Expect Header = REMOVAL
375 {\
376  +change-x-forwarded-for{block} \
377 }
378 TAG:^change-x-forwarded-for\{block\}$
379
380 # Set Header    = X-Forwarded-For: 10.0.0.1
381 # Expect Header = SOME CHANGE
382 {\
383  +change-x-forwarded-for{add} \
384 }
385 TAG:^change-x-forwarded-for\{add\}$
386
387 #######################################################
388 # Test hide-from-header
389 #######################################################
390
391 # Set Header    = From: schneewitchen@example.org
392 # Expect Header = REMOVAL
393 {\
394  +hide-from-header{block}\
395 }
396 TAG:^hide-from-header\{block\}$
397
398 # Set Header    = From: schneewitchen@example.org
399 # Expect Header = From: siebenzwerge@example.org
400 {\
401  +hide-from-header{siebenzwerge@example.org}\
402 }
403 TAG:^hide-from-header\{siebenzwerge@example.org\}$
404
405 #######################################################
406 # Test prevent-compression
407 #######################################################
408
409 # Set Header    = Accept-Encoding: gzip, deflate
410 # Expect Header = REMOVAL
411 #
412 # Set Header    = Accept-Encoding: gzip
413 # Expect Header = REMOVAL
414 #
415 # Set Header    = Accept-Encoding: deflate
416 # Expect Header = REMOVAL
417 {\
418  +prevent-compression\
419 }
420 TAG:^prevent-compression$
421
422 #######################################################
423 # Test content filters which could cause problems with
424 # range requests.
425 #######################################################
426
427 # Set Header    = Range: bytes=1234-5678
428 # Expect Header = REMOVAL
429 # Set Header    = If-Range: bytes=1234-5678
430 # Expect Header = REMOVAL
431 # Set Header    = Request-Range: bytes=1234-5678
432 # Expect Header = REMOVAL
433 {\
434  -client-header-tagger{range-requests} \
435  +deanimate-gifs{last} \
436  -filter \
437 }
438 TAG:^deanimate-gifs\{last\}$
439
440 # Set Header    = Range: bytes=1234-5678
441 # Expect Header = REMOVAL
442 # Set Header    = If-Range: bytes=1234-5678
443 # Expect Header = REMOVAL
444 # Set Header    = Request-Range: bytes=1234-5678
445 # Expect Header = REMOVAL
446 {\
447  -client-header-tagger{range-requests} \
448  -deanimate-gifs \
449  +filter{banners-by-size} \
450 }
451 TAG:^filter\{banners-by-size\}$
452
453 # Set Header    = Range: bytes=1234-5678
454 # Expect Header = NO CHANGE
455 # Set Header    = If-Range: bytes=1234-5678
456 # Expect Header = NO CHANGE
457 # Set Header    = Request-Range: bytes=1234-5678
458 # Expect Header = NO CHANGE
459 {\
460  -client-header-tagger{range-requests} \
461  -deanimate-gifs \
462  -filter \
463 }
464 TAG:^no-content-filter$
465
466 # Set Header    = Connection: keep-alive
467 # Expect Header = NO CHANGE
468 # Level = 13
469 # Set Header    = Connection:
470 # Expect Header = REMOVAL
471 # Level = 13
472 {}
473 TAG:^Connection: keep-alive$
474
475 # Set Header    = Connection: keep-alive
476 # Expect Header = Connection: close
477 # Level = 14
478 # Set Header    = Connection:
479 # Expect Header = Connection: close
480 # Level = 14
481 {}
482 TAG:^Connection: close$
483
484 # Set Header    = Connection: close
485 # Expect Header = NO CHANGE
486 # Level = 15
487 {}
488 TAG:^connection-sharing disabled$
489
490 # Set Header    = Connection: close
491 # Expect Header = REMOVAL
492 # Level = 16
493 # Set Header    = Connection: keep-alive
494 # Expect Header = NO CHANGE
495 # Level = 16
496 {}
497 TAG:^connection-sharing enabled$
498
499 # XXX: Removing a header by not specifying a value is
500 # an inherited curl feature and could be viewed as a
501 # bug as far as Privoxy-Regression-Test is concerned.
502 #
503 # Set Header    = Host:
504 # Expect Header = Host: p.p
505 {}
506 TAG:^No Host header$
507
508 # Set Header    = Host: whatever.example.org
509 # Expect Header = NO CHANGE
510 {}
511 TAG:^Host header other than the target host$
512
513 # Set Header = Keep-Alive: 20
514 # Expect Header = NO CHANGE
515 # Level = 13
516 {}
517 TAG:^Pass Keep-Alive header$
518
519 # Set Header = Keep-Alive: 20
520 # Expect Header = REMOVAL
521 # Level = 14
522 {}
523 TAG:^Keep-Alive header removal$
524
525 # XXX: check the RFC to use a real value
526 # Set Header = proxy-connection: keep-alive
527 # Expect Header = REMOVAL
528 {}
529 TAG:^Proxy-Connection removal$
530
531 # Set Header = Proxy-Connection: keep-alive
532 # Expect Header = REMOVAL
533 {}
534 TAG:^Proxy-Connection removal$
535
536 # These are somewhat redundant when testing with
537 # GET requests, but I want to remember then when
538 # TRACE requests are supported.
539 #
540 # Set Header = Max-Forwards: 0
541 # Expect Header = NO CHANGE
542 # Set Header = Max-Forwards: 1
543 # Expect Header = NO CHANGE
544 # Set Header = Max-Forwards: -1
545 # Expect Header = NO CHANGE
546 # Set Header = Max-Forwards: 3
547 # Expect Header = NO CHANGE
548 {}
549 TAG:^Max-Forwards header without TRACE method$
550
551 ################################################################
552 #
553 # Fairly dumb tests for Privoxy CGI pages.
554 #
555 # These are mainly useful for checking for memory leaks
556 # with Valgrind or whether or not the user manual is installed
557 # correctly and are unlikely to actually detect any
558 #
559 # Note that if "Expect Status Code" is missing, 200 is implied.
560 #
561 ################################################################
562
563 # Fetch Test = http://p.p/
564 # Fetch Test = http://p.p/die
565 # Expect Status Code = 404
566 # Level = 18
567 # Fetch Test = http://p.p/die
568 # Expect Status Code = 200
569 # Level = 19
570 # Fetch Test = http://p.p/show-status
571 # Fetch Test = http://config.privoxy.org/show-status?file=actions&index=0
572 # Fetch Test = http://config.privoxy.org/show-status?file=filter&index=0
573 # XXX: for the invalid ones we probably shouldn't return status code 200.
574 # Fetch Test = http://config.privoxy.org/show-status?file=actions&index=100
575 # Fetch Test = http://config.privoxy.org/show-status?file=actions&index=NaN
576 # Fetch Test = http://config.privoxy.org/show-status?file=actions
577 # Fetch Test = http://config.privoxy.org/show-status?file=filter&index=100
578 # Fetch Test = http://config.privoxy.org/show-status?file=filter&index=NaN
579 # Fetch Test = http://config.privoxy.org/show-status?file=filter
580 # Fetch Test = http://config.privoxy.org/show-status?file=invalid
581 # Fetch Test = http://config.privoxy.org/show-status?file=trust
582 # Fetch Test = http://p.p/show-version
583 # Fetch Test = http://p.p/show-request
584 # Fetch Test = http://p.p/show-url-info
585 # Fetch Test = http://p.p/show-url-info?url=www.privoxy.org%2F
586 # Fetch Test = http://p.p/show-url-info?url=http:%2F%2Fwww.privoxy.org%2F
587 # Fetch Test = http://p.p/show-url-info?url=HTTp:%2F%2Fwww.privoxy.org%2F
588 # Fetch Test = http://p.p/show-url-info?url=https:%2F%2Fwww.privoxy.org%2F
589 # Fetch Test = http://p.p/show-url-info?url=HtTps:%2F%2Fwww.privoxy.org%2F
590 # Fetch Test = http://p.p/show-url-info?url=ftp:%2F%2Fwww.privoxy.org%2F
591 # Fetch Test = http://p.p/show-url-info?url=FTp:%2F%2Fwww.privoxy.org%2F
592 # Fetch Test = http://p.p/show-url-info?url=
593 # Fetch Test = http://p.p/show-url-info?url=%2F
594 # Fetch Test = http://p.p/toggle
595 # Fetch Test = http://p.p/edit-actions
596 # Fetch Test = http://p.p/eaa
597 # Fetch Test = http://p.p/eau
598 # Fetch Test = http://p.p/ear
599 # Fetch Test = http://p.p/eal
600 # Fetch Test = http://p.p/eafu
601 # Fetch Test = http://p.p/eas
602 # Fetch Test = http://p.p/easa
603 # Fetch Test = http://p.p/easr
604 # Fetch Test = http://p.p/eass
605 # Fetch Test = http://p.p/edit-actions-for-url
606 # Fetch Test = http://p.p/edit-actions-list
607 # Fetch Test = http://p.p/edit-actions-submit
608 # Fetch Test = http://p.p/edit-actions-url
609 # Fetch Test = http://p.p/edit-actions-url-form
610 # Fetch Test = http://p.p/edit-actions-add-url
611 # Fetch Test = http://p.p/edit-actions-add-url-form
612 # Fetch Test = http://p.p/edit-actions-remove-url
613 # Fetch Test = http://p.p/edit-actions-remove-url-form
614 # Fetch Test = http://p.p/edit-actions-section-add
615 # Fetch Test = http://p.p/edit-actions-section-remove
616 # Fetch Test = http://p.p/edit-actions-section-swap
617 # Fetch Test = http://p.p/error-favicon.ico
618 # Fetch Test = http://p.p/favicon.ico
619 # Fetch Test = http://p.p/robots.txt
620 # Fetch Test = http://p.p/send-banner
621 # Fetch Test = http://p.p/send-stylesheet
622 # Fetch Test = http://p.p/t
623 # Fetch Test = http://p.p/url-info-osd.xml
624
625 # Trusted CGI Request = http://p.p/edit-actions
626 # Expect Status Code = 302
627 # Level = 12 # Depends on the CGI editor being enabled
628 # Fetch Test = http://p.p/does-not-exist
629 # Expect Status Code = 404
630 # Trusted CGI Request = http://p.p/eaa
631 # Trusted CGI Request = http://p.p/eau
632 # Trusted CGI Request = http://p.p/ear
633 # Trusted CGI Request = http://p.p/eal
634 # Trusted CGI Request = http://p.p/eafu
635 # Trusted CGI Request = http://p.p/eas
636 # Trusted CGI Request = http://p.p/easa
637 # Trusted CGI Request = http://p.p/easr
638 # Trusted CGI Request = http://p.p/eass
639 # Trusted CGI Request = http://p.p/edit-actions-for-url
640 # Trusted CGI Request = http://p.p/edit-actions-list
641 # Trusted CGI Request = http://p.p/edit-actions-submit
642 # Trusted CGI Request = http://p.p/edit-actions-url
643 # Trusted CGI Request = http://p.p/edit-actions-url-form
644 # Trusted CGI Request = http://p.p/edit-actions-add-url
645 # Trusted CGI Request = http://p.p/edit-actions-add-url-form
646 # Trusted CGI Request = http://p.p/edit-actions-remove-url
647 # Trusted CGI Request = http://p.p/edit-actions-remove-url-form
648 # Trusted CGI Request = http://p.p/edit-actions-section-add
649 # Trusted CGI Request = http://p.p/edit-actions-section-remove
650 # Trusted CGI Request = http://p.p/edit-actions-section-swap
651 # Trusted CGI Request = http://p.p/send-stylesheet
652
653 # The following tests depend on Privoxy being configured to deliver the user manual
654
655 # Fetch Test = http://p.p/user-manual
656 # Expect Status Code = 302
657 # Level = 9
658 # Fetch Test = http://p.p/user-manual/
659 # Level = 9
660 # Fetch Test = http://p.p/user-manual/actions-file.html
661 # Level = 9
662 # Fetch Test = http://p.p/user-manual/appendix.html
663 # Level = 9
664 # Fetch Test = http://p.p/user-manual/config.html
665 # Level = 9
666 # Fetch Test = http://p.p/user-manual/configuration.html
667 # Level = 9
668 # Fetch Test = http://p.p/user-manual/contact.html
669 # Level = 9
670 # Fetch Test = http://p.p/user-manual/copyright.html
671 # Level = 9
672 # Fetch Test = http://p.p/user-manual/files-in-use.jpg
673 # Level = 9
674 # Fetch Test = http://p.p/user-manual/filter-file.html
675 # Level = 9
676 # Fetch Test = http://p.p/user-manual/index.html
677 # Level = 9
678 # Fetch Test = http://p.p/user-manual/installation.html
679 # Level = 9
680 # Fetch Test = http://p.p/user-manual/introduction.html
681 # Level = 9
682 # Fetch Test = http://p.p/user-manual/p_doc.css
683 # Level = 9
684 # Fetch Test = http://p.p/user-manual/proxy2.jpg
685 # Level = 9
686 # Fetch Test = http://p.p/user-manual/proxy_setup.jpg
687 # Level = 9
688 # Fetch Test = http://p.p/user-manual/quickstart.html
689 # Level = 9
690 # Fetch Test = http://p.p/user-manual/seealso.html
691 # Level = 9
692 # Fetch Test = http://p.p/user-manual/startup.html
693 # Level = 9
694 # Fetch Test = http://p.p/user-manual/templates.html
695 # Level = 9
696 # Fetch Test = http://p.p/user-manual/whatsnew.html
697 # Level = 9
698
699
700 # Method Test = OPTIONS
701 # Method Test = GET
702 # Method Test = get
703 # Method Test = gEt
704 # Method Test = HEAD
705 # Method Test = POST
706 # Method Test = PUT
707 # Method Test = DELETE
708 # Method Test = OPTIONS
709 # Method Test = TRACE
710 # Method Test = CONNECT
711 # Method Test = PROPFIND
712 # Method Test = PROPPATCH
713 # Method Test = MOVE
714 # Method Test = COPY
715 # Method Test = MKCOL
716 # Method Test = LOCK
717 # Method Test = UNLOCK
718 # Method Test = BCOPY
719 # Method Test = BMOVE
720 # Method Test = BDELETE
721 # Method Test = BPROPFIND
722 # Method Test = BPROPPATCH
723 # Method Test = SUBSCRIBE
724 # Method Test = UNSUBSCRIBE
725 # Method Test = NOTIFY
726 # Method Test = POLL
727 # Method Test = VERSION-CONTROL
728 # Method Test = REPORT
729 # Method Test = CHECKOUT
730 # Method Test = CHECKIN
731 # Method Test = UNCHECKOUT
732 # Method Test = MKWORKSPACE
733 # Method Test = UPDATE
734 # Method Test = LABEL
735 # Method Test = MERGE
736 # Method Test = BASELINE-CONTROL
737 # Method Test = MKACTIVITY
738 # Method Test = PRIVOXY-REGRESSION-TEST-IN-THE-HOUSE
739 # Expect Status Code = 400
740
741 {+block{Forbidden Port. You are not supposed to see this.}}
742 config.privoxy.org:1-/
743 p.p:1-/
744
745 {-block}
746 config.privoxy.org:3,79-81/
747 p.p:3,22,79-81/
748
749 # Fetch Test = http://oh-dear-this-hostname-is-so-very-long-that-it-can-not-possibly-be-forwarded-through-socks5-as-a-result-we-therefore-expect-privoxy-to-return-an-error-response-instead-of-forwarding-the-request-because-as-already-mentioned-this-host-is-really-very-long.example
750 # Expect Status Code = 503
751 {+forward-override{forward-socks5 127.0.0.1:12345 .}}
752 oh-dear-this-hostname-is-so-very-long-that-it-can-not-possibly-be-forwarded-through-socks5-as-a-result-we-therefore-expect-privoxy-to-return-an-error-response-instead-of-forwarding-the-request-because-as-already-mentioned-this-host-is-really-very-long.example/
753
754 # Fetch Test = http://oh-dear-this-hostname-is-short-enough-but-there-is-no-socks-server-listening.example
755 # Expect Status Code = 503
756 {+forward-override{forward-socks5 127.0.0.1:12345 .}}
757 oh-dear-this-hostname-is-short-enough-but-there-is-no-socks-server-listening.example
758
759 # This one currently triggers the same error condition as the
760 # test above (socks5 server unreachable), but once Privoxy
761 # starts to properly reject invalid ports it should become useful.
762
763 # Fetch Test = http://invalid-forward5-gateway-port.example
764 # Expect Status Code = 503
765 {+forward-override{forward-socks5 127.0.0.1:-1 127.0.0.1:12345}}
766 invalid-forward5-gateway-port.example
767
768 # Fetch Test = http://forward5-null-gateway-host.example
769 # Expect Status Code = 503
770 {+forward-override{forward-socks5 :12345 127.0.0.1:12345}}
771 forward5-null-gateway-host.example
772
773 # Fetch Test = http://www.forbidden-connect.example:444/
774 # Method = CONNECT
775 # Expect Status Code = 403
776 {+limit-connect{443}}
777 www.forbidden-connect.example/
778
779 # Fetch Test = http://www.blocked-request.example/blocked-request
780 # Expect Status Code = 403
781 {+block{This request failed to make it to the target destination which means the test succeeded.}}
782 www.blocked-request.example/blocked-request
783
784 # Fetch Test = http://www.blocked-request.example/blocked-request-with-no-reason-specified
785 # Expect Status Code = 403
786 {+block}
787 www.blocked-request.example/blocked-request-with-no-reason-specified
788
789 # Some domain pattern tests
790 #
791 {+block{domain pattern test}}
792 # Blocked URL = http://domain-pattern-test.example/
793 # Blocked URL = http://domain-pattern-test.example.org/
794 domain-pattern-test.example.
795
796 {+block{Hostname patterns without trailing dots cover hostnames with trailing dots as well.}}
797 # Blocked URL = http://trailing-dot.example.org./
798 # Blocked URL = http://trailing-dot.example.org./foo
799 trailing-dot.example.org
800
801 # Just in case there is no white-space fuzzer in the house ...
802 #
803 # Set Header = X-LWS-Test: no superfluous white space here
804 # Expect Header = NO CHANGE
805 # Set Header = X-LWS-Test:  superfluous   white space  in  the   house
806 # Expect Header = X-LWS-Test: superfluous white space in the house
807 # Set Header = X-LWS-Test   :  superfluous   white   space   in   the    house
808 # Expect Header = X-LWS-Test: superfluous white space in the house
809 # Set Header = X-LWS-Test:  :superfluous white space in the house
810 # Expect Header = X-LWS-Test: :superfluous white space in the house
811 # Set Header = X-LWS-Test: :no superfluous white space here
812 # Expect Header = NO CHANGE
813 # Set Header = X-LWS-Test:      superfluous             white                   tabs in the house
814 # Expect Header = X-LWS-Test: superfluous white tabs in the house
815 # Set Header = X-LWS-Test       :       superfluous             white                   tabs in the house
816 # Expect Header = X-LWS-Test: superfluous white tabs in the house
817 # Set Header = X-LWS-Test: "leave  quoted  lws alone"
818 # Expect Header = X-LWS-Test: "leave  quoted  lws alone"
819 # Set Header = X-LWS-Test:  "leave  quoted  lws alone"  thxbye
820 # Expect Header = X-LWS-Test: "leave  quoted  lws alone" thxbye
821 # Set Header = X-LWS-Test: " Do I Look like     quoted  text? Me    thinks  not.
822 # Expect Header = X-LWS-Test: " Do I Look like quoted text? Me thinks not.
823 # Set Header = X-LWS-Test: "This  is  quoted" this  is  not "but   this  is  again"
824 # Expect Header = X-LWS-Test: "This  is  quoted" this is not "but   this  is  again"
825 # Set Header = X-LWS-Test:  "This  is  quoted" this   is  not "this  is  "  but  "  this again   is  not
826 # Expect Header = X-LWS-Test: "This  is  quoted" this is not "this  is  " but " this again is not
827 {}
828 TAG:^LWS Tests$