HTML templates containing Javascript template strings are subject to XSS in jte
jte (Java Template Engine) is a secure and lightweight template engine for Java and Kotlin. In affected versions Jte HTML templates with `script` tags or script attributes that include a Javascript template string (backticks) are subject to XSS. The `javaScriptBlock` and `javaScriptAttribute` methods in the `Escape` class do not escape backticks, which are used for Javascript template strings. Dollar signs in template strings should also be escaped as well to prevent undesired interpolation. HTML templates rendered by Jte's `OwaspHtmlTemplateOutput` in versions less than or equal to `3.1.15` with `script` tags or script attributes that contain Javascript template strings (backticks) are vulnerable. Users are advised to upgrade to version 3.1.16 or later to resolve this issue. There are no known workarounds for this vulnerability.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2025-23026
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 4 Nov 2026, 01:41 UTC · Revision 1
Source evidence
HTML templates containing Javascript template strings are subject to XSS in jte
core-osv · Original sourcePublished 13 Jan 2025, 19:36 UTC
jte (Java Template Engine) is a secure and lightweight template engine for Java and Kotlin. In affected versions Jte HTML templates with `script` tags or script attributes that include a Javascript template string (backticks) are subject to XSS. The `javaScriptBlock` and `javaScriptAttribute` methods in the `Escape` class do not escape backticks, which are used for Javascript template strings. Dollar signs in template strings should also be escaped as well to prevent undesired interpolation. HTML templates rendered by Jte's `OwaspHtmlTemplateOutput` in versions less than or equal to `3.1.15` with `script` tags or script attributes that contain Javascript template strings (backticks) are vulnerable. Users are advised to upgrade to version 3.1.16 or later to resolve this issue. There are no known workarounds for this vulnerability.
osv:CVE-2025-23026
Complete source record
{
"id": "a9735b058a2688d0d9c053e080f3e90c4d91549c9144d811106e3b540287f07d",
"url": "https://osv.dev/vulnerability/CVE-2025-23026",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "HTML templates containing Javascript template strings are subject to XSS in jte",
"summary": "jte (Java Template Engine) is a secure and lightweight template engine for Java and Kotlin. In affected versions Jte HTML templates with `script` tags or script attributes that include a Javascript template string (backticks) are subject to XSS. The `javaScriptBlock` and `javaScriptAttribute` methods in the `Escape` class do not escape backticks, which are used for Javascript template strings. Dollar signs in template strings should also be escaped as well to prevent undesired interpolation. HTML templates rendered by Jte's `OwaspHtmlTemplateOutput` in versions less than or equal to `3.1.15` with `script` tags or script attributes that contain Javascript template strings (backticks) are vulnerable. Users are advised to upgrade to version 3.1.16 or later to resolve this issue. There are no known workarounds for this vulnerability.",
"evidence": "osv:CVE-2025-23026",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2025-23026",
"aliases": [
"CVE-2025-23026",
"GHSA-vh22-6c6h-rm8q"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/casid/jte",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "d50dce8119b7a50bfb6fa1b8d655f74251d313f9"
}
],
"database_specific": {
"extracted_events": [
{
"range": [
{
"introduced": "0"
},
{
"fixed": "3.1.16"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StringRangeExpression"
}
]
}
}
],
"versions": [
"3.1.15",
"3.1.14",
"3.1.13",
"3.1.12",
"3.1.11",
"3.1.10",
"3.1.9",
"3.1.8",
"3.1.7",
"3.1.6",
"3.1.5",
"3.1.4",
"3.1.3",
"3.1.2",
"3.1.1",
"3.1.0",
"3.0.3",
"3.0.2",
"3.0.1",
"3.0.0",
"2.3.2",
"2.3.1",
"2.3.0",
"2.2.6",
"2.2.4",
"2.2.3",
"2.2.2",
"2.2.1",
"2.2.0",
"2.1.2",
"2.1.1",
"2.1.0",
"2.0.4",
"2.0.3",
"2.0.2",
"2.0.1",
"2.0.0",
"1.12.1",
"1.12.0",
"1.11.4",
"1.11.3",
"1.11.2",
"1.11.1",
"1.11.0",
"1.10.0",
"1.9.0",
"1.8.0",
"1.7.0",
"1.6.0",
"1.5.2",
"1.5.1",
"1.5.0",
"1.4.0",
"1.3.0",
"1.2.0",
"1.1.0",
"1.0.0",
"0.8.0",
"0.7.0",
"0.6.0",
"0.5.0",
"0.4.0",
"0.3.0",
"0.2.0",
"0.1.1"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-23026.json"
}
}
],
"modified": "2026-10-28T02:30:32.328586480Z",
"provider": "osv",
"references": [
"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#description",
"https://github.com/casid/jte/blob/main/jte-runtime/src/main/java/gg/jte/html/escape/Escape.java#L43-L83",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/23xxx/CVE-2025-23026.json",
"https://github.com/casid/jte/security/advisories/GHSA-vh22-6c6h-rm8q",
"https://nvd.nist.gov/vuln/detail/CVE-2025-23026"
],
"provider_metadata": {
"cwe_ids": [
"CWE-150",
"CWE-79"
],
"cna_assigner": "GitHub_M",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/23xxx/CVE-2025-23026.json"
}
},
"related_cves": [
{
"value": "CVE-2025-23026",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 499472,
"published_at": "2025-01-13T19:36:03.286+00:00"
}