Ecosyste.ms: Advisories
An open API service providing security vulnerability metadata for many open source software ecosystems.
Security Advisories: GSA_kwCzR0hTQS0yMmdoLTNyOXEteGYzOM0V2A
Lacking Protection against HTTP Request Smuggling in mitmproxy
Impact
In mitmproxy 7.0.2 and below, a malicious client or server is able to perform HTTP request smuggling attacks through mitmproxy. This means that a malicious client/server could smuggle a request/response through mitmproxy as part of another request/response's HTTP message body. While mitmproxy would only see one request, the target server would see multiple requests. A smuggled request is still captured as part of another request's body, but it does not appear in the request list and does not go through the usual mitmproxy event hooks, where users may have implemented custom access control checks or input sanitization.
Unless you use mitmproxy to protect an HTTP/1 service, no action is required.
Patches
The vulnerability has been fixed in mitmproxy 7.0.3 and above.
Acknowledgements
We thank João Sobral (@chinchila) for responsibly disclosing this vulnerability to the mitmproxy team.
Timeline
- 2021-09-08: Received initial report for mitmproxy <= 6.0.2.
- 2021-09-08: Requested clarification if 7.x is affected.
- 2021-09-10: Received additional details, 7.x situation still unclear.
- 2021-09-13: Internally determined that 7.x is also affected.
- 2021-09-13: Shared initial fix with researcher.
- 2021-09-14: Received confirmation that fix is working, but H2.TE/H2.CL should also be looked at.
- 2021-09-14: Shared revised fix that includes additional H2.TE mitigations.
- 2021-09-14: Received confirmation that revised fix is working.
- 2021-09-16: Completed internal patch review.
- 2021-09-16: Published patch release and advisory.
JSON: https://advisories.ecosyste.ms/api/v1/advisories/GSA_kwCzR0hTQS0yMmdoLTNyOXEteGYzOM0V2A
Source: GitHub Advisory Database
Origin: Unspecified
Severity: Critical
Classification: General
Published: about 3 years ago
Updated: 2 months ago
CVSS Score: 8.1
CVSS vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS Percentage: 0.00188
EPSS Percentile: 0.56696
Identifiers: GHSA-22gh-3r9q-xf38, CVE-2021-39214
References:
- https://github.com/mitmproxy/mitmproxy/security/advisories/GHSA-22gh-3r9q-xf38
- https://nvd.nist.gov/vuln/detail/CVE-2021-39214
- https://github.com/pypa/advisory-database/tree/main/vulns/mitmproxy/PYSEC-2021-328.yaml
- https://github.com/advisories/GHSA-22gh-3r9q-xf38
Blast Radius: 22.7
Affected Packages
pypi:mitmproxy
Dependent packages: 30Dependent repositories: 639
Downloads: 316,078 last month
Affected Version Ranges: < 7.0.3
Fixed in: 7.0.3
All affected versions: 0.8.1, 0.9.1, 0.9.2, 0.10.1, 0.11.1, 0.11.2, 0.11.3, 0.12.0, 0.12.1, 0.14.0, 0.18.1, 0.18.2, 0.18.3, 1.0.0, 1.0.1, 1.0.2, 2.0.0, 2.0.1, 2.0.2, 3.0.0, 3.0.1, 3.0.2, 3.0.3, 3.0.4, 4.0.0, 4.0.1, 4.0.3, 4.0.4, 5.0.0, 5.0.1, 5.1.0, 5.1.1, 5.3.0, 6.0.0, 6.0.1, 6.0.2, 7.0.0, 7.0.1, 7.0.2
All unaffected versions: 7.0.3, 7.0.4, 8.0.0, 8.1.0, 8.1.1, 9.0.0, 9.0.1, 10.0.0, 10.1.0, 10.1.1, 10.1.2, 10.1.3, 10.1.4, 10.1.5, 10.1.6, 10.2.0, 10.2.1, 10.2.2, 10.2.3, 10.2.4, 10.3.0, 10.3.1, 10.4.0, 10.4.1, 10.4.2, 11.0.0, 11.0.1