{"id":"CVE-2025-15265","aliases":["CVE-2025-15265","GHSA-6738-r8g5-qwp3"],"related":[],"kind":"vulnerability","state":"published","title":"Svelte 5.46.0  - Hydratable Key Script-Breakout XSS (SSR)","summary":"An SSR XSS exists in async hydration when attacker‑controlled keys are passed to hydratable. The key is embedded inside a <script> block without HTML‑safe escaping, allowing </script> to terminate the script and inject arbitrary JavaScript. This enables remote script execution in users' browsers, with potential for session theft and account compromise.\nThis issue affects Svelte: from 5.46.0 before 5.46.3.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"An SSR XSS exists in async hydration when attacker‑controlled keys are passed to hydratable. The key is embedded inside a <script> block without HTML‑safe escaping, allowing </script> to terminate the script and inject arbitrary JavaScript. This enables remote script execution in users' browsers, with potential for session theft and account compromise.\nThis issue affects Svelte: from 5.46.0 before 5.46.3.","source":"cvelist"},{"lang":"en","text":"## Summary\n\nAn XSS vulnerability exists in Svelte 5.46.0-2 resulting from improper escaping of `hydratable` keys. If these keys incorporate untrusted user input, arbitrary JavaScript can be injected into server-rendered HTML.\n\n## Details\n\nWhen using the [`hydratable`](https://svelte.dev/docs/svelte/hydratable) function, the first argument is used as a key to uniquely identify the data, such that the value is not regenerated in the browser.\n\nThis key is embedded into a `<script>` block in the server-rendered `<head>` without escaping unsafe characters. A malicious key can break out of the script context and inject arbitrary JavaScript into the HTML response.\n\n## Impact\n\nThis is a cross-site scripting vulnerability affecting applications that have the `experimental.async` flag enabled and use `hydratable` with keys incorporating untrusted user input. \n\n- **Impact**: Arbitrary JS execution in the client’s browser.\n- **Exploitability**: Remote, single-request if key is attacker-controlled.\n- **Typical Outcomes**:\n  - Session/token theft\n  - DOM defacement\n  - CSRF bypass via injected JS\n  - Account takeover depending on cookie/session strategy\n\nAffected applications should upgrade to a patched version immediately.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Existe una vulnerabilidad de tipo SSR XSS en la hidratación asíncrona cuando se pasan claves controladas por el atacante a `hydratable`. La clave se incrusta dentro de un bloque `` termine el script e inyecte código JavaScript arbitrario. Esto permite la ejecución remota de scripts en los navegadores de los usuarios, con el riesgo de robo de sesión y compromiso de la cuenta. Este problema afecta a Svelte: desde la versión 5.46.0 hasta la 5.46.3.","source":"nvd"}],"published":"2026-01-15T19:59:41.683Z","modified":"2026-06-17T08:37:29.597Z","severity":{"scorer":"Fluid Attacks","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","score":5.3,"rating":"MEDIUM"},"severities":[{"scorer":"Fluid Attacks","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","score":5.3,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","score":6.1,"rating":"MEDIUM"}],"cwes":["CWE-79"],"affected":[{"ranges":[{"type":"custom","introduced":"5.46.0","fixed":"5.46.3","status":"affected"}],"vendor":"Svelte","product":"Svelte","package":"svelte","platforms":["Windows","Linux","MacOS"],"source":"cvelist"},{"ranges":[{"type":"semver","introduced":"5.46.0","status":"affected","fixed":"5.46.4"}],"ecosystem":"npm","package":"svelte","purl":"pkg:npm/svelte","source":"ghsa"},{"ranges":[{"status":"affected","introduced":"5.46.0","fixed":"5.46.3"}],"vendor":"svelte","product":"svelte","cpe":"cpe:2.3:a:svelte:svelte:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://fluidattacks.com/advisories/lydian","tags":["exploit","patch","third-party-advisory","web"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/sveltejs/svelte/security/advisories/GHSA-6738-r8g5-qwp3","tags":["third-party-advisory","vendor-advisory","web"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-15265","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/sveltejs/svelte/commit/ef81048e238844b729942441541d6dcfe6c8ccca","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/sveltejs/svelte","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/sveltejs/svelte/releases/tag/svelte%405.46.4","tags":["web"],"sources":["ghsa"]}],"credits":["Camilo Vera"],"assigner":"Fluid Attacks","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"no","technicalImpact":"partial","date":"2026-01-15T20:28:05.329Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-15265","url":"https://www.cve.org/CVERecord?id=CVE-2025-15265","licence":"CVE Terms of Use","modified":"2026-01-15T20:28:16.479Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-6738-r8g5-qwp3","url":"https://github.com/advisories/GHSA-6738-r8g5-qwp3","licence":"CC-BY-4.0","modified":"2026-02-03T03:17:21.713Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-15265","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-15265","licence":"Public domain","modified":"2026-06-17T08:37:29.597Z"}],"updatedAt":"2026-11-25T22:59:10.652Z","epss":{"score":0.00346,"percentile":0.30129,"date":"2026-12-01T12:00:22.000Z"}}