Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessLow-priv local shell on Ubuntu LXD host
-
DeliveryPlant malicious uaclient package in /tmp/.local
-
ExploitWait for next LXD daemon start
-
ExecutionRoot pro imports per-user site directory
-
PersistPython executes injected code as root
-
ImpactArbitrary code execution / full root compromise
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A08:2025 - Software or Data Integrity Failures
ASVS 5.0
V13 - Configuration Search path element control
|
| Exploitation Conditions | Requires an Ubuntu host (os-release NAME=Ubuntu) running the affected LXD snap (6/stable 6.10 through 6.10.1), where the snap launcher exports HOME=/tmp/ and the run-host wrapper fails to reset it before nsenter, causing the root-run |
| Impact | This is a genuine local-privilege-escalation-to-root flaw (CVSS 4.0 base 7.3, High) rather than a high-score-but-low-risk issue, but its real-world urgency is moderated by several gating factors. The vector is AV:L (local access required), AC:H, and PR:L, meaning an already-present low-privileged local user - not a remote attacker - is the threat actor. The AC:H and the reporter's own notes reflect a real timing dependency: the root |
| Exploit ScenarioDerived | A low-privileged local user on an Ubuntu host running the LXD snap writes a malicious Python package into /tmp/.local/lib/pythonX.Y/site-packages (shadowing uaclient), which is world-writable because the snap launcher exports HOME=/tmp/ and run-host does not reset it. At the next LXD daemon start the root-run |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Dec 02, 2026
Local privilege escalation to root in the Canonical LXD snap (6/stable, 6.10 through 6.10.1) lets any unprivileged local user on an Ubuntu host plant a Python package under the host's world-writable /tmp and have it imported as root the next time the LXD daemon starts, giving arbitrary code execution with high confidentiality and integrity impact. The root cause is an uncontrolled search path (CWE-427): the snap launcher exports HOME=/tmp/ and the run-host wrapper enters the host mount namespace with nsenter without resetting HOME, so the root-run pro (ubuntu-advantage) client resolves its per-user Python site directory inside host /tmp. Exploitation needs local access and a daemon restart after the payload is planted (CVSS 4.0 base 7.3, High; assessed CVSS 3.1 AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H); the upstream advisory ships PoC scripts, but the reporter validated each link through source review and read-only host checks rather than executing the end-to-end escalation, and no confirmed active exploitation is reported in the supplied intelligence.
RemediationAI
Upgrade the LXD snap to 6.10.2 (snap refresh lxd) - this is the vendor-stated fixed version for the 6.10 branch, documented in GHSA-mm7v-2mcg-5fjg, and it closes the 6.10 through 6.10.1 window. Where the snap cannot be refreshed immediately, upstream's suggested code-level fixes are to make run-host set HOME to a root-owned directory or unset it before nsenter, and to export PYTHONNOUSERSITE=1 so host Python tools never consult a per-user site directory; both require patching the snap's run-host wrapper, since no runtime toggle for this behaviour is advertised. Because the trigger is the daemon's own start-up call to pro, restarting the LXD daemon is precisely the event that fires the payload, and the reporter notes a reboot clears /tmp before that start - that shortens the window but is a timing artifact, not a fix. Detection and containment can focus on the PoC's landing path, /tmp/.local/lib/python3.X/site-packages, on Ubuntu hosts running the affected snap, and on auditing any root process that inherits HOME=/tmp/ through the snap launcher.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The flaw is a classic CWE-427 uncontrolled search path, but the search path lives in Python rather than in a dynamic loader. In the LXD snap, snap/local/commands/daemon.start exports HOME=/tmp/ for the daemon (a private directory inside the snap) and later links /run/bin/pro to the wrappers/run-host wrapper. run-host deliberately resets PATH and unsets LD_LIBRARY_PATH, PYTHONPATH and PYTHONDONTWRITEBYTECODE, but it leaves HOME untouched before executing the target with nsenter -t 1 -m as root - so inside the host mount namespace HOME points at the host's world-writable /tmp. When lxd/daemon.go calls ubuntupro.New at daemon start on hosts whose os-release NAME is Ubuntu, the client shells out to pro api u.pro.status.is_attached.v1 via shared.RunCommand with a nil environment, inheriting HOME=/tmp/; pro is a setuptools console script with a #!/usr/bin/python3 shebang. CPython 3.12 site.py enables the per-user site directory unless PYTHONNOUSERSITE is set or the real and effective IDs differ, derives it from HOME, and processes its .pth/package contents at interpreter start-up - so a root-owned import of an attacker-controlled directory occurs. The daemon re-executes itself with aa-exec -p unconfined, so no AppArmor profile confines the pro invocation. The same inherited-HOME problem extends to other interpreted host tools reached through run-host, notably the guest-token call and the ceph wrapper when ceph.external=true. The chain was established by source reading of the public tree plus read-only checks on an Ubuntu 24.04.4 host with snap revision 41228; the escalation itself was not executed, so it remains a well-substantiated but not end-to-end demonstrated issue.
Know when Lxd gets its next vulnerability
- 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
CVSS:4.0/AV:L/AC:H/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Local-only attack by an unprivileged user (AV:L, PR:L); AC:H because success depends on a daemon restart with no intervening /tmp-clearing reboot; full root code execution gives C/I/A High.
Primary rating from Vendor (canonical).
CVSS VectorVendor: canonical
Lifecycle Timeline
2DescriptionCVE.org
Uncontrolled search path element in the run-host command wrapper in Canonical LXD 6.10 before 6.10.2 allows any local user to execute arbitrary code as root via a Python per-user site directory planted under the host's world-writable /tmp, which the root-run pro client imports at the next LXD daemon start because the snap launcher exports HOME=/tmp/ and run-host does not reset it for host commands.
Articles & Coverage 1
Executive ViewAI
CVE-2026-140085 is a high-severity local privilege escalation flaw in the Canonical LXD snap (versions 6.10 through 6.10.1) affecting Ubuntu hosts, where any unprivileged local user can achieve root-level code execution. This should concern leadership because a foothold by any low-privileged account-an employee, contractor, or an attacker who has landed on a host-could be escalated to full root control, enabling broad data compromise and system tampering across the estate.
Apply vendor patch.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
Cross-site request forgery in the LXD-UI component of Canonical LXD 5.0 before 5.0.5, 5.1 before 5.21.4, and 6.0 before
Privilege escalation in Canonical LXD's operations API (LXD before 6.5 and LXD 5.21 before 5.21.4) allows an authenticat
Authenticated remote attackers with access to the Canonical LXD instance log retrieval or deletion endpoints can read ar
Server-side template injection in Canonical LXD's instance snapshot naming feature lets an authenticated user who can mo
Improper certificate validation in the HTTPS API listener of Canonical LXD lets an unauthenticated remote attacker prese
Unauthenticated project enumeration in Canonical LXD 5.21.x before 5.21.4 and 6.x before 6.5 lets remote attackers deter
Unauthenticated remote attackers can confirm the existence of LXD projects on Canonical LXD by comparing HTTP status cod
Privilege escalation to host root in Canonical LXD occurs when the container manager unpacks crafted image or backup arc
Host root code execution in Canonical LXD arises from a path-traversal flaw in instance template processing, letting an
Arbitrary host file read and write in Canonical LXD occurs because the image import/unpack routine does not verify wheth
Canonical LXD's NVIDIA GPU passthrough configuration handler fails to sanitize newline characters in user-supplied `nvid
Path traversal in Canonical's LXD container and VM manager allows a user with backup import/restore privileges to write
EUVD-2026-140680
NVD
CVE.org
GitHub
Exploit-DB