5.4

CVE-2026-10618: Hugo 0.93.0 through 0.165.0 Stored Cross-Site Scripting via Unescaped Code-Fence Attribute Values

Analyzed
AliasesUBUNTU-CVE-2026-10618DEBIAN-CVE-2026-10618
Published 24-08-2026Last modified 26-08-2026

Vulnerability summary

CVE-2026-10618 is a medium (CVSS 5.4) vulnerability in gohugo hugo. EPSS estimates a 0.21% chance of exploitation in the next 30 days, higher than 12.6% of scored vulnerabilities.

Priority
Routine

Not severe (CVSS 4.8, network access); no exploitation reported by the 5 checked sources

Source freshness unavailable

How is this decided?
CVSS score
5.4/10
010
Medium · v3.1 (CVE.org)
EPSS score
0.21%
0%100%
Low · -0.09 pp in 30 days
KEVNot listedNot listed by any tracked catalog.
RansomwareNot flaggedNo ransomware use recorded.
Public exploits0No public exploits recorded

Advisory lineage

Upstream 0 · Downstream 1

Timeline

  1. 24-08-2026
    PublishedVulnerability first disclosed.
  2. 26-08-2026
    Last modifiedVulnerability information updated.

Description

Hugo's default fenced-code-block renderer writes attribute values taken from the code-fence info string into the rendered HTML without escaping them. New in markup/internal/attributes/attributes.go converts every attribute value from a byte slice to a string as it is stored, deliberately dropping the escaping that used to happen there, and RenderAttributes in the same file escapes only values that are still byte slices, so its escaping branch is never reached and every value is written verbatim. The function's documentation states that it performs HTML escaping of string attributes, which it does not. A quote inside an attribute value in the info string therefore terminates the attribute and allows a further attribute, including an event handler, to be placed on the wrapper element, and the script runs for every visitor who loads the page. This path is reached under the default configuration, with code fences enabled and without goldmark's unsafe setting or any custom render hook. Attribute names beginning with on are filtered when the attributes are parsed, so injection is achieved through the value rather than the name.

CVSS metrics

7 scores · 4 sources · 2 versions

EPSS trend

Probability

0.21%

Chance of exploitation in the next 30 days

Percentile

13%

Versus all other CVEs

30-day change

Decrease -0.09 pp

From 0.30% on 04-11-2026

04-11-202604-12-2026

Known exploited

Compare KEV catalogs
CISA KEV

Not in the CISA KEV catalog.

ENISA CNW

Not in the ENISA CNW catalog.

CIRCL

Not in the CIRCL catalog.

Public exploits

0 found

No public exploits indexed.

Weaknesses

CWE · root cause

Affected systems

Version check

Known conditions: network-reachable, low-privilege account, user interaction (CVSS vector). Other conditions: not stated in public data.

Debian1 product
  • hugoAll versions (No fix recorded) | < 0.166.0-1
Gohugo1 product
  • hugo≥ 0.93.0, < 0.165.0
Gohugoio1 product
  • hugo≥ 0.93.0, ≤ 0.165.0
Ubuntu1 product
  • hugoAll versions (No fix recorded)

4 vendors · 4 products

References

8 links