---
id: CVE-2026-20736
title: Gitea does not properly verify repository context when deleting attachments
summary: >-
  Gitea does not properly verify repository context when deleting attachments. A
  user who previously uploaded an attachment to a repository may be able to
  delete it after losing access to that repository by making the request through
  a dif…
severity: high
cvss: 7.5
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N'
cwe:
  - CWE-284
  - CWE-284
vendor: gitea
product: gitea
affected:
  - gitea < 1.25.4
patched:
  - gitea 1.25.4
published: '2026-01-22'
updated: '2026-06-30'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2026-20736'
references:
  - url: 'https://blog.gitea.com/release-of-1.25.4/'
    label: 88ee5874-cf24-4952-aea0-31affedb7ff2
  - url: 'https://github.com/go-gitea/gitea/pull/36320'
    label: 88ee5874-cf24-4952-aea0-31affedb7ff2
  - url: 'https://github.com/go-gitea/gitea/releases/tag/v1.25.4'
    label: 88ee5874-cf24-4952-aea0-31affedb7ff2
  - url: 'https://github.com/go-gitea/gitea/security/advisories/GHSA-jr6h-pwwp-c8g6'
    label: 88ee5874-cf24-4952-aea0-31affedb7ff2
  - url: 'https://access.redhat.com/security/cve/CVE-2026-20736'
    label: 0b0ca135-0b70-47e7-9f44-1890c2a1c46c
  - url: 'https://bugzilla.redhat.com/show_bug.cgi?id=2432205'
    label: 0b0ca135-0b70-47e7-9f44-1890c2a1c46c
  - url: >-
      https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-20736.json
    label: 0b0ca135-0b70-47e7-9f44-1890c2a1c46c
tags:
  - nvd
epss: 0.00439
epssPercentile: 0.35489
ingestedAt: '2026-06-30T13:26:50.543Z'
---

## Overview

Gitea does not properly verify repository context when deleting attachments. A user who previously uploaded an attachment to a repository may be able to delete it after losing access to that repository by making the request through a different repository they can access.

## Affected

- `gitea < 1.25.4`

## Remediation

Upgrade past the affected range:

- `gitea 1.25.4`
