Back to Blog
high SEVERITY7 min read

How Proxy-Authorization Header Leakage Happens in Axios and How to Fix It

A high-severity vulnerability (CVE-2026-44486) in Axios versions prior to 1.16.0 caused Proxy-Authorization headers to leak to redirect targets when the HTTP client re-evaluated proxy settings and switched to a direct connection. This information disclosure bug exposed sensitive proxy credentials to unintended destinations, and was fixed by upgrading from Axios 1.15.2 to 1.18.0 in the client application.

O
By Orbis AppSec
•Technically reviewed by Anupam Mediratta•Published August 19, 2026•Reviewed August 19, 2026

Answer Summary

CVE-2026-44486 is a high-severity information disclosure vulnerability in Axios (CWE-200) where Proxy-Authorization headers leak to HTTP redirect targets when the client switches from proxied to direct connections. The vulnerability affects Axios versions before 1.16.0 and 0.32.0, exposing proxy credentials to unintended servers during redirect chains. The fix requires upgrading to Axios 1.18.0 or later, which properly strips proxy authentication headers when connections are re-evaluated to bypass the proxy.

Vulnerability at a Glance

cweCWE-200 (Exposure of Sensitive Information to an Unauthorized Actor)
fixUpgrade Axios from 1.15.2 to 1.18.0 to properly handle header sanitization during redirect flows
riskProxy credentials exposed to redirect targets during connection re-evaluation
languageJavaScript (Node.js)
root causeAxios failed to strip Proxy-Authorization headers when switching from proxy to direct connection during redirects
vulnerabilityProxy-Authorization Header Leakage via HTTP Redirects

Introduction

In a client application's dependency tree, we discovered a high-severity information disclosure vulnerability in Axios 1.15.2 that could expose proxy authentication credentials to unintended servers. The vulnerability, tracked as CVE-2026-44486, exists in the client/package-lock.json dependency manifest where Axios was pinned at version 1.15.2. When an HTTP request configured to use a proxy server encounters a redirect, and Axios re-evaluates the connection to bypass the proxy for the redirect target, the Proxy-Authorization header—containing sensitive credentials—was not stripped from the outgoing request. This meant that proxy usernames and passwords could be leaked to arbitrary third-party servers during redirect chains.

The vulnerable dependency was identified by Trivy scanner, which flagged the specific pattern where proxy credentials could be disclosed through HTTP redirects. The fix involved upgrading Axios from version 1.15.2 to 1.18.0 across both client/package.json and client/pnpm-lock.yaml, ensuring the HTTP client properly sanitizes proxy-specific headers during connection re-evaluation.

The Vulnerability Explained

The Proxy-Authorization header is used to authenticate with HTTP proxy servers. It typically contains credentials in the format Basic base64(username:password). In normal operation, this header should only be sent to the proxy server itself, never to the final destination server.

Here's what happened in Axios 1.15.2:

  1. A client application makes an HTTP request through a configured proxy server
  2. The request includes a Proxy-Authorization header with credentials
  3. The proxy server responds with an HTTP redirect (301, 302, 307, 308)
  4. Axios re-evaluates the connection and determines the redirect target doesn't require proxying
  5. The vulnerability: Axios switches to a direct connection but fails to remove the Proxy-Authorization header
  6. The sensitive proxy credentials are sent directly to the redirect target server

Looking at the dependency configuration before the fix:

"axios": "^1.14.0",

And in the lock file:

axios:
  specifier: ^1.14.0
  version: 1.15.2

The application was using Axios 1.15.2, which contained the vulnerable redirect handling logic. When the HTTP client processed redirects and switched from proxied to direct connections, it didn't properly sanitize the header collection.

Real-World Attack Scenario

Consider this attack scenario specific to the client application:

  1. An attacker controls a web service that the client application might interact with (perhaps through user-supplied URLs or API integrations)
  2. The client application runs behind a corporate proxy requiring authentication
  3. The attacker's service returns an HTTP 302 redirect to a domain under their control
  4. When Axios follows the redirect and determines it doesn't need the proxy for the new destination, it switches to a direct connection
  5. The Proxy-Authorization header (containing corporate proxy credentials) is sent to the attacker's server
  6. The attacker now has valid proxy credentials that could be used to:
    - Access internal resources through the corporate proxy
    - Pivot to other internal systems
    - Mask malicious traffic as legitimate by using stolen proxy credentials

The impact is particularly severe in environments where:
- Proxy credentials grant access to sensitive internal networks
- The same proxy credentials are shared across multiple users or services
- Proxy logs are used for security monitoring (stolen credentials could enable undetected access)

The Fix

The fix involved upgrading Axios to version 1.18.0, which includes proper header sanitization during redirect handling. Here's what changed:

Before (client/package.json):

"dependencies": {
  "@stellar/freighter-api": "^6.0.1",
  "axios": "^1.14.0",
  "chart.js": "^4.5.1",
  // ... other dependencies
}

After (client/package.json):

"dependencies": {
  "@stellar/freighter-api": "^6.0.1",
  "axios": "^1.18.0",
  "chart.js": "^4.5.1",
  // ... other dependencies
}

Before (client/pnpm-lock.yaml):

axios:
  specifier: ^1.14.0
  version: 1.15.2

After (client/pnpm-lock.yaml):

axios:
  specifier: ^1.18.0
  version: 1.18.0

The upgrade from 1.15.2 to 1.18.0 brings in the security fix that was introduced in Axios 1.16.0. The updated version includes logic that:

  1. Tracks connection type changes: Monitors when a request transitions from proxied to direct connection
  2. Identifies proxy-specific headers: Recognizes headers like Proxy-Authorization that should only be sent to proxies
  3. Sanitizes headers during redirects: Removes proxy-specific headers when following redirects to direct connections
  4. Preserves valid headers: Maintains other authentication headers (like Authorization) that are legitimately intended for the destination server

The fix required changes to both files because:
- package.json defines the acceptable version range for the dependency
- pnpm-lock.yaml pins the exact resolved version and ensures reproducible builds

By updating both files, the fix ensures that:
- New installations will get Axios 1.18.0 or later
- Existing installations will upgrade to the secure version on next pnpm install
- The lock file prevents accidental downgrades to vulnerable versions

Key Takeaways

  • Axios versions before 1.16.0 leak Proxy-Authorization headers when switching from proxied to direct connections during HTTP redirects, exposing proxy credentials to redirect targets
  • The client application's dependency on Axios 1.15.2 in client/package-lock.json created a direct path for credential disclosure through the HTTP client's redirect handling
  • Upgrading to Axios 1.18.0 eliminates the vulnerability by implementing proper header sanitization that strips proxy-specific authentication from requests during connection re-evaluation
  • Both package.json and pnpm-lock.yaml required updates to ensure the secure version is enforced across all installations and prevent version drift back to vulnerable releases
  • Trivy scanner successfully detected this CVE-2026-44486 pattern in the dependency manifest, demonstrating the value of automated vulnerability scanning in CI/CD pipelines

How Orbis AppSec Detected This

  • Source: Axios dependency declaration in client/package.json and resolved version in client/package-lock.json
  • Sink: Axios HTTP client redirect handling logic that forwards headers during proxy-to-direct connection transitions
  • Missing control: Header sanitization during connection type re-evaluation; Proxy-Authorization headers were not stripped when switching from proxied to direct connections during redirects
  • CWE: CWE-200 (Exposure of Sensitive Information to an Unauthorized Actor)
  • Fix: Upgraded Axios from 1.15.2 to 1.18.0, which includes the security patch that properly removes proxy-specific headers during redirect flows

Orbis AppSec automatically detected this vulnerability and opened a pull request with the fix. Try Orbis AppSec on your repositories to find and fix issues like this automatically.

Conclusion

CVE-2026-44486 demonstrates how subtle flaws in HTTP client redirect handling can lead to serious information disclosure vulnerabilities. The leakage of Proxy-Authorization headers during connection re-evaluation could expose corporate proxy credentials to malicious third parties, enabling unauthorized access to internal networks and resources. By upgrading Axios from 1.15.2 to 1.18.0, the client application now properly sanitizes proxy-specific headers during redirects, preventing credential leakage.

This vulnerability underscores the importance of keeping HTTP client libraries up to date and implementing defense-in-depth strategies for handling sensitive authentication data. Regular dependency audits, automated vulnerability scanning, and careful header management during redirects are essential practices for maintaining secure applications. Always treat authentication credentials—whether for proxies, APIs, or services—as highly sensitive data that requires explicit protection at every layer of your application.

Prevention and further reading

View the Security Fix

Check out the pull request that fixed this vulnerability

View PR #758

Related Articles

high

axios 1.18.1 CVE-2026-101898: HTTP/2 Ignores proxy and lookup

A dependency upgrade moved `axios` from 1.18.1 to 1.20.0 to pick up the fix for CVE-2026-101898, in which proxy and DNS resolution settings supplied through axios request configuration were not applied on the HTTP/2 request path. Applications that rely on `config.proxy`, `HTTP_PROXY`/`NO_PROXY` environment variables, or a custom `lookup` function as an SSRF or egress control could have those controls silently skipped for HTTP/2 requests.

critical

Yandex Translate API Key Leaked via URL Query Parameter

The `translateYandex()` helper built its request URL by interpolating the caller-supplied API key directly into the query string, meaning every call leaked the credential into server access logs, proxy logs, and any Referer header sent by intermediaries. The fix switches the request from a GET with the key in the URL to a POST with the key in the request body via `URLSearchParams`, removing the credential from any URL-logging surface entirely.

high

Unvalidated thumbnailUrl Passed to axios.get(): SSRF Risk

A server-side image helper passes a `thumbnailUrl` value — sourced from 3D-print file metadata returned by an OctoPrint instance — straight into `axios.get()` with no scheme, host, or IP validation. Anyone who can write that metadata (a crafted G-code file, or a compromised/spoofed OctoPrint endpoint) turns the application into an HTTP proxy for internal networks and cloud metadata services. The accompanying pull request bumps `react-router-dom` from 7.9.1 to 7.18.4 to pick up the CVE-2026-21884

high

How Denial of Service via Prototype Pollution happens in Axios and how to fix it

Axios versions prior to 1.15.1 merged untrusted configuration objects without guarding against the `__proto__` key, letting attacker-controlled input pollute `Object.prototype` and crash or destabilize applications. Upgrading axios (and its transitive dependencies `form-data`, `follow-redirects`, `proxy-from-env`) closes this Denial of Service and prototype-pollution attack surface without changing any application code.

critical

How SSRF via Vulnerable Dependency Versions Happens in Node.js and How to Fix It

A permissive semver range in `package.json` allowed npm to install axios versions vulnerable to SSRF (CVE-2024-39338). By bumping the minimum version from `^1.6.0` to `^1.7.4`, all downstream consumers of this SDK are now protected from server-side request forgery attacks. This critical fix required changing just one line in the dependency manifest.

critical

How Server-Side Request Forgery happens in Node.js maintenance scripts and how to fix it

A critical Server-Side Request Forgery (SSRF) vulnerability was discovered in `maintenance/getImages.js`, where the `getImage()` function passed database-sourced URLs directly to `axios.get()` without any validation. An attacker who could modify the elements database could redirect these requests to internal network resources — including AWS cloud metadata endpoints — potentially exposing IAM credentials and other sensitive infrastructure data. The fix introduces a strict URL allowlist that limi