Description
nbviewer through 1.0.1 contains a path traversal vulnerability in LocalFileHandler.can_show() that uses string-prefix comparison instead of proper path validation. Attackers can read files from sibling directories outside the configured root by requesting paths that share the root as a textual prefix, disclosing unintended notebooks and credentials.
Published: 2026-09-06
Score: 8.2 High
EPSS: < 1% Very Low
KEV: No
Impact: Remote File Disclosure
Action: Immediate Patch
AI Analysis

Impact

The vulnerability is a path traversal flaw in nbviewer’s LocalFileHandler.can_show() method, which relies on a simple string-prefix check instead of validating absolute file paths. This weakness allows an attacker to read arbitrary files located in directories adjacent to the configured root, including notebooks and credential files. The vulnerability falls under CWE‑22 and can lead to confidentiality breaches. The impact is the unauthorized disclosure of files that should be protected, potentially exposing sensitive data.

Affected Systems

Jupyter nbviewer versions 1.0.1 and earlier are affected. Any deployment of nbviewer that uses the LocalFileHandler component and has not applied the fix noted in the referenced commit or later releases is vulnerable. Existing installations should verify the exact version they are running to determine if they fall within the affected range.

Risk and Exploitability

The CVSS score of 8.2 classifies this issue as high severity. The EPSS score is not available, so the exploitation probability is unknown, but the flaw can be triggered by a crafted HTTP request to the nbviewer server and does not require any privileged access. It is not listed in the CISA KEV catalog at this time. An attacker with network access to the nbviewer instance can construct a path that shares the configured root as a textual prefix, causing the server to resolve to a file outside the intended directory and return its contents. The attack path is straightforward and does not rely on code execution or advanced privilege escalation.

Generated by OpenCVE AI on September 6, 2026 at 13:21 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade nbviewer to the latest available release that contains the LocalFileHandler path‑validation fix.
  • If an upgrade is not possible, apply a local patch to enforce proper absolute path validation or replace the can_show() implementation with a safe routine that rejects paths outside the configured root.
  • Restrict network exposure of nbviewer by placing it behind a firewall or internal network boundary and limiting access to trusted hosts.

Generated by OpenCVE AI on September 6, 2026 at 13:21 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Thu, 10 Sep 2026 16:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Mon, 07 Sep 2026 08:45:00 +0000

Type Values Removed Values Added
First Time appeared Jupyter
Jupyter nbviewer
Vendors & Products Jupyter
Jupyter nbviewer

Sun, 06 Sep 2026 12:45:00 +0000

Type Values Removed Values Added
Description nbviewer through 1.0.1 contains a path traversal vulnerability in LocalFileHandler.can_show() that uses string-prefix comparison instead of proper path validation. Attackers can read files from sibling directories outside the configured root by requesting paths that share the root as a textual prefix, disclosing unintended notebooks and credentials.
Title nbviewer through 1.0.1 Path Traversal via LocalFileHandler
Weaknesses CWE-22
References
Metrics cvssV3_1

{'score': 5.9, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N'}

cvssV4_0

{'score': 8.2, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N'}


Subscriptions

Jupyter Nbviewer
cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-09-24T14:21:19.100Z

Reserved: 2026-09-06T11:35:19.317Z

Link: CVE-2026-86258

cve-icon Vulnrichment

Updated: 2026-09-10T14:19:04.303Z

cve-icon NVD

Status : Awaiting Analysis

Published: 2026-09-06T13:17:10.830

Modified: 2026-09-10T16:18:02.407

Link: CVE-2026-86258

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-09-07T08:24:37Z

Weaknesses
  • CWE-22

    Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')