Vulnerabilities in pkg:npm/@jupyter-notebook/help-extension

PACKAGE
Advisory Identifier: GHSA-rch3-82jr-f9w9
Advisory Summary

CVE-2026-40171 is a HIGH cross-site scripting vulnerability (CWE-601: URL Redirection to Untrusted Site ('Open Redirect')) affecting @jupyter notebook/help extension libraries in the npm ecosystem. The issue involves jupyter notebook vulnerable to authentication token theft via commandlinker xss. Remediation is available by upgrading affected packages to version 7.5.6, 4.5.7.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:npm/@jupyter-notebook/help-extension

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:npm/@jupyter-notebook/help-extension. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-rch3-82jr-f9w9 CVE-2026-40171 HIGH Jupyter Notebook Vulnerable to Authentication Token Theft via CommandLinker XSS

CVE-2026-40171 at a Glance

CVE Identifier CVE-2026-40171
GHSA Identifier GHSA-rch3-82jr-f9w9
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-601: URL Redirection to Untrusted Site ('Open Redirect')
Affected Product @jupyter notebook/help extension
Package Ecosystem npm
Published Date
Last Updated

How to Fix CVE-2026-40171

To remediate this vulnerability, upgrade all affected @jupyter notebook/help extension dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@jupyter-notebook/help-extension fixed: 7.5.6
npm install @jupyter-notebook/help-extension@7.5.6
notebook fixed: 7.5.6
pip install notebook>=7.5.6
jupyterlab fixed: 4.5.7
pip install jupyterlab>=4.5.7
@jupyterlab/help-extension fixed: 4.5.7
npm install @jupyterlab/help-extension@4.5.7
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @jupyter-notebook/help-extension

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-40171, inspect your project dependencies using npm:

npm ls @jupyter-notebook/help-extension

Analyze the terminal output to locate any version of @jupyter notebook/help extension in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 7.5.6), your application is affected.

Note: The npm ls @jupyter-notebook/help-extension command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-601: URL Redirection to Untrusted Site ('Open Redirect'), where the web application accepts a user-controlled input that specifies a link to an external site, and uses that link in a redirect. In @jupyter notebook/help extension, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact A stored Cross-Site Scripting (XSS) vulnerability in Jupyter Notebook allows attackers to steal authentication tokens from users who open malicious notebook files and interact with elements that the attacker can make look indistinguishable from legitimate controls (single click interaction). The vulnerability enables complete account takeover through the Jupyter REST API, allowing the attacker to: 1. Read all files 2. Modify/create files 3. Access running kernels and execute arbitrary code 4. Create terminals for shell access ### Patches Jupyter Notebook 7.5.6 and JupyterLab 4.5.7 include patches for this vulnerability. ### Workarounds The help extension can be disabled via CLI: ``` jupyter labextension disable @jupyter-notebook/help-extension jupyter labextension disable @jupyterlab/help-extension ``` ### Hardening The patched versions include a toggle to disable the command linker functionality altogether, for example via `overrides.json`: ```json { "@jupyterlab/apputils-extension:sanitizer": { "allowCommandLinker": false } } ``` ### Resources - https://jupyterlab.readthedocs.io/en/latest/user/commands.html#commands-in-markdown-output-and-files ### Acknowledgments Reported by Daniel Teixeira - NVIDIA AI Red Team

CVE-2026-40171 Affected @jupyter notebook/help extension Versions

4 component(s)
Fixed Versions:
7.5.64.5.7
Product / Package Ecosystem Affected Versions Fixed Version
@jupyter-notebook/help-extension
npm
≥ 7.0.0
< 7.5.6
7.5.6
notebook
PyPI
≥ 7.0.0
< 7.5.6
7.5.6
jupyterlab
PyPI
< 4.5.7
4.5.7
@jupyterlab/help-extension
npm
< 4.5.7
4.5.7

References

Frequently Asked Questions

What is CVE-2026-40171?
CVE-2026-40171 is a security vulnerability in @jupyter notebook/help extension involving Jupyter Notebook Vulnerable to Authentication Token Theft via CommandLinker XSS under CWE-601: URL Redirection to Untrusted Site ('Open Redirect').
Which @jupyter notebook/help extension versions are affected?
Affected versions include releases prior to 7.5.6, 4.5.7 across affected packages: @jupyter-notebook/help-extension, notebook, jupyterlab, @jupyterlab/help-extension.
What version fixes CVE-2026-40171?
Upgrading to 7.5.6, 4.5.7 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @jupyter-notebook/help-extension affected?
Yes, @jupyter-notebook/help-extension is affected in releases prior to 7.5.6. Upgrade your dependency to 7.5.6 or later.
Is notebook affected?
Yes, notebook is affected in releases prior to 7.5.6. Upgrade your dependency to 7.5.6 or later.
What CWE is associated with CVE-2026-40171?
CVE-2026-40171 is classified under CWE-601: URL Redirection to Untrusted Site ('Open Redirect') (The web application accepts a user-controlled input that specifies a link to an external site, and uses that link in a redirect.).
How can I check npm dependencies for CVE-2026-40171?
Run the dependency tree command: 'npm ls @jupyter-notebook/help-extension'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-rch3-82jr-f9w9",
  "modified" : "2026-05-08T19:26:04Z",
  "published" : "2026-04-30T17:25:47Z",
  "aliases" : [ "CVE-2026-40171" ],
  "summary" : "Jupyter Notebook Vulnerable to Authentication Token Theft via CommandLinker XSS",
  "details" : "### Impact\n\nA stored Cross-Site Scripting (XSS) vulnerability in Jupyter Notebook allows attackers to steal authentication tokens from users who open malicious notebook files and interact with elements that the attacker can make look indistinguishable from legitimate controls (single click interaction).\n\nThe vulnerability enables complete account takeover through the Jupyter REST API, allowing the attacker to:\n1. Read all files\n2. Modify/create files\n3. Access running kernels and execute arbitrary code\n4. Create terminals for shell access\n\n### Patches\n\nJupyter Notebook 7.5.6 and JupyterLab 4.5.7 include patches for this vulnerability.\n\n### Workarounds\n\nThe help extension can be disabled via CLI:\n\n```\njupyter labextension disable @jupyter-notebook/help-extension\njupyter labextension disable @jupyterlab/help-extension\n```\n\n### Hardening\n\nThe patched versions include a toggle to disable the command linker functionality altogether, for example via `overrides.json`:\n\n```json\n{\n  \"@jupyterlab/apputils-extension:sanitizer\": {\n    \"allowCommandLinker\": false\n  }\n}\n```\n\n### Resources\n\n- https://jupyterlab.readthedocs.io/en/latest/user/commands.html#commands-in-markdown-output-and-files\n\n### Acknowledgments\n\nReported by Daniel Teixeira - NVIDIA AI Red Team",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@jupyter-notebook/help-extension"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.0.0"
      }, {
        "fixed" : "7.5.6"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 7.5.5"
    }
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "notebook"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.0.0"
      }, {
        "fixed" : "7.5.6"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 7.5.5"
    }
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "jupyterlab"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "4.5.7"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 4.5.6"
    }
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@jupyterlab/help-extension"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "4.5.7"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 4.5.6"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/jupyter/notebook/security/advisories/GHSA-rch3-82jr-f9w9"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-40171"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/jupyter/notebook"
  }, {
    "type" : "WEB",
    "url" : "https://jupyterlab.readthedocs.io/en/latest/user/commands.html#commands-in-markdown-output-and-files"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-601", "CWE-79" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-04-30T17:25:47Z",
    "nvd_published_at" : "2026-05-06T20:16:31Z"
  }
}