{"id":"CVE-2026-58403","published":"2026-07-06T19:25:45Z","modified":"2026-07-06T20:51:27Z","title":"Hugo symlink confinement bypass in os.ReadFile","vendor":"gohugoio","product":"hugo","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.9,"severity":"MEDIUM","version":"4.0","vector":"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","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00475,"percentile":0.41978,"provenance":"source"},"cwes":[{"id":"CWE-59","name":"Improper Link Resolution Before File Access"}],"references":[{"url":"https://github.com/gohugoio/hugo/security/advisories/GHSA-c3wq-j5vh-68rc","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/gohugoio/hugo/pull/15020","tags":["x_refsource_MISC"]},{"url":"https://github.com/gohugoio/hugo/commit/cf9c8f93ca2a2838ce378f9e36d052ac2f79e229","tags":["x_refsource_MISC"]},{"url":"https://github.com/gohugoio/hugo/releases/tag/v0.163.1","tags":["x_refsource_MISC"]}],"priority":{"score":12.5,"factors":[{"name":"EPSS percentile","points":8.4},{"name":"CVSS severity","points":4.13}]},"vendorSlug":"gohugoio","affectedVersions":[{"vendor":"gohugoio","product":"hugo","versions":[">= 0.123.0, < 0.163.1"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial","timestamp":"2026-07-06T20:51:16.911843Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"github.com/gohugoio/hugo","vulnerableRanges":[">=0.123.0, <0.163.1"],"patched":["0.163.1"],"from":["GO-2026-5309"],"provenance":"source"}],"summary":{"text":"In Hugo, the static site generator, a regression in the virtual filesystem's RootMappingFs.statRoot (present from v0.123.0 through v0.163.0) causes it to follow symlinks rather than inspect them, so a symlink inside a mounted directory can resolve to a file outside the mount tree. An attacker who can place a symlink within a theme or local mount can cause Hugo to read files outside that mount, provided they can get the affected content into a directory the user builds with Hugo and the user must run the build, with the impact limited to files readable by the user running hugo.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:50:32Z"},"euvd":{"id":"EUVD-2026-41907","exploited":false,"provenance":"source"}}