CVE-2026-44727: Jupyter Server: Stored XSS in `NbconvertFileHandler` / `NbconvertPostHandler` via missing `sandbox` CSP

Published Jun 18, 2026
·
Updated

Jupyter Server is the backend for Jupyter web applications. Prior to 2.20, the nbconvert HTTP handlers in jupyterserver render user-authored notebook HTML under the Jupyter origin without a sandbox directive in their Content-Security-Policy. Combined with nbconvert.HTMLExporter's default non-sanitizing behavior, a notebook carrying an HTML payload in a displaydata output triggers stored XSS with cookie access, full /api/ authority, and kernel RCE. This vulnerability is fixed in 2.20.

Other sources

The nbconvert HTTP handlers in jupyterserver render user-authored notebook HTML under the Jupyter origin without a sandbox directive in their Content-Security-Policy.

Combined with nbconvert.HTMLExporter's default non-sanitizing behavior, a notebook carrying an HTML payload in a displaydata output triggers stored XSS with cookie access, full /api/ authority, and kernel RCE.

Impact

An authenticated victim who navigates to /nbconvert/html/<path> containing attacker-authored output can have their token exfiltrated to another domain because it is executed in the Jupyter origin.

Patches

Fixed in v2.20.0, commit 6cbee8d

Workarounds

For deployments where editing the installed jupyterserver is impractical (containerized builds, read-only images), adding this to jupyterserverconfig.py has the same effect as the patch above without touching source files:

import jupyterserver.nbconvert.handlers as nb

def csp(self): return super(type(self), self).contentsecuritypolicy + "; sandbox allow-scripts"

nb.NbconvertFileHandler.contentsecuritypolicy = property(csp) nb.NbconvertPostHandler.contentsecuritypolicy = property(csp)

GitHub

Affected Software

2 affected componentsFixes available
pip/jupyter-server<=2.19.0
2.20.0
jupyter Jupyter Server<2.20.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.20.0
  2. Upgrade

    Upgrade jupyter_server to a version that resolves this vulnerability.

    Fixed in 2.20.0Patch 6cbee8d
  3. Configuration

    In jupyter_server_config.py, set NbconvertFileHandler.content_security_policy (property backed by _csp) to append "; sandbox allow-scripts" to the existing Content-Security-Policy so nbconvert-rendered HTML is sandboxed.

    jupyter_server.nbconvert.handlers.NbconvertFileHandler content_security_policy (via _csp) = super(type(self), self).content_security_policy + "; sandbox allow-scripts"
  4. Configuration

    In jupyter_server_config.py, set NbconvertPostHandler.content_security_policy (property backed by _csp) to append "; sandbox allow-scripts" to the existing Content-Security-Policy so nbconvert-rendered HTML is sandboxed.

    jupyter_server.nbconvert.handlers.NbconvertPostHandler content_security_policy (via _csp) = super(type(self), self).content_security_policy + "; sandbox allow-scripts"

Event History

Jun 18, 2026
Advisory Published
via GitHub·03:04 PM
Data Sourced
via GitHub·03:04 PM
DescriptionWeaknessAffected Software
Jun 22, 2026
CVE Published
via MITRE·07:56 PM
Data Sourced
via MITRE·07:56 PM
DescriptionWeakness
Data Sourced
via Red Hat·09:02 PM
DescriptionSeverityAffected Software
Data Sourced
via NVD·09:16 PM
RemedyDescriptionSeverityWeaknessAffected 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-44727?

The severity of CVE-2026-44727 is rated at 77, indicating a high risk vulnerability.

2

How do I fix CVE-2026-44727?

To fix CVE-2026-44727, ensure that your Jupyter server is updated to the latest version where the issue is resolved.

3

What type of vulnerability is CVE-2026-44727?

CVE-2026-44727 is an XSS (Cross-Site Scripting) vulnerability affecting the nbconvert HTTP handlers in jupyter_server.

4

What components are affected by CVE-2026-44727?

CVE-2026-44727 affects the nbconvert functionality and HTTP handlers in the Jupyter server software.

5

Are there any known exploits for CVE-2026-44727?

As of now, there are no specific known exploits publicly disclosed for CVE-2026-44727.

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