jupyter-server@2.11.1

The backend—i.e. core services, APIs, and REST endpoints—to Jupyter web applications.

  • latest version

    2.21.1

  • latest non vulnerable version

  • first published

    8 years ago

  • latest version published

    1 months ago

  • licenses detected

  • Direct Vulnerabilities

    Known vulnerabilities in the jupyter-server package. This does not include vulnerabilities belonging to this package’s dependencies.

    Fix vulnerabilities automatically

    Snyk's AI Trust Platform automatically finds the best upgrade path and integrates with your development workflows. Secure your code at zero cost.

    Fix for free
    VulnerabilityVulnerable Version
    • H
    Insertion of Sensitive Information into Log File

    Affected versions of this package are vulnerable to Insertion of Sensitive Information into Log File via the log_request function in jupyter_server/log.py, which logs the full Referer header value without sanitization. When a request causes a 500 error, the Referer header - which may contain an authentication token embedded as a query parameter - is written verbatim to server logs, exposing the token to anyone with log access. The fix scrubs sensitive query parameters from the Referer URI before logging.

    How to fix Insertion of Sensitive Information into Log File?

    Upgrade jupyter-server to version 2.21.0 or higher.

    [,2.21.0)
    • C
    Improper Restriction of Rendered UI Layers or Frames

    Affected versions of this package are vulnerable to Improper Restriction of Rendered UI Layers or Frames via the NbconvertFileHandler and NbconvertPostHandler classes when rendering user-authored notebook HTML without a proper sandbox directive in the Content-Security-Policy. An attacker can execute arbitrary scripts in the context of the Jupyter origin, exfiltrate authentication tokens, gain access to API endpoints, and potentially achieve remote code execution by crafting a notebook with malicious HTML payloads and convincing an authenticated user to visit a specific URL.

    How to fix Improper Restriction of Rendered UI Layers or Frames?

    Upgrade jupyter-server to version 2.20.0 or higher.

    [,2.20.0)
    • M
    Permissive Regular Expression

    Affected versions of this package are vulnerable to Permissive Regular Expression in the use of re.match() to verify allow_origin_pat values. This allows an attacker to bypass intended CORS restrictions and gain unauthorized access to sensitive API responses. Code execution is possible by convincing an authenticated user to visiting a malicious origin while the non-default CORS regex allowlist is enabled. re.match() is based on prefix matching, so a malicious domain whose lefthand segments are a trusted domain passes.

    How to fix Permissive Regular Expression?

    Upgrade jupyter-server to version 2.18.0 or higher.

    [1.12.0,2.18.0)
    • H
    Directory Traversal

    Affected versions of this package are vulnerable to Directory Traversal due to insufficient validation of file paths in _get_os_path() function within jupyter_server/services/contents/fileio.py. An attacker can gain unauthorized read and write access to files outside the intended directory by submitting crafted directory traversal sequences. This may result in exposure of sensitive data, especially in shared hosting environments.

    How to fix Directory Traversal?

    Upgrade jupyter-server to version 2.18.2 or higher.

    [,2.18.2)
    • H
    Regular Expression without Anchors

    Affected versions of this package are vulnerable to Regular Expression without Anchors through the allow_origin_pat checks in websocket.py, login.py. An attacker can bypass CORS, WebSocket origin checks, and login redirect validation by supplying an Origin or Referer value that matches the configured pattern only as a prefix, such as a trusted hostname followed by attacker-controlled suffixes. This lets a malicious site make authenticated requests or steer redirects to an attacker-controlled origin, exposing user data and enabling cross-site actions in deployments that rely on allow_origin_pat for origin restrictions.

    Workarounds

    • Wrap your allow_origin_pat value with ^ and $ so it matches the full origin string instead of only a prefix; this prevents attacker-controlled origins like trusted.example.com.evil.com from passing origin validation.

    How to fix Regular Expression without Anchors?

    Upgrade jupyter-server to version 2.18.0 or higher.

    [,2.18.0)
    • C
    Directory Traversal

    Affected versions of this package are vulnerable to Directory Traversal due to the _get_os_path check in fileio.py in the file manager component. An attacker can read, write, and delete files outside the configured root directory by supplying a path whose resolved absolute path shares a prefix with the root, such as a sibling directory name that starts with the root name.

    How to fix Directory Traversal?

    Upgrade jupyter-server to version 2.18.0 or higher.

    [,2.18.0)
    • M
    Open Redirect

    Affected versions of this package are vulnerable to Open Redirect through the LoginFormHandler in the login handler. An attacker can send a crafted /login request with a protocol-relative redirect target beginning with // to make the application redirect a victim to an external site after login. This can be used for phishing and to send users away from the trusted Jupyter interface to attacker-controlled content.

    How to fix Open Redirect?

    Upgrade jupyter-server to version 2.18.0 or higher.

    [,2.18.0)
    • H
    Insufficient Session Expiration

    Affected versions of this package are vulnerable to Insufficient Session Expiration due to jupyter_cookie_secret never being automatically rotated or cleared. An attacker can keep or reuse authenticated session cookies after a password change by presenting a cookie signed with a secret that does not incorporate the current password. This lets the attacker retain access to the server as the affected user, exposing notebooks, files, and other authenticated server resources.

    Workarounds

    • Remove ~/.local/share/jupyter/runtime/jupyter_cookie_secret and restart the Jupyter server to invalidate existing authentication cookies, preventing stolen or old cookies from remaining valid after a password change.

    How to fix Insufficient Session Expiration?

    Upgrade jupyter-server to version 2.18.0 or higher.

    [,2.18.0)
    • H
    Information Exposure

    Affected versions of this package are vulnerable to Information Exposure through the NTLMv2 password hash exposure process. An attacker can obtain and potentially crack this hash to gain unauthorized access to the Windows machine hosting the server or to other network-accessible machines or third-party services using the same credentials.

    How to fix Information Exposure?

    Upgrade jupyter-server to version 2.14.1 or higher.

    [,2.14.1)
    • M
    Generation of Error Message Containing Sensitive Information

    Affected versions of this package are vulnerable to Generation of Error Message Containing Sensitive Information. When handling API requests from an authenticated user, unhandled errors include traceback information, which can reveal path information. The revealed paths are not considered particularly sensitive, given that the requesting user has arbitrary execution permissions already in the same environment.

    How to fix Generation of Error Message Containing Sensitive Information?

    Upgrade jupyter-server to version 2.11.2 or higher.

    [,2.11.2)