cve.bz

CVE-2021-41134 jupyter: Cross-site Scripting

5.4 mediumEPSS 0.7%Fix available

Medium (5.4) in jupyter. EPSS 0.7% estimated probability of exploitation activity in the next 30 days. Fixed in nbdime 1.1.1, 2.1.1, 3.1.1.

On this page
nbdime provides tools for diffing and merging of Jupyter Notebooks. In affected versions a stored cross-site scripting (XSS) issue exists within the Jupyter-owned nbdime project. It appears that when reading the file name and path from disk, the extension does not sanitize the string it constructs before returning it to be displayed. The diffNotebookCheckpoint function within nbdime causes this issue. When attempting to display the name of the local notebook (diffNotebookCheckpoint), nbdime appears to simply append .ipynb to the name of the input file. The NbdimeWidget is then created, and the base string is passed through to the request API function. From there, the frontend simply renders the HTML tag and anything along with it. Users are advised to patch to the most recent version of the affected product.

Severity

CVSS 3.1

5.4 medium
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
EPSS
0.7% (unchanged from 0.7% a week ago; 0.7% 30 days ago) estimated probability of exploitation activity in the next 30 days; 54th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CWE
CWE-79 Improper Neutralization of Input During Web Page Generation (Cross-site Scripting)
OWASP Top 10
A05:2025 Injection
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2021-41134 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2021-41134?via=ask-ai-copy and https://cve.bz/cve/CVE-2021-41134?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2021-41134 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
jupyter:nbdimefrom 1.0.0 before 1.1.1
jupyter:nbdimefrom 2.0.0 before 2.1.1
jupyter:nbdimefrom 3.0.0 through 3.1.1
jupyter:nbdimefrom 5.0.0 before 5.0.2
jupyter:nbdimefrom 6.0.0 before 6.1.2
jupyter:nbdime-jupyterlabfrom 1.0.0 before 1.0.1
jupyter:nbdime-jupyterlabfrom 2.0.0 before 2.1.1

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-p6rw-44q7-3fw4PyPInbdime<1.1.11.1.1
GHSA-p6rw-44q7-3fw4PyPInbdime>=2.0.0 <2.1.12.1.1
GHSA-p6rw-44q7-3fw4PyPInbdime>=3.0.0 <3.1.13.1.1
GHSA-p6rw-44q7-3fw4npmnbdime<5.0.25.0.2
GHSA-p6rw-44q7-3fw4npmnbdime>=6.0.0 <6.1.26.1.2
GHSA-p6rw-44q7-3fw4npmnbdime-jupyterlab<1.0.11.0.1
GHSA-p6rw-44q7-3fw4npmnbdime-jupyterlab>=2.0.0 <2.1.12.1.1
PYSEC-2021-428PyPInbdime<1.1.1
>=2.0.0 <2.1.1
>=3.0.0 <3.1.1
1.1.1, 2.1.1, 3.1.1

Attack patterns (CAPEC)

  • CAPEC-63 Cross-Site Scripting (XSS) Likelihood: High · Severity: Very High
  • CAPEC-85 AJAX Footprinting Likelihood: High · Severity: Low
  • CAPEC-209 XSS Using MIME Type Mismatch Severity: Medium
  • CAPEC-588 DOM-Based XSS Likelihood: High · Severity: Very High
  • CAPEC-591 Reflected XSS Likelihood: High · Severity: Very High
  • CAPEC-592 Stored XSS Likelihood: High · Severity: Very High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON