Skip to content
CVE-2026-133842

CVE-2026-133842

github.com • November 24, 2026

If an app, runtime or extension installed system-wide uses the extra-data mechanism, and its apply_extra program or script creates a very deeply-nested directory hierarchy, then it can arrange for /var/lib/flatpak to contain a setuid-root executable whose setuid permission will not be cleared by Flatpak.

A malicious local user, in cooperation with a compromised or malicious app/runtime/extension, can use the setuid-root executable for root privilege escalation.

Or, if the app/runtime/extension itself has permissions that grant it the ability to run arbitrary code as the user, then it can escalate its own privileges to root.

Or, if the app/runtime/extension combines this vulnerability with any unrelated vulnerability that provides arbitrary code execution as the user, then it can escalate its own privileges to root.

This was resolved in Flatpak 1.18.6 and 1.19.4. The 1.18.5 and 1.19.3 tags also include the fix, but the release process for those version failed and they were superseded by 1.18.6 and 1.19.4.

Fixed in Flatpak 1.18.6 (stable branch) and 1.19.4 (development branch) by commits:

d087606 "utils: Fail closed if canonicalizing permissions can't open directory"

a21a102 "utils: Fail closed when canonicalizing permissions if readdir() fails"

Automated test coverage is provided by commits:

2988601 "tests: Test deeply nested files in apply_extra output"

ab4a20d "tests: Assert that extra-data can't normally contain setuid/setgid files"

Backports of these commits are available in the flatpak-1.16.x branch for LTS distributions that have stayed on that branch, such as Debian 13. This branch is no longer supported upstream and a formal release from it will not be provided.

In the solution as currently implemented, attempts to exploit this vulnerability will leave behind a directory named similar to /var/lib/flatpak/app/$APP/$ARCH/$BRANCH/.$HASH-XXXXXX that still contains a setuid/setgid executable below the files/extra/ subdirectory, but the permissions of the files/extra subdirectory will be set so that the setuid/setgid executable is inaccessible for non-root users, preventing it from being used for privilege escalation. This limitation is tracked as #6991 .

Avoid installing untrusted apps, runtimes or extensions system-wide, even if they will only be run by unprivileged users. Do not change the polkit rules for Flatpak to allow untrusted local users to install apps, runtimes or extensions system-wide.

2026-11-13: First privately reported

2026-11-24: Fix released, public advisory

See above for commit references.

Reported by @RoyalOughtness , fixes developed by @smcv .

CVE ID obtained from Red Hat CNA.

Extracted Entities

Attack Types (1)

Platforms (1)