github.com/gohugoio/hugo
Affected
- introduced
0.60.0, fixed0.163.3(semver)
Fixed versions
0.163.3
Fix
- Fixed version
0.163.3go get github.com/gohugoio/[email protected]
Advisory
Also known as: CVE-2026-58402, GO-2026-5569
Hugo: XSS via unescaped code-fence language in default code block renderer
Hugo's default code-block renderer wrote the Markdown code-fence language / info-string into the <code class="language-…" data-lang="…"> wrapper without HTML escaping. A fence info-string containing a quote and a <script> payload breaks out of the attribute and injects a live script element.
This is not an issue if you fully trust every file under /content and every content adapter you load.
Medium Basis: The source's own band: MODERATE
0.60.0, fixed 0.163.3 (semver)0.163.3
0.163.3go 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