Vulnerabilities/

@mattkrick/sanitize-svg vulnerable to Cross-Site Scripting (XSS)

Severity:
High

Description

The sanitize-svg package uses a deny-list-pattern to sanitize SVGs to prevent cross-site scripting (XSS). In doing so, literal <script>-tags and on-event handlers were detected:

There are more ways to embed JavaScript in XML files.

Recommendation

Update the @mattkrick/sanitize-svg package to the latest compatible version. Followings are version details:

References

Related Issues

Tags:
npm
@mattkrick/sanitize-svg
Anything's wrong? Let us know Last updated on January 29, 2023