---
title: "CVE-2026-52811: Gogs: UploadRepoFiles writes outside repo working tree via committed parent sym"
url: https://erroneo.us/security/cve/CVE-2026-52811/
description: "CVE-2026-52811 (gogs.io/gogs (Go)): Gogs is an open source self-hosted Git service. Prior to 0.14.3, (Repository).UploadRepoFiles checks for symlinks only…"
type: vulnerability-record
section: "Security Digest"
date_published: 2026-06-24
date_modified: 2026-07-21
publisher: erroneo.us
author: erroneo.us Security Desk
cve: "CVE-2026-52811"
kev: false
cvss: 9
epss: 0.00474
license: All rights reserved. Quote with attribution and a link.
---

# CVE-2026-52811: Gogs: UploadRepoFiles writes outside repo working tree via committed parent sym

**Signal:** Critical, preconditions apply. Severe if exploited, but exploitation needs conditions that may not apply to you. (Computed from CISA KEV, EPSS and CVSS; not an editorial verdict.)

## Should you act?

- No confirmed exploitation. It is not in CISA’s KEV catalog and CISA’s SSVC assessment records no known exploitation. That can change quickly after a public write-up; re-check if you are affected.
- EPSS 0.5% , percentile 40: FIRST’s model estimates a 0.5% chance of exploitation activity in the next 30 days, higher than 40% of all scored CVEs (low). EPSS is a probability, not a verdict.
- Needs an account (low (any account)). Exposure depends on who can log in.
- Only applies if your dependency tree includes gogs.io/gogs (Go) < 0.14.3, fixed in 0.14.3 . Check your lockfile, including transitive dependencies.

## What it is

Gogs is an open source self-hosted Git service. Prior to 0.14.3, (Repository).UploadRepoFiles checks for symlinks only on the leaf of the upload target (osx.IsSymlink(targetPath)). The siblings UpdateRepoFile, DeleteRepoFile, and GetDiffPreview use hasSymlinkInPath, which lstats every component — UploadRepoFiles is the lone outlier. An attacker with repo-write access plus a multipart upload whose filename contains a literal backslash (preserved by filepath.Base on Linux, then converted to / by pathx.Clean) redirects the write through a previously-committed directory symlink. iox.CopyFile opens the destination with os.Create (no ONOFOLLOW), so the kernel follows the parent symlink and writes attacker bytes anywhere the gogs UID can write — ~git/.ssh/authorizedkeys → SSH foothold, or .git/hooks/post-receive → next-push RCE. This vulnerability is fixed in 0.14.3.

## Affected packages

- Go `gogs.io/gogs` < 0.14.3 → fixed: 0.14.3

## Affected products (CVE record)

- gogs gogs: < 0.14.3

## Severity

- GitHub_M CVSS 4.0: 9 `CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H`
- GitHub CVSS 4.0: 9.0 `CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H`

## Exploitation

- CISA KEV: not listed (no confirmed in-the-wild exploitation known to CISA).
- CISA SSVC assessment: exploitation none , automatable no , technical impact total .
- FIRST EPSS (model of 2026-10-21): 0.47% probability of exploitation activity in the next 30 days; percentile 40.

## Sources

- [GitHub Advisory GHSA-89mr-xqfv-758m](https://github.com/advisories/GHSA-89mr-xqfv-758m)
- [CVE.org record CVE-2026-52811](https://www.cve.org/CVERecord?id=CVE-2026-52811)
- [NVD entry CVE-2026-52811](https://nvd.nist.gov/vuln/detail/CVE-2026-52811)
- [github.com](https://github.com/gogs/gogs/security/advisories/GHSA-89mr-xqfv-758m)
- [github.com](https://github.com/gogs/gogs/pull/8332)
- [github.com](https://github.com/gogs/gogs/commit/04cb8afbb01d855454e59977a1cdbf522ea1db31)
- [github.com](https://github.com/gogs/gogs/releases/tag/v0.14.3)

---
Source page: https://erroneo.us/security/cve/CVE-2026-52811/ · Security Digest: https://erroneo.us/security/ · More: https://erroneo.us/llms.txt
