GHSA-22jx-p735-qcpm
Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessIdentify Go app using vulnerable template with yield
-
DeliveryCraft input reaching mis-escaped regexp literal
-
ExploitBreak JS context via faulty escaping
-
ExecutionVictim browser loads page and executes injected script
-
ImpactSession/credential theft or client-side compromise
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that the affected Go application's own trusted html/template source contains the JavaScript |
| Impact | This analysis is scoped to CVE-2026-97030 only (html/template: recognize |yield| as regexp preceder keyword), one of several fixes bundled in the Go 1.27.2 / 1.26.9 release announcement. No CVSS vector, CWE, EPSS score, KEV listing, or POC is provided in the input, so quantitative exploitation signals are entirely absent and cannot be compared. Qualitatively, this is a template auto-escaping context-tracking defect: when a trusted template author uses the JavaScript |
| Exploit ScenarioDerived | A Go web application renders a server-side html/template that embeds the |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 08, 2026
Improper JavaScript context tracking in Go's html/template package fails to treat the yield keyword as a regular-expression preceder, so a regexp literal that follows yield inside a template-literal expression is mis-escaped instead of being correctly recognized and neutralized. Only applications that server-render HTML with html/template and whose trusted template source actually contains this specific yield-plus-regexp construct are meaningfully exposed, and a victim must load the rendered page (CVSS PR:N - no authentication required, but UI:R - user interaction required). No public exploit code identified at time of analysis; fixes ship in Go 1.27.2 and Go 1.26.9.
RemediationAI
Vendor-released patch: Go 1.27.2 and Go 1.26.9. Upgrade the Go toolchain to one of those releases, then rebuild and redeploy every affected binary, since the vulnerable html/template code is compiled into the artifact rather than resolved at runtime; GOTOOLCHAIN=go1.27.2 can be used to force the corrected toolchain in build pipelines. Where immediate rebuilding is not possible, audit templates for the yield keyword immediately followed by a regexp literal and rewrite that construct - for example by moving the regular expression into a RegExp constructor call or hoisting it outside the template-literal expression - or by removing interpolation of untrusted data from that region; the trade-off is manual template review effort and the risk that a rewritten expression changes intended rendering behavior, and neither workaround removes exposure for templates not covered by the audit. Note that the sibling html/template context-tracking fix (CVE-2026-94448, https://go.dev/issue/81821) and the other issues bundled in the same release announcement (net/http HTTP/2 HPACK and Trailer flaws, crypto/tls ECH, cmd/go checksum bypasses, MIME multipart limit bypass, HTTP/1 CONNECT desynchronization) require the same toolchain upgrade and rebuild.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 2 packages in go, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Go's html/template performs contextual auto-escaping: it parses template text alongside the surrounding HTML/JavaScript context and tracks state (HTML text, script block, template literal, regexp literal, etc.) so it can apply the correct escaping to each interpolated value. Inside JavaScript template literals, the parser must know which tokens can precede a regular-expression literal; the yield keyword (as used in generator functions) is a valid regexp preceder, but the escaping engine did not recognize it as such. The result is that a regexp literal appearing immediately after yield was not classified as a regexp literal, causing context mis-tracking and incorrect escaping of subsequent interpolated data - a context-dependent output-encoding failure of the same class as script-injection/XSS defects. A closely related fix in the same release, incorrect reset of context variables across consecutive template-literal expressions, is tracked separately as CVE-2026-94448 and should not be conflated with this CVE. No CWE identifier was supplied in the source feed, and no CPE entries were provided.
Know when Golang gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Web-delivered XSS so AV:N and scope-changing S:C into the victim browser; AC:H because a specific yield+regexp template construct must exist; UI:R as a victim must load the page; no availability impact.
Primary rating from Vendor (CNA).
CVSS VectorVendor
Lifecycle Timeline
2Description PRE-NVD
Executive ViewAI
A critical vulnerability in Go's html/template package could allow attackers to bypass output encoding in server-rendered web applications, potentially leading to cross-site scripting attacks against end users. The flaw is unauthenticated but requires user interaction, and only applications running affected Go versions whose trusted template source contains a specific yield-plus-regexp construct are meaningfully exposed; no public exploit has been identified at time of analysis. Engineering leadership should prioritize identifying and upgrading affected Go deployments to fixed releases to prevent potential session hijacking or data exposure.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
Denial of service against HTTP/2 server implementations allows remote unauthenticated attackers to exhaust server resour
The SSH transport protocol with certain OpenSSH extensions, found in OpenSSH before 9.6 and other products, allows remot
The net/http package in Go through 1.6 does not attempt to address RFC 3875 section 4.1.18 namespace conflicts and there
Erugo file-sharing platform up to version 0.2.14 has a CVSS 10.0 path traversal allowing authenticated users to read any
Critical certificate validation bypass in Go crypto/tls during session resumption. If ClientCAs or RootCAs fields are mu
WAGO PFC200 G2 PLC (firmware affected) allows privilege escalation through cookie manipulation. Users can modify cookie
Authentication bypass in WeGIA charitable institution management system before 3.6.5. The adicionar_tipo_docs_atendido.p
CGI path splitting vulnerability in FrankenPHP before 1.11.2 — Unicode characters bypass path validation during CGI proc
net/url in Go before 1.11.13 and 1.12.x before 1.12.8 mishandles malformed hosts in URLs, leading to an authorization by
Free5gc NRF 1.4.0 has an authorization bypass in access token generation that allows authenticated users to request toke
Algo 8028 Control Panel version 3.3.3 contains a command injection vulnerability in the fm-data.lua endpoint that allows
Denial of service in PocketBase versions prior to 0.22.48 (0.22.x branch) and 0.23.0 through 0.39.6 (0.23.0+ branch) all
EUVD-2026-95416
NVD
CVE.org
EPSS
VulDB
Exploit-DB