CVE-2021-26539
MEDIUM 5.3CVSS 3.1Improper Input Validation in sanitize-html
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.
- Published
- 8 Feb 2021
- Last modified
- 17 Jun 2026
- Assigned by
- cve@mitre.org
- NVD status
- Modified
- Weakness
- CWE-20
- Also known as
- GHSA-rjqq-98f6-6j3r
- Sources
- NVDJSONOSV GHSA-rjqq-98f6-6j3rJSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | MEDIUM 5.3 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N |
| OSV | GitHub | CVSS 3.1 | MEDIUM 5.3 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | MEDIUM 5.0 | AV:N/AC:L/Au:N/C:N/I:P/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | apostrophecms | sanitize-htmlcpe:2.3:a:apostrophecms:sanitize-html:*:*:*:*:*:node.js:*:* |
< 2.3.1 | 2.3.1 |
| OSV | npm | sanitize-html | < 2.3.1 | 2.3.1 |
References
- https://advisory.checkmarx.net/advisory/CX-2021-4308 · Exploit, Third Party Advisory, WEB
- https://github.com/apostrophecms/sanitize-html/blob/main/CHANGELOG.md#231-2021-01-22 · Release Notes, Third Party Advisory, WEB
- https://github.com/apostrophecms/sanitize-html/pull/458 · Patch, Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2021-26539 · ADVISORY
- https://github.com/apostrophecms/sanitize-html/commit/bdf7836ef8f0e5b21f9a1aab0623ae8fcd09c1da · WEB
- https://github.com/apostrophecms/sanitize-html · PACKAGE
History
- 25 Nov 2026 20:32 UTC · NVD: first stored (published 8 Feb 2021)
- 25 Nov 2026 20:11 UTC · OSV: first stored (published 6 May 2021)