CVE-2026-27120
published medium CVSS 3.1 · 6.1Leaf-kit html escaping does not work on characters that are part of extended grapheme cluster
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| vapor | — | leaf-kit< 1.4.1 | Affected | Not stated | GitHub_M |
Description
Leafkit is a templating language with Swift-inspired syntax. Prior to 1.4.1, htmlEscaped in leaf-kit will only escape html special characters if the extended grapheme clusters match, which allows bypassing escaping by using an extended grapheme cluster containing both the special html character and some additional characters. In the case of html attributes, this can lead to XSS if there is a leaf variable in the attribute that is user controlled. This vulnerability is fixed in 1.4.1.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 3.1
- Base score
- 6.1 / 10
- Severity
- medium
- Provider
- GitHub_M · cna
- Vector string
- CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| vapor | leaf-kit | < 1.4.1 (affected) | GitHub_M · cna |
Weaknesses
3- CWE-75 CWE-75: Failure to Sanitize Special Elements into a Different Plane (Special Element Injection)
- CWE-79 CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
- CWE-87 CWE-87: Improper Neutralization of Alternate XSS Syntax
References
2Provider assertions
2GitHub_M · cna
Leaf-kit html escaping does not work on characters that are part of extended grapheme cluster
CISA-ADP · adp
CISA ADP Vulnrichment
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 6218a213aaeab96175ffc371f45716154c7ca14a4eb94e042b256a9cb41f438c
- Ingested
- 23 Sep 2026, 09:07:24 UTC
- Source record
- Official CVE record