CVE-2023-51652
Last modified
CVE-2023-51652 is a medium-severity vulnerability rated 6.1/10 on the CVSS scale. OWASP AntiSamy .NET is a library for performing cleansing of HTML coming from untrusted sources. Prior to version 1.2.0, there is a potential for a mutation cross-site scripting (mXSS) vulnerability in AntiSamy caused by flawed parsing of the HTML being sanitized. EPSS estimates a 0.45% chance of exploitation in the next 30 days.
Description
OWASP AntiSamy .NET is a library for performing cleansing of HTML coming from untrusted sources. Prior to version 1.2.0, there is a potential for a mutation cross-site scripting (mXSS) vulnerability in AntiSamy caused by flawed parsing of the HTML being sanitized. To be subject to this vulnerability the `preserveComments` directive must be enabled in your policy file and also allow for certain tags at the same time. As a result, certain crafty inputs can result in elements in comment tags being interpreted as executable when using AntiSamy's sanitized output. This is patched in OWASP AntiSamy .NET 1.2.0 and later. See important remediation details in the reference given below. As a workaround, manually edit the AntiSamy policy file (e.g., antisamy.xml) by deleting the `preserveComments` directive or setting its value to `false`, if present. Also it would be useful to make AntiSamy remove the `noscript` tag by adding a line described in the GitHub Security Advisory to the tag definitions under the `<tagrules>` node, or deleting it entirely if present. As the previously mentioned policy settings are preconditions for the mXSS attack to work, changing them as recommended should be sufficient to protect you against this vulnerability when using a vulnerable version of this library. However, the existing bug would still be present in AntiSamy or its parser dependency (HtmlAgilityPack). The safety of this workaround relies on configurations that may change in the future and don't address the root cause of the vulnerability. As such, it is strongly recommended to upgrade to a fixed version of AntiSamy.
Metrics
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Weakness Enumeration
Affected Software
| Vendor | Product | Versions |
|---|---|---|
| Spassarop | Owasp Antisamy .Net | < 1.2.0 |
References
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2023-51652?
How severe is CVE-2023-51652?
How do I fix CVE-2023-51652?
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 2023
- CVE-2023-51647Allegra saveInlineEdit Directory Traversal Remote Code Execu…4.7
- CVE-2023-51648Allegra getFileContentAsString Directory Traversal Informati…6.5
- CVE-2023-51649Nautobot is a Network Source of Truth and Network Automation…4.3
- CVE-2023-5165Docker Desktop before 4.23.0 allows an unprivileged user to …8.8
- CVE-2023-51650Hertzbeat is an open source, real-time monitoring system. Pr…7.5
- CVE-2023-51651AWS SDK for PHP is the Amazon Web Services software developm…3.3
- CVE-2023-51653Hertzbeat is a real-time monitoring system. In the implement…9.8
- CVE-2023-51654Improper link resolution before file access ('Link Following…5.5
- CVE-2023-51655In JetBrains IntelliJ IDEA before 2023.3.2 code execution wa…9.8
- CVE-2023-51656Deserialization of Untrusted Data vulnerability in Apache Io…9.8
- CVE-2023-5166Docker Desktop before 4.23.0 allows Access Token theft via a…6.5
- CVE-2023-51661Wasmer is a WebAssembly runtime that enables containers to r…8.6
Are you affected by CVE-2023-51652?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
