From: Fabian Keil Date: Thu, 28 Jan 2021 13:56:59 +0000 (+0100) Subject: Add test scenario gzip compression X-Git-Url: http://www.privoxy.org/gitweb/show-status?p=privoxy.git;a=commitdiff_plain;h=515869172fe9e95ffcc6b46f327210e147028938 Add test scenario gzip compression Sponsored by: Privoxy project funds collected at SPI --- diff --git a/tests/cts/gzip-compression/data/test1 b/tests/cts/gzip-compression/data/test1 new file mode 100644 index 00000000..52325dfe --- /dev/null +++ b/tests/cts/gzip-compression/data/test1 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. Valid gzip data. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test10 b/tests/cts/gzip-compression/data/test10 new file mode 100644 index 00000000..2fefead0 --- /dev/null +++ b/tests/cts/gzip-compression/data/test10 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%01%00%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. Skipping 1 bytes for gzip compression. Does this sound right? + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test11 b/tests/cts/gzip-compression/data/test11 new file mode 100644 index 00000000..a9564745 --- /dev/null +++ b/tests/cts/gzip-compression/data/test11 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%FF%00%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%FF%00%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. gzip extra fields. Unreasonable amount of bytes to skip (-1). Stopping decompression + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test12 b/tests/cts/gzip-compression/data/test12 new file mode 100644 index 00000000..d621a117 --- /dev/null +++ b/tests/cts/gzip-compression/data/test12 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%00%01]hex%%repeat[256 x A]%hex[%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%00%01]hex%%repeat[256 x A]%hex[%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. gzip extra fields. Unexpected error while decompressing to the buffer (iob): invalid distance too far back + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test13 b/tests/cts/gzip-compression/data/test13 new file mode 100644 index 00000000..87f5a0af --- /dev/null +++ b/tests/cts/gzip-compression/data/test13 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%00%01]hex%%repeat[256 x A]%hex[%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. Skipping 256 bytes for gzip compression. Does this sound right? + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test14 b/tests/cts/gzip-compression/data/test14 new file mode 100644 index 00000000..1080abde --- /dev/null +++ b/tests/cts/gzip-compression/data/test14 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%00%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. Skipping 0 bytes for gzip compression. Does this sound right? + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test15 b/tests/cts/gzip-compression/data/test15 new file mode 100644 index 00000000..12d3042f --- /dev/null +++ b/tests/cts/gzip-compression/data/test15 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%18%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00]hex%This is a comment to skip%hex[%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. Comment to skip. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test16 b/tests/cts/gzip-compression/data/test16 new file mode 100644 index 00000000..25a4a039 --- /dev/null +++ b/tests/cts/gzip-compression/data/test16 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%18%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00]hex%%repeat[1000 x This is a long comment to skip]%hex[%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. Long comment to skip. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test17 b/tests/cts/gzip-compression/data/test17 new file mode 100644 index 00000000..b25b44b8 --- /dev/null +++ b/tests/cts/gzip-compression/data/test17 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%a2%c1%12%60%00%03%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. No filename to skip. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test18 b/tests/cts/gzip-compression/data/test18 new file mode 100644 index 00000000..59683592 --- /dev/null +++ b/tests/cts/gzip-compression/data/test18 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%02%a2%c1%12%60%00%FF%FF%03%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. gzip extra fields. Checksum to skip. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test19 b/tests/cts/gzip-compression/data/test19 new file mode 100644 index 00000000..0a8c8aba --- /dev/null +++ b/tests/cts/gzip-compression/data/test19 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%02%a2%c1%12%60%00%FF]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%02%a2%c1%12%60%00%FF]hex% + + + + + +http + + +gzip-encoded content. gzip extra fields. Checksum to skip. Insufficient data left. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test2 b/tests/cts/gzip-compression/data/test2 new file mode 100644 index 00000000..8ebb10e4 --- /dev/null +++ b/tests/cts/gzip-compression/data/test2 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%08%a2%c1%12%60%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%08%a2%c1%12%60%00]hex% + + + + + +http + + +gzip-encoded content. Malformed gzip header. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test20 b/tests/cts/gzip-compression/data/test20 new file mode 100644 index 00000000..7fcd00ab --- /dev/null +++ b/tests/cts/gzip-compression/data/test20 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%00%00%00%00%02%03%ed%c4%31%0d%00%00%08%03%b0%1f%97%4b%26%01%ff%c1%05%57%7b%b4%d9%4c%25%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%a4%9f%0e%80%af%70%a8%40%ec%00%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%00%00%00%00%02%03%ed%c4%31%0d%00%00%08%03%b0%1f%97%4b%26%01%ff%c1%05%57%7b%b4%d9%4c%25%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%a4%9f%0e%80%af%70%a8%40%ec%00%00]hex% + + + + + +http + + +gzip-encoded content. Buffer limit reached while decompressing iob. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test21 b/tests/cts/gzip-compression/data/test21 new file mode 100644 index 00000000..255d54e0 --- /dev/null +++ b/tests/cts/gzip-compression/data/test21 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%00%00%00%00%02%03%ed%c4%31%0d%00%00%08%03%b0%1f%97%4b%26%01%ff%c1%05%57%7b%b4%d9%4c%25%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%a4%9f%0e%80%af%70%a8%40%ec%00%00]hex%%repeat[10000 x padding data]% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%00%00%00%00%02%03%ed%c4%31%0d%00%00%08%03%b0%1f%97%4b%26%01%ff%c1%05%57%7b%b4%d9%4c%25%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%24%49%92%a4%9f%0e%80%af%70%a8%40%ec%00%00]hex%%repeat[10000 x padding data]% + + + + + +http + + +gzip-encoded content. Buffer limit reached while extending the buffer (iob). + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test22 b/tests/cts/gzip-compression/data/test22 new file mode 100644 index 00000000..d3c41bcf --- /dev/null +++ b/tests/cts/gzip-compression/data/test22 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +deflate compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: deflate +X-Control: swsclose + +%hex[%0b%ce%cf%4d%55%48%49%4d%cb%49%2c%49%55%48%cd%4b%ce%4f%49%4d%51%48%49%2c%49%d4%e3%f2%4b%2d%57%c8%c9%cc%4b%55%c8%48%2d%4a%d5%e3%02%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 42 + +Some deflate encoded data. +New line here. + + + + + +http + + +deflate-encoded content. Valid. + + +proxy + + +-H "Accept-Encoding: deflate" http://%HOSTIP:%HTTPPORT/deflate-compressed-data/%TESTNUMBER + + + + + +GET /deflate-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: deflate + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test23 b/tests/cts/gzip-compression/data/test23 new file mode 100644 index 00000000..07b5bf24 --- /dev/null +++ b/tests/cts/gzip-compression/data/test23 @@ -0,0 +1,71 @@ + + + +HTTP +HTTP GET +deflate compression +skip + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: deflate +X-Control: swsclose + +%hex[%0b%ce%cf%4d%55%48%49%4d%cb%49%2c%49%55%48%cd%4b%ce%4f%49%4d%]hex% +Bogus data blafasel + + + +# The actual reply does not contain a line break after the trailing NUL byte +# but we can't currently express this as the tag has to be on its +# own line. + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: deflate +X-Control: swsclose + +%hex[%0b%ce%cf%4d%55%48%49%4d%cb%49%2c%49%55%48%cd%4b%ce%4f%49%4d%]hex% +Bogus data blafasel +%hex[%00]hex% + + + + + +http + + +deflate-encoded content. Corrupted data. + + +proxy + + +-H "Accept-Encoding: deflate" http://%HOSTIP:%HTTPPORT/deflate-compressed-data/%TESTNUMBER + + + + + +GET /deflate-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: deflate + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test24 b/tests/cts/gzip-compression/data/test24 new file mode 100644 index 00000000..94eae477 --- /dev/null +++ b/tests/cts/gzip-compression/data/test24 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%00%FF%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%00%00%FF%00%0A%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00]hex% + + + + + +http + + +gzip-encoded content. gzip extra fields with skip bytes that would be negative when not being casted. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test25 b/tests/cts/gzip-compression/data/test25 new file mode 100644 index 00000000..520d69e8 --- /dev/null +++ b/tests/cts/gzip-compression/data/test25 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00]hex% + + + + + +http + + +gzip-encoded content. gzip extra fields with not enough data. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test26 b/tests/cts/gzip-compression/data/test26 new file mode 100644 index 00000000..62621cc0 --- /dev/null +++ b/tests/cts/gzip-compression/data/test26 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%1A%a2%c1%12%60%FF%03%62%6c%61%66%61%73%65%6c%FF%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%FF%62%37%9b%0c%24%FF%FF%FF%FF]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%1A%a2%c1%12%60%FF%03%62%6c%61%66%61%73%65%6c%FF%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%FF%62%37%9b%0c%24%FF%FF%FF%FF]hex% + + + + + +http + + +gzip-encoded content. Unterminated file name and comment. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test27 b/tests/cts/gzip-compression/data/test27 new file mode 100644 index 00000000..52e22f57 --- /dev/null +++ b/tests/cts/gzip-compression/data/test27 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%1A%a2%c1%12%60%FF%03%62%6c%61%66%61%73%65%6c%FF%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%FF%62%37%9b%0c%24%FF%FF%FF%FF]hex%%repeat[302 x A]% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%1A%a2%c1%12%60%FF%03%62%6c%61%66%61%73%65%6c%FF%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%FF%62%37%9b%0c%24%FF%FF%FF%FF]hex%%repeat[302 x A]% + + + + + +http + + +gzip-encoded content. Unterminated file name and comment, padding data to fill iob. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test28 b/tests/cts/gzip-compression/data/test28 new file mode 100644 index 00000000..106b0e21 --- /dev/null +++ b/tests/cts/gzip-compression/data/test28 @@ -0,0 +1,63 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%00%00%00%00%00%03%03%00%00%00%00%00%00%00%00%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 0 + + + + + + +http + + +gzip-encoded content. Valid gzip data, no compressed content + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test3 b/tests/cts/gzip-compression/data/test3 new file mode 100644 index 00000000..020fa63f --- /dev/null +++ b/tests/cts/gzip-compression/data/test3 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%08%a2%c1%12%60]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%08%a2%c1%12%60]hex% + + + + + +http + + +gzip-encoded content. Insufficient data to start decompression. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test4 b/tests/cts/gzip-compression/data/test4 new file mode 100644 index 00000000..fab585f9 --- /dev/null +++ b/tests/cts/gzip-compression/data/test4 @@ -0,0 +1,65 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%00%00%00%00%00%00%03%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +X-Control: swsclose +Content-Length: 36 + +Blafasel die da +Some more data here + + + + + +http + + +gzip-encoded content. Valid gzip data. No embedded file name. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test5 b/tests/cts/gzip-compression/data/test5 new file mode 100644 index 00000000..c5e9944b --- /dev/null +++ b/tests/cts/gzip-compression/data/test5 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1G%8b%08%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1G%8b%08%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. Invalid gzip header when decompressing 1. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test6 b/tests/cts/gzip-compression/data/test6 new file mode 100644 index 00000000..45a80c47 --- /dev/null +++ b/tests/cts/gzip-compression/data/test6 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8c%08%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8c%08%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. Invalid gzip header when decompressing 2. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test7 b/tests/cts/gzip-compression/data/test7 new file mode 100644 index 00000000..b5488097 --- /dev/null +++ b/tests/cts/gzip-compression/data/test7 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%FF%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%FF%08%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. Invalid gzip header when decompressing 3. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test8 b/tests/cts/gzip-compression/data/test8 new file mode 100644 index 00000000..568dc753 --- /dev/null +++ b/tests/cts/gzip-compression/data/test8 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%e8%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%e8%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. Invalid gzip header flags. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/data/test9 b/tests/cts/gzip-compression/data/test9 new file mode 100644 index 00000000..31f35b04 --- /dev/null +++ b/tests/cts/gzip-compression/data/test9 @@ -0,0 +1,64 @@ + + + +HTTP +HTTP GET +gzip compression + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +HTTP/1.1 200 OK +Date: Thu, 22 Jul 2010 11:22:33 GMT +Connection: close +Content-Type: text/html +Content-Encoding: gzip +X-Control: swsclose + +%hex[%1f%8b%08%0C%a2%c1%12%60%00%03%62%6c%61%66%61%73%65%6c%00%73%ca%49%4c%4b%2c%4e%cd%51%48%c9%4c%55%48%49%e4%0a%ce%cf%4d%55%c8%cd%2f%02%71%4a%12%15%32%52%8b%52%b9%00%62%37%9b%0c%24%00%00%00%0a]hex% + + + + + +http + + +gzip-encoded content. gzip extra fields. Unreasonable amount of bytes to skip. + + +proxy + + +-H "Accept-Encoding: gzip" http://%HOSTIP:%HTTPPORT/gzip-compressed-data/%TESTNUMBER + + + + + +GET /gzip-compressed-data/%TESTNUMBER HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +User-Agent: curl/%VERSION +Accept: */* +Accept-Encoding: gzip + + + +0 + + + diff --git a/tests/cts/gzip-compression/gzip-compression.action b/tests/cts/gzip-compression/gzip-compression.action new file mode 100644 index 00000000..0928e192 --- /dev/null +++ b/tests/cts/gzip-compression/gzip-compression.action @@ -0,0 +1,3 @@ +# Enable a filter so Privoxy decompresses the content +{+filter{img-reorder}} +/ diff --git a/tests/cts/gzip-compression/privoxy.conf b/tests/cts/gzip-compression/privoxy.conf new file mode 100644 index 00000000..ba95f952 --- /dev/null +++ b/tests/cts/gzip-compression/privoxy.conf @@ -0,0 +1,20 @@ +listen-address 127.0.0.1:9119 + +debug 1 # Log the destination for each request Privoxy let through. See also debug 1024. +debug 2 # show each connection status +debug 4 # show tagging-related messages +debug 8 # show header parsing +debug 32 # debug force feature +debug 64 # debug regular expression filters +debug 128 # debug redirects +debug 256 # debug GIF de-animation +debug 512 # Common Log Format +debug 1024 # Log the destination for requests Privoxy didn't let through, and the reason why. +debug 4096 # Startup banner and warnings. +debug 8192 # Non-fatal errors + +filterfile ../../../default.filter +actionsfile ./gzip-compression.action + +# Reduce buffer limit so we reach it sooner +buffer-limit 30