Live threats

All CVEs / Golang

CVE-2026-27142Golang Go

Cross-Site Scripting (XSS) in HTML meta tag content attribute in Go

Medium 6.1 No auth needed

Priority
52
CVSS 3.1
6.1
EPSS
—
Auth required
No
Published
Mar 6, 2026
Updated
Jun 17, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-79
SSVC (CISA)
Exploitation: none · Automatable: no · Technical impact: partial
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

What happens

Actions that insert URLs into the content attribute of HTML meta tags are not properly escaped, allowing XSS when the meta tag has an http-equiv attribute set to "refresh". Affects Go versions before 1.25.8 and 1.26.0. A new GODEBUG setting has been added to control this behavior.

Show the original NVD text

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.

Source text, unmodified. NVD.

What to do

Patch available · fixed versions: 1.25.8, 1.26.1

Update Go to version 1.25.8 or later (1.26.1 or higher for the 1.26 branch). As a temporary mitigation, you can set GODEBUG=htmlmetacontenturlescape=0.

Vendor advisory · pkg.go.dev ↗

  1. Apply the vendor's security update for Go.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
Go stdlib < 1.25.8 1.25.8 go get stdlib@v1.25.8
Go stdlib ≥ 1.26.0-0 < 1.26.1 1.26.1 go get stdlib@v1.26.1

Per OSV / GitHub Advisories (GO-2026-4603). Check the version in your lockfile before upgrading.

Affected products (CPE)

VendorProductVersions
golanggo< 1.25.8
golanggo1.26.0

Official advisories

Also: SUSE (+19)

Vendor, CERT and distribution advisories that name this CVE. Original titles.

On social media

1 person and 1 post on Bluesky in the last 30 days.

Most recent posts, without bots or automated feeds. The text belongs to its authors. Search on Bluesky

Official sources

References

Links published by the sources. Open them with care.