{"id":"EUVD-2026-28790","revision":null,"records":[{"revision":"a700e1809dfc45c7b9d53c8c6fcfa70a","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-41591","aliases":[],"title":"Marko: XSS via case-insensitive script/style closing tag bypass in runtime HTML escaping","description":"Marko is a declarative, HTML-based language for building web apps. Prior to marko version 5.38.36 and prior to @marko/runtime-tags 6.0.164, when dynamic text is interpolated into a <script> or <style> tag the Marko runtime failed to prevent tag breakout when the closing tag used non-lowercase casing. An attacker able to place input inside a <script> or <style> block could break out of the tag with </SCRIPT>, </Style>, etc. and inject arbitrary HTML/JavaScript, resulting in cross-site scripting. This issue has been patched in marko version 5.38.36 and @marko/runtime-tags 6.0.164.","state":0,"publishedAt":"2026-05-08T15:22:50.99+00:00","modifiedAt":"2026-05-08T21:26:58.356+00:00","affected":[{"ecosystem":"Vendor product","name":"marko","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"marko-js\",\n                    \"product\": \"marko\",\n                    \"versions\": [\n                        {\n                            \"version\": \"marko < 5.38.36\",\n                            \"status\": \"affected\"\n                        },\n                        {\n                            \"version\": \"@marko/runtime-tags < 6.0.164\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N","score":6.4,"severity":"MEDIUM"}],"references":["https://github.com/marko-js/marko/security/advisories/GHSA-x9fj-57fh-c8wq"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-41591","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-41591","identifiers":["CVE-2026-41591"]},"retained":false,"historicalAffected":[]},{"revision":"327710a1834141eaad785fca2a6f4e9c","observedAt":"2026-11-19T13:46:25.904+00:00","statement":{"source":"euvd","id":"EUVD-2026-28790","aliases":["CVE-2026-41591","GHSA-x9fj-57fh-c8wq"],"title":"Marko is a declarative, HTML-based language for building web apps. Prior to marko version 5.38.36 and prior to @marko/runtime-tags 6.0.164, when dynamic text is interpolated into a <script> or <style> tag the Marko runtime failed to prevent…","description":"Marko is a declarative, HTML-based language for building web apps. Prior to marko version 5.38.36 and prior to @marko/runtime-tags 6.0.164, when dynamic text is interpolated into a <script> or <style> tag the Marko runtime failed to prevent tag breakout when the closing tag used non-lowercase casing. An attacker able to place input inside a <script> or <style> block could break out of the tag with </SCRIPT>, </Style>, etc. and inject arbitrary HTML/JavaScript, resulting in cross-site scripting. This issue has been patched in marko version 5.38.36 and @marko/runtime-tags 6.0.164.","state":0,"publishedAt":null,"modifiedAt":null,"affected":[],"metrics":[{"system":"EUVD CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N","score":6.4,"severity":null}],"references":["https://github.com/marko-js/marko/security/advisories/GHSA-x9fj-57fh-c8wq"],"sourceUrl":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2026-28790","license":"ENISA EUVD · source terms and attribution apply","enrichment":{"sourceStatus":null,"weaknesses":[],"productCriteria":[],"sourceDates":{"datePublished":"May 8, 2026, 3:22:50 PM","dateUpdated":"May 8, 2026, 9:26:58 PM"},"relatedAdvisories":[],"note":"EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON."},"key":"euvd:EUVD-2026-28790","identifiers":["EUVD-2026-28790","CVE-2026-41591","GHSA-x9fj-57fh-c8wq"]},"retained":false,"historicalAffected":[]},{"revision":"90e0644daf46445c846161c3437649d8","observedAt":"2026-10-25T09:17:41.905+00:00","statement":{"source":"nvd","id":"CVE-2026-41591","aliases":[],"title":"Marko is a declarative, HTML-based language for building web apps. Prior to marko version 5.38.36 and prior to @marko/runtime-tags 6.0.164, when dynamic text is interpolated into a <script> or <style> tag the Marko runtime failed to prevent…","description":"Marko is a declarative, HTML-based language for building web apps. Prior to marko version 5.38.36 and prior to @marko/runtime-tags 6.0.164, when dynamic text is interpolated into a <script> or <style> tag the Marko runtime failed to prevent tag breakout when the closing tag used non-lowercase casing. An attacker able to place input inside a <script> or <style> block could break out of the tag with </SCRIPT>, </Style>, etc. and inject arbitrary HTML/JavaScript, resulting in cross-site scripting. This issue has been patched in marko version 5.38.36 and @marko/runtime-tags 6.0.164.","state":0,"publishedAt":"2026-05-08T16:16:11.167+00:00","modifiedAt":"2026-08-26T19:16:01.883+00:00","affected":[],"metrics":[{"system":"CVSS 3.1 · security-advisories@github.com · Secondary","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N","score":6.4,"severity":"MEDIUM"}],"references":["https://github.com/marko-js/marko/security/advisories/GHSA-x9fj-57fh-c8wq"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-41591","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Analyzed","weaknesses":["CWE-79"],"productCriteria":["cpe:2.3:a:openjsf:marko:*:*:*:*:*:node.js:*:*","cpe:2.3:a:openjsf:marko\\/runtime-tags:*:*:*:*:*:node.js:*:*"],"sourceDates":{"published":"2026-05-08T16:16:11.167","lastModified":"2026-08-26T19:16:01.883"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2026-41591","identifiers":["CVE-2026-41591"]},"retained":false,"historicalAffected":[]},{"revision":"d8026aaf09eb4e60b0dccdd95217c42e","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-x9fj-57fh-c8wq","aliases":["CVE-2026-41591"],"title":"Marko: XSS via case-insensitive script/style closing tag bypass in runtime HTML escaping","description":"### Summary\n\nWhen dynamic text is interpolated into a `<script>` or `<style>` tag the Marko runtime failed to prevent tag breakout when the closing tag used non-lowercase casing.\nAn attacker able to place input inside a `<script>` or `<style>` block could break out of the tag with `</SCRIPT>`, `</Style>`, etc. and inject arbitrary HTML/JavaScript, resulting in cross-site scripting.\n\n### Details\n\nThe affected helpers used case-sensitive regular expressions to detect attempts at closing the surrounding tag:\n\n```js\n// packages/runtime-tags/src/html/content.ts\nconst unsafeScriptReg = /<\\/script/g;\nconst unsafeStyleReg  = /<\\/style/g;\n\n// packages/runtime-class/src/runtime/html/helpers/escape-script-placeholder.js\nconst unsafeCharsReg = /<\\/script/g;\n\n// packages/runtime-class/src/runtime/html/helpers/escape-style-placeholder.js\nconst unsafeCharsReg = /<\\/style/g;\n```\n\nHTML tag names are case-insensitive in the browser parser, so inputs such as `</SCRIPT>`, `</Script>`, or `</sTyLe>` were not matched by these regexes and passed through the helpers unchanged. A browser rendering the output treats the mixed-case end tag as a valid closing tag, terminating the script or style context, and then parses anything that follows as HTML.\n\nThe Marko compiler routes interpolated values inside `<script>` and `<style>` tags through these helpers automatically (see `native-tag.ts:1080-1085`), so application code following the framework's conventions had no way to detect or compensate for the gap.\n\n### PoC\n\n```marko\n$ const userCode = \"</SCRIPT><script>alert(1)//\";\n<script>\n  const data = ${JSON.stringify(userCode)};\n</script>\n```\n\nWould yield the following:\n\n```html\n<script>const data = \"</SCRIPT><script>alert(1)//\";</script>\n```\n\nWhich is then parsed in any WHATWG-compliant browser as:\n```html\n<script>const data = \"</script>\n<script>alert(1)//\";</script>\n```\n\n### Impact\n\nCross-site scripting. Any Marko template that explicitly interpolates untrusted data inside a `<script>` or `<style>` block is affected.\n\nStored XSS is trivial if the value originates from any persisted user input (username, profile bio, comment body, etc.) that is later embedded in a script tag during rendering. Exploitation yields arbitrary JavaScript execution in the victim's browser, enabling session token theft, account takeover, and arbitrary actions as the victim.\n\nSince the internal `_escape_script` and `_escape_style` helpers are the framework's designated defense against script/style tag breakout, applications following standard Marko patterns had no obvious reason to add a second layer of sanitization.\n\nThis does not affect scripts or hydration state serialized by Marko itself — only templates that explicitly interpolate untrusted values inside a <script> or <style> tag.\n\n### Patch\n\nCommit `19d4b37d0` — `fix: html script, style, and comment escaping`.\n\n```diff\n- const unsafeScriptReg = /<\\/script/g;\n+ const unsafeScriptReg = /<\\/script/gi;\n\n- const unsafeStyleReg  = /<\\/style/g;\n+ const unsafeStyleReg  = /<\\/style/gi;\n```\n\nThe same commit also introduced an `_escape_comment` helper and corresponding `escape-comment-placeholder.js`, hardening HTML comment escaping as a related preventative fix. Test fixtures were added under `escape-script-case`, `escape-style-case`, and `escape-comment`.\n\n### Workarounds\n\nUpgrade to the patched release. As a short-term mitigation on affected versions, pre-sanitize any untrusted data before it reaches a template position rendered inside a `<script>` or `<style>` tag — e.g. normalize `</script`, `</style`, and their mixed-case variants before interpolation, or avoid direct interpolation of untrusted values inside these tags entirely.","state":0,"publishedAt":"2026-04-22T19:55:51+00:00","modifiedAt":"2026-05-13T13:54:56.772894+00:00","affected":[{"ecosystem":"npm","name":"marko","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"5.38.36"}]}],"versions":[],"rawVersionEvidence":null},{"ecosystem":"npm","name":"@marko/runtime-tags","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"6.0.164"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"MODERATE"}],"references":["https://github.com/marko-js/marko/security/advisories/GHSA-x9fj-57fh-c8wq","https://nvd.nist.gov/vuln/detail/CVE-2026-41591","https://github.com/marko-js/marko"],"sourceUrl":"https://github.com/advisories/GHSA-x9fj-57fh-c8wq","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-x9fj-57fh-c8wq","identifiers":["GHSA-x9fj-57fh-c8wq","CVE-2026-41591"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-20T19:47:57.5341112+00:00","complete":true,"records":1790,"lastAttemptAt":"2026-11-20T19:47:57.5341112+00:00","lastSuccessAt":"2026-11-20T19:47:57.714404+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:47:57.7144048+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-ab394367b327976f2e615091908e1dede6760751304792bb06c748f95767cbef-0e5af85070af46394bcc0f3a098980d538393c1617670daddf8422eb30e180de","complete":true,"records":429921,"lastAttemptAt":"2026-11-20T19:46:07.5891826+00:00","lastSuccessAt":"2026-11-20T19:46:07.3989946+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:46:07.5891826+00:00","snapshotPublishedAt":"2026-11-20T19:19:08+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-aef9a964b68f448392343603f4dc1221","complete":false,"records":13914,"lastAttemptAt":"2026-11-20T19:48:32.8902112+00:00","lastSuccessAt":"2026-11-20T19:48:32.884+00:00","error":"68 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-20T19:48:32.884+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13894,"expectedIdentifiers":13962,"failedIdentifiers":68},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-20T19:47:57.5341112+00:00","complete":true,"records":1131,"lastAttemptAt":"2026-11-20T19:47:57.5341112+00:00","lastSuccessAt":"2026-11-20T19:47:57.7151916+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:47:57.7151918+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-f50737edc1594f37a971853d3f362bb6","complete":false,"records":13926,"lastAttemptAt":"2026-11-20T19:48:22.8641394+00:00","lastSuccessAt":"2026-11-20T19:48:22.861+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:48:22.861+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13951,"expectedIdentifiers":13962,"failedIdentifiers":0},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-a479762f093c173daaf94ab78c6e1c5dc2a2542cfb360d0428239181880c03b4","complete":true,"records":9988,"lastAttemptAt":"2026-11-20T19:47:57.3861729+00:00","lastSuccessAt":"2026-11-20T15:48:09.8429817+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:47:57.3861729+00:00","snapshotPublishedAt":"2026-11-20T15:18:25+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-6ba2352decd0c95d34a1b50f642582aa34659ce946f552488f0a5cea4e0cc09a","complete":true,"records":2020,"lastAttemptAt":"2026-11-20T19:46:07.7708255+00:00","lastSuccessAt":"2026-11-20T15:46:15.4249619+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:46:07.7708255+00:00","snapshotPublishedAt":"2026-11-20T14:48:20+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-0d57516b4a7264d7a3e50d41b832d65b6f43cdd6a79ce9e39aca7fd9f0df1b84","complete":true,"records":3208,"lastAttemptAt":"2026-11-20T19:47:57.4946115+00:00","lastSuccessAt":"2026-11-20T18:47:57.1855043+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:47:57.4946115+00:00","snapshotPublishedAt":"2026-11-20T17:03:30+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-28c32e8d3a8d48efdd17f8ce49e80447fc79edabc15f2621032d6012b7260982","complete":true,"records":232838,"lastAttemptAt":"2026-11-20T19:47:57.2562817+00:00","lastSuccessAt":"2026-11-20T19:47:56.1593338+00:00","error":null,"lastVerifiedAt":"2026-11-20T19:47:57.2562817+00:00","snapshotPublishedAt":"2026-11-20T19:33:25+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}