CVE-2026-35397: jupyter-server path traversal allows access to sibling directories sharing root_dir name prefix

Published May 5, 2026
·
Updated

Summary

Jupyter Server <=2.17.0 can access directories sibling to the root directory, if it starts with the root dir's name.

PoC

Minimal:

. ├── test/ <- root directory. │ └── test.txt └── testtest/ └── secret.txt <- file to exfiltrate that we should not be able to access via API

bash HOST="http://localhost:8888" TOKEN="" SIBLING="testtest" TARGET="secret.txt"

curl -s -X POST \ "$HOST/api/contents/%2e%2e/$SIBLING/$TARGET/checkpoints" \ -H "Authorization: token $TOKEN"

Full PoC by @stef41: https://gist.github.com/Yann-P/66d4982a965dee8fcb8dd89db29e7006

Impact

It is possible for an authenticated user to access content outside the server's rootdir in siblings directories sharing the same prefix as the rootdir. The attacker can escalate access, reading, writing, and deleting from sibling directories.

This can have a tangible impact for deployments using predictable naming scheme with multi-tenant server, for example user1, user2, user3, ..., user10 etc, as user1 could access and modify files of all user10 - user19 and higher.

In a hypothetical system where users can choose a name of their folder, an attacker could choose a single-letter username to gain access to a significant number of sibling directories.

Workarounds

Use folder names that do not overlap.

Acknowledgments

Thank you to @stef41 for providing a useful PoC.

Other sources

Jupyter Server is the backend for Jupyter web applications. In versions 2.17.0 and earlier, a path traversal vulnerability in the REST API allows an authenticated user to escape the configured rootdir and access sibling directories whose names begin with the same prefix as the rootdir. For example, with a rootdir named "test", the API permits access to a sibling directory named "testtest" through a crafted request to the /api/contents endpoint using encoded path components. An attacker can read, write, and delete files in affected sibling directories. Multi-tenant deployments using predictable naming schemes are particularly at risk, as a user with a directory named "user1" could access directories for user10 through user19 and beyond. A user who can choose a single-character folder name could gain access to a significant number of sibling directories.

Version 2.18.0 contains a fix. As a workaround, ensure folder names do not share a common prefix with any sibling directory.

MITRE

Affected Software

2 affected componentsFixes available
pip/jupyter-server<=2.17.0
2.18.0
jupyter Jupyter Server<2.18.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/jupyter-server to a version that resolves this vulnerability.

    Fixed in 2.18.0
  2. Upgrade

    Upgrade Jupyter Server to a version that resolves this vulnerability.

    Fixed in 2.18.0
  3. Configuration

    As a workaround (and in multi-tenant predictable deployments), ensure user-provided folder names do not share a common prefix with any sibling directory (e.g., avoid a root_dir named "test" having sibling directories like "testtest").

    Jupyter Server (REST API root_dir usage) folder naming scheme = Use folder names that do not overlap / do not share a common prefix with any sibling directory

Event History

May 5, 2026
Advisory Published
via GitHub·04:49 PM
Data Sourced
via GitHub·04:49 PM
DescriptionSeverityWeaknessAffected Software
CVE Published
via MITRE·07:37 PM
Data Sourced
via MITRE·07:37 PM
DescriptionWeakness
Data Sourced
via Red Hat·08:01 PM
DescriptionSeverityAffected Software
Data Sourced
via NVD·08:16 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-35397?

CVE-2026-35397 has a moderate severity rating due to the potential for unauthorized file access.

2

How do I fix CVE-2026-35397?

To mitigate CVE-2026-35397, upgrade Jupyter Server to version 2.18.0 or later.

3

What software is affected by CVE-2026-35397?

CVE-2026-35397 affects Jupyter Server versions up to and including 2.17.0.

4

What type of vulnerability is CVE-2026-35397?

CVE-2026-35397 is a directory traversal vulnerability.

5

Can CVE-2026-35397 lead to data exfiltration?

Yes, CVE-2026-35397 can potentially allow for unauthorized access to sensitive files, leading to data exfiltration.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203