CVE-2026-126338

Gitea private diff disclosure through code comment replies

Published Nov 15, 2026 CVSS n/a EPSS n/a KEV · Not listed
Description
Replying to a code review comment accepted a review ID that belongs to a different pull request, through the web form, the API and incoming mail replies. A signed-in user could reply on a pull request they can access with the ID of a review in a repository they cannot read, and the new comment was attached to that review and received the diff context of the commented lines. Replies are now only accepted for a review of the same pull request, and for a pending review only from its author.

Analysis

AI-generated

Technical impact

The vulnerability allows an authenticated user to reply to a code review comment by providing a review ID that belongs to a different pull request. Because the system accepted the ID, the new comment was attached to that review and included the diff context of the commented lines. As a result, an attacker could expose the content of private code diffs from repositories they are not authorized to view. This reflects an authorization bypass through user‑controlled input (CWE‑639).

Affected Systems

Affected systems include installations of Gitea prior to the 28.4.0 release; the issue existed in all versions that did not enforce review‑ID validation on replies made through the web interface, the API, or by incoming mail.

Risk and Exploitability

The exploit requires only that the user is authenticated to the Gitea instance; no additional privileges are required. Because the flaw can reveal private repository data, the confidentiality risk is high, though the CVSS score is not publicly available. The vulnerability is not listed in the CISA KEV catalog and no EPSS score is available, suggesting limited documented exploitation but that does not diminish the potential impact. A remediation that restricts replies to reviews belonging to the same pull request mitigates the risk.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply the latest Gitea patch (v28.4.0) which enforces that replies are accepted only for reviews of the same pull request and for pending reviews only from the author.
  • Validate that the web interface, API endpoints, and email handling reject review IDs that do not belong to the current pull request; test with a user who has no access to the target repository.
  • Disable or restrict the email reply-to-review feature if your workflow does not require it, to eliminate a possible route for exploitation.

Generated by OpenCVE AI on November 15, 2026 at 22:21 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Gitea
Gitea gitea
Vendors & Products Gitea
Gitea gitea
Type Values Removed Values Added
Description Replying to a code review comment accepted a review ID that belongs to a different pull request, through the web form, the API and incoming mail replies. A signed-in user could reply on a pull request they can access with the ID of a review in a repository they cannot read, and the new comment was attached to that review and received the diff context of the commented lines. Replies are now only accepted for a review of the same pull request, and for a pending review only from its author.
Title Gitea private diff disclosure through code comment replies
Weaknesses CWE-639
References
Weaknesses
  • CWE-639

    Authorization Bypass Through User-Controlled Key

Sources

Status
PUBLISHED
Assigner
Gitea
Published
Updated
Nov 15, 2026, 9:14 PM
Reserved
Nov 15, 2026, 8:29 PM
Status
Deferred
Published
Nov 15, 2026, 10:17 PM
Modified
Nov 15, 2026, 10:17 PM