CVE-2026-94448: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in Go standard library html/template
Description
CVE-2026-94448 is a cross-site scripting (XSS) vulnerability in the Go standard library's html/template package. The flaw occurs when JavaScript template literals contain consecutive expressions, causing improper context tracking and failure to reset state correctly. This leads to incorrect escaping of subsequent regular expression literals, potentially allowing injection of malicious scripts.
Affected software
Go standard library
html/template
pkg:golang/html/templateRun on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability arises because the context tracking state in the html/template package was not properly reset upon entering a new expression within JavaScript template literals containing consecutive expressions. This improper neutralization of input during web page generation (CWE-79) can result in incorrect escaping of regular expression literals following these expressions. The fix ensures that template-literal expression entries correctly reset context variables so that all subsequent regular expression literals are accurately recognized and escaped.
Potential Impact
If exploited, this vulnerability could allow an attacker to inject malicious JavaScript code into web pages generated using the affected versions of the Go html/template package, leading to cross-site scripting attacks. This could compromise the security of users by executing arbitrary scripts in their browsers. However, there are no known exploits in the wild at this time.
Mitigation Recommendations
A fix is available in Go standard library versions 1.26.9 and 1.27.2 and later. Users should upgrade to these or later versions to mitigate this vulnerability. Since this is a library vulnerability, updating the affected versions of the html/template package is the recommended remediation.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- Go
- Date Reserved
- 2026-09-21T16:43:04.758Z
- State
- PUBLISHED
Threat ID: 6ac821662cdf04f656417219
Added to database: 10/08/2026, 23:04:06 UTC
Last enriched: 10/08/2026, 23:18:59 UTC
Last updated: 10/08/2026, 23:19:11 UTC
Views: 5
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.