PT-2026-51621 · Gogs · Gogs

CVE-2026-52802

·

Published

2026-06-23

·

Updated

2026-07-30

CVSS v3.1

5.4

Medium

VectorAV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
Name of the Vulnerable Software and Affected Versions Gogs versions prior to 0.14.3
Description An open redirect issue exists where attacker-controlled redirect to parameters can bypass validation, allowing redirection to arbitrary external sites. This occurs in all redirects validated via the IsSameSite() function, which only inspects the first two characters of the URL string. The check fails to account for directory traversal sequences followed by backslashes (e.g., /a/../example.com). Because web browsers normalize backslashes to forward slashes, the resulting URL becomes a cross-origin redirect. This affects all endpoints using the redirect to query parameter, including login and other post-action flows.
Recommendations Update to version 0.14.3. As a temporary workaround, restrict or sanitize the use of the redirect to parameter in all affected API endpoints until the update is applied.

Exploit

Fix

Open Redirect

Found an issue in the description? Have something to add? Feel free to write us 👾

Weakness Enumeration

Related Identifiers

CVE-2026-52802
GHSA-XXHQ-69MF-W8CR
GO-2026-5773
OPENSUSE-SU-2026:21483-1

Affected Products

Gogs