Skip to main content

jupyterlab-git CVE-2026-54527

| EUVDEUVD-2026-42428 CRITICAL
Cross-site Scripting (XSS) (CWE-79)
2026-06-19 https://github.com/jupyterlab/jupyterlab-git GHSA-f962-v9hr-pfg5
9.3
CVSS 4.0 · Vendor: https://github.com/jupyterlab/jupyterlab-git
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Gain commit access to shared repo
  2. Delivery
    Commit file with XSS-crafted filename
  3. Exploit
    Push rename commit to repo
  4. Install
    Victim opens rename diff in Git History
  5. C2
    innerHTML executes injected JavaScript
  6. Execute
    Script opens terminal via /api/terminals
  7. Impact
    Run shell commands, exfiltrate credentials

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the adversary to have commit/push access to a Git repository that the victim has cloned into a JupyterLab environment with jupyterlab-git installed (default config once installed), and the crafted payload must be placed in a filename that is then renamed in a subsequent commit so it appears in rename history. The escalation to RCE additionally requires JupyterLab terminals to be enabled and reachable via /api/terminals. Limiting factors that reduce real-world risk: the victim must actively interact (CVSS UI:A) - specifically navigate to the Git History tab, click the rename commit, and click the renamed file to open the diff - so it is not zero-click; the attacker needs prior write access to a trusted shared repository (PR:L), meaning it favors malicious contributors, insiders, or poisoned shared repos rather than anonymous internet attackers. Affected only in versions >= 0.30.0b3 and < 0.54.0.

Impact

The vendor-supplied CVSS 4.0 vector (9.3, AV:N/AC:L/AT:N/PR:L/UI:A with high impact to both vulnerable and subsequent systems) is credible: the attacker needs commit access to a shared repo (PR:L) and the victim must actively click through to the rename diff (UI:A), but the payoff is full high-impact compromise including a scope change to the server environment. This is a real, high-severity issue rather than an inflated high-CVSS score, because the RCE outcome and credential/secret exposure are concrete. Tempering factors: exploitation is not zero-click - it depends on a specific multi-step victim interaction and on the adversary already having write access to a repository the victim trusts, which points to targeted/insider or malicious-shared-repo scenarios rather than mass exploitation. No EPSS score was provided, it is not in CISA KEV, and no weaponized exploit code is published, so there is no evidence of active exploitation; the primary risk signal is the technical impact plus a public, well-documented advisory that lowers the bar to reproduce.

Exploit ScenarioDerived

An attacker with commit rights to a shared or collaborative repository adds a file named like <img src=x onerror=eval(atob("..."))>.py and renames it in a later commit, then pushes both commits. A data scientist pulls the repo in JupyterLab, opens the Git History tab, clicks the rename commit, and clicks the renamed file to view the diff; the payload executes in their session, opens a terminal via /api/terminals, and runs shell commands to exfiltrate environment variables and credentials. No published exploit code exists, but the vendor advisory provides a complete step-by-step reproduction.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv3 – Jul 08, 2026

Stored cross-site scripting in the jupyterlab-git extension (versions 0.30.0b3 through 0.53.x) escalates to remote code execution when a victim views a rename diff in the Git History tab. The PlainTextDiff.ts createHeader() method injects unsanitized Git filenames into innerHTML, so a filename such as <img src=x onerror=eval(atob(...))>.py fires JavaScript that reads the _xsrf cookie, spawns a JupyterLab terminal via POST /api/terminals, and runs arbitrary shell commands. Reported by AWS Security; no public exploit identified at time of analysis, though the vendor advisory (GHSA-f962-v9hr-pfg5) documents a detailed reproduction path, and it is not listed in CISA KEV.

Earlier versions of this analysis (2)
v2 Jul 08, 2026 - 21:28 cvss changed CVSS 9.3

Stored cross-site scripting escalating to remote code execution in the jupyterlab-git extension (versions >= 0.30.0b3, < 0.54.0) lets a user with commit access to a shared Git repository embed a JavaScript payload inside a crafted filename that executes in a victim's JupyterLab browser session. Discovered by AWS Security, the flaw lives in PlainTextDiff.ts's createHeader(), which writes unsanitized rename-diff filenames to innerHTML; once triggered, the payload reads the _xsrf cookie, opens a terminal via POST /api/terminals, and runs arbitrary shell commands, exposing user code, data, environment variables, and credentials. No public exploit identified at time of analysis, though AWS published a detailed attack writeup; carries a CVSS 4.0 score of 9.3 and is fixed in 0.54.0.

v1 Jun 19, 2026 - 21:25

Stored cross-site scripting leading to remote code execution affects the jupyterlab-git JupyterLab extension (versions 0.30.0b3 through 0.54.0a1), where unsanitized Git filenames rendered in the rename-diff view allow an attacker with commit access to a shared repository to execute arbitrary JavaScript in a victim's JupyterLab session and pivot to shell command execution via the terminal API. The flaw was discovered by AWS Security during internal testing; publicly available exploit code exists in the form of a detailed proof of concept in the vendor advisory, but no public exploit identified at time of analysis as a packaged tool. The vendor has released a fix in version 0.54.0.

RemediationAI

Vendor-released patch: upgrade to jupyterlab-git 0.54.0 (pip jupyterlab-git / jupyterlab-git-core and npm @jupyterlab/git all fixed at 0.54.0); the fix is in commit c6d37b88f36aa59aee317930b95e427fb9d6b09b and release https://github.com/jupyterlab/jupyterlab-git/releases/tag/v0.54.0, which replaces innerHTML rendering with textContent in PlainTextDiff.ts and NotebookDiff.ts. If you cannot upgrade immediately, the practical compensating controls are to avoid opening the Git History / rename-diff view on repositories from untrusted or shared contributors, and to only clone repositories whose committers you trust - since the trigger is viewing a rename diff, not merely cloning. Because the escalation to RCE relies on the terminal API, environments that do not need it can disable JupyterLab terminals (set ServerApp.terminals_enabled = False), which blocks the RCE pivot at the cost of losing terminal functionality, though the underlying XSS in the victim's session would remain. The AWS/vendor-suggested source fix (textContent, or escaping <, >, &, ", ' before DOM insertion) is already incorporated in 0.54.0, so patching is strongly preferred over ad-hoc mitigation.

Affected VersionsENISA

jupyterlab-git 0.30.0b3, < 0.54.0

Affected Packages

npm @jupyterlab/git fix: 0.54.0
npm jupyterlab-git fix: 0.54.0
npm jupyterlab-git-core fix: 0.54.0
pypi @jupyterlab/git fix: 0.54.0
pypi jupyterlab-git fix: 0.54.0
pypi jupyterlab-git-core fix: 0.54.0
euvd jupyterlab_git_0_30_0b3 fix: 0.54.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 4 packages in npm, pypi, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

jupyterlab-git is a server/browser extension for JupyterLab (shipped as pip packages jupyterlab-git and jupyterlab-git-core and npm @jupyterlab/git) that surfaces Git operations - status, commits, diffs, and history - inside the JupyterLab UI. The root cause is CWE-79 (improper neutralization of input during web page generation): the diff-header rendering in src/components/diff/PlainTextDiff.ts built an HTML string by concatenating branch/file 'labels' and assigned it via head.innerHTML, and the parallel NotebookDiff.ts path had the same pattern. Because Git filenames are attacker-controllable and rename history passes the old/new filename through as a label, any HTML in the filename is parsed by the browser. The fix replaces innerHTML string concatenation with document.createElement('span') plus textContent, so filenames are rendered as inert text. Notably the payload crosses trust boundaries: browser-side script uses JupyterLab's own authenticated API surface (the _xsrf token and /api/terminals WebSocket) to obtain server-side shell execution, which is why an XSS becomes RCE.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/jupyterlab/jupyterlab-git) PRIMARY 9.3 CRITICAL
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H
vuln.today AI 9.0 CRITICAL

Attacker needs repo commit access (PR:L) and victim must click through the rename diff (UI:R); browser XSS pivots to server terminal RCE, a scope change (S:C) with full C/I/A impact.

3.1 AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:L/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H
Red Hat 9.0 HIGH

Primary rating from Vendor (https://github.com/jupyterlab/jupyterlab-git).

CVSS VectorVendor: https://github.com/jupyterlab/jupyterlab-git

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
Active
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
High
Subsequent system: Integrity
High
Subsequent system: Availability
High

Lifecycle Timeline

3
Analysis Updated
Jul 08, 2026 - 21:28 vuln.today
v3 - CVSS changed
Analysis Updated
Jul 08, 2026 - 21:28 vuln.today
v2 - CVSS changed
CVSS changed
Jul 08, 2026 - 21:22 NVD
9.3 (CRITICAL)

DescriptionCVE.org

Overview

Amazon Web Services (AWS) Security has identified a stored cross-site scripting (XSS) issue in the jupyterlab-git JupyterLab extension that can lead to remote code execution (RCE). The issue exists in the PlainTextDiff.ts component, where the createHeader() method passes Git filenames directly to innerHTML without sanitization when rendering diffs for renamed files in commit history. This allows an adversary to craft a filename containing arbitrary HTML/JavaScript that executes when another user views the rename diff in the Git History tab.

The issue can be leveraged through the rename history view in the JupyterLab Git panel. An adversary creates a file with a crafted filename containing a JavaScript payload (e.g., <img src=x onerror=eval(atob("base64_payload"))>.py), renames the file in a subsequent commit, and pushes to a shared repository. When a victim clones the repository, navigates to the Git History tab, clicks the rename commit, and then clicks the renamed file to view the diff, the unsanitized filename renders via innerHTML, executing arbitrary JavaScript in the victim's browser session. The injected JavaScript reads the xsrf cookie, opens a JupyterLab terminal via POST /api/terminals, connects via WebSocket, and executes arbitrary shell commands - achieving full RCE. An adversary can leverage this to exfiltrate secrets or credentials from the victim's environment.

Scope of impact

We discovered this issue during internal security testing. The issue is present in the default configuration of JupyterLab when the jupyterlab-git extension is installed.

The attack requires:

  • The adversary to have commit access to a Git repository that the victim has cloned
  • The victim to navigate to the Git History tab, click the rename commit, and click the renamed file to view the diff

The issue could allow an actor who has access to a shared Git repository to execute arbitrary JavaScript in another user's JupyterLab environment by committing a file with a crafted filename, potentially leading to remote code execution with access to user code, data, environment variables, and credentials.

Proof of concept

The issue exists in the createHeader() method where filenames from rename history are passed directly to innerHTML without sanitization:

[1] https://github.com/jupyterlab/jupyterlab-git/blob/main/src/components/diff/PlainTextDiff.ts#L214

Attack flow:

  1. An adversary creates a file with a crafted filename containing a JavaScript payload, e.g., <img src=x onerror=eval(atob("base64_payload"))>.py
  2. The adversary renames the file in a subsequent commit and pushes both commits to a shared Git repository
  3. The victim clones or pulls the repository and navigates to the Git History tab in JupyterLab
  4. The victim clicks the rename commit, then clicks the renamed file to view the diff
  5. The createHeader() method constructs a diff header using string concatenation with the unsanitized filename and assigns the result to innerHTML
  6. The injected JavaScript executes in the victim's browser session, reads the _xsrf cookie, sends a POST request to /api/terminals to open a JupyterLab terminal, connects via WebSocket, and executes arbitrary shell commands

Proof-of-concept mitigation

The issue can be mitigated by replacing innerHTML with textContent for filename rendering in the createHeader() method of PlainTextDiff.ts. Alternatively, proper HTML sanitization (escaping <, >, &, ", ') can be applied before inserting user-controlled filenames into the DOM.

Executive ViewAI

Why It Matters

The jupyterlab-git extension (versions 0.30.0b3-0.53.x) contains a critical vulnerability that could give attackers complete unauthorized access to affected systems through a simple user interaction with a malicious Git commit. This directly threatens organizations where data scientists, researchers, and engineers use JupyterLab-compromised systems could expose sensitive datasets, intellectual property, and access credentials to production infrastructure. Immediate patching is essential, as the attack requires only that a user interact with a crafted commit.

Business Impact: Severe
Compensating Controls

Apply vendor patch. Interim mitigations while patching: Disable jupyterlab-git extension on systems where Git integration is not critical; restrict Git repository access to trusted, internal sources only; monitor JupyterLab terminal spawning and process execution for unusual activity.

Threat Intelligence Overview

EPSS Score
0.3%
Top 80% exploitable
Prevalence
Medium
popular Git extension within the widely-used JupyterLab data-science ecosystem
Threat Intel
1
1 source
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS GHSA Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
Very High

Priority Score

46
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +46
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

Vendor StatusVendor

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy