Open redirect in Gogs /redirect endpoint via backslash bypass
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Passive
- Attack complexity
- Low
- Attack requirements
- None
- Impact type
- Spoofing
- Confidentiality · integrity · availability
- None · None · None
- Fix status
- Fixed
Attack profile from CVSS 4.0 · CNA. Fix status from CNA. Impact type from CWE-601.
Summary
Gogs before 0.15.0+dev is affected in its /redirect endpoint and in similar post-action redirect flows. The IsSameSite check validates a normalized form of the target, but the redirect uses the original value, so a backslash bypasses the check (CWE-601). An unauthenticated remote attacker can make a link on the trusted Gogs domain send a victim to attacker-controlled content if the victim opens the link.
Written with Claude Haiku 5.5 from the sources below · 2026-10-28
Description from the CNA
Gogs is an open source self-hosted Git service. Prior to 0.15.0+dev, an unauthenticated attacker can provide a backslash-containing target to the /redirect endpoint, and similar post-action redirect flows are also affected. internal/urlx/urlx.go IsSameSite validates a normalized form of the target while cmd/gogs/internal/web/web.go getRedirect and other callers use the original value in the Location response. This backslash normalization mismatch lets browsers interpret the Location value as a scheme-relative external URL, allowing links on a trusted Gogs domain to redirect victims to attacker-controlled content for phishing. This vulnerability is fixed in 0.15.0+dev.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- Poc
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
Upgrade Gogs to 0.15.0+dev, the version that fixes this issue.
Written with Claude Haiku 5.5 from the sources below · 2026-10-28
- Fix · CNA gogs (gogs) Fixed in 0.15.0+dev
Timeline
- 2026-10-15 Threatist record created from CVE-2026-82402
- 2026-10-20 CISA SSVC decision points changed
- 2026-10-20 Priority changed: LOW → MEDIUM
References
More Gogs vulnerabilities
- TI-2025-07419 File overwrite in file update API in Gogs KEVCVSS 4.0HIGH 8.7
- TI-2022-01876 OS Command Injection in gogs/gogs CVSS 3.1CRITICAL 9.8
- TI-2024-36988 Gogs has a Path Traversal in file update API CVSS 4.0HIGH 8.7
- TI-2026-37922 Gogs: Path Traversal in organization name results in RCE through Git hooks CVSS 3.1CRITICAL 10.0
- TI-2022-01744 Remote Command Execution in gogs/gogs CVSS 3.1CRITICAL 10.0
- TI-2025-39562 Gogs's update .git/config file allows remote command execution CVSS 4.0CRITICAL 9.3
Sources
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences