CVE-2026-111755

follow-redirects sensitiveHeaders regex escaping can expose credential headers

Published Oct 19, 2026 CVSS 4.0 · 8.2 High EPSS < 1% KEV · Not listed
Description
follow-redirects is a Node.js HTTP and HTTPS client wrapper that automatically follows redirects. From 1.16.0 until 1.16.1, escapeRegex leaves valid header-name metacharacters unescaped in sensitiveHeaders. When an application declares a sensitive header whose name contains ^ or | and follows a cross-origin or HTTPS-to-HTTP redirect, unescaped regular-expression metacharacters prevent the generated filter from matching the declared header name, and the credential header is forwarded to an attacker-controlled redirect target. This issue is fixed in version 1.16.1.

Analysis

AI-generated

Technical impact

follow-redirects, a Node.js HTTP and HTTPS client wrapper, contains a flaw where the escapeRegex function fails to escape regex metacharacters in the sensitiveHeaders list. When an application declares a header name that includes characters such as ^ or | and the request follows a cross‑origin or HTTPS‑to‑HTTP redirect, the generated filter does not match the header name and the credential header is forwarded to the attacker‑controlled redirect target. This unauthorized forwarding results in the disclosure of sensitive credentials that were intended to remain private.

Affected Systems

Versions of follow‑redirects from 1.16.0 through just before 1.16.1 are affected. Any Node.js application that uses this library to automatically follow redirects and declares a sensitive header whose name contains unescaped regex metacharacters is at risk. The vulnerable product is the follow‑redirects library commonly used in JavaScript/Node.js HTTP client code.

Risk and Exploitability

The vulnerability has a CVSS score of 8.2, signifying high severity. The EPSS score is not available, and it is not listed in the CISA KEV catalog. Attackers can exploit this by directing traffic through a malicious redirect URL that receives the forwarded credential header. The impact is primarily the exposure of credential information; the attack does not require local code execution or elevated privileges on the target system, but it does rely on influencing or observing a redirect path. Therefore, the risk is significant, especially when sensitive headers contain unescaped characters exposed during redirects.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the follow‑redirects library to version 1.16.1 or later, which contains the fixed escapeRegex logic.
  • If an upgrade cannot be performed immediately, review any sensitive header names for characters such as ^ or | and either remove those characters or avoid declaring them as sensitive headers.
  • Avoid using cross‑origin or HTTPS‑to‑HTTP redirects that transmit sensitive headers, or configure the application to strip sensitive headers before redirecting.

Generated by OpenCVE AI on October 20, 2026 at 07:17 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-8r9p-f939-6h3c follow-redirects sensitiveHeaders regex escaping can expose credential headers
History
Type Values Removed Values Added
Weaknesses CWE-212
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.9, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N'}

threat_severity

Moderate

Type Values Removed Values Added
First Time appeared Follow-redirects
Follow-redirects follow Redirects
Vendors & Products Follow-redirects
Follow-redirects follow Redirects
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description follow-redirects is a Node.js HTTP and HTTPS client wrapper that automatically follows redirects. From 1.16.0 until 1.16.1, escapeRegex leaves valid header-name metacharacters unescaped in sensitiveHeaders. When an application declares a sensitive header whose name contains ^ or | and follows a cross-origin or HTTPS-to-HTTP redirect, unescaped regular-expression metacharacters prevent the generated filter from matching the declared header name, and the credential header is forwarded to an attacker-controlled redirect target. This issue is fixed in version 1.16.1.
Title follow-redirects sensitiveHeaders regex escaping can expose credential headers
Weaknesses CWE-185
CWE-200
References
Metrics cvssV4_0

{'score': 8.2, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-185

    Incorrect Regular Expression

  • CWE-200

    Exposure of Sensitive Information to an Unauthorized Actor

  • CWE-212

    Improper Removal of Sensitive Information Before Storage or Transfer

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Oct 19, 2026, 6:00 PM
Reserved
Oct 16, 2026, 5:52 PM
Status
Awaiting Analysis
Published
Oct 19, 2026, 6:17 PM
Modified
Oct 19, 2026, 9:13 PM
Severity
Moderate
Public date
Oct 19, 2026, 5:27 PM