CVE-2026-40175: Axios Library Vulnerability Leading to Unrestricted Cloud Metadata Exfiltration

axios Updated 10 Apr 2026

Summary

10/04/2026
Yes i
Critical
10.0

CVE-2026-40175: Axios has Unrestricted Cloud Metadata Exfiltration via Header Injection Chain. Affects axios versions < 1.15.0. Fixed in 1.15.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Axios is a popular JavaScript library used for making HTTP requests from both the browser and Node.js environments. It simplifies the process of sending asynchronous HTTP requests to REST endpoints and performing CRUD operations. The library is widely adopted due to its promise-based architecture, ease of use, and ability to handle requests and responses seamlessly. However, it has a critical vulnerability that allows for unrestricted cloud metadata exfiltration due to improper header sanitization.

Vulnerability Detail

The Axios library is susceptible to a 'Gadget' attack chain that can escalate prototype pollution in third-party dependencies into Remote Code Execution (RCE) or Full Cloud Compromise through an AWS IMDSv2 bypass. This vulnerability arises from a lack of HTTP header sanitization, allowing attackers to inject malicious headers without direct user input. If an attacker can manipulate the Object.prototype via any library in the stack, Axios will merge these polluted properties into request headers, leading to potential request smuggling and unauthorized access to sensitive cloud metadata.

How To Fix

Latest published version: 1.20.0 as of 22 Oct 2026

npm install axios@1.20.0

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.15.0

This is the first release that contains the fix.

npm install axios@1.15.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, ensure that no third-party libraries that may pollute Object.prototype are used in conjunction with Axios. Additionally, you can manually sanitize header values before making requests to prevent injection of CRLF characters.

Conclusion

The Axios library's vulnerability (CVE-2026-40175) poses a significant risk due to its potential for remote code execution and cloud metadata exfiltration. It is crucial for developers to update to the patched version and implement proper header validation to mitigate this risk.

See every vulnerability recorded for axios →

Share this vulnerability

FAQ

CVE-2026-40175 is a critical vulnerability in the Axios library that allows for unrestricted cloud metadata exfiltration due to improper header sanitization.

If your application uses Axios and is vulnerable, attackers can exploit this flaw to execute arbitrary code or access sensitive cloud metadata, potentially compromising your cloud environment.

All versions of Axios from v0.x to v1.x are affected by this vulnerability.

You can use Vulert, which monitors open-source vulnerabilities in your software by analyzing package-lock.json. Visit Vulert Scanner to check your application without needing to sign up.

The CVSS score for this vulnerability is 10.0, indicating a critical level of severity.

Related vulnerabilities

Recent vulnerabilities recorded for axios.

How To Fix

Latest published version: 1.20.0 as of 22 Oct 2026

npm install axios@1.20.0

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.15.0

This is the first release that contains the fix.

npm install axios@1.15.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback