GO-2026-4980
Escaper bypass leads to XSS in html/template
At a glance
- Published
- Updated
- CVE
- CVE-2026-39826
- Aliases
- BIT-golang-2026-39826
Description
If a trusted template author were to write a <script> tag containing an empty 'type' attribute or a 'type' attribute with an ASCII whitespace, the execution of the template would incorrectly escape any data passed into the <script> block.
Affected packages
| Package | Versions |
|---|---|
| Go · stdlib | introduced 0, fixed 1.25.10, introduced 1.26.0-0, fixed 1.26.3 |
References
- https://go.dev/issue/78981 REPORT
- https://go.dev/cl/771180 FIX
- https://groups.google.com/g/golang-announce/c/qcCIEXso47M WEB
Sources
| Source | Licence |
|---|---|
| OSV.dev | CC-BY 4.0 — Go Vulnerability Database |