Skip to content
OpenAdvisories
High · 7.5 CVE-2026-140395 EUVD-2026-140248GHSA-r48v-r4vw-h9v8GHSA-rhmv-h4x2-hfcr

Hugo 0.56.0 before 0.170.0 Path Traversal via _vendor/modules.txt

Published Dec 1, 2026 · Updated Dec 2, 2026 · Assigned by VulnCheck

Description

Hugo from 0.56.0 before 0.170.0 contains a path traversal vulnerability that allows malicious themes or modules to read arbitrary build host files by supplying '..' segments in _vendor/modules.txt import paths. Attackers can make Hugo treat any directory as a module root and use readFile or static mounts to publish secrets, credentials, and system files in the generated site.

Affected products

VendorProductAffectedFixed
gohugoio hugo 0.56.0 – < 0.170.0 0.170.0

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Red Hat Hardened Images 1 hugo 0.170.1-0.1.hum1 RHSA-2026:104146

Affected packages

EcosystemPackageAffectedFixedRecord
Go github.com/gohugoio/hugo >= 0.56.0, < 0.170.0 0.170.0 GHSA-r48v-r4vw-h9v8

Advisories 1

References