Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend HTTP request with spoofed X-Forwarded-For header
-
DeliveryRealIP middleware extracts leftmost (attacker-controlled) value
-
Exploitr.RemoteAddr overwritten with spoofed IP
-
ExecutionApplication IP-ACL evaluates forged address
-
PersistACL or rate-limit bypass achieved
-
ImpactAccess restricted resource or evade throttling
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A07:2025 - Authentication Failures
ASVS 5.0
V6 - Authentication Anti-spoofing controls
MITRE ATT&CK
1 technique across 1 tactic: Defense Evasion The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires two simultaneous conditions: first, the application must explicitly register middleware.RealIP in its chi router chain (r.Use(middleware.RealIP)); second, the application must implement access controls - IP-based ACLs, rate limiting, or audit logging - that rely on r.RemoteAddr or r.Request.RemoteAddr as overwritten by the middleware. Applications that do not use middleware.RealIP, or that use it but perform no IP-based gating, are not exploitable. No authentication is required and no non-default configuration is needed on the attacker side - the attack requires only the ability to send an HTTP request with a custom header. Exploitation is further limited to chi versions 5.2.1 through 5.2.x; both older chi v4 deployments and updated 5.3.0 deployments are unaffected. |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N) reflects a straightforward, unauthenticated, low-complexity network attack with no prerequisites beyond sending an HTTP request - the lowest possible exploitation barrier. The scored impact is limited (VC:L/VI:L/VA:N), correctly capturing that the attack does not yield remote code execution or data exfiltration directly but enables ACL bypass and rate-limit evasion, which are themselves enablers for follow-on attacks. No EPSS data was supplied; however, given the public POC in the GHSA advisory and the trivial nature of the exploit (a single HTTP header), opportunistic exploitation of exposed endpoints is realistic wherever the middleware is deployed with IP-based controls. The vulnerability is NOT in CISA KEV, suggesting no confirmed widespread exploitation at this time. Real-world severity is context-dependent: applications that rely on chi's RealIP middleware for access control face meaningful risk, while those that do not use IP-based gating are functionally unaffected despite the vulnerability existing in the dependency. |
| Exploit ScenarioDerived | An attacker targeting an IP-restricted chi endpoint sends a GET /admin/secret HTTP request with the header 'X-Forwarded-For: 1.2.3.4' (an allowlisted administrator IP) from their own arbitrary IP. The RealIP middleware overwrites r.RemoteAddr with '1.2.3.4', causing the application's IP-ACL check to succeed and granting access to the restricted resource. A working proof-of-concept demonstrating this bypass is published in the GHSA advisory. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Aug 14, 2026
IP spoofing via the RealIP middleware in go-chi/chi (versions 5.2.1 through 5.2.x) allows unauthenticated remote attackers to bypass IP-based access control lists, circumvent rate-limiting mechanisms, and forge log entries by prepending a fabricated address to the X-Forwarded-For HTTP header. A proof-of-concept is included in the GitHub security advisory (GHSA-3fxj-6jh8-hvhx), confirming exploitability against any chi application that enables the RealIP middleware and enforces controls based on the overwritten r.RemoteAddr. No active exploitation has been confirmed in CISA KEV at time of analysis.
RemediationAI
Upgrade go-chi/chi to version 5.3.0, which fixes the vulnerability by no longer blindly trusting the leftmost X-Forwarded-For value. Run 'go get github.com/go-chi/chi/v5@v5.3.0' and update go.sum accordingly. The fix is confirmed in the upstream advisory at https://github.com/go-chi/chi/security/advisories/GHSA-3fxj-6jh8-hvhx. If an immediate upgrade is not possible, the most effective compensating control is to remove or bypass the middleware.RealIP registration (r.Use(middleware.RealIP)) and implement your own trusted-proxy-aware IP extraction that walks the X-Forwarded-For list right-to-left, stopping at the first IP not belonging to a known trusted proxy CIDR. Alternatively, enforce IP-based access control at the reverse proxy or load-balancer layer (e.g., nginx allow/deny or AWS security groups) rather than in application code, so forged headers never influence the control plane. Note: removing RealIP entirely may cause application logic that depends on r.RemoteAddr to see proxy IPs instead of client IPs, requiring code-level adjustments.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 3 packages in go, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
go-chi/chi is a lightweight, idiomatic Go HTTP router widely used for building REST APIs and microservices. The vulnerable component is middleware/realip.go, which implements the RealIP middleware (CWE-290: Authentication Bypass by Spoofing). The flaw lies in the realIP() function: it reads the X-Forwarded-For header and extracts only the first comma-separated (leftmost) value via strings.Cut(xff, ','), then overwrites r.RemoteAddr with it. Per RFC 7239 and industry practice, each reverse proxy appends the connecting client IP to the right of X-Forwarded-For - making the leftmost value fully attacker-controlled because clients can freely set this header before it reaches any proxy. Correct implementations must trust only the rightmost IP injected by a known, trusted proxy. The affected CPE is cpe:2.3:a:go-chi:chi:*:*:*:*:*:*:*:*, versions >= 5.2.1 and < 5.3.0.
Know when Chi gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
Network-accessible, no complexity or privilege needed; impacts are limited to ACL bypass and log forgery with no availability consequence.
AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
Lifecycle Timeline
1DescriptionCVE.org
go-chi chi versions >= 5.2.1 and before 5.3.0 contain an IP spoofing vulnerability in the RealIP middleware, which blindly trusts the first (leftmost) value of the X-Forwarded-For HTTP header. A remote attacker can bypass IP-based access control lists and rate-limiting mechanisms, and forge log entries, by supplying a spoofed IP address in the X-Forwarded-For header. The issue is fixed in version 5.3.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.
IP spoofing in go-chi/chi's RealIP middleware through version 5.2.1 enables unauthenticated remote attackers to inject a
IP spoofing in go-chi's RealIP middleware allows unauthenticated network attackers to forge the apparent client source I
IP spoofing in Go Chi before 5.4.0 allows an unauthenticated client that can reach the Go server directly to forge its a
Open redirect in chi (go-chi/chi) versions before 5.2.2 allows Host header injection via the RedirectSlashes middleware,
Same weakness CWE-290 – Authentication Bypass by Spoofing
View allSame technique Authentication Bypass
View allVendor StatusVendor
SUSE
Severity: Moderate| Product | Status |
|---|---|
| SUSE Linux Enterprise Desktop 15 SP7 | Affected |
| SUSE Linux Enterprise Desktop 15 SP7 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP7 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP7 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP7 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP7 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP7 | Affected |
| SUSE Linux Enterprise Module for HPC 15 SP7 | Affected |
| SUSE Linux Enterprise Server 15 SP7 | Affected |
| SUSE Linux Enterprise Server 15 SP7 | Affected |
| SUSE Linux Enterprise Server 16.0 | Affected |
| SUSE Linux Enterprise Server 16.0 | Affected |
| SUSE Linux Enterprise Server 16.0 | Affected |
| SUSE Linux Enterprise Server 16.1 | Affected |
| SUSE Linux Enterprise Server 16.1 | Affected |
| SUSE Linux Enterprise Server 16.1 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP7 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP7 | Affected |
| SUSE Linux Enterprise Server for SAP applications 16.0 | Affected |
| SUSE Linux Enterprise Server for SAP applications 16.0 | Affected |
| SUSE Linux Enterprise Server for SAP applications 16.0 | Affected |
| SUSE Linux Enterprise Server for SAP applications 16.1 | Affected |
| SUSE Linux Enterprise Server for SAP applications 16.1 | Affected |
| SUSE Linux Enterprise Server for SAP applications 16.1 | Affected |
| openSUSE Leap 16.0 | Affected |
| openSUSE Leap 16.0 | Affected |
| openSUSE Leap 16.0 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5-LTSS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5-LTSS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5-LTSS | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP4 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP4 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP5 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP5 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP6 | Affected |
| SUSE Linux Enterprise Module for Basesystem 15 SP6 | Affected |
| SUSE Linux Enterprise Module for HPC 15 SP5 | Affected |
| SUSE Linux Enterprise Module for HPC 15 SP6 | Affected |
| SUSE Linux Enterprise Server 15 SP4 | Affected |
| SUSE Linux Enterprise Server 15 SP4 | Affected |
| SUSE Linux Enterprise Server 15 SP4-LTSS | Affected |
| SUSE Linux Enterprise Server 15 SP4-LTSS | Affected |
| SUSE Linux Enterprise Server 15 SP5 | Affected |
| SUSE Linux Enterprise Server 15 SP5 | Affected |
| SUSE Linux Enterprise Server 15 SP5-LTSS | Affected |
| SUSE Linux Enterprise Server 15 SP5-LTSS | Affected |
| SUSE Linux Enterprise Server 15 SP6 | Affected |
| SUSE Linux Enterprise Server 15 SP6 | Affected |
| SUSE Linux Enterprise Server 15 SP6-LTSS | Affected |
| SUSE Linux Enterprise Server 15 SP6-LTSS | Affected |
| SUSE Linux Enterprise Server 15 SP6-LTSS | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP4 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP4 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP5 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP5 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP6 | Affected |
| SUSE Linux Enterprise Server for SAP Applications 15 SP6 | Affected |
| SUSE Manager Proxy 4.3 | Affected |
| SUSE Manager Proxy 4.3 | Affected |
| SUSE Manager Proxy LTS 4.3 | Affected |
| SUSE Manager Proxy LTS 4.3 | Affected |
| SUSE Manager Retail Branch Server 4.3 | Affected |
| SUSE Manager Retail Branch Server 4.3 | Affected |
| SUSE Manager Retail Branch Server LTS 4.3 | Affected |
| SUSE Manager Retail Branch Server LTS 4.3 | Affected |
| SUSE Manager Server 4.3 | Affected |
| SUSE Manager Server 4.3 | Affected |
| SUSE Manager Server LTS 4.3 | Affected |
| SUSE Manager Server LTS 4.3 | Affected |
| SUSE Linux Enterprise Desktop 15 SP4 | Affected |
| SUSE Linux Enterprise Desktop 15 SP4 | Affected |
| SUSE Linux Enterprise Desktop 15 SP5 | Affected |
| SUSE Linux Enterprise Desktop 15 SP5 | Affected |
| SUSE Linux Enterprise Desktop 15 SP6 | Affected |
| SUSE Linux Enterprise Desktop 15 SP6 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP4 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP4 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5-ESPOS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5-ESPOS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP5-ESPOS | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP6 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP6 | Affected |
| SUSE Linux Enterprise High Performance Computing 15 SP6 | Affected |
| SUSE Linux Enterprise Real Time 15 SP4 | Affected |
| SUSE Linux Enterprise Real Time 15 SP4 | Affected |
| openSUSE Leap 15.4 | Affected |
| openSUSE Leap 15.4 | Affected |
| openSUSE Leap 15.5 | Affected |
| openSUSE Leap 15.5 | Affected |
| openSUSE Leap 15.5 | Affected |
| openSUSE Leap 15.6 | Affected |
| openSUSE Leap 15.6 | Affected |
| openSUSE Leap 15.6 | Affected |
| suse/cosign | Affected |
EUVD-2026-58630
GHSA-qgxv-hqxp-4rcx
NVD
CVE.org
EPSS
VulDB
Exploit-DB