Bug 1469424 - gzip compression broken in UniFi (built-in tomcat)
gzip compression broken in UniFi (built-in tomcat)
Status: ASSIGNED
Product: Fedora
Classification: Fedora
Component: zlib (Show other bugs)
27
Unspecified Unspecified
unspecified Severity high
: ---
: ---
Assigned To: Pavel Raiskup
Fedora Extras Quality Assurance
: Patch
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2017-07-11 04:57 EDT by Jens Timmerman
Modified: 2018-06-01 06:32 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Permit a deflateParams() parameter change as soon as possible. (2.87 KB, application/mbox)
2017-07-11 04:57 EDT, Jens Timmerman
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
Launchpad 1692870 None None None 2017-07-11 04:57 EDT

  None (edit)
Description Jens Timmerman 2017-07-11 04:57:20 EDT
Created attachment 1296136 [details]
Permit a deflateParams() parameter change as soon as possible.

Description of problem:
zlib 1.2.11 introduces a bug which breaks compression in some applications

Version-Release number of selected component (if applicable):
1.2.11

How reproducible:
every time

Steps to Reproduce:
1. install and run unifi (https://www.ubnt.com/download/unifi 

Actual results:
2. # curl -vvvv --compress localhost:8880/guest/s/default/
* Trying ::1...
* TCP_NODELAY set
* Connected to localhost (::1) port 8880 (#0)
> GET /guest/s/default/ HTTP/1.1
> Host: localhost:8880
> User-Agent: curl/7.52.1
> Accept: */*
> Accept-Encoding: deflate, gzip
>
< HTTP/1.1 200 OK
< Server: Apache-Coyote/1.1
< Content-Type: text/html;charset=utf-8
< Transfer-Encoding: chunked
< Content-Encoding: gzip
< Vary: Accept-Encoding
< Date: Tue, 23 May 2017 11:19:22 GMT
<
* Error while processing content unencoding: invalid code lengths set
* Failed writing data
* Curl_http_done: called premature == 1
* Closing connection 0
curl: (23) Error while processing content unencoding: invalid code lengths set


Expected results:
2. # curl -vvvv --compress localhost:8880/guest/s/default/
* Trying ::1...
* TCP_NODELAY set
* Connected to localhost (::1) port 8880 (#0)
> GET /guest/s/default/ HTTP/1.1
> Host: localhost:8880
> User-Agent: curl/7.52.1
> Accept: */*
> Accept-Encoding: deflate, gzip
>
< HTTP/1.1 200 OK
< Server: Apache-Coyote/1.1
< Content-Type: text/html;charset=utf-8
< Transfer-Encoding: chunked
< Content-Encoding: gzip
< Vary: Accept-Encoding
< Date: Tue, 23 May 2017 11:19:22 GMT
<
<!DOCTYPE html>
<html document>

Additional info:
works when turning off compression in curl (but browsers don't do that by default, as such the page is broken on most browsers)


This was fixed in https://github.com/madler/zlib/commit/f9694097dd69354b03cb8af959094c7f260db0a1
I can confirm the fix works after rebuilding the with attached patch in place.
Comment 1 Siddhesh Poyarekar 2018-01-08 13:02:35 EST
Confirmed on F27 as well.  This breaks unifi AP captive portals, so bumping severity.

Note You need to log in before you can comment on or make changes to this bug.