Vulnerability · Published Mar 6, 2026 · Assigned by Go

CVE-2026-27142URLs in meta content attribute actions are not escaped in html/template

Medium 6.1

In plain English

A medium-severity security flaw in html/template from Go standard library. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 32% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)6.1Medium
Exploit odds (30 days)0.4%top 68.5% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

Actions which insert URLs into the content attribute of HTML meta tags are not escaped. This can allow XSS if the meta tag also has an http-equiv attribute with the value "refresh". A new GODEBUG setting has been added, htmlmetacontenturlescape, which can be used to disable escaping URLs in actions in the meta content attribute which follow "url=" by setting htmlmetacontenturlescape=0.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Alpine:v3.23go1.25.8-r0ALPINE-CVE-2026-27142
Alpine:v3.24go1.25.8-r0ALPINE-CVE-2026-27142
Alpine:v3.24rclone1.73.5-r0ALPINE-CVE-2026-27142
Debian:12golang-1.19no fix listedDEBIAN-CVE-2026-27142
Debian:13golang-1.24no fix listedDEBIAN-CVE-2026-27142
Debian:14golang-1.261.26.1-1DEBIAN-CVE-2026-27142
Gostdlib1.25.8, 1.26.1GO-2026-4603
Ubuntu:22.04:LTSgolang-1.24no fix listedUBUNTU-CVE-2026-27142
Ubuntu:24.04:LTSgolang-1.24no fix listedUBUNTU-CVE-2026-27142
Ubuntu:25.10golang-1.24no fix listedUBUNTU-CVE-2026-27142
Ubuntu:26.04:LTSgolang-1.24no fix listedUBUNTU-CVE-2026-27142
Ubuntu:22.04:LTSgolang-1.25no fix listedUBUNTU-CVE-2026-27142
Ubuntu:24.04:LTSgolang-1.25no fix listedUBUNTU-CVE-2026-27142
Ubuntu:25.10golang-1.25no fix listedUBUNTU-CVE-2026-27142
Ubuntu:26.04:LTSgolang-1.25no fix listedUBUNTU-CVE-2026-27142
Ubuntu:22.04:LTSgolang-1.26no fix listedUBUNTU-CVE-2026-27142
Ubuntu:24.04:LTSgolang-1.26no fix listedUBUNTU-CVE-2026-27142
Ubuntu:26.04:LTSgolang-1.26no fix listedUBUNTU-CVE-2026-27142
Ubuntu:26.10golang-1.26no fix listedUBUNTU-CVE-2026-27142

Affected products (as reported)

VendorProductVersions
Go standard library html/template 0 – before 1.25.81.26.0-0 – before 1.26.1

References