9.9Critical

Canonical Lxd

CVE-2026-66897

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.

What this means for your business

  • It affects Canonical Lxd. It matters if your company, or a supplier that handles your data, runs it.
  • Code showing how to exploit it has been published, but real attacks have not been confirmed.
  • An attacker can use it remotely, over a network, with an ordinary user login, and without anyone at your company clicking anything.
  • FIRST's prediction model gives it a 0.7% chance of attack attempts being seen in the next 30 days, ranking above 50% of all known flaws.

What to do

  1. 1Check whether your company or your suppliers run Canonical Lxd, and which version. The affected versions are listed further down this page.
  2. 2If you do, apply the vendor's fix. A patch or vendor advisory has been published.

Fastnexa security experts

Not sure if your company is exposed to CVE-2026-66897?

Tell us where you run Canonical Lxd and a Fastnexa penetration tester will check whether this flaw, or others like it, can be used against your websites, apps and network.

The full test is free for our first 10 founding clients until 31 December 2026. See the offer

Book a 30-min callWhatsApp us

Think you’ve already been hit? Don’t wait on a form: call or WhatsApp +1 (732) 454 2616. We reply within 1 hour, 24/7. Emergency help →

Scoring

CVSS
9.9 (v3.1)
Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
Weakness
CWE-22
Assigned by
security@ubuntu.com

Dates

Published
2026-08-24
Last modified
2026-09-11
Sources
NVD

Affected products

  • Canonical Lxd- 4.0.13, 5.0.0 - 5.0.9, 5.1 - 5.21.7, 6.0 - 6.9

As listed in the NVD configuration data. Not a statement about your estate.

References

CVE-2026-66897 — Canonical Lxd | CyberBrief