Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable gzip if not already enabled #310

Closed
davecheney opened this issue Apr 2, 2018 · 7 comments
Closed

Enable gzip if not already enabled #310

davecheney opened this issue Apr 2, 2018 · 7 comments
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. priority/important-longterm Important over the long term, but may not be staffed and/or may need multiple releases to complete.
Milestone

Comments

@davecheney
Copy link
Contributor

  • check it doesn’t come for free (long shot)
  • enable it unconditionally for a reasonable set of media types
  • (later) add annotation to disable it (probably won’t do, I can’t think of a good reason to want to disable compression)
@davecheney davecheney added help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. priority/important-longterm Important over the long term, but may not be staffed and/or may need multiple releases to complete. labels Apr 2, 2018
@davecheney davecheney added this to the 0.5.0 milestone Apr 2, 2018
@davecheney
Copy link
Contributor Author

Bumping to 0.6

@davecheney davecheney modified the milestones: 0.5.0, 0.6.0 Apr 17, 2018
@davecheney
Copy link
Contributor Author

This is still open for anyone to work on it in 0.6 after April 23

@rosskukulinski
Copy link
Contributor

Envoy added support for a gzip HTTP filter in 1.6: envoyproxy/envoy#269

Moving to 0.7.0 unless someone else has bandwidth to tackle.

@rosskukulinski rosskukulinski modified the milestones: 0.6.0, 0.7.0 Aug 9, 2018
@mattmoyer
Copy link

(later) add annotation to disable it (probably won’t do, I can’t think of a good reason to want to disable compression)

One reason someone might want to do this is as a blanket mitigation for BREACH.

yob added a commit to yob/contour that referenced this issue Oct 4, 2018
This unconditionally enables envoys gzip http_filter[1], which will
compress responses if the request indicates it can handle it (via a
"accept-encoding: gzip" request header).

I've enabled it with no options, which means it gets the defaults, as
listed at [2]. In envoy 1.7.0, they're:

    {
      "memory_level": 5,
      "content_length": 30",
      "compression_level": "DEFAULT",
      "compression_strategy": "DEFAULT",
      "content_type": [“application/javascript”, “application/json”, “application/xhtml+xml”, “image/svg+xml”, “text/css”, “text/html”, “text/plain”, “text/xml”],
      "disable_on_etag_header": false,
      "remove_accept_encoding_header": false,
      "window_bits": 12
    }

Note the list of content types that will be compressed. It's possible
some users will want to customise this list, but for now I haven't
exposed that option.

Fixes projectcontour#310

[1] https://www.envoyproxy.io/docs/envoy/latest/configuration/http_filters/gzip_filter
[2] https://www.envoyproxy.io/docs/envoy/latest/api-v2/config/filter/http/gzip/v2/gzip.proto

Signed-off-by: James Healy <james@yob.id.au>
@StarpTech
Copy link

Hi, what's the status? As far I can test gzip is not enabled by default and I also can't find any hint in the docs.

@jpeach
Copy link
Contributor

jpeach commented Jun 21, 2020

@StarpTech Contour always enables the Envoy gzip filter with the default setting, which are documented here.

@StarpTech
Copy link

@jpeach thanks, I will retest it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. priority/important-longterm Important over the long term, but may not be staffed and/or may need multiple releases to complete.
Projects
None yet
Development

No branches or pull requests

5 participants