CVE-2021-32797
JupyterLab: XSS due to lack of sanitization of the action attribute of an html <form>
Reported by github_m · Published August 9, 2021
notebook is fixed in 6.4.1 and 5.7.11 (PyPI)
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.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| notebook | PyPI | 6.4.1, 5.7.11 |
| jupyterlab | PyPI | 504825938c0abfa2fb8ff8d529308830a5ae42ed, 3.1.4, 3.0.17, 2.3.2, 2.2.10, 1.2.21 |
| jupyterlab | Arch Linux | 3.1.4-1 |
| jupyterlab | jupyter | 3.1.4, 3.0.17, 2.3.2, 2.2.10, 1.2.21 |
| jupyterlab | Bitnami | 3.1.4, 3.0.17, 2.3.2, 2.2.10, 1.2.21 |
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| jupyterlab | jupyterlab | >= 3.1.0, < 3.1.4, >= 3.0.0, < 3.0.17, >= 2.3.0, < 2.3.2 |
| arch | jupyterlab | 0 |
| PyPI | notebook | 0, 6.0.0 |
| PyPI | jupyterlab | 3.1.0a0, 0, 2.0.0a0 |
| jupyterlab | jupyterlab | 3.1.0, 3.0.0, 2.3.0 |
Timeline
- Aug 9, 2021 CVE Published
- Aug 10, 2021 EPSS Score (30 in total, the first dated here)
- Mar 10, 2026 Security Advisory (2 in total, the first dated here)
- Jun 17, 2026 CVE Updated
- Aug 1, 2026 Coalition ESS Score
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2021-32797
vulnetix vdb fixes CVE-2021-32797
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2021-32797/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- x_refsource_CONFIRM
- x_refsource_MISC
- https://nvd.nist.gov/vuln/detail/CVE-2021-32797 advisory
- https://github.com/advisories/GHSA-4952-p58q-6crx advisory
- https://github.com/google/security-research/security/advisories/GHSA-c469-p3jp-2vhx url
- https://github.com/pypa/advisory-database/tree/main/vulns/jupyterlab/PYSEC-2021-130.yaml advisory