CVE-2026-66897: Instance template path traversal allows arbitrary host file write as root
Vulnerability summary
CVE-2026-66897 is a critical (CVSS 9.9) vulnerability in canonical lxd. EPSS estimates a 0.60% chance of exploitation in the next 30 days, higher than 50.3% of scored vulnerabilities. 1 public exploit is recorded.
Public exploit (GitHub, Date unknown)
CIRCL last checked 05-12-2026
Source freshness unavailable
How is this decided?Timeline
- 24-08-2026PublishedVulnerability first disclosed.
- 25-08-2026Last modifiedVulnerability information updated.
Description
A path traversal vulnerability in LXD's instance template processing allows an attacker with container edit permissions, or any user launching a crafted image, to overwrite arbitrary files on the host system as root. When processing target template paths specified in metadata.yaml, LXD validates the path against a confined os.Root directory handle but subsequently opens and creates the file using os.Create with an unconfined string path. This discrepancy between path resolution checks and file creation allows an attacker to escape directory confinement, overwrite root-owned host files, and achieve host root code execution.
CVSS metrics
4 scores · 4 sources · 1 version- OSV · UbuntuEcosystem advisory · calculated9.9CriticalCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
- OSV · DebianEcosystem advisory · calculated9.9CriticalCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
- NVDNIST9.9CriticalCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
EPSS trend
Probability
0.60%
Chance of exploitation in the next 30 days
Percentile
50%
Versus all other CVEs
30-day change
Decrease -0.11 pp
From 0.72% on 04-11-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
1 foundLxd
Maturity: poc
Weaknesses
CWE · root cause- CWE-22Improper Limitation of a Pathname to a Restricted DirectoryThe product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.
- CWE-23Relative Path TraversalThe product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize sequences such as ".." that can resolve to a location that is outside of that directory.
Affected systems
Known conditions: network-reachable, low-privilege account, no user interaction (CVSS vector). Other conditions: not stated in public data.
Canonical1 product
- lxd≥ 4.0.0, < 4.0.13 | ≥ 5.21.0, < 5.21.7 | ≥ 6.0, < 6.10 | < 4.0.13 | ≥ 5.0.0, < 5.0.9 | ≥ 5.1, < 5.21.7 | ≥ 6.0, ≤ 6.9
Debian1 product
- lxdAll versions (No fix recorded)
Ubuntu1 product
- lxdAll versions (No fix recorded)
3 vendors · 3 products
References
4 links- github.com/canonical/lxd/security/advisories/GHSA-q39m-8fx9-42fvVDB EntryVendor AdvisoryREPORTExploit