GHSA-w8gf-g2vq-j2f4: Amphp/http client Denial of Service Vulnerability
HIGHGHSA-w8gf-g2vq-j2f4 is a HIGH (CVSS 8.2) denial of service vulnerability (CWE-789: Memory Allocation with Excessive Size Value) affecting Amphp/http client libraries in the Packagist ecosystem. The issue involves amphp/http-client denial of service via http/2 continuation frames. Remediation is available by upgrading affected packages to version 4.1.0-rc1.
GHSA-w8gf-g2vq-j2f4 at a Glance
Security Impact
CVSS: 8.2
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H).
How to Fix GHSA-w8gf-g2vq-j2f4
To remediate this vulnerability, upgrade all affected Amphp/http client dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade amphp/http-client to 4.1.0-rc1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for amphp/http-client
How to Check if You Are Affected
To determine whether your application is affected by GHSA-w8gf-g2vq-j2f4, inspect your project dependencies for Amphp/http client:
inspect dependencies for amphp/http-client
Analyze the terminal output to locate any version of Amphp/http client in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.1.0-rc1), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-789: Memory Allocation with Excessive Size Value, where the product allocates memory based on an untrusted, large size value, but it does not ensure that the size is within expected limits, allowing arbitrary amounts of memory to be allocated. In Amphp/http client, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-w8gf-g2vq-j2f4 Affected Amphp/http client Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
amphp/http-client
|
Packagist |
≥ 4.0.0-rc10
< 4.1.0-rc1
|
4.1.0-rc1
|
References
Frequently Asked Questions
What is GHSA-w8gf-g2vq-j2f4?
Which Amphp/http client versions are affected?
What version fixes GHSA-w8gf-g2vq-j2f4?
Is amphp/http-client affected?
What is the CVSS score of GHSA-w8gf-g2vq-j2f4?
What CWE is associated with GHSA-w8gf-g2vq-j2f4?
How can I check Packagist dependencies for GHSA-w8gf-g2vq-j2f4?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-w8gf-g2vq-j2f4",
"modified" : "2024-04-03T18:49:42Z",
"published" : "2024-04-03T18:49:42Z",
"aliases" : [ ],
"summary" : "amphp/http-client Denial of Service via HTTP/2 CONTINUATION Frames",
"details" : "Early versions of `amphp/http-client` with HTTP/2 support (v4.0.0-rc10 to 4.0.0) will collect HTTP/2 `CONTINUATION` frames in an unbounded buffer and will not check the header size limit until it has received the `END_HEADERS` flag, resulting in an OOM crash. Later versions of `amphp/http-client` (v4.1.0-rc1 and up) depend on `amphp/http` for HTTP/2 processing and will therefore need an updated version of `amphp/http`, see [GHSA-qjfw-cvjf-f4fm](https://github.com/amphp/http/security/advisories/GHSA-qjfw-cvjf-f4fm).\n\n## Acknowledgements\n\nThank you to [Bartek Nowotarski](https://nowotarski.info/) for reporting the vulnerability.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "amphp/http-client"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "4.0.0-rc10"
}, {
"fixed" : "4.1.0-rc1"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 4.0.0"
}
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/amphp/http-client/security/advisories/GHSA-w8gf-g2vq-j2f4"
}, {
"type" : "WEB",
"url" : "https://github.com/amphp/http/security/advisories/GHSA-qjfw-cvjf-f4fm"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/amphp/http-client"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-770", "CWE-789" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2024-04-03T18:49:42Z",
"nvd_published_at" : null
}
}