Bug#601033: apache2.2-common: AddOutputFilterByType is deprecated but used in deflate.conf
Package: apache2.2-common
Version: 2.2.16-3
Severity: normal
AddOutputFilterByType is deprecated, however it is used in the Debian
package in mods-available/deflate.conf.
http://httpd.apache.org/docs/2.2/mod/core.html#addoutputfilterbytype
I had a problem in a reverse proxy configuration that I believe is
caused by this. I found a bunch of similar reports, eg:
https://issues.apache.org/bugzilla/show_bug.cgi?id=31226
https://issues.apache.org/bugzilla/show_bug.cgi?id=14335
The response is always to stop using AddOutputFilterByType and use
mod_filter instead. What is funny is that the above reports that
AddOutputFilterByType was being ignored in reverse proxied requests. It
seems that that problem has been fixed. What I am seeing is that
AddOutputFilterByType is triggering for all mime types, even though the
config line is reduced to
AddOutputFilterByType DEFLATE text/plain
Eg, I request a file of type application/zip through the reverse proxy,
and the proxy adds a Content-Encoding: gzip. I have verified that the
origin site did not use a Content-Encoding. Commenting out the
AddOutputFilterByType caused the Content-Encoding: gzip not to be added.
It gets weirder: if I change text/plain to text/html, the encoding is
not added. It seems that AddOutputFilterByType catches proxied requests
if text/plain appears in its list of mime types, as if all proxied
requests were considered text/plain.
This caused me greate pain because Internet Explorer mis-handles
application/zip downloads with Content-Encoding: gzip:
http://support.microsoft.com/kb/2002350
I don't have much time to continue debugging this. My plan is to turn
off mod_deflate for now, and investigate mod_filter shortly. But I
think my experience implies that mod_deflate should not be configured
this way by default. It doesn't work reliably enough, and the fallout
when it breaks is obscure, hard to diagnose corruption.
Andrew
-- Package-specific info:
List of enabled modules from 'apache2 -M':
alias auth_basic authn_file authz_default authz_groupfile
authz_host authz_user autoindex cgi dir env mime negotiation perl
reqtimeout setenvif status userdir
-- System Information:
Debian Release: squeeze/sid
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: i386 (i686)
Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages apache2.2-common depends on:
ii apache2-utils 2.2.16-3 utility programs for webservers
ii apache2.2-bin 2.2.16-3 Apache HTTP Server common binary f
ii libmagic1 5.04-5 File type determination library us
ii lsb-base 3.2-26 Linux Standard Base 3.2 init scrip
ii mime-support 3.48-1 MIME files 'mime.types' & 'mailcap
ii perl 5.10.1-15 Larry Wall's Practical Extraction
ii procps 1:3.2.8-9 /proc file system utilities
Versions of packages apache2.2-common recommends:
ii ssl-cert 1.0.27 simple debconf wrapper for OpenSSL
Versions of packages apache2.2-common suggests:
pn apache2-doc <none> (no description available)
pn apache2-suexec | apache2-su <none> (no description available)
ii iceweasel [www-browser] 3.5.13-1 Web browser based on Firefox
ii lynx-cur [www-browser] 2.8.8dev.5-1 Text-mode WWW Browser with NLS sup
ii w3m [www-browser] 0.5.2-9 WWW browsable pager with excellent
Versions of packages apache2.2-common is related to:
pn apache2-mpm-event <none> (no description available)
pn apache2-mpm-itk <none> (no description available)
ii apache2-mpm-prefork 2.2.16-3 Apache HTTP Server - traditional n
pn apache2-mpm-worker <none> (no description available)
-- no debconf information
Reply to: