GHSA-6x33-pw7p-hmpq

Suggest an improvement
Source
https://github.com/advisories/GHSA-6x33-pw7p-hmpq
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2020/09/GHSA-6x33-pw7p-hmpq/GHSA-6x33-pw7p-hmpq.json
JSON Data
https://api.test.osv.dev/v1/vulns/GHSA-6x33-pw7p-hmpq
Published
2020-09-04T17:59:49Z
Modified
2024-01-29T20:57:00Z
Severity
  • 7.5 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H CVSS Calculator
Summary
Denial of Service in http-proxy
Details

Versions of http-proxy prior to 1.18.1 are vulnerable to Denial of Service. An HTTP request with a long body triggers an ERR_HTTP_HEADERS_SENT unhandled exception that crashes the proxy server. This is only possible when the proxy server sets headers in the proxy request using the proxyReq.setHeader function.

For a proxy server running on http://localhost:3000, the following curl request triggers the unhandled exception:
curl -XPOST http://localhost:3000 -d "$(python -c 'print("x"*1025)')"

Recommendation

Upgrade to version 1.18.1 or later

Database specific
{
    "nvd_published_at": null,
    "cwe_ids": [
        "CWE-184",
        "CWE-693"
    ],
    "severity": "HIGH",
    "github_reviewed": true,
    "github_reviewed_at": "2020-08-31T19:01:05Z"
}
References

Affected packages

npm / http-proxy

Package

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
1.18.1

Ecosystem specific

{
    "affected_functions": [
        "(http-proxy).createProxyServer"
    ]
}