Categories
CVE-2026-34178

Vulnerability in github.com/canonical/lxd (CVE-2026-34178)

Summary

Vulnerability in github.com/canonical/lxd (CVE-2026-34178). Successful exploitation can lead to full system takeover. Exploitable via index.yaml.

Original description

The description as published by the source.

Summary

LXD instance backup import validates project restrictions against backup/index.yaml embedded in the tar archive, but creates the actual instance from backup/container/backup.yaml extracted to the storage volume. Because these are separate, independently attacker-controlled files within the same tar archive, an attacker with instance-creation rights in a restricted project can craft a backup where index.yaml contains clean configuration (passing all restriction checks) while backup.yaml contains security.privileged=true, raw.lxc host filesystem mounts, and restricted device types. The instance is created from the unchecked backup.yaml, bypassing all project restriction enforcement.

Details

LXD projects support a restricted=true mode that enforces security boundaries on what instances within the project can do. These restrictions include blocking security.privileged=true containers, raw.lxc / raw.apparmor overrides, and device passthrough (GPU, USB, PCI, unix-char). These restrictions are intended to prevent container escape vectors regardless of user privilege level within the project.

The backup import path has two distinct configuration sources within a single tar archive:

  1. backup/index.yaml - A quick-access metadata file read by backup.GetInfo() at backup/backup_info.go:68. This is the config checked against project restrictions.
  2. backup/container/backup.yaml - The full instance configuration extracted to the storage volu…

Source: OSV.dev (Open Source Vulnerabilities) NVD GitHub Advisory OSV

Auto-generated summary

Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.

A vulnerability tracked as CVE-2026-34178 has been found in github.com/canonical/lxd.
Attackers can target a specific entry point like index.yaml over the network to misuse the product.
Successful exploitation can lead to full system takeover.
What to do: apply the vendor's official patched release.
If unsure, ask your IT team or search "github.com/canonical/lxd CVE-2026-34178" on the vendor's site.

CVE-2026-34178 (github.com/canonical/lxd) — CWE-20
Attack vector: remote (network-reachable) / no user interaction
Attack surface: index.yaml / backup.yaml / raw.lxc / raw.apparmor
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.

❓ What is the problem

A vulnerability (CWE-20) exists in github.com/canonical/lxd. Attackers reach the vulnerable code path via index.yaml.

📍 Affected scope

Check the vendor advisory for the affected versions of github.com/canonical/lxd. Attack surface: index.yaml / backup.yaml / raw.lxc / raw.apparmor.

🔥 Severity

Severity: ?. Successful exploitation can lead to full system takeover.

🔧 How to fix

Update to the patched release per vendor advisory.

🛡️ Workaround

Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.

🔍 Detection

Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'github.com/canonical/lxd' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.

Response actions

Concrete steps and command examples for SOC/SRE teams to execute in order

  1. 1
    Identify exposure identify
    grep -r 'github.com/canonical/lxd' . | grep -v node_modules

    リポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で github.com/canonical/lxd を grep し、稼働しているサービス・バージョンを把握する。

  2. 2
    Post-deployment verification verify
    Confirm patched version is live in production

    パッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。

Affected packages

Go github.com/canonical/lxd
[{"type":"SEMVER","events":[{"introduced":"0.0.0-20210305023314-538ac3df036e"},{"last_affected":"0.0.0-20260226085519-736f34afb267"}]}]

Fix status by distribution

Fixed packages published by each distribution for this CVE

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details