CVE-2021-43862Self XSS on user input
- 3.7LowCVSS base score
- 1.1%Exploitation in 30 daysEPSS · top 35% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
Description
jQuery Terminal Emulator is a plugin for creating command line interpreters in your applications. Versions prior to 2.31.1 contain a low impact and limited cross-site scripting (XSS) vulnerability. The code for XSS payload is always visible, but an attacker can use other techniques to hide the code the victim sees. If the application uses the `execHash` option and executes code from URL, the attacker can use this URL to execute their code. The scope is limited because the javascript attribute used is added to span tag, so no automatic execution like with `onerror` on images is possible. This issue is fixed in version 2.31.1. As a workaround, the user can use formatting that wrap whole user input and its no op. The code for this workaround is available in the GitHub Security Advisory. The fix will only work when user of the library is not using different formatters (e.g. to highlight code in different way).
Timeline
ID reserved
By GitHub_M
- 44 days later
· 44 days later
Published
- 3 years later
· 3 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| GitHub_MCNA (assigner) | 3.1 | Low3.7 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:L/I:L/A:N |
| NVDNVD · Modified | 3.1 | Medium5.4 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N |
- EPSS (exploitation in 30 days)
- 1.1% · top 35% of all CVEs (12 Nov 2026)
The list uses the assigner's score when there is one, then CISA's, then NVD's: Low 3.7.
Affected products
- affected < 2.31.1
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- npmjquery.terminalGHSA-x9r5-jxvq-4387 (opens in a new tab)
References
References4
- https://github.com/jcubic/jquery.terminal/security/advisories/GHSA-x9r5-jxvq-4387 (opens in a new tab)x_refsource_CONFIRMx_transferred
- https://github.com/jcubic/jquery.terminal/issues/727 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/jcubic/jquery.terminal/commit/77eb044d0896e990d48a9157f0bc6648f81a84b5 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/jcubic/jquery.terminal/releases/tag/2.31.1 (opens in a new tab)x_refsource_MISCx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2022-0739 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-x9r5-jxvq-4387 (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2021-43862)Record last updated .