CVE-2026-40895 — follow-redirects
CVE-2026-40895 is a Information Exposure vulnerability in follow-redirects. A fix is available for follow-redirects — see the affected versions and patch details below.
follow-redirects: Custom Authentication Headers Leaked to Cross-Domain Redirect Targets
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for CVE-2026-40895.
EPSS Exploitation Probability
EPSS (Exploit Prediction Scoring System) is a daily probability model maintained by FIRST.org. It estimates the likelihood a CVE will be exploited in production environments within the next 30 days, derived from real-world threat intelligence signals.
Real-World Exposure
How broadly this vulnerability is actually deployed: weekly install volume shows current usage, and reverse-dependency count shows how many other packages break if it stays unpatched.
follow-redirectsnpmDescription
follow-redirects is an open source, drop-in replacement for Node's http and https modules that automatically follows redirects. Prior to 1.16.0, when an HTTP request follows a cross-domain redirect (301/302/307/308), follow-redirects only strips authorization, proxy-authorization, and cookie headers (matched by regex at index.js). Any custom authentication header (e.g., X-API-Key, X-Auth-Token, Api-Key, Token) is forwarded verbatim to the redirect target. This vulnerability is fixed in 1.16.0.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | follow-redirects | all versions | 1.16.0npm install follow-redirects@1.16.0 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for follow-redirects, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update follow-redirects to 1.16.0 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2026-40895 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 Security's impact-aware SCA analyses which vulnerable code paths your application actually calls, so a match like CVE-2026-40895 can be triaged on real exposure rather than presence alone.
Tailored to CVE-2026-40895. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
This Important impact information disclosure vulnerability in the follow-redirects npm package allows custom authentication headers (such as X-API-Key or X-Auth-Token) to be forwarded verbatim when HTTP requests follow cross-domain redirects. Applications that pass sensitive authentication headers while using…
| Product | Fixed in | Advisory |
|---|---|---|
| Cryostat 4 on RHEL 9 | cryostat/cryostat-openshift-console-plugin-rhel9:4.2.0-9 | RHSA-2026:17789 |
| Cluster Observability Operator 1.5.0 | cluster-observability-operator/distributed-tracing-console-plugin-pf4-rhel9:1781116645 | RHSA-2026:26010 |
| multicluster engine for Kubernetes 2.1 | multicluster-engine/console-mce-rhel9:1780917531 | RHSA-2026:24536 |
| multicluster engine for Kubernetes 2.11 | multicluster-engine/console-mce-rhel9:1780910888 | RHSA-2026:25271 |
| multicluster engine for Kubernetes 2.6 | multicluster-engine/console-mce-rhel9:1778511348 | RHSA-2026:17657 |
| multicluster engine for Kubernetes 2.8 | multicluster-engine/console-mce-rhel9:1778383863 | RHSA-2026:17699 |
| multicluster engine for Kubernetes 2.9 | multicluster-engine/console-mce-rhel9:1778532610 | RHSA-2026:19109 |
| Network Observability (NETOBSERV) 1.11.0 | network-observability/network-observability-console-plugin-compat-rhel9:1778508956 | RHSA-2026:16874 |
Frequently Asked Questions
Is CVE-2026-40895 in your dependencies?
O3 Security finds CVE-2026-40895 across npm dependencies, including transitive ones, and its impact-aware SCA ranks findings by whether your code actually calls the vulnerable path.