Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAttacker supplies malicious data with event handler property
-
DeliveryApplication spreads data as element attributes
-
ExploitVulnerable Svelte version renders event handler in HTML output
-
ExecutionVictim's browser parses malicious HTML attribute
-
PersistVictim interacts with element before hydration
-
ImpactInjected event handler executes with victim's privileges
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | The vulnerability triggers only under all of the following conditions: (1) the application uses Svelte spread syntax ({...data}) to bind attributes to HTML elements, (2) the spread data source is untrusted or user-controlled (e.g., from a user input, external API, database, or URL parameter), (3) the victim's browser has JavaScript enabled, and (4) Svelte's hydration mechanism does not process the vulnerable element before a user interaction triggers the injected event handler. The window of vulnerability is narrow-it exists only during the time between when the browser parses the malicious HTML and when Svelte hydration attaches event listeners to the element. Applications that (a) only spread explicitly whitelisted internal properties, (b) validate and sanitize all external data before spreading, or (c) use normal attribute binding instead of spread syntax for dynamic attributes are not affected. Partial hydration strategies or components with deferred hydration create a wider exploitation window. |
| Impact | This vulnerability requires specific deployment and usage conditions to trigger: the application must use spread syntax with untrusted data, JavaScript must be enabled in the victim's browser, and Svelte's hydration mechanism must fail to process the element before the injected event fires. The CVSS vector is not provided, limiting standard risk quantification; however, the attack vector is clearly network-based (HTTP-delivered malicious data), privilege requirement is none (unauthenticated attacker can supply data), and user interaction is implicit (victim must trigger the injected event, such as by hovering or clicking). The CWE-79 classification confirms this as XSS. Real-world risk depends heavily on how the application implements spread syntax and whether hydration is reliably applied; applications that hydrate all dynamic elements immediately or avoid spreading untrusted data directly face lower risk. The condition that hydration must not reach the element creates a window of vulnerability that exists primarily in race conditions or partial hydration scenarios. No EPSS, KEV, or POC data is provided, so the current exploitation status cannot be confirmed; however, the detailed nature of the vulnerability description and the existence of a fix commit suggest this represents a genuine code-path vulnerability rather than a theoretical issue. |
| Exploit ScenarioDerived | An attacker controls or injects data that becomes an application object spread as element attributes-for example, via a user profile field, API response, or URL parameter. The malicious object contains an event handler property like onclick with a payload: {onclick: 'alert(document.cookie)'}. When the Svelte component renders this on the server, the vulnerable code includes the event handler in the HTML output as a literal attribute: <div onclick='alert(document.cookie)'>. The victim's browser receives this HTML. If Svelte's hydration has not yet attached to this element when the victim hovers or clicks it, the injected event handler executes in the victim's browser context, allowing JavaScript execution such as session theft or malware delivery. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 14, 2026
Cross-site scripting in Svelte versions up to 5.55.6 allows remote attackers to inject malicious event handlers via spread syntax when rendering untrusted data as element attributes. The vulnerability executes in victims' browsers only when JavaScript is enabled and Svelte's hydration mechanism does not process the vulnerable element before the injected event fires. Vendor-released patch: version 5.55.7.
RemediationAI
Upgrade Svelte to version 5.55.7 or later immediately. The patched version moves Svelte runtime properties to symbols, preventing them from being included in spread attribute output, and hardens attribute handling during SSR. Organizations unable to upgrade immediately should avoid using spread syntax ({...data}) with untrusted data sources as element attributes; instead, explicitly bind known-safe attributes using normal attribute binding syntax, or pre-validate and sanitize external data before spreading. Ensure all dynamic components are hydrated early in the page load before user interactions can trigger injected events. Review any server-side templates or components that use spread syntax to identify and remediate patterns that accept external or user-controlled data.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in npm
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Svelte is a JavaScript framework that compiles components to vanilla JavaScript at build time. The vulnerability exists in Svelte's server-side rendering (SSR) layer when using spread syntax ({...data}) to apply user-controlled or external data as HTML element attributes. Unlike traditional frameworks that handle attribute binding at runtime, Svelte's compilation process should sanitize spread attributes to prevent event handler properties (such as onclick, onmouseover) from being rendered as literal HTML attributes. The underlying issue is classified as CWE-79 (Improper Neutralization of Input During Web Page Generation), a cross-site scripting flaw. The affected component npm/svelte <= 5.55.6 fails to neutralize event handler properties during SSR, allowing them to pass through as rendered HTML. The fix moves Svelte runtime properties to symbols and hardens the handling of spread attributes, preventing event handler injection during the hydration process.
Know when the next one hits your stack
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:H/AT:P/PR:H/UI:N/VC:N/VI:N/VA:N/SC:H/SI:H/SA:N
Primary rating from Vendor (https://github.com/sveltejs/svelte).
CVSS VectorVendor: https://github.com/sveltejs/svelte
Lifecycle Timeline
2DescriptionCVE.org
When using spread syntax to render attributes from untrusted data, event handler properties are included in the rendered HTML output. If an application spreads user-controlled or external data as element attributes, an attacker can inject malicious event handlers that execute in victims' browsers. Note that this vulnerability _only_ triggers if the user's browser has JavaScript enabled but Svelte's hydration mechanism does not reach the vulnerable element before the event fires.
This is similar to but different from CVE-2026-27121.
Blast Radius
ecosystem impact- 11 npm packages depend on svelte (7 direct, 4 indirect)
Ecosystem-wide dependent count for version 5.55.7.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
EUVD-2026-35703
GHSA-pr6f-5x2q-rwfp
NVD
CVE.org
EPSS
VulDB
Exploit-DB