CVE-2021-26540
Last modified
CVE-2021-26540 is a medium-severity vulnerability rated 5.3/10 on the CVSS scale. Apostrophe Technologies sanitize-html before 2.3.2 does not properly validate the hostnames set by the "allowedIframeHostnames" option when the "allowIframeRelativeUrls" is set to true, which allows attackers to bypass hostname whitelist for iframe element, related using an src value that starts with "/\\example.com".. EPSS estimates a 1.75% chance of exploitation in the next 30 days.
Description
Apostrophe Technologies sanitize-html before 2.3.2 does not properly validate the hostnames set by the "allowedIframeHostnames" option when the "allowIframeRelativeUrls" is set to true, which allows attackers to bypass hostname whitelist for iframe element, related using an src value that starts with "/\\example.com".
Metrics
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
Affected Software
| Vendor | Product | Versions |
|---|---|---|
| Apostrophecms | Sanitize-Html | < 2.3.2 |
References
- https://advisory.checkmarx.net/advisory/CX-2021-4309Exploit, Patch, Third Party Advisory
- https://github.com/apostrophecms/sanitize-html/blob/main/CHANGELOG.md#232-2021-01-26Release Notes, Third Party Advisory
- https://github.com/apostrophecms/sanitize-html/pull/460Patch, Third Party Advisory
- https://advisory.checkmarx.net/advisory/CX-2021-4309Exploit, Patch, Third Party Advisory
- https://github.com/apostrophecms/sanitize-html/blob/main/CHANGELOG.md#232-2021-01-26Release Notes, Third Party Advisory
- https://github.com/apostrophecms/sanitize-html/pull/460Patch, Third Party Advisory
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2021-26540?
How severe is CVE-2021-26540?
How do I fix CVE-2021-26540?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2021
- CVE-2021-26504Directory Traversal vulnerability in Foddy node-red-contrib-…7.5
- CVE-2021-26505Prototype pollution vulnerability in MrSwitch hello.js versi…9.8
- CVE-2021-26528The mg_http_serve_file function in Cesanta Mongoose HTTP ser…9.1
- CVE-2021-26529The mg_tls_init function in Cesanta Mongoose HTTPS server 7.…9.1
- CVE-2021-26530The mg_tls_init function in Cesanta Mongoose HTTPS server 7.…9.1
- CVE-2021-26539Apostrophe Technologies sanitize-html before 2.3.1 does not …5.3
- CVE-2021-26541The gitlog function in src/index.ts in gitlog before 4.0.4 h…9.8
- CVE-2021-26543The "gitDiff" function in Wayfair git-parse <=1.0.4 has a co…8.8
- CVE-2021-26544Livy server version 0.7.0-incubating (only) is vulnerable to…5.4
- CVE-2021-26549An XSS issue was discovered in SmartFoxServer 2.17.0. Input …5.4
- CVE-2021-26550An issue was discovered in SmartFoxServer 2.17.0. Cleartext …5.5
- CVE-2021-26551An issue was discovered in SmartFoxServer 2.17.0. An attacke…8.8
Are you affected by CVE-2021-26540?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
