llamaCVEVulnerability Intelligence
/
Advisory · GitHub · Go · github.com/gohugoio/hugo

GHSA-WCPJ-VCVM-J4PG

Stored XSS via unescaped heading ID in Table of Contents HTML

Parche disponible
Descargar PNG JSON
CVSS
—
medium
Fuente: —
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche1 versiónPrimer parche el mismo día de la divulgación
Exposición53 dDesde la divulgación, 28 sept 2026, 10:45 a. m.
Detección51 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Explotación
Remediación
Parche v0.167.0
Monitoreo
Detectada +1
28 sept 26
18 nov 26
20 nov 26
28 sept 26
11 oct 26
25 oct 26
7 nov 26
20 nov 26
FechaFaseEventoDetalle
Divulgación Publicada GHSA-WCPJ-VCVM-J4PG divulgada
Remediación Parche v0.167.0 github.com/gohugoio/hugo · 0 d desde divulgación
Monitoreo Detectada Ingresó al índice
Monitoreo Verificada Última verificación contra las fuentes
Resumen
Descripción del advisory
Texto original · GitHub · en inglés
Impact

Explicit heading IDs in Markdown (e.g. `## Intro {id="..."}`) were written unescaped into the `href` of the generated Table of Contents HTML. A content author who controls Markdown can break out of the attribute and inject arbitrary HTML, including elements with event handlers, into any page that renders `.TableOfContents` or `.Fragments.ToHTML`.

This affects sites that build untrusted or third-party Markdown content and render a table of contents. The heading element itself was already escaped; only the ToC output was affected.

Affected versions

Hugo v0.60.0 (Goldmark as the default Markdown renderer) up to and including v0.166.0.

Patches

Fixed in v0.167.0 by escaping heading IDs before they are written to the ToC HTML.

Workarounds

Do not render `.TableOfContents` or `.Fragments.ToHTML` for untrusted content, or validate heading IDs in a content pipeline before building.

References
  • CWE-79: Improper Neutralization of Input During Web Page Generation
Versiones

Rangos afectados

Afectada Corregida Última
github.com/gohugoio/hugo≥ v0.60.0 < v0.167.0
v0.60.0
v0.167.0
v0.170.0
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
gogithub.com/gohugoio/hugo
Corregida v0.167.0 0 d v0.170.0 no afectada
Versiones corregidasv0.167.0
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Advisoryhttps://github.com/gohugoio/hugo/security/advisories/GHSA-wcpj-vcvm-j4pg

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.