CVE-2026-40171 Details
Description
In Jupyter Notebook versions 7.0.0 through 7.5.5, JupyterLab versions 4.5.6 and earlier, and the corresponding @jupyter-notebook/help-extension and @jupyterlab/help-extension packages before 7.5.6 and 4.5.7, a stored cross-site scripting issue in the help command linker can be chained with attacker-controlled notebook content to steal authentication tokens with a single click. An attacker can craft a malicious notebook file containing elements that appear indistinguishable from legitimate controls and trigger execution when a user interacts with them. Successful exploitation allows theft of the user's authentication token and complete takeover of the Jupyter session through the REST API, including reading files, creating or modifying files, accessing kernels to execute arbitrary code, and creating terminals for shell access. This issue has been fixed in Notebook 7.5.6, JupyterLab 4.5.7, @jupyter-notebook/help-extension 7.5.6, and @jupyterlab/help-extension 4.5.7. As a workaround, disable the affected help extensions or set allowCommandLinker to false in the sanitizer configuration.
A stored cross-site scripting vulnerability has been identified in Jupyter Notebook versions 7.0.0 through 7.5.5, as well as in JupyterLab versions 4.5.6 and earlier. This vulnerability resides in the help command linker, where malicious notebook content can be used to steal authentication tokens with a single click. Attackers can craft notebook files that contain elements mimicking legitimate controls, which, when interacted with, execute the embedded malicious content. Exploitation of this vulnerability leads to unauthorized access to the user's Jupyter session via the REST API, allowing attackers to read, modify, or create files, execute arbitrary code through access to kernels, and open terminals for shell access.
Users can update to Jupyter Notebook 7.5.6 or JupyterLab 4.5.7, both of which include patches for this vulnerability. Alternatively, the affected help extensions can be disabled via the command line. For JupyterLab, the command 'jupyter labextension disable @jupyter-notebook/help-extension' can be used. After updating, the command linker functionality can be disabled altogether by setting 'allowCommandLinker' to false in the sanitizer configuration.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No CVSS 3.x data is available for this CVE.
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed May 7, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/jupyter/notebook/security/advisories/GHSA-rch3-82jr-f9w9 | [email protected] |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | [email protected] |
Affected Products
No affected product data is available for this CVE.
Change History
3 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| May 6, 2026 | New CVE Received | [email protected] |