CVE-2025-69202: Axios cache interceptor Remote Code Execution Vulnerability

MODERATE
Advisory Identifier: GHSA-x4m5-4cw8-vc44
CWE-639 CWE-524
Published
Advisory Summary

CVE-2025-69202 is a MODERATE remote code execution vulnerability (CWE-639: Authorization Bypass Through User-Controlled Key) affecting Axios cache interceptor libraries in the npm ecosystem. The issue involves axios-cache-interceptor vulnerable to cache poisoning via ignored http vary header. Remediation is available by upgrading affected packages to version 1.11.1.

CVE-2025-69202 at a Glance

CVE Identifier CVE-2025-69202
GHSA Identifier GHSA-x4m5-4cw8-vc44
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-639: Authorization Bypass Through User-Controlled Key
Affected Product Axios cache interceptor
Package Ecosystem npm
Published Date
Last Updated

How to Fix CVE-2025-69202

To remediate this vulnerability, upgrade all affected Axios cache interceptor dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

axios-cache-interceptor fixed: 1.11.1
npm install axios-cache-interceptor@1.11.1
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls axios-cache-interceptor

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2025-69202, inspect your project dependencies using npm:

npm ls axios-cache-interceptor

Analyze the terminal output to locate any version of Axios cache interceptor in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.11.1), your application is affected.

Note: The npm ls axios-cache-interceptor command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-639: Authorization Bypass Through User-Controlled Key, where the system's authorization functionality does not prevent one user from gaining access to another user's data or record by modifying the key value identifying the data. In Axios cache interceptor, 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

## Summary When a server calls an upstream service using different auth tokens, axios-cache-interceptor returns incorrect cached responses, leading to authorization bypass. ## Details The cache key is generated only from the URL, ignoring request headers like `Authorization`. When the server responds with `Vary: Authorization` (indicating the response varies by auth token), the library ignores this, causing all requests to share the same cache regardless of authorization. ## Impact **Affected:** Server-side applications (APIs, proxies, backend services) that: - Use axios-cache-interceptor to cache requests to upstream services - Handle requests from multiple users with different auth tokens - Upstream services replies on `Vary` to differentiate caches **Not affected:** Browser/client-side applications (single user per browser session). Services using different auth tokens to call upstream services will return incorrect cached data, bypassing authorization checks and leaking user data across different authenticated sessions. ## Solution After `v1.11.1`, automatic `Vary` header support is now enabled by default. When server responds with `Vary: Authorization`, cache keys now include the authorization header value. Each user gets their own cache. ```js // v1.11.1+ (automatic, no config needed) // User 123: key = hash(url + {authorization: 'Bearer 123'}) // User 456: key = hash(url + {authorization: 'Bearer 456'}) // ✓ Different caches, no poisoning ``` ## Remediation Upgrade to v1.11.1 or later. _No code changes required, protection is automatic_ ## Proof of Concept ```js const http = require('node:http'); const axios = require('axios'); const { setupCache } = require('axios-cache-interceptor'); // Server that returns different responses based on Authorization const server = http.createServer((req, res) => { const auth = req.headers.authorization; res.setHeader('Vary', 'Authorization'); if (auth === 'Bearer 123') { res.write('Hello, user 123!'); } else if (auth === 'Bearer 456') { res.write('Hello, user 456!'); } else { res.write('Unknown'); } res.end(); }); server.listen(5000); // Client making requests with different tokens const cachedAxios = setupCache(axios.create()); const server2 = http.createServer(async (_req, res) => { const authHeader = Math.random() < 0.5 ? 'Bearer 123' : 'Bearer 456'; const response = await cachedAxios.get('http://localhost:5000', { headers: { Authorization: authHeader } }); console.log({ response: response.data, cached: response.cached, auth: authHeader }); res.write(response.data); res.end(); }); server2.listen(5001); // Trigger 10 requests Promise.all( Array.from({ length: 10 }, () => axios.get('http://localhost:5001').catch(console.error) ) ).finally(() => { server.close(); server2.close(); }); ``` All 10 responses return "Hello, user 123!" even when using "Bearer 456" - users receive each other's cached data.

CVE-2025-69202 Affected Axios cache interceptor Versions

1 component(s)
Fixed Versions:
1.11.1
Product / Package Ecosystem Affected Versions Fixed Version
axios-cache-interceptor
npm
< 1.11.1
1.11.1

References

Frequently Asked Questions

What is CVE-2025-69202?
CVE-2025-69202 is a security vulnerability in Axios cache interceptor involving axios-cache-interceptor Vulnerable to Cache Poisoning via Ignored HTTP Vary Header under CWE-639: Authorization Bypass Through User-Controlled Key.
Which Axios cache interceptor versions are affected?
Affected versions include releases prior to 1.11.1 across affected packages: axios-cache-interceptor.
What version fixes CVE-2025-69202?
Upgrading to 1.11.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is axios-cache-interceptor affected?
Yes, axios-cache-interceptor is affected in releases prior to 1.11.1. Upgrade your dependency to 1.11.1 or later.
What CWE is associated with CVE-2025-69202?
CVE-2025-69202 is classified under CWE-639: Authorization Bypass Through User-Controlled Key (The system's authorization functionality does not prevent one user from gaining access to another user's data or record by modifying the key value identifying the data.).
How can I check npm dependencies for CVE-2025-69202?
Run the dependency tree command: 'npm ls axios-cache-interceptor'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-x4m5-4cw8-vc44",
  "modified" : "2026-01-05T22:35:17Z",
  "published" : "2025-12-30T15:37:55Z",
  "aliases" : [ "CVE-2025-69202" ],
  "summary" : "axios-cache-interceptor Vulnerable to Cache Poisoning via Ignored HTTP Vary Header",
  "details" : "## Summary\n\nWhen a server calls an upstream service using different auth tokens, axios-cache-interceptor returns incorrect cached responses, leading to authorization bypass.\n\n## Details\n\nThe cache key is generated only from the URL, ignoring request headers like `Authorization`. When the server responds with `Vary: Authorization` (indicating the response varies by auth token), the library ignores this, causing all requests to share the same cache regardless of authorization.\n\n## Impact\n\n**Affected:** Server-side applications (APIs, proxies, backend services) that:\n\n- Use axios-cache-interceptor to cache requests to upstream services\n- Handle requests from multiple users with different auth tokens\n- Upstream services replies on `Vary` to differentiate caches\n\n**Not affected:** Browser/client-side applications (single user per browser session).\n\nServices using different auth tokens to call upstream services will return incorrect cached data, bypassing authorization checks and leaking user data across different authenticated sessions.\n\n## Solution\n\nAfter `v1.11.1`, automatic `Vary` header support is now enabled by default.\n\nWhen server responds with `Vary: Authorization`, cache keys now include the authorization header value. Each user gets their own cache.\n\n```js\n// v1.11.1+ (automatic, no config needed)\n// User 123: key = hash(url + {authorization: 'Bearer 123'})\n// User 456: key = hash(url + {authorization: 'Bearer 456'})\n// ✓ Different caches, no poisoning\n```\n\n## Remediation\n\nUpgrade to v1.11.1 or later. _No code changes required, protection is automatic_\n\n\n## Proof of Concept\n\n```js\nconst http = require('node:http');\nconst axios = require('axios');\nconst { setupCache } = require('axios-cache-interceptor');\n\n// Server that returns different responses based on Authorization\nconst server = http.createServer((req, res) => {\n  const auth = req.headers.authorization;\n\n  res.setHeader('Vary', 'Authorization');\n\n  if (auth === 'Bearer 123') {\n    res.write('Hello, user 123!');\n  } else if (auth === 'Bearer 456') {\n    res.write('Hello, user 456!');\n  } else {\n    res.write('Unknown');\n  }\n\n  res.end();\n});\n\nserver.listen(5000);\n\n// Client making requests with different tokens\nconst cachedAxios = setupCache(axios.create());\n\nconst server2 = http.createServer(async (_req, res) => {\n  const authHeader =\n    Math.random() < 0.5 ? 'Bearer 123' : 'Bearer 456';\n\n  const response = await cachedAxios.get('http://localhost:5000', {\n    headers: { Authorization: authHeader }\n  });\n\n  console.log({\n    response: response.data,\n    cached: response.cached,\n    auth: authHeader\n  });\n  res.write(response.data);\n  res.end();\n});\n\nserver2.listen(5001);\n\n// Trigger 10 requests\nPromise.all(\n  Array.from({ length: 10 }, () =>\n    axios.get('http://localhost:5001').catch(console.error)\n  )\n).finally(() => {\n  server.close();\n  server2.close();\n});\n```\n\nAll 10 responses return \"Hello, user 123!\" even when using \"Bearer 456\" - users receive each other's cached data.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:H/AT:P/PR:L/UI:N/VC:H/VI:N/VA:N/SC:L/SI:L/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "axios-cache-interceptor"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.11.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/arthurfiorette/axios-cache-interceptor/security/advisories/GHSA-x4m5-4cw8-vc44"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-69202"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/arthurfiorette/axios-cache-interceptor/commit/49a808059dfc081b9cc23d48f243d55dfce15f01"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/arthurfiorette/axios-cache-interceptor"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-524", "CWE-639" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-12-30T15:37:55Z",
    "nvd_published_at" : "2025-12-29T20:15:42Z"
  }
}