Cross-site scripting (XSS) in docsify
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- High · Low · Low
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-79.
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
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | docsify | before 4.12.0 | 4.12.0 | Patch available | CNA |
| — | docsify (npm) | before 4.12.0 | 4.12.0 | Patch available | GHSA-2mm9-c2fx-c7m4 |
- docsify Vendor— Affected before 4.12.0 Fixed in 4.12.0 Patch available CNA
- docsify (npm) Vendor— Affected before 4.12.0 Fixed in 4.12.0 Patch available GHSA-2mm9-c2fx-c7m4
Remediation
- Fix · CNA docsify Fixed in 4.12.0
- Fix · GHSA-2mm9-c2fx-c7m4 docsify (npm) Fixed in 4.12.0 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2021-23342
- 2026-10-03 Alias added: GHSA-2mm9-c2fx-c7m4
References
Advisory 2
More Docsifyjs Docsify vulnerabilities
- TI-2020-06200 Cross-site scripting in docsify CVSS 3.1MEDIUM 6.1
- TI-2021-10652 docsify 4.12.1 is affected by Cross Site Scripting (XSS) because the search component… CVSS 3.1MEDIUM 6.1
Sources
- CVE-2021-23342 · CVE Program
- CVE-2021-23342 · NVD
- FIRST EPSS
- GHSA-2mm9-c2fx-c7m4 · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences