All vulnerabilities

Servers and applications

GHSA-53f6-cgcf-gp6v

Commit-message issue references post comments into private repositories the pusher cannot access

Severity
Medium 5.4
Published
24 Nov 2026
Last changed
24 Nov 2026
Added to UpHeron
24 Nov 2026
Weakness
Missing authorization (CWE-862)
Attack
Over the network · Needs a user account · No user action needed
Attacker can
Read some data · Change some data
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N
Sources
Project advisories (GitHub)

Description

When commits are pushed, Gogs scans their messages for owner/repo#N references and adds a "referenced this issue" comment to each referenced issue. It does this for any repository, including private ones the pusher has no access to.

An attacker therefore pushes a commit to their own repository whose message references victim/private-repo#1, and a comment with attacker-controlled text and links appears in the victim's private issue. The response also confirms whether a private issue exists.

Reproduced on v0.14.3 and on main @ dbbd717e.

internal/database/actions.go, updateCommitReferencesToIssues:

  • GetIssueByRef(ref) resolves an issue in any repository.
  • CreateRefComment(doer, repo, issue, message, sha) is then called with no permission check.

The close and reopen keyword loops in the same function do limit themselves to issue.RepoID == repo.ID.

From gogs/gogs's security advisory. Shortened; the full text is there.

Affected software

SoftwareAffected versions
GogsServers and applications · github:gogs/gogs
  • Every version up to 0.14.3

About Gogs

free forge based on Git written in Go

From Wikidata, CC0 1.0.
Docker Hub pulls
94,097,312Docker Hub, 22 Nov 2026
GitHub stars
47,981GitHub, 22 Nov 2026
Forks
5,081GitHub, 22 Nov 2026
Latest release
v0.14.4GitHub, 22 Nov 2026
Released
12 Nov 2026GitHub
Developer
FLOSS contributorWikidata
License
Expat licenseWikidata
Written in
Go, Cascading Style Sheets, JavaScriptWikidata
First released
11 Feb 2014Wikidata
First published on GitHub
12 Feb 2014GitHub

References