CVE-2021-23342 json
Cross-site Scripting (XSS)
published 2021-02-19 5 y ago modified 2026-06-17 4 mo ago also GHSA-2mm9-c2fx-c7m4 , EUVD-2021-0585
- cvss
- 8.6
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.7%
- EPSS 1.7% chance of exploitation in 30 days, percentile 76%
- public exploits
- 0
- none known
Summary
This affects the package docsify before 4.12.0. It is possible to bypass the remediation done by CVE-2020-7680 and execute malicious JavaScript through the following methods 1) When parsing HTML from remote URLs, the HTML code on the main page is sanitized, but this sanitization is not taking place in the sidebar. 2) The isURL external check can be bypassed by inserting more “////” characters
Patch / fix
Exploit prediction
1.66% chance of exploitation in the next 30 days, higher than 76% of all scored CVEs (FIRST EPSS, 2026-11-08).
Exploits and checks
- snyk.io https://snyk.io/vuln/SNYK-JS-DOCSIFY-1066017 referenced PoC, tagged "exploit" by a source, unverified
- snyk.io https://snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-1076593 referenced PoC, tagged "exploit" by a source, unverified
- packetstormsecurity.com http://packetstormsecurity.com/files/161495/docsify-4.11.6-Cross-Site-Scripting.html referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 8.6 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:L/E:P/RL:U/RC:C |
| CNA | 3.1 | 8.6 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:L |
| NVD | 3.1 | 6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
| NVD | 2.0 | 4.3 | AV:N/AC:M/Au:N/C:N/I:P/A:N |
| GitHub | 3.1 | 6.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| npm | docsify | <4.12.0 |
4.12.0 |
Affected products
- n/a docsify
Classification
- Weakness
-
- CWE-79 Improper Neutralization of Input During Web Page Generation
References
-
github.com
/docsifyjs/docsify/commit/ff2a66f12752471277fe81a64ad6c4b2c08111fe
web, patch, third-party-advisory
-
snyk.io
/vuln/SNYK-JS-DOCSIFY-1066017
web, exploit, third-party-advisory
-
snyk.io
/vuln/SNYK-JAVA-ORGWEBJARSNPM-1076593
web, exploit, third-party-advisory
-
packetstormsecurity.com
/files/161495/docsify-4.11.6-Cross-Site-Scripting.html
web, exploit, third-party-advisory
-
seclists.org
/fulldisclosure/2021/Feb/71
mailing-list, web, third-party-advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-23342
advisory
-
npmjs.com
/package/docsify
web
Sources
- CVE List CVE-2021-23342
- GitHub Advisory GHSA-2mm9-c2fx-c7m4
- NVD CVE-2021-23342
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.