Bug #18095 Updated: browser cant read zlib compressed output
| From: | sr@php.net | Date: | Tue, 02 Jul 2002 17:43:43 +0000 |
| Subject: | Bug #18095 Updated: browser cant read zlib compressed output | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-12837@lists.php.net to get a copy of this message | ||
ID: 18095
Updated by: sr@php.net
Reported By: bugzilla@cm51-210.liwest.at
-Status: Open
+Status: Feedback
Bug Type: Zlib Related
Operating System: Linux 2.4.18
PHP Version: 4.0CVS-2002-07-01
New Comment:
It seems that there are two issues:
1.) Why isn't zlib.output_compression = Off active?
How do you set this? Via Apache-Config or php.ini? ini_set doesn't work
for this option, please try setting it in php.ini, maybe there are some
things wrong with the Apache2 config handling.
2.) Why does the Content-Encoding-Header vanish if chunked transfer
encoding is used by Apache? Maybe this is an Apache 2 issue, too. Is it
possible that you try this with Apache 1.3.26 so that we can localize
this bug (if it's an Apache 2 thing or a general zlib bug)?
Thank you!
Previous Comments:
------------------------------------------------------------------------
[2002-07-02 05:24:18] bugzilla@cm51-210.liwest.at
looks like
Content-Encoding: gzip
is missing for some pages (?)
------------------------------------------------------------------------
[2002-07-02 05:20:03] bugzilla@cm51-210.liwest.at
did a little debugging with socat:
request:
> GET /wiki/index.php?pagename=RecentChanges HTTP/1.1\r
> Host: cm51-210.liwest.at:91\r
> User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.1a+)
Gecko/20020624\r
> Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,video/x-mng,image/png,image/jpeg,image/gif;q=0.2,text
/css,*/*;q=0.1\r
> Accept-Language: en-us, en;q=0.50\r
> Accept-Encoding: gzip, deflate, compress;q=0.9\r
> Accept-Charset: ISO-8859-1, utf-8;q=0.66, *;q=0.66\r
> Keep-Alive: 300\r
> Connection: keep-alive\r
response:
< HTTP/1.1 200 OK\r
< Date: Tue, 02 Jul 2002 11:13:10 GMT\r
< Server: Apache/2.0.40-dev (Unix) mod_ssl/2.0.40-dev OpenSSL/0.9.6b
PHP/4.3.0-dev\r
< Accept-Ranges: bytes\r
< X-Powered-By: PHP/4.3.0-dev\r
< Set-Cookie: PHPSESSID=974cec260ca6ac776ff114bf0a1e2f08; path=/\r
< Set-Cookie:
WIKI_PREFS2=O%3A15%3A%22userpreferences%22%3A1%3A%7Bs%3A6%3A%22_prefs%22%3Ba%3A0%3A%7B%7D%7D;
expires=Wed, 02-Jul-03 11:13:10 GMT
; path=/\r
< Last-Modified: Sat, 29 Jun 2002 10:19:44 +0000\r
< Transfer-Encoding: chunked\r
< Content-Type: text/html; charset=iso-8859-1\r
< \r
< 3661\r
< ..\b........@6..<?xml version="1.0" encoding="iso-8859-1"?>
< <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
< "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
< <html xmlns="http://www.w3.org/1999/xhtml">
< <head>
for other pages i get
< HTTP/1.1 200 OK\r
< Date: Tue, 02 Jul 2002 11:16:39 GMT\r
< Server: Apache/2.0.40-dev (Unix) mod_ssl/2.0.40-dev OpenSSL/0.9.6b
PHP/4.3.0-dev\r
< Accept-Ranges: bytes\r
< X-Powered-By: PHP/4.3.0-dev\r
< Set-Cookie:
WIKI_PREFS2=O%3A15%3A%22userpreferences%22%3A1%3A%7Bs%3A6%3A%22_prefs%22%3Ba%3A0%3A%7B%7D%7D;
expires=Wed, 02-Jul-03 11:16:39 GMT
; path=/\r
< Content-Encoding: gzip\r
< Vary: Accept-Encoding\r
< Content-Length: 12914\r
< Content-Type: text/html; charset=iso-8859-1\r
< \r
< ..\b........Q2..<?xml version="1.0" encoding="iso-8859-1"?>
< <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
< "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
< <html xmlns="http://www.w3.org/1999/xhtml">
< <head>
Transfer-Encoding / Content-Encoding ????
------------------------------------------------------------------------
[2002-07-02 04:24:13] bugzilla@cm51-210.liwest.at
zlib.output_compression Off
zlib.output_compression_level 0
(http://cm51-210.liwest.at/info/) -> faulty gzheader is generated
setting output compression to "0" & restarting ->
in phpinfo, output compression stays "off",
gzheader is generated again :-(
i dont think that the correct content encoding header is generated ...
trying to test that via netcat
------------------------------------------------------------------------
[2002-07-01 16:33:24] sr@php.net
If you use 0 as zlib.ouput_compression_level, the output isn't
compressed, but the gzip/deflate headers are added to the output (and
the corresponding Content-Encoding header).
Can you check with a phpinfo()-page that zlib.output_compression really
is set to "off" (otherwise try setting it to "0")?
I can't reproduce the binary display with your example URL, it works
with Mozilla 1.0 and lynx, if I make the HTTP by hand, it displays the
correct headers.
------------------------------------------------------------------------
[2002-07-01 15:20:23] bugzilla@cm51-210.liwest.at
i think the compressed data is the gzlib "dont compress, store only"
header.
browser is mozilla 1.1 cvs
doesnt work with ie 6.0 either
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/18095
--
Edit this bug report at http://bugs.php.net/?id=18095&edit=1