NewApp Monitoring is liveSign up free
AgentbeamBeta
Open-source package vulnerability · Go

GHSA-q76j-gcg9-vxc6: Hugo: XSS via unescaped code-fence language in default code block renderer

mediumCVSS 4.0 5.1

Hugo's default code-block renderer wrote the Markdown code-fence language / info-string into the wrapper without HTML escaping. A fence info-string containing a quote and a 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.

Published Jun 19, 2026

Affected packages

github.com/gohugoio/hugo

Ecosystem
Go
Affected
>= 0.60.0, < 0.163.3
Fixed in
0.163.3
Check
go list -m github.com/gohugoio/hugo

Advisory details

From the GitHub Advisory Database (CC BY 4.0).

Hugo's default code-block renderer wrote the Markdown code-fence language / info-string into the ` wrapper without HTML escaping. A fence info-string containing a quote and a ` 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.

Credited to k0ngj1.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology

More Go vulnerabilities

All Go entries