CVE-2025-41235
Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.
NVD · uneditedSpring Cloud Gateway Server forwards the X-Forwarded-For and Forwarded headers from untrusted proxies.
Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.
dbcve analysis · high confidenceSpring Cloud Gateway Server improperly forwards X-Forwarded-For and Forwarded HTTP headers from untrusted proxies, allowing attackers to manipulate these headers to spoof client IP addresses, bypass IP-based access controls, or conduct header injection attacks.
Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.
CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.
From the vector- Attack vector
- Network
- Complexity
- Low
- Privileges
- None
- User interaction
- None
- Scope
- Changed
- Confidentiality
- None
- Integrity
- High
- Availability
- None
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N
Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.
dbcve checksWork through these to decide whether this CVE applies to you.
-
Identify Spring Cloud Gateway installationLocate the Spring Cloud Gateway application JAR file or Docker container. Check the application's pom.xml or build.gradle for the spring-cloud-gateway dependency and note the version number.Affected if The installed Spring Cloud Gateway version falls within the affected range (any unpatched version).
-
Verify forwarded header configurationCheck the application configuration files (application.yml or application.properties) for the property 'spring.cloud.gateway.forwarded.enabled'. Also check for 'spring.cloud.gateway.forwarded.host-header' and 'spring.cloud.gateway.forwarded.port-header' settings.Affected if The property is set to 'true' or is not explicitly set (defaults to true in vulnerable versions), allowing untrusted header forwarding.
-
Check trusted proxy configurationLook for 'spring.cloud.gateway.forwarded.host-header' or any trusted proxy whitelist configuration in application properties or environment variables. Review network configuration to determine if proxy trust boundaries are defined.Affected if No trusted proxy whitelist is configured, or the configuration allows forwarding headers from untrusted sources.
-
Inspect runtime header forwarding behaviorSend a test request to the gateway with a crafted X-Forwarded-For header (e.g., 'X-Forwarded-For: 1.2.3.4') and a Forwarded header (e.g., 'Forwarded: for=5.6.7.8'). Capture the request received by a backend service to see if these headers are passed through unchanged.Affected if The gateway forwards custom X-Forwarded-For or Forwarded headers from the incoming request to backend services without validation.
-
Review proxy trust settingsExamine all configuration sources including application.yml, application.properties, environment variables, and Kubernetes/Docker config maps for any Spring Cloud Gateway proxy trust settings. Check if 'trusted proxies' or similar trust configuration is explicitly defined.Affected if No explicit trusted proxy configuration exists, leaving the default behavior that accepts headers from any source.
You are affected if Spring Cloud Gateway is running and the forwarded header feature is enabled without explicit configuration of trusted proxies, allowing untrusted clients to manipulate X-Forwarded-For and Forwarded headers.
Generated from the published advisory. Verify against your own configuration.
Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.
From vendor dataConfigure Spring Cloud Gateway to only forward headers from trusted proxies by setting spring.cloud.gateway.forwarded.enabled=false or by explicitly configuring trusted proxy addresses; alternatively, filter/strip these headers before forwarding to backend services.
- Consultation3.0 h
- Implementation3.0 h
- Testing4.0 h
- Review / QA2.0 h
An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $3,360.
Scan for this in your stack
Free · runs locallyCheck whether your project pulls in CVE-2025-41235 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.
References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.
Primary sourcesPractitioner notes
ContributedPeer-ranked notes from engineers who’ve handled CVE-2025-41235 in production — separate from our analysis above.
The advisory tells you what broke. It rarely tells you what actually worked. If you’ve dealt with this one, that detail is what the next engineer is searching for.
- The version that genuinely resolved it — not the one the vendor claimed
- A config change or rule that shut the vector down
- A gotcha in the upgrade path that cost you an afternoon
No notes yet
Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.
A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.
- Verified mitigations, workarounds, and config changes
- Version or environment caveats, and links to real fixes
- No weaponised exploit code, or anything meant to cause harm
- No spam, self-promotion, credentials, or personal data