CVE-2023-39319

Improper handling of special tags within script contexts in html/template

State
Published
Severity
Not scored
Published
Sep 8, 2023
Updated
Feb 13, 2025
Reserved
Jul 27, 2023

Read the record on cve.org

Description

The html/template package does not apply the proper rules for handling occurrences of "<script", "<!--", and "</script" within JS literals in <script> contexts. This may cause the template parser to improperly consider script contexts to be terminated early, causing actions to be improperly escaped. This could be leveraged to perform an XSS attack.

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
html/templateGo standard library
  • before 1.20.8Affected
  • 1.21.0-0 to before 1.21.1Affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.