# CVE-2026-58403: Hugo symlink confinement bypass in os.ReadFile

- Severity: Medium 5.9 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.32%, higher than 26% of CVEs (2026-12-02)
- Published: 2026-06-19T17:45:38.000Z
- Modified: 2026-10-25T20:10:00.147Z
- Also known as: GHSA-c3wq-j5vh-68rc, GO-2026-5309
- Weaknesses: CWE-59
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Hugo is a static site generator. From v0.123.0 through v0.163.0, Hugo's virtual filesystem is designed so that files under a mount cannot reach outside the mount tree, but a regression caused RootMappingFs.statRoot to call Stat, which follows symlinks, instead of Lstat, so a direct os.ReadFile "somefile" where somefile was a symlink pointing outside the mount would return the target's contents. This effectively let a symlink planted inside a theme or local mount read arbitrary files reachable to the user running hugo. This issue is fixed in v0.163.1.

(As written by CVE List.)

## Affected

- gohugoio hugo: >= 0.123.0, < 0.163.1
- github.com/gohugoio/hugo (Go): from 0.123.0 before 0.163.1
- gohugo hugo: from 0.123.0 before 0.163.1

## Every score

- GitHub_M: CVSS:4.0 5.9 Medium `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:N/SC:H/SI:N/SA:N`
- NVD: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N`

## References

- <https://github.com/gohugoio/hugo/security/advisories/GHSA-c3wq-j5vh-68rc> (advisory, vendor-advisory, web)
- <https://github.com/gohugoio/hugo/pull/15020> (issue-tracking)
- <https://github.com/gohugoio/hugo/commit/cf9c8f93ca2a2838ce378f9e36d052ac2f79e229> (patch)
- <https://github.com/gohugoio/hugo/releases/tag/v0.163.1> (release-notes, web)
- <https://github.com/gohugoio/hugo> (package)

## Sources

- CVE List: [CVE-2026-58403](https://www.cve.org/CVERecord?id=CVE-2026-58403), CVE Terms of Use, modified 2026-07-06
- GitHub Advisory Database: [GHSA-c3wq-j5vh-68rc](https://github.com/advisories/GHSA-c3wq-j5vh-68rc), CC-BY-4.0, modified 2026-07-24
- Go Vulnerability Database: [GO-2026-5309](https://pkg.go.dev/vuln/GO-2026-5309), CC-BY-4.0, modified 2026-07-24
- NVD: [CVE-2026-58403](https://nvd.nist.gov/vuln/detail/CVE-2026-58403), Public domain, modified 2026-10-25

---

Page: https://cve.day/CVE-2026-58403 · Whole record: https://cve.day/CVE-2026-58403.json · Rebuilt by cve.day 2026-11-25T22:59:27.245Z
