Advisories · Node.js & Next.js
CVE-2024-39338
High
CVSS 7.5
axios URL host confusion
Disclosed 2024 · Last reviewed 2 Dec 2026
A URL passed to axios could be requested at a host other than the one the caller expected.
What happened
The URL parser and the HTTP client disagreed on the host.
Affected and patched versions
- Affected
- axios through 1.7.3.
- Patched
- axios 1.7.4 and later.
How to check your server
Check
npm ls axios
How to fix and harden
- Upgrade axios to 1.7.4 or later.
- Build URLs on the server from a fixed origin. Do not pass a user-supplied absolute URL to axios.
Fix
npm ls axios
Sources
Version ranges and fixes follow the vendor advisory. When a distribution backports a fix, trust its security tracker over the upstream version number. New advisories: RSS · JSON