Skip to content

Improper Input Validation in sanitize-html

Moderate severity GitHub Reviewed Published May 6, 2021 to the GitHub Advisory Database • Updated Apr 21, 2023

Package

npm sanitize-html (npm)

Affected versions

< 2.3.1

Patched versions

2.3.1

Description

Apostrophe Technologies sanitize-html before 2.3.1 does not properly handle internationalized domain name (IDN) which could allow an attacker to bypass hostname whitelist validation set by the "allowedIframeHostnames" option.

References

Published by the National Vulnerability Database Feb 8, 2021
Reviewed Mar 29, 2021
Published to the GitHub Advisory Database May 6, 2021
Last updated Apr 21, 2023

Severity

Moderate
5.3
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
Low
Availability
None
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

Weaknesses

CVE ID

CVE-2021-26539

GHSA ID

GHSA-rjqq-98f6-6j3r

Credits

Checking history
See something to contribute? Suggest improvements for this vulnerability.