CVE-2026-33897: Incus vulnerable to arbitrary file read and write through pongo templates
Summary Instance template files can be used to cause arbitrary read or writes as root on the host server.
Details Incus allows for pongo2 templates within instances which can be used at various times in the instance lifecycle to template files inside of the instance. This particular implementation of pongo2 within Incus allowed for file read/write but with the expectation that the pongo2 chroot feature would isolate all such access to the instance's filesystem.
This was allowed such that a template could theoretically read a file and then generate a new version of said file.
Unfortunately the chroot isolation mechanism is entirely skipped by pongo2 leading to easy access to the entire system's filesystem with root privileges.
Credit This issue was discovered and reported by the team at 7asecurity
Other sources
Incus is a system container and virtual machine manager. Prior to version 6.23.0, instance template files can be used to cause arbitrary read or writes as root on the host server. Incus allows for pongo2 templates within instances which can be used at various times in the instance lifecycle to template files inside of the instance. This particular implementation of pongo2 within Incus allowed for file read/write but with the expectation that the pongo2 chroot feature would isolate all such access to the instance's filesystem. This was allowed such that a template could theoretically read a file and then generate a new version of said file. Unfortunately the chroot isolation mechanism is entirely skipped by pongo2 leading to easy access to the entire system's filesystem with root privileges. Version 6.23.0 patches the issue.
— MITRE
Affected Software
Event History
Frequently Asked Questions
What is the severity of CVE-2026-33897?
CVE-2026-33897 has a high severity due to its potential for arbitrary file read and write as root.
How do I fix CVE-2026-33897?
To fix CVE-2026-33897, upgrade your Incus installation to version 6.23.0 or later.
What versions of Incus are affected by CVE-2026-33897?
CVE-2026-33897 affects all versions of Incus prior to 6.23.0.
What types of systems are vulnerable with CVE-2026-33897?
Systems using Incus as a system container and virtual machine manager before version 6.23.0 are vulnerable.
What are the implications of CVE-2026-33897 for system security?
The implications of CVE-2026-33897 include potential unauthorized access to sensitive files and modification of system configurations.