High

Jupyter Server: 5xx request logging leaks token-bearing Referer header values

  • Disclosed: 17.09.2026
  • Updated: 11.10.2026 15:18

Summary

When a request returns a 500, jupyter_server/log.py logs a small JSON block of request headers.

The Referer header was copied into it as-is, so a token in the Referer URL ended up in the logs in plain text.

Impact

Anyone who can read the server logs can pick tokens out of these 500 entries. Tokens end up in the Referer during normal token-based login and launch flows.

Affected: all versions before 2.21.0.

PoC

Any malformed request that returns a 500 works:

bash
curl -i -X POST \
  -H 'Content-Type: application/json' \
  -H 'Referer: http://127.0.0.1:8899/tree?token=REFERTOKEN' \
  --data '{"name":123}' \
  'http://127.0.0.1:8899/api/kernels?token=VALIDTOKEN'

The log shows the token twice, once raw and once redacted:

"Referer": "http://127.0.0.1:8899/tree?token=REFERTOKEN",
[E ... ServerApp] 500 POST /api/kernels?token=[secret] (...) referer=http://127.0.0.1:8899/tree?token=[secret]

Patches

Fixed in 2.21.0 by 5251352. Header values are now scrubbed before the block is logged. Upgrade to 2.21.0 or later.

Workarounds

Limit who can read the server logs. If you can, avoid flows that put the token in the URL.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
Python (PyPI) jupyter-server < 2.21.0 2.21.0

References

CVSS score 7.1/10
CVSS vector
CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H
Weakness (CWE)
CWE-532
Platform
Python (PyPI)
Package
jupyter-server
Disclosed
17.09.2026
Updated
11.10.2026 15:18

Sources and licenses

OSV / GitHub Advisory Database - PYSEC-2026-4054 - PyPA Advisory Database; CC BY 4.0

OSV / GitHub Advisory Database - GHSA-c3mw-737p-c7g2 - CC BY 4.0

Vulnerability history: jupyter-server

All published vulnerabilities of this package (Python (PyPI)), newest first. Shows whether this is a one-off slip or a package that needs watching.

All (14) in the archive
Total entries
14
First → latest
11.2020 09.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • Critical 1
  • High 7
  • Medium 6

Disclosures per year

  1. 2020: 2
  2. 2021: 0
  3. 2022: 2
  4. 2023: 3
  5. 2024: 1
  6. 2025: 0
  7. 2026: 6
Severity:
  1. Jupyter Server: 5xx request logging leaks token-bearing Referer header values this entry
    High · 7.1 CVE-2026-86049 < 2.21.0 2.21.0
  2. High · 7.5 CVE-2024-35178 < 2.14.1 2.14.1
  3. High · 7.1 CVE-2022-29241 < 1.17.1, >= 2.0.0a0, < 2.0.0a1 1.17.1, 2.0.0a1

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.