CVE-2022-25887
Apostrophecms Sanitize-html vulnerability
The package sanitize-html before 2.7.1 are vulnerable to Regular Expression Denial of Service (ReDoS) due to insecure global regular expression replacement logic of HTML comment removal.
Affected products
Sanitize-html. The exact versions are in the references.
What to do now
- Check your exposureFind out whether Apostrophecms Sanitize-html runs anywhere in your environment, including systems of suppliers.
- UpdateInstall the version in which the vendor fixed the vulnerability. The references lead to the advisory.
- Limit access until thenIf you cannot update at once, take the system off the internet or restrict who can reach it.
References
- github.com/apostrophecms/sanitize-html/commit/b4682c12fd30e12e82fa2d9b766de91d7d2cd23c · Patch
- github.com/apostrophecms/sanitize-html/pull/557 · Patch
- security.snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-3008102 · Patch
- security.snyk.io/vuln/SNYK-JS-SANITIZEHTML-2957526 · Patch
- nvd.nist.gov/vuln/detail/CVE-2022-25887
- github.com/advisories/GHSA-cgfm-xwp7-2cvr
- nvd.nist.gov/vuln/detail/CVE-2022-25887
- cve.org/CVERecord?id=CVE-2022-25887
Data: CVE list and the NVD. This product uses data from the NVD API but is not endorsed or certified by the NVD.