github.com/gohugoio/hugo
Affected
- introduced
0.43.0, fixed0.161.0(semver)
Fixed versions
0.161.0
Fix
- Fixed version
0.161.0go get github.com/gohugoio/[email protected]
Advisory
Also known as: CVE-2026-44301, GO-2026-5740
Hugo's Node tool execution allows file system access outside the project directory
Impact
When building a Hugo site that uses Node-based asset pipelines (PostCSS, Babel, TailwindCSS), Hugo invoked the configured Node tools without restrictions on file system access. As a result, executing hugo against an untrusted site could allow code running through these tools to read or write files outside the project's working directory.
Users who do not use PostCSS, Babel, or TailwindCSS, or who only build trusted sites, are not affected.
Patches
From v0.161.0, Hugo runs Node tools under Node's permission model with strict defaults: No write access and only read access to the site source directories and files.
Workarounds
Block these tools in security.exec.allow.
Medium Basis: The source's own band: MODERATE
0.43.0, fixed 0.161.0 (semver)0.161.0
0.161.0go get github.com/gohugoio/[email protected]Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0