Possible regression from patch for CVE-2025-69224
Author: dleidertCreated Oct 1, 2026Updated Oct 1, 2026
Labelsbug
Describe the bug
I wonder if the patch for CVE-2025-69224 causes a bug/regression. The patch changed this code, for example.
- enc = enc.lower()
- if enc in ('gzip', 'deflate', 'br', 'zstd'):
+ if enc.isascii() and enc.lower() in {"gzip", "deflate", "br", "zstd"}:
encoding = encSo, originally, the value got lowercased, then compared and assigned. But now it is only compared in lowercase and then assigned as-is. IMHO it should be:
encoding = enc.lower()to preserve the original behavior.
To Reproduce
It should be easy to adjust the tests to use GZIP or Gzip for content-encoding.
Expected behavior
Tolerate and process uppercase or mixed-case values.
Logs/tracebacks
n/aPython Version
Python 3.14.7aiohttp Version
3.14.3multidict Version
not relevantpropcache Version
not relevantyarl Version
not relevantOS
Linux
Related component
Server
Additional context
No response
Code of Conduct
- I agree to follow the aio-libs Code of Conduct
Source: aio-libs/aiohttp