CVE-2026-97030

Recognize yield as regexp preceder keyword in html/template

Published Oct 8, 2026 CVSS 3.1 · 6.1 Medium EPSS < 1% KEV · Not listed
Description
A trusted template author may have previously written a valid template wherein the use of the 'yield' keyword would not be correctly escaped. We now ensure that valid keyword uses are escaped and non-keyword uses are not escaped.

Analysis

AI-generated

Technical impact

A template author who writes a template in Go's standard html/template package may create a mis‑interpreted ‘yield’ keyword if it is not escaped. The flawed logic fails to neutralize input correctly, corresponding to CWE‑74, and allows the template engine to interpret untrusted text as a template command. This can lead to unintended template execution or injection of malicious content into rendered output, representing a potential template injection vulnerability.

Affected Systems

The vulnerability is present in the Go standard library package html/template. No specific version ranges are listed in the advisory, so users should verify whether their installed Go release incorporates the fix referenced in the official issue tracker. Any version prior to the patch that allows an unescaped ‘yield’ token in trusted author templates is affected.

Risk and Exploitability

The CVE does not provide a CVSS or EPSS score, and it is not listed in the CISA KEV catalog, indicating no known widespread exploitation. The attack vector requires an attacker to control or modify a trusted template that contains an unescaped ‘yield’ keyword, which could happen when developers unknowingly deploy such templates or when templates are retrieved from untrusted sources. Because the flaw is limited to trusted template authors, the likelihood of exploitation depends on the organization’s template management practices.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade your Go installation to a version that includes the fix referenced at https://go.dev/cl/840925
  • Audit all existing html/template files for unescaped use of the word ‘yield’ and escape or remove it if it is literal text
  • If an immediate upgrade is not possible, employ a temporary bypass by wrapping the literal word ‘yield’ in a no‑op placeholder or by redefining it in the template environment so it is not parsed as a keyword

Generated by OpenCVE AI on October 9, 2026 at 01:22 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Weaknesses CWE-79
Metrics cvssV3_1

{'score': 6.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N'}

ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Weaknesses CWE-74
Type Values Removed Values Added
First Time appeared Go Standard Library
Go Standard Library html/template
Vendors & Products Go Standard Library
Go Standard Library html/template
Type Values Removed Values Added
Description A trusted template author may have previously written a valid template wherein the use of the 'yield' keyword would not be correctly escaped. We now ensure that valid keyword uses are escaped and non-keyword uses are not escaped.
Title Recognize yield as regexp preceder keyword in html/template
References
Weaknesses
  • CWE-74

    Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')

  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

Sources

Status
PUBLISHED
Assigner
Go
Published
Updated
Oct 15, 2026, 3:30 PM
Reserved
Sep 23, 2026, 11:03 PM
Status
Awaiting Analysis
Published
Oct 8, 2026, 11:17 PM
Modified
Oct 15, 2026, 4:18 PM