JupyterLab: XSS due to lack of sanitization of the action attribute of an html <form>
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Required
- Attack complexity
- Low
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-79.
Summary
JupyterLab is a user interface for Project Jupyter which will eventually replace the classic Jupyter Notebook. In affected versions untrusted notebook can execute code on load. In particular JupyterLab doesn’t sanitize the action attribute of html `<form>`. Using this it is possible to trigger the form validation outside of the form itself. This is a remote code execution, but requires user action to open a notebook.
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 |
|---|---|---|---|---|---|
| jupyterlab | jupyterlab | 3.1.0 to before 3.1.4; 3.0.0 to before 3.0.17; 2.3.0 to before 2.3.2; 2.0.0 to before 2.2.10; before 1.2.1 | 3.1.4, 3.0.17, 2.3.2, 2.2.10, 1.2.1 | Patch available | CNA |
| — | jupyterlab (PyPI) | before 1.2.21 | 1.2.21 | Patch available | GHSA-4952-p58q-6crx |
| — | jupyterlab (PyPI) | 2.0.0a0 to before 2.2.10 | 2.2.10 | Patch available | GHSA-4952-p58q-6crx |
| — | jupyterlab (PyPI) | 2.3.0a0 to before 2.3.2 | 2.3.2 | Patch available | GHSA-4952-p58q-6crx |
| — | jupyterlab (PyPI) | 3.0.0a0 to before 3.0.17 | 3.0.17 | Patch available | GHSA-4952-p58q-6crx |
| — | jupyterlab (PyPI) | 3.1.0a0 to before 3.1.4 | 3.1.4 | Patch available | GHSA-4952-p58q-6crx |
| — | notebook (PyPI) | before 5.7.11 | 5.7.11 | Patch available | GHSA-4952-p58q-6crx |
| — | notebook (PyPI) | 6.0.0 to before 6.4.1 | 6.4.1 | Patch available | GHSA-4952-p58q-6crx |
- jupyterlab Vendorjupyterlab Affected 3.1.0 to before 3.1.4; 3.0.0 to before 3.0.17; 2.3.0 to before 2.3.2; 2.0.0 to before 2.2.10; before 1.2.1 Fixed in 3.1.4, 3.0.17, 2.3.2, 2.2.10, 1.2.1 Patch available CNA
- jupyterlab (PyPI) Vendor— Affected before 1.2.21 Fixed in 1.2.21 Patch available GHSA-4952-p58q-6crx
- jupyterlab (PyPI) Vendor— Affected 2.0.0a0 to before 2.2.10 Fixed in 2.2.10 Patch available GHSA-4952-p58q-6crx
- jupyterlab (PyPI) Vendor— Affected 2.3.0a0 to before 2.3.2 Fixed in 2.3.2 Patch available GHSA-4952-p58q-6crx
- jupyterlab (PyPI) Vendor— Affected 3.0.0a0 to before 3.0.17 Fixed in 3.0.17 Patch available GHSA-4952-p58q-6crx
- jupyterlab (PyPI) Vendor— Affected 3.1.0a0 to before 3.1.4 Fixed in 3.1.4 Patch available GHSA-4952-p58q-6crx
- notebook (PyPI) Vendor— Affected before 5.7.11 Fixed in 5.7.11 Patch available GHSA-4952-p58q-6crx
- notebook (PyPI) Vendor— Affected 6.0.0 to before 6.4.1 Fixed in 6.4.1 Patch available GHSA-4952-p58q-6crx
CPE configurations NVD · 1
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:jupyter:jupyterlab:*:*:*:*:*:*:*:* | before 1.2.21; 2.0.0 to before 2.2.10; 2.3.0 to before 2.3.2; 3.0.0 to before 3.0.17; 3.1.0 to before 3.1.4 | Vulnerable | jupyterlab |
- cpe:2.3:a:jupyter:jupyterlab:*:*:*:*:*:*:*:* Versions before 1.2.21; 2.0.0 to before 2.2.10; 2.3.0 to before 2.3.2; 3.0.0 to before 3.0.17; 3.1.0 to before 3.1.4 Vulnerable ·jupyterlab
Remediation
- Fix · CNA jupyterlab (jupyterlab) Fixed in 3.1.4, 3.0.17, 2.3.2, 2.2.10, 1.2.1
- Fix · GHSA-4952-p58q-6crx jupyterlab (PyPI) Fixed in 1.2.21 Advisory →
- Fix · GHSA-4952-p58q-6crx jupyterlab (PyPI) Fixed in 2.2.10 Advisory →
- Fix · GHSA-4952-p58q-6crx jupyterlab (PyPI) Fixed in 2.3.2 Advisory →
- Fix · GHSA-4952-p58q-6crx jupyterlab (PyPI) Fixed in 3.0.17 Advisory →
- Fix · GHSA-4952-p58q-6crx jupyterlab (PyPI) Fixed in 3.1.4 Advisory →
- Fix · GHSA-4952-p58q-6crx notebook (PyPI) Fixed in 5.7.11 Advisory →
- Fix · GHSA-4952-p58q-6crx notebook (PyPI) Fixed in 6.4.1 Advisory →
Vendor assessments
Timeline
- 2026-10-02 Threatist record created from CVE-2021-32797
- 2026-10-03 Alias added: GHSA-4952-p58q-6crx
References
Advisory 2
More Jupyterlab vulnerabilities
- TI-2024-26623 Remote Code Execution (RCE) vulnerability in jupyterlab extension template `update-integration-tests` GitHub Action CVSS 3.1CRITICAL 10.0
- TI-2026-30579 Improper input validation in jupyterlab CVSS 3.1HIGH 8.8
- TI-2026-30837 jupyterlab: Command linker attributes in HTML enable one-click command execution from untrusted content CVSS 4.0HIGH 8.6
- TI-2024-14994 Potential authentication and CSRF tokens leak in JupyterLab CVSS 3.1HIGH 7.6
- TI-2024-29399 HTML injection in Jupyter Notebook and JupyterLab leading to DOM Clobbering CVSS 3.1HIGH 7.6
- TI-2024-14993 Stored cross site scripting in Markdown Preview in JupyterLab CVSS 3.1MEDIUM 6.5
Sources
- CVE-2021-32797 · CVE Program
- CVE-2021-32797 · NVD
- FIRST EPSS
- GHSA-4952-p58q-6crx · GitHub Advisory Database · CC BY 4.0
- CVE-2021-32797 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences