{"id":"CVE-2021-32797","published":"2021-08-09T20:45:10Z","modified":"2024-08-03T23:33:56Z","title":"JupyterLab: XSS due to lack of sanitization of the action attribute of an html <form>","vendor":"jupyterlab","product":"jupyterlab","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.4,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:N/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.0266,"percentile":0.86059,"provenance":"source"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"references":[{"url":"https://github.com/jupyterlab/jupyterlab/security/advisories/GHSA-4952-p58q-6crx","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/jupyterlab/jupyterlab/commit/504825938c0abfa2fb8ff8d529308830a5ae42ed","tags":["x_refsource_MISC"]}],"priority":{"score":22.4,"factors":[{"name":"EPSS percentile","points":17.21},{"name":"CVSS severity","points":5.18}]},"vendorSlug":"jupyterlab","affectedVersions":[{"vendor":"jupyterlab","product":"jupyterlab","versions":[">= 3.1.0, < 3.1.4",">= 3.0.0, < 3.0.17",">= 2.3.0, < 2.3.2",">= 2.0.0, < 2.2.10","< 1.2.1"]}],"affected":[{"ecosystem":"PyPI","package":"jupyterlab","vulnerableRanges":["<1.2.21",">=2.0.0a0, <2.2.10",">=2.3.0a0, <2.3.2",">=3.0.0a0, <3.0.17",">=3.1.0a0, <3.1.4",">=2, <2.2.10",">=2.3, <2.3.2",">=3, <3.0.17",">=3.1, <3.1.4"],"patched":["1.2.21","2.2.10","2.3.2","3.0.17","3.1.4"],"from":["GHSA-4952-p58q-6crx","PYSEC-2021-130"],"provenance":"source"},{"ecosystem":"PyPI","package":"notebook","vulnerableRanges":["<5.7.11",">=6.0.0, <6.4.1"],"patched":["5.7.11","6.4.1"],"from":["GHSA-4952-p58q-6crx","PYSEC-2026-688"],"provenance":"source"}],"summary":{"text":"JupyterLab, the user interface for Project Jupyter, fails to sanitize the action attribute of HTML form elements, which allows untrusted notebooks to inject script through cross-site scripting. An attacker who can get a user to open a malicious notebook can execute code in that user's JupyterLab session, with no authentication needed beyond that user interaction.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T06:46:52Z"},"euvd":{"id":"EUVD-2021-0107","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-jupyterlab-cve-2021-32797","children":[{"from":"CVE-2021-32797","to":"CVE-2024-43805","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["packages/apputils/src/sanitizer.ts"],"commits":["https://github.com/jupyterlab/jupyterlab/commit/504825938c0abfa2fb8ff8d529308830a5ae42ed","https://github.com/jupyterlab/jupyterlab/commit/06ad9de836f155add7d3d651ef936cc4c5ea8093","https://github.com/jupyterlab/jupyterlab/commit/88e24baac551196f9cb3de16bd060a7ab1597674"],"basis":"shared function","functions":["Sanitizer"]}]}],"packageHistory":[{"cve":"CVE-2019-10255","published":"2019-03-28","fixed":"5.7.8","kev":false},{"cve":"CVE-2019-10856","published":"2019-04-04","fixed":"5.7.8","kev":false},{"cve":"CVE-2020-26215","published":"2020-11-18","fixed":"6.1.5","kev":false,"link":{"from":"CVE-2020-26215","to":"CVE-2021-32797","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:notebook","fromFixed":"6.1.5","toFixed":"6.4.1","daysApart":264}]}},{"cve":"CVE-2021-32797","published":"2021-08-09","fixed":"6.4.1","kev":false},{"cve":"CVE-2021-32798","published":"2021-08-09","fixed":"6.4.1","kev":false},{"cve":"CVE-2022-24758","published":"2022-03-31","fixed":"6.4.10","kev":false,"link":{"from":"CVE-2021-32797","to":"CVE-2022-24758","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:notebook","fromFixed":"6.4.1","toFixed":"6.4.10","daysApart":234}]}},{"cve":"CVE-2022-29238","published":"2022-06-14","fixed":"6.4.12","kev":false}],"package":"PyPI:notebook"}}