# CVE-2021-23342: Cross-site Scripting (XSS)

- Severity: High 8.6 (CVSS:3.1, scored by snyk) `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`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.68%, higher than 77% of CVEs (2026-12-01)
- Public exploit code or proof of concept: 3 links below, marked "exploit"
- Published: 2021-02-19T16:35:15.574Z
- Modified: 2026-06-17T03:38:35.400Z
- Also known as: GHSA-2mm9-c2fx-c7m4
- Weaknesses: CWE-79
- Assigned by: snyk

## Description

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

(As written by CVE List.)

## Affected

- docsify: from unspecified before 4.12.0
- docsify (npm): before 4.12.0
- docsifyjs docsify: before 4.12.0

## Every score

- snyk: CVSS:3.1 8.6 High `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`
- GitHub: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`
- NVD: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`
- NVD: CVSS:2.0 4.3 Medium `AV:N/AC:M/Au:N/C:N/I:P/A:N`

## References

- <https://snyk.io/vuln/SNYK-JS-DOCSIFY-1066017> (exploit, third-party-advisory, web)
- <https://snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-1076593> (exploit, third-party-advisory, web)
- <http://packetstormsecurity.com/files/161495/docsify-4.11.6-Cross-Site-Scripting.html> (exploit, third-party-advisory, web)
- <https://github.com/docsifyjs/docsify/commit/ff2a66f12752471277fe81a64ad6c4b2c08111fe> (patch, third-party-advisory, web)
- <http://seclists.org/fulldisclosure/2021/Feb/71> (mailing-list, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-23342> (advisory)
- <https://www.npmjs.com/package/docsify> (web)

## Sources

- CVE List: [CVE-2021-23342](https://www.cve.org/CVERecord?id=CVE-2021-23342), CVE Terms of Use, modified 2024-09-16
- GitHub Advisory Database: [GHSA-2mm9-c2fx-c7m4](https://github.com/advisories/GHSA-2mm9-c2fx-c7m4), CC-BY-4.0, modified 2025-01-14
- NVD: [CVE-2021-23342](https://nvd.nist.gov/vuln/detail/CVE-2021-23342), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-23342 · Whole record: https://cve.day/CVE-2021-23342.json · Rebuilt by cve.day 2026-11-25T22:57:59.994Z
