Flatpak 1.18.6 arrives with fixes for two sandbox-breaking vulnerabilities
Flatpak's security patch release plugs a setuid root-escalation flaw and a portal file-descriptor leak, landing amid what is by any measure the project's busiest security year yet.
Flatpak 1.18.6 shipped today, and this time the news is entirely in the backend. The release closes two vulnerabilities in the Flatpak system helper and portal infrastructure: one that could hand a malicious application a shortcut to root, and another that lets an ordinary sandboxed program escape its isolation.
Both vulnerabilities sit in the critical-to-high range. Both are already patched in 1.18.6 and in the development branch's 1.19.4. If you're running anything older than 1.18.5, or 1.19.x below 1.19.3, you're vulnerable.
To see why this release matters, it helps to remember what Flatpak's sandbox actually does. Each app runs isolated from the host using kernel namespaces, seccomp filters, bind mounts, and the bubblewrap helper. Access to host resources is not granted by default, and that boundary is the entire value proposition. Both CVEs strike it directly.
A backdoor to root through extra-data
CVE-2026-133842 is the more serious of the two, and it's rated critical. A researcher known as RoyalOughtness found it, and Simon McVittie (GitHub: smcv) wrote the fix.
Flatpak's extra-data mechanism lets an application download large resources during install. Think game assets or ML model files that simply don't fit inside the immutable OSTree tree. When such an app is installed system-wide, Flatpak runs its apply_extra program as part of the privileged install. The trouble begins when apply_extra builds a very deeply nested directory tree.
Under those conditions, the step that clears dangerous setuid and setgid bits from freshly created files can fail with EMFILE, meaning the process exhausts its open file descriptors while walking the deep tree. When that canonicalization fails, Flatpak may leave a setuid-root executable sitting in the host's /var/lib/flatpak/app directory.
A leftover setuid-root binary is basically a backdoor. Depending on the scenario, a malicious local user working with a compromised app could escalate to root, or an app that already runs code as the user could climb all the way up.
The fix is, frankly, as boring as a security fix gets. Flatpak now fails closed: if it cannot open the directory or a readdir() call fails, it aborts rather than leaving an insecure state behind. Automated tests confirm that deeply nested extra-data output can't normally ship setuid files.
There is one caveat. An exploitation attempt could still leave a directory containing a setuid executable, but Flatpak sets the permissions on the files/extra subdirectory so that non-root users can't actually reach it. That neutralizes the path.
A leak that unlocks the whole sandbox
CVE-2026-133845 is the one researchers will remember. It's rated high, reported by refi64 with an independent rediscovery by oz9un, and patched by refi64 and smcv.
The flaw lives in flatpak-portal, the privileged helper that does things on an app's behalf. When the portal spawns a sub-sandbox, its third Spawn argument can map two different file descriptors to the same handle. An internal dup2() call then fails, and because that failure wasn't handled, the code fell through and leaked a privileged file descriptor that was originally open inside the portal down into the sandbox.
Here's the nasty part. An attacker can reasonably predict the file descriptor number of the unfiltered D-Bus session bus. Get a hold of that fd, and per the advisory you have "enough to achieve a full sandbox escape."
The fix came in two layers. First, an immediate mitigation to exit the child process if mapping fds fails. Then a more thorough fix using a new FlatpakUniqueFDList utility that tracks unique fds inside a D-Bus message, preventing any single fd from being reused.
If you thought this was an isolated blunder, it isn't. 2026 has been an intense year for Flatpak security. Earlier this year, 1.18.1 shipped with roughly ten separate vulnerabilities fixed, including full sandbox escapes and local root escalation. Then 1.18.4 brought another six CVEs in late September. 1.18.6 rounds out the calendar with two more.
Keep in mind that this reflects a genuine increase in security auditing of sandboxed software, plus a mature coordinated-disclosure process. Flatpak credits external researchers and works with teams like AISLE in cooperation with Red Hat. The project has also been bundling updated copies of bubblewrap and xdg-dbus-proxy, both of which have their own CVE histories.
One more thing for enterprise readers. The fixes were backported to the older 1.16.x branch for LTS distributions such as Debian 13. But since that branch is no longer supported upstream, no formal release will come from it. Distribution maintainers have to deliver the patches themselves. If you're on an LTS distro, verify with your vendor rather than assuming you're covered.
So what should you actually do? Update Flatpak itself to 1.18.6 as soon as your distro offers it, since the runtime and helper are what these flaws touch. Then update your installed apps and runtimes, which typically ship newer bundled copies of the affected components.
And for least-privilege sanity: avoid changing polkit rules to let unprivileged users install apps system-wide, and be cautious about installing untrusted software system-wide at all.
Head here to the GitHub release page.
