← Vulnerabilities

MediumAdvisoryGoGitHubJavaScript / Node.js

Hugo theme-defined module replacements bypass mount restrictions and widen the Node.js read sandbox

Affected

PackageAffected versionsFixed in
go:github.com/gohugoio/hugo>= 0.152.0, < 0.168.00.168.0

A theme or module could define its own module.replacements and mount directories anywhere on the host. Details A theme or module could define its own module.replacements. If the project didn't set any replacements, Hugo applied the theme's replacements as if the project had set them. The theme could then import and mount a directory anywhere on the host, either by absolute path or by escaping themesDir with ../. This got around the rule that theme mount sources must be local paths. Mounting suc…

Read on GitHub Advisory Database

On 12/01/2026, 06:49 AM, GitHub Advisory Database published "Hugo theme-defined module replacements bypass mount restrictions and widen the Node.js read sandbox" (type: Advisory). Severity is "Medium" (medium). Related technologies: Go, GitHub, JavaScript / Node.js.