Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

github логотип

GHSA-4fh9-h7wg-q85m

Опубликовано: 02 дек. 2025
Источник: github
Github: Прошло ревью
CVSS4: 6.9
CVSS3: 5.3

Описание

mdast-util-to-hast has unsanitized class attribute

Impact

Multiple (unprefixed) classnames could be added in markdown source by using character references. This could make rendered user supplied markdown code elements appear like the rest of the page. The following markdown:

```js xss ```

Would create <pre><code class="language-js xss"></code></pre> If your page then applied .xss classes (or listeners in JS), those apply to this element. For more info see https://github.com/ChALkeR/notes/blob/master/Improper-markup-sanitization.md#unsanitized-class-attribute

Patches

The bug was patched. When using regular semver, run npm install. For exact ranges, make sure to use 13.2.1.

Workarounds

Update.

References

Пакеты

Наименование

mdast-util-to-hast

npm
Затронутые версииВерсия исправления

>= 13.0.0, < 13.2.1

13.2.1

EPSS

Процентиль: 22%
0.00073
Низкий

6.9 Medium

CVSS4

5.3 Medium

CVSS3

Дефекты

CWE-20
CWE-915

Связанные уязвимости

nvd
2 месяца назад

mdast-util-to-hast is an mdast utility to transform to hast. From 13.0.0 to before 13.2.1, multiple (unprefixed) classnames could be added in markdown source by using character references. This could make rendered user supplied markdown code elements appear like the rest of the page. This vulnerability is fixed in 13.2.1.

EPSS

Процентиль: 22%
0.00073
Низкий

6.9 Medium

CVSS4

5.3 Medium

CVSS3

Дефекты

CWE-20
CWE-915