CVE-2026-66297·Docker vulnerability
Improper Neutralization of Special Elements used in an OS Command (OS Command Injection) vulnerability in livebook-dev livebook allows command injection into generated deployment setup commands. LivebookWeb.Hub.Teams.DeploymentGroupAgentComponent.docker_instructions/2 and LivebookWeb.Hub.Teams.DeploymentGroupAgentComponent.fly_instructions/4 in lib/livebook_web/live/hub/teams/deployment_group_agent_component.ex interpolate deployment group environment variable values into the generated Docker and Fly.io setup commands without shell escaping. The values originate from the deployment group configuration and reach the sinks through Livebook.Hubs.Dockerfile.online_docker_info/3. Both sinks place the value inside a double-quoted shell word, so a value containing a command substitution such as $(...) or backticks is evaluated by the shell without any need to break out of the quoting, and a literal double quote terminates the quoted word and allows arbitrary further tokens. The generated command is displayed in the Livebook web interface with a copy button, so a user who copies it and runs it without reviewing it first executes the injected commands on their own machine, under their own account. An attacker requires privileges sufficient to set deployment group environment variables, while the resulting code execution occurs on the machine of whoever runs the generated command. The Kubernetes instructions are not affected, because they render the same values into a YAML manifest with escaping rather than into a shell command. This issue affects livebook: from 0.13.0 before 0.18.7 and from 0.19.0 before 0.19.9.
- Severity
- high
- Software
- Docker
- Fixed in
- 0.19.9
- Published
- 2026-08-05
Affected versions
From: 0.19.0
Until: 0.19.9
Fixed in: 0.19.9
How to fix this CVE
Update Docker to version 0.19.9 or later to patch the OS command injection vulnerability in deployment setup command generation. The vulnerability allows attackers with deployment group configuration privileges to inject arbitrary shell commands that execute when users copy and run generated Docker or Fly.io deployment instructions. Immediately audit any deployment group environment variables for suspicious content and review command history on machines where deployment setup commands were executed.
sudo dnf update docker-ceDefensia detects this vulnerability
WAF mitigation (if patching is not yet possible)
Add this rule to your WAF to block exploitation attempts while you schedule the patch.
Implement WAF rules to detect and block HTTP requests containing suspicious payloads in deployment group configuration API endpoints, specifically patterns matching shell metacharacters such as $(, `, |, ;, &, and backticks in environment variable fields. Additionally, enforce strict input validation on the Livebook web interface to reject environment variable values containing command substitution syntax.How to check if you are affected
- Run 'docker --version' to confirm the current Docker version installed on your system
- Check if Livebook is running by querying 'curl -s http://localhost:8080/health' (default port) or reviewing process list with 'ps aux | grep livebook'
- Search system logs for suspicious environment variable patterns: 'grep -r "\$(" /var/log/ | grep -i deployment' or 'grep -r '\`' /var/log/ | grep -i deployment'
- Verify the patched version is active by stopping and restarting the Docker daemon: 'sudo systemctl restart docker' and confirm with 'docker --version'
FAQ
What is CVE-2026-66297?
CVE-2026-66297 is an OS command injection vulnerability in Livebook's deployment setup command generation. When creating Docker or Fly.io deployment instructions, environment variable values are directly interpolated into shell commands without proper escaping, allowing attackers with configuration access to inject arbitrary commands executed by users who run the generated setup commands.
Is CVE-2026-66297 being actively exploited?
No, this vulnerability is not currently listed on the CISA KEV catalog and has no known public exploits, though users should still apply patches promptly as exploitation depends on social engineering rather than complexity.
What versions of Docker are affected by CVE-2026-66297?
CVE-2026-66297 affects Livebook versions 0.13.0 through 0.18.7 and 0.19.0 through 0.19.8. The fix is available in Livebook 0.19.9 and later versions.
How do I check if my server is vulnerable to CVE-2026-66297?
Run 'docker --version' and if you have Livebook installed, check the Livebook version in your deployment configuration or via the web interface settings page. Compare against the affected version ranges: 0.13.0-0.18.7 or 0.19.0-0.19.8.
Does Defensia detect CVE-2026-66297?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If Docker or Livebook is installed on a monitored server, CVE-2026-66297 will appear in your dashboard with remediation steps.
Related Docker CVEs
References
- https://cna.erlef.org/cves/CVE-2026-66297.html
- https://github.com/livebook-dev/livebook/commit/0c2487326bbb37cb1eb43bb2f76eb93ad9f8fd6b
- https://github.com/livebook-dev/livebook/commit/b2a8416d149043132fe5a14ed611e0fefc9dc9cd
- https://github.com/livebook-dev/livebook/commit/f8fe9c62cb8bfc1dd0ccda4ea4a57c5e91563c85
- https://github.com/livebook-dev/livebook/security/advisories/GHSA-qpjc-w5mm-73mj
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2026-66297. Free for 1 server.
Get started free