Description
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.
Published: 2026-10-14
Score: 5.3 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Open Redirect leading to phishing
Action: Patch
AI Analysis

Impact

An unauthenticated attacker can supply a backslash-containing URL to the /redirect endpoint in Gogs. Because the IsSameSite function normalizes the target differently than the Location header generation, browsers treat the target as a scheme-relative external address, which results in a redirect to attacker-controlled content. This creates an open-redirect flaw that can be used for phishing or social-engineering attacks. The weakness is identified as CWE-601.

Affected Systems

Gogs self-hosted Git service, version 0.14.x and earlier (any release before 0.15.0+dev). The vulnerability is fixed in 0.15.0+dev and later releases. Only unauthenticated users can trigger the redirect, so any user accessing the service is at risk.

Risk and Exploitability

The CVSS score is 5.3, indicating a moderate severity. The EPSS score is not available, and the vulnerability is not listed in CISA KEV, suggesting it is not a widely exploited target at this time. Despite this, the flaw is trivial to exploit—an attacker simply crafts a URL with a backslash to the vulnerable /redirect endpoint, or any process that triggers post-action redirects. The open redirect can be leveraged in phishing campaigns, and the impact can be significant if attackers spread malicious campaigns to users of the trusted Gogs domain.

Generated by OpenCVE AI on October 15, 2026 at 14:02 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Gogs to 0.15.0+dev or newer.
  • Configure a web application firewall or reverse proxy to reject URLs containing backslashes or scheme‑relative redirects from the /redirect endpoint.
  • Monitor application logs for unexpected redirect requests or suspicious activity and investigate promptly.

Generated by OpenCVE AI on October 15, 2026 at 14:02 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Wed, 14 Oct 2026 19:00:00 +0000

Type Values Removed Values Added
Description 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.
Title Gogs: Open Redirect in /redirect endpoint via backslash bypass in `IsSameSite`
Weaknesses CWE-601
References
Metrics cvssV4_0

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


Subscriptions

No data.

cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-10-14T18:49:19.768Z

Reserved: 2026-08-28T22:00:43.512Z

Link: CVE-2026-82402

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-14T19:17:21.660

Modified: 2026-10-14T19:17:21.660

Link: CVE-2026-82402

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-15T14:15:15Z

Weaknesses
  • CWE-601

    URL Redirection to Untrusted Site ('Open Redirect')