Description
Prism (aka PrismJS) through 1.29.0 allows DOM Clobbering (with resultant XSS for untrusted input that contains HTML but does not directly contain JavaScript), because document.currentScript lookup can be shadowed by attacker-injected HTML elements.
Recommendation
Update the prismjs package to the latest compatible version. Followings are version details:
- Affected version(s): < 1.30.0
- Patched version(s): 1.30.0
References
Could your website be exposed too?
SmartScanner can check your website for PrismJS DOM Clobbering vulnerability and gives you actionable findings to investigate.
Start a free scanRelated Issues
- mavo DOM Clobbering vulnerability - CVE-2024-53388
- Stage.js DOM Clobbering vulnerabilty - CVE-2024-53386
- Webpack's AutoPublicPathRuntimeModule has a DOM Clobbering Gadget that leads to XSS - CVE-2024-43788
- DOM clobbering could escalate to Cross-site Scripting (XSS) - @pagefind/default-ui - CVE-2024-45389


