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

Brotli encoding used when not accepted by client #13980

Open
rodarima opened this issue Jun 21, 2024 · 0 comments
Open

Brotli encoding used when not accepted by client #13980

rodarima opened this issue Jun 21, 2024 · 0 comments

Comments

@rodarima
Copy link

See context here: https://lists.mailman3.com/hyperkitty/list/[email protected]/message/IJ5DAPK5B2MVQ363E677YFHLJ752Q5IG/

When loading (at least) the following pages in Dillo:

They are returned encoded with Brotli:

content-encoding: br

When the browser is requesting those pages with support for gzip and deflate only.

Here is a reproducer with CURL:

hop% curl -I -H 'Accept-Encoding: gzip, deflate' https://ubuntu.com/navigation
HTTP/2 200
server: nginx/1.14.0 (Ubuntu)
date: Fri, 21 Jun 2024 18:51:33 GMT
content-type: text/html; charset=utf-8
x-view-name: webapp.views.navigation_nojs
x-clacks-overhead: GNU Terry Pratchett
permissions-policy: interest-cohort=()
cache-control: max-age=60, stale-while-revalidate=86400, stale-if-error=300
x-frame-options: SAMEORIGIN
x-content-type-options: NOSNIFF
x-vcs-revision: 1718983740-db5b8f6
x-request-id: 5d66aeb6-8697-49ff-b5d5-21979ffa7aaf
strict-transport-security: max-age=15724800
link: <https://assets.ubuntu.com>; rel=preconnect; crossorigin, <https://assets.ubuntu.com>; rel=preconnect, <https://res.cloudinary.com>; rel=preconnect
content-encoding: br <----------- here
x-cache-status: HIT from content-cache-il3/0

Depending on the request being cached, you may have different results:

hop% for i in {1..10}; do curl -sI -H 'Accept-Encoding: gzip, deflate' https://ubuntu.com/tutorials/configure-ssh-2fa | grep content-encoding; sleep 1; done
content-encoding: br
content-encoding: br
content-encoding: gzip
content-encoding: gzip
content-encoding: gzip
content-encoding: gzip
content-encoding: gzip
content-encoding: br
content-encoding: gzip
content-encoding: gzip

You can use any tutorial link in https://ubuntu.com/tutorials to reproduce this issue if the server has cached the response and it doesn't serve Brotli anymore.


Reported from: https://ubuntu.com/navigation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant