Axios: XSRF Token Cross-Origin Leakage via Prototype Pollution Gadget in `withXSRFToken` Boolean Coercion
Affects axiosSource GCVE Database
Not known to be exploited · CVSS 5.4 Medium : upgrade to 1.15.1 when convenient.
Data as of 27 Oct 2026, 01:30 UTC
- Patch
- Available – fixed in 1.15.1, 0.31.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:NExploitation evidence
Disclosed: evidence found.
CVE published 5 May 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Upgrade axios to 1.15.1; axios to 0.31.1.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| npmaxios | Affected
| Fixed in
|
| npmaxios | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
A patch is available in Axios versions 1.15.1 and 0.31.1 that corrects the boolean coercion logic for the `withXSRFToken` property. Users should upgrade to these fixed versions to remediate the vulnerability. No additional mitigations are required if the patch is applied. If upgrading is not immediately possible, ensure that prototype pollution vulnerabilities are mitigated in dependencies and avoid misconfiguring `withXSRFToken` with non-boolean truthy values.
Description
Axios contains a vulnerability in its XSRF token protection logic where the `withXSRFToken` configuration property is coerced using JavaScript truthy/falsy semantics rather than strict boolean checks. This flaw allows prototype pollution or misconfiguration to cause the same-origin check to be bypassed, resulting in XSRF tokens being sent to cross-origin servers, potentially controlled by attackers. The vulnerability affects all Axios versions from 1.0.0 up to but not including 1.15.1, and all versions before 0.31.1. It is limited to browser environments and enables theft of anti-CSRF tokens, which can facilitate CSRF attacks but does not directly compromise session tokens. A fix is available in versions 1.15.1 and 0.31.1.