Summary
CVE-2026-86258 is a path traversal vulnerability (CWE-22) in Jupyter nbviewer versions up to and including 1.0.1, affecting the LocalFileHandler.can_show() method used when nbviewer is run in local-file serving mode. The flaw allows a remote, unauthenticated attacker to read files outside the configured notebook root directory. The issue carries a CVSS v4.0 base score of 8.2 (High).
Technical details
- Root cause:
LocalFileHandler.can_show()validates requested paths using a plain string-prefix comparison (fullpath.startswith(self.localfile_path)) instead of proper path canonicalization/containment checking. - Trigger condition: nbviewer must be deployed with local file serving (
--localfiles) enabled, and a sibling directory must exist whose absolute path textually shares the configured root as a prefix (e.g., root/data/notebooksvs. sibling/data/notebooks_private). - Attack vector: Network — a crafted HTTP request to the local file provider path can bypass the containment check without authentication or user interaction.
- Impact: Disclosure of files and notebooks located outside the intended served directory, potentially exposing credentials, configuration files, or other private notebook content stored in adjacent directories.
Affected software
- Jupyter nbviewer versions 0 through 1.0.1 (inclusive), when run with local file serving enabled.
Severity
- CVSS v4.0: 8.2 (High) —
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 - CVSS v3.1: 5.9 (Medium) —
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N
Mitigation and recommended actions
- Immediate: Upgrade nbviewer to a version that includes the fix committed in
aad36106f72a1ca7721310c6fccc677ce4c744a5, which replaces the string-prefix check with a normalized, separator-aware containment comparison inLocalFileHandler.can_show(). - If no patch is available: Disable or avoid running nbviewer with
--localfiles(local file serving) enabled; if local file serving is required, ensure no sibling directories exist whose paths share the configured root as a string prefix, and restrict network access to the nbviewer instance to trusted sources only.
How IONIX identifies potentially affected assets
IONIX matches the following signal against data already collected when it crawled the asset; identifying the technology sends no request beyond that crawl.
- Raw response body:
<link rel="shortcut icon" href="[…]static/ico/ipynb_icon_16x16.png"

