Meet Corgea at Black Hat, BSides Las Vegas & DEF CON
MEDIUM 4.2 npm

tarteaucitron.js vulnerable to DOM Clobbering via document.currentScript

GHSA-q43x-79jr-cq98 · CVE-2025-48939

Published · Modified

Description

A vulnerability was identified in tarteaucitron.js where document.currentScript was accessed without verifying that it referenced an actual <script> element. If an attacker injected an HTML element such as:

<img name="currentScript" src="https://malicious.example.com">

it could clobber the document.currentScript property. This causes the script to resolve incorrectly to an element instead of the