CVE-2026-66298: Livebook: sandboxed JS bypasses origin check, forces exec
HIGHLivebook's JS-view sandbox fails to verify Event.isTrusted when forwarding keyboard events from an untrusted, cross-origin iframe to the parent page, so notebook-defined JavaScript can synthesize keystrokes that the app treats as genuine user input. Because Livebook's global shortcut handler runs on document capture without further validation, that forged input can trigger session-wide shortcuts that queue full evaluation of every cell — meaning simply opening a third-party notebook, or having a malicious output mirrored to you by a collaborator, causes arbitrary Elixir code to execute on your runtime with no confirmation dialog. CVSS 8.8 (network, low complexity, no privileges, user interaction required) reflects the full compromise of confidentiality, integrity and availability once triggered; EPSS sits low in absolute terms (0.00167) and this is not in CISA KEV, no public exploit or Nuclei template exists, and CISA SSVC rates it TRACK — so there is no evidence of active exploitation and this is not an emergency-patch situation. Any team running Livebook for AI/ML experimentation, prototyping, or teaching should upgrade to 0.18.7+ (0.5.x-0.18.x branch) or 0.19.9+ (0.19.x branch) on the next normal patch cycle, and in the interim treat notebooks from untrusted sources (including ones reached via published docs or shared links) as executable code, not passive documents.
What is the risk?
High severity (CVSS 8.8) with a straightforward network attack vector and low complexity, but tempered by the requirement for user interaction (opening or receiving a mirrored malicious notebook output) and the absence of any known exploitation signal — no CISA KEV listing, no public PoC, no Nuclei template, and an EPSS score of 0.00167 in absolute terms despite ranking in the top 94th percentile of scored CVEs. CISA's own SSVC decision is TRACK, the lowest-urgency category, meaning organizations should monitor and patch on a standard cycle rather than treat this as an incident. The realistic risk driver is not mass internet scanning but targeted or opportunistic distribution of a malicious .livemd notebook to Livebook users — a plausible vector given Livebook's popularity for sharing reproducible Elixir/ML notebooks publicly and in teams.
How does the attack unfold?
How severe is it?
What is the attack surface?
What should I do?
1 step-
Upgrade Livebook to 0.18.7 or later (for the 0.5.0-0.18.x line) or 0.19.9 or later (for the 0.19.x line) — the fix adds Event.isTrusted validation and constrains which events the iframe forwards to the parent. Until patched, treat any Livebook notebook (.livemd) obtained from outside your organization, downloaded from documentation/blog posts, or shared by an unverified third party as untrusted executable content and do not open it in a session with access to production credentials or sensitive runtimes. Disable or avoid opening JS-view-producing cell outputs from unknown notebooks, and for collaborative sessions, restrict who can share notebook links that will auto-render outputs to other connected clients. Detection is limited since this is a client-side UI logic flaw with no server-side log signature; monitor for unexpected full-notebook evaluation events or unexplained runtime restarts correlated with a newly opened external notebook.
What does CISA's SSVC say?
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
How is it classified?
Which compliance frameworks are affected?
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2026-66298?
Livebook's JS-view sandbox fails to verify Event.isTrusted when forwarding keyboard events from an untrusted, cross-origin iframe to the parent page, so notebook-defined JavaScript can synthesize keystrokes that the app treats as genuine user input. Because Livebook's global shortcut handler runs on document capture without further validation, that forged input can trigger session-wide shortcuts that queue full evaluation of every cell — meaning simply opening a third-party notebook, or having a malicious output mirrored to you by a collaborator, causes arbitrary Elixir code to execute on your runtime with no confirmation dialog. CVSS 8.8 (network, low complexity, no privileges, user interaction required) reflects the full compromise of confidentiality, integrity and availability once triggered; EPSS sits low in absolute terms (0.00167) and this is not in CISA KEV, no public exploit or Nuclei template exists, and CISA SSVC rates it TRACK — so there is no evidence of active exploitation and this is not an emergency-patch situation. Any team running Livebook for AI/ML experimentation, prototyping, or teaching should upgrade to 0.18.7+ (0.5.x-0.18.x branch) or 0.19.9+ (0.19.x branch) on the next normal patch cycle, and in the interim treat notebooks from untrusted sources (including ones reached via published docs or shared links) as executable code, not passive documents.
Is CVE-2026-66298 actively exploited?
No confirmed active exploitation of CVE-2026-66298 has been reported, but organizations should still patch proactively.
How to fix CVE-2026-66298?
Upgrade Livebook to 0.18.7 or later (for the 0.5.0-0.18.x line) or 0.19.9 or later (for the 0.19.x line) — the fix adds Event.isTrusted validation and constrains which events the iframe forwards to the parent. Until patched, treat any Livebook notebook (.livemd) obtained from outside your organization, downloaded from documentation/blog posts, or shared by an unverified third party as untrusted executable content and do not open it in a session with access to production credentials or sensitive runtimes. Disable or avoid opening JS-view-producing cell outputs from unknown notebooks, and for collaborative sessions, restrict who can share notebook links that will auto-render outputs to other connected clients. Detection is limited since this is a client-side UI logic flaw with no server-side log signature; monitor for unexpected full-notebook evaluation events or unexplained runtime restarts correlated with a newly opened external notebook.
What systems are affected by CVE-2026-66298?
This vulnerability affects the following AI/ML architecture patterns: notebook-based ML/AI development environments, collaborative data science tooling, interactive model prototyping workflows.
What is the CVSS score for CVE-2026-66298?
CVE-2026-66298 has a CVSS v3.1 base score of 8.8 (HIGH). The EPSS exploitation probability is 0.17%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0011 User Execution AML.T0011.000 Unsafe AI Artifacts Compliance Controls Affected
What are the technical details?
Original Advisory
Origin Validation Error vulnerability in livebook-dev livebook allows untrusted notebook output JavaScript to trigger session-wide keyboard shortcuts, including forced evaluation of all cells and runtime restart. Livebook's JS-view feature renders notebook-defined JavaScript inside a sandboxed, cross-origin iframe specifically because that JavaScript is untrusted. The trusted iframe shell in iframe/priv/static/iframe/v5.html forwards every keydown event fired in its own window to the parent page without consulting Event.isTrusted, so an event synthesized by the untrusted script through window.dispatchEvent is forwarded exactly as a genuine keystroke would be. The parent-side relay in assets/js/hooks/js_view.js reconstructs and re-dispatches it on the live page with no further validation, and because assets/js/hooks/session.js registers the global shortcut handler on the document in the capture phase, that handler acts on the replicated event regardless of how it was produced. Sandboxed output JavaScript can therefore drive Livebook's session-wide keyboard shortcuts. Two of them reach LivebookWeb.SessionLive and execute immediately with no confirmation: the shortcut for queueing full evaluation runs every cell in the notebook, and the shortcut for reconnecting the runtime disconnects and reconnects it, discarding in-memory state. A third shortcut deletes the focused cell behind a confirmation dialog that the user can permanently dismiss, after which it too executes silently. Forced full evaluation is the significant consequence, because it causes the notebook's own Elixir code to run without the user choosing to evaluate anything. A user who merely opens a notebook obtained from a third party, or reached from published documentation, can have its code executed on their runtime. Livebook also mirrors cell outputs to every connected client, so a malicious output triggers in a collaborator's browser as soon as it renders. This issue affects livebook: from 0.5.0 before 0.18.7 and from 0.19.0 before 0.19.9.
Exploitation Scenario
An adversary crafts a Livebook notebook (.livemd) containing a JS-view cell whose output JavaScript, once rendered, calls window.dispatchEvent to synthesize a keydown event matching Livebook's 'evaluate all cells' shortcut. They publish or share this notebook via a blog post, GitHub repo, Slack channel, or internal wiki page framed as a useful ML/data-science example. A victim opens the notebook in their own Livebook instance (or is a collaborator connected to a session where someone else opens it, since outputs are mirrored to all clients); the moment the JS-view output renders, the sandboxed iframe forwards the forged keydown to the trusted parent page, which re-dispatches it on the document in capture phase, triggering the global shortcut handler with no confirmation prompt. Every cell in the notebook now executes automatically, running any attacker-authored Elixir code as the victim's Livebook runtime — potentially exfiltrating data, pivoting to connected systems, or corrupting a legitimate ML pipeline running in that session — and the attacker can additionally force a runtime reconnect to wipe in-memory model/data state as a secondary disruption.
Weaknesses (CWE)
CWE-346 — Origin Validation Error: The product does not properly verify that the source of data or communication is valid.
Source: MITRE CWE corpus.
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H References
- cna.erlef.org/cves/CVE-2026-66298.html
- github.com/livebook-dev/livebook/commit/296318ffdfa6e5ed7b18ad8d5a5b2af90f3cd728
- github.com/livebook-dev/livebook/commit/5980e5c6b71036806b3bf54101eb1d6c0f50f19c
- github.com/livebook-dev/livebook/commit/a552ce8f99ad348ea37061394dc950a0cebdb33e
- github.com/livebook-dev/livebook/security/advisories/GHSA-68c2-prqg-x62g
- osv.dev/vulnerability/EEF-CVE-2026-66298
Timeline
Related Vulnerabilities
CVE-2024-2912 10.0 BentoML: RCE via insecure deserialization (CVSS 10)
Same attack type: Code Execution CVE-2026-21858 10.0 n8n: Input Validation flaw enables exploitation
Same attack type: Code Execution CVE-2025-5120 10.0 smolagents: sandbox escape enables unauthenticated RCE
Same attack type: Code Execution CVE-2025-59528 10.0 Flowise: Unauthenticated RCE via MCP config injection
Same attack type: Code Execution GHSA-vvpj-8cmc-gx39 10.0 picklescan: security flaw enables exploitation
Same attack type: Code Execution