Fedora has shipped an update to Flatpak 1.18.6 addressing CVE-2026-133842 (GHSA-p4mw-6jfq-r82r), a vulnerability that allowed a compromised or malicious application, runtime, or extension using extra-data to create setuid root files on the host system during installation. The bug was reported by RoyalOughtness and disclosed through the Fedora advisory channel (linuxsecurity.com advisory).
This is not a sandbox escape in the classic sense — it is worse in some ways. Flatpak's entire security promise rests on the assumption that installing an application is a safe operation, even if the application itself is hostile. CVE-2026-133842 breaks that assumption: an attacker who controls a Flatpak package, or compromises a runtime/extension consumed by an otherwise-trusted app, can plant a root-owned setuid binary on the host filesystem at install time. From there, any unprivileged process — including a confined one — can execute that binary and gain root on the host. That converts a single-package compromise into a full host privilege escalation primitive, and it fits neatly into supply-chain threat models where malicious Flatpaks are distributed via lookalike repositories or compromised upstreams.
If you run Fedora (or any distribution consuming the same Flatpak release) and install Flatpaks — particularly from third-party remotes or with --system installation — treat this as a priority patch. The remainder of this post breaks down the mechanics, detection opportunities, and a verification script you can run fleet-wide.
Technical Analysis
Affected Products and Versions
- Component: Flatpak, the Linux application sandboxing and distribution framework
- Fixed version: 1.18.6
- Affected versions: Flatpak releases prior to 1.18.6 that support
extra-datain application, runtime, or extension manifests - Distribution: Fedora (advisory FEDORA-FLATPAK-2026-333e4d33d7); other distributions shipping vulnerable Flatpak builds should be checked independently
- CVE: CVE-2026-133842, also tracked as GHSA-p4mw-6jfq-r82r
- Reporter: RoyalOughtness
How the Vulnerability Works
Flatpak's extra-data mechanism exists to handle applications that cannot be distributed directly (e.g., proprietary binaries that must be downloaded at install time). The manifest declares an external payload, and Flatpak fetches and stages it during installation. Critically, when Flatpaks are installed system-wide — the default for most Fedora desktop workflows — the installation process runs with elevated privileges because it writes to /var/lib/flatpak.
CVE-2026-133842 is a failure to sanitize file permissions during that staging process. A malicious or compromised app, runtime, or extension crafted with extra-data could cause Flatpak to create files on the host with the setuid bit set and root ownership. The attack chain from a defender's perspective:
- Victim installs (or updates) a Flatpak — possibly a legitimate package whose runtime or extension was compromised upstream, or a malicious package from a lookalike remote.
- During install/update, the vulnerable Flatpak writes attacker-controlled files to the host filesystem with mode
4755(or similar setuid-root permissions). - Attacker code — running at any privilege level, including inside a confined sandbox — executes the planted setuid binary.
- The binary runs with effective UID 0, yielding root on the host. Sandboxing is irrelevant at this point; the attacker has escaped to full host control.
The exploitation requirements are favorable to defenders in one respect: the victim must actually install the malicious package. That means distribution requires either a supply-chain angle (compromised runtime/extension in a trusted dependency chain) or social engineering (tricking users into adding a malicious remote and installing from it). Neither is a high bar in targeted campaigns.
Exploitation Status
As of the advisory publication, there is no confirmed in-the-wild exploitation, no public weaponized PoC of note, and the CVE has not been added to CISA's Known Exploited Vulnerabilities catalog. The flaw was reported responsibly and fixed before disclosure. That said, install-time filesystem-planting bugs are straightforward to reverse-engineer from patch diffs, and Flatpak is ubiquitous on Fedora, RHEL-family derivatives, and increasingly on immutable/atomic desktop distributions. The window between patch availability and opportunistic exploitation is typically measured in days for defects of this class. Patch before there is a PoC, not after.
Detection & Response
For this vulnerability, the highest-value detection surface is the filesystem itself: setuid root files that appeared under Flatpak-managed paths, unexpected new setuid binaries anywhere on the host, and install-time process behavior. Behavioral process rules are secondary here because the malicious write happens inside legitimate Flatpak install flows — but auditing what flatpak child processes touch and hunting for anomalous setuid artifacts is high signal and low noise.
Sigma Rules
---
title: Flatpak Install Process Creating setuid Files
timestamp: 2026/05/12
id: 3f8c2a41-9b7d-4e6f-a1c2-5d8e9f0a1b2c
status: experimental
description: Detects chmod calls setting the setuid bit by flatpak, flatpak-helper, or install-helper processes. During CVE-2026-133842 exploitation, install-time helper processes plant setuid root files on the host. Legitimate Flatpak installs should never need to set the setuid bit on staged extra-data.
references:
- https://linuxsecurity.com/advisories/fedora/fedora-flatpak-2026-333e4d33d7
- https://attack.mitre.org/techniques/T1548/001/
author: Security Arsenal
date: 2026/05/12
tags:
- attack.privilege_escalation
- attack.t1548.001
logsource:
category: process_creation
product: linux
detection:
selection_img:
Image|endswith:
- '/flatpak'
- '/flatpak-helper'
- '/flatpak-bwrap'
selection_chmod:
CommandLine|contains:
- 'chmod '
- '4755'
- 'u+s'
- 'setuid'
condition: selection_img and selection_chmod
falsepositives:
- Rare; legitimate Flatpak install flows do not apply setuid bits to staged payloads
level: high
---
title: New setuid Root File Created Under Flatpak Paths
timestamp: 2026/05/12
id: 8a1d4e6b-2c9f-4a7b-b3d1-6e0f4a5c7d8e
status: experimental
description: Detects creation of files with setuid permission under Flatpak system or user installation directories, the primary artifact left by CVE-2026-133842 exploitation. Correlate with recent flatpak install/update activity.
references:
- https://linuxsecurity.com/advisories/fedora/fedora-flatpak-2026-333e4d33d7
- https://attack.mitre.org/techniques/T1548/001/
author: Security Arsenal
date: 2026/05/12
tags:
- attack.privilege_escalation
- attack.t1548.001
- attack.persistence
logsource:
category: file_event
product: linux
detection:
selection:
TargetFilename|contains:
- '/var/lib/flatpak/'
- '/.local/share/flatpak/'
Message|contains:
- 'setuid'
- '4755'
- 'mode=4755'
falsepositives:
- None expected; Flatpak-managed content should never include setuid binaries
level: critical
KQL (Microsoft Sentinel / Defender)
If you ingest Linux auditd/Syslog into Sentinel, this query hunts for setuid artifacts under Flatpak paths and chmod activity from Flatpak install processes. Pair it with your patch-compliance data to scope to unpatched hosts.
// Hunt for setuid file creation under Flatpak install paths (CVE-2026-133842)
// Requires Syslog/auditd ingestion into Sentinel
Syslog
| where TimeGenerated >= ago(14d)
| where Facility == "audit" or SyslogMessage has_any ("chmod", "setuid", "4755", "flatpak")
| where SyslogMessage has_any ("/var/lib/flatpak", ".local/share/flatpak")
| where SyslogMessage has_any ("4755", "u+s", "setuid")
| project TimeGenerated, Computer, SyslogMessage, ProcessName, ProcessID
| summarize Count = count(), Sample = any(SyslogMessage) by Computer, ProcessName
| order by Count desc
Velociraptor VQL
This artifact enumerates setuid root files under Flatpak-managed directories across the fleet — the smoking-gun artifact of this vulnerability. A hit on this hunt on any endpoint is a near-certain indicator of compromise and warrants immediate DFIR triage.
-- CVE-2026-133842: Hunt for setuid root files planted under Flatpak install paths
-- Any result is highly anomalous -- Flatpak content should never be setuid
SELECT FullPath, Mtime AS Modified, Atime AS Accessed,
Mode AS Permissions, Uid, Gid, Size
FROM glob(globs=[
"/var/lib/flatpak/**/*.setuid",
"/var/lib/flatpak/app/**",
"/var/lib/flatpak/runtime/**",
"/home/*/.local/share/flatpak/**"
],
accessor="file",
permissions=0o4000)
Remediation and Verification Script
Run this on Fedora (and derivative) endpoints to verify the patched Flatpak version is installed and audit for residual setuid artifacts under Flatpak paths. Deploy via your configuration management or MDM pipeline and alert on any non-zero audit findings.
#!/usr/bin/env bash
# CVE-2026-133842 remediation/verification - Fedora Flatpak setuid host escalation
set -euo pipefail
REQUIRED_VERSION="1.18.6"
echo "[+] Checking installed flatpak version..."
CURRENT=$(rpm -q flatpak --qf '%{VERSION}' 2>/dev/null || flatpak --version | awk '{print $NF}')
echo " Installed: ${CURRENT}"
version_ge() {
[ "$(printf '%s\n%s\n' "$2" "$1" | sort -V | head -n1)" = "$2" ]
}
if version_ge "$CURRENT" "$REQUIRED_VERSION"; then
echo "[OK] Flatpak ${CURRENT} >= ${REQUIRED_VERSION} (patched against CVE-2026-133842)"
else
echo "[!] VULNERABLE: Flatpak ${CURRENT} < ${REQUIRED_VERSION}"
echo " Applying update now..."
sudo dnf upgrade --refresh -y flatpak
fi
echo "[+] Auditing for setuid files under Flatpak install paths..."
FINDINGS=0
for dir in /var/lib/flatpak "$HOME/.local/share/flatpak" /home/*/.local/share/flatpak; do
if [ -d "$dir" ]; then
HITS=$(find "$dir" -perm -4000 -type f 2>/dev/null || true)
if [ -n "$HITS" ]; then
echo "[!] SUSPICIOUS setuid files found in ${dir}:"
echo "$HITS"
FINDINGS=1
fi
fi
done
if [ "$FINDINGS" -eq 0 ]; then
echo "[OK] No setuid files under Flatpak-managed paths."
else
echo "[!!] IOC DETECTED - isolate host and begin DFIR triage immediately."
exit 2
fi
echo "[+] Auditing system-wide for recently-added setuid binaries (last 30 days)..."
find / -xdev -perm -4000 -type f -mtime -30 2>/dev/null | \
grep -vE '^/(usr/)?(bin|sbin|libexec)/' || echo " None found outside standard locations."
Remediation
Primary action — patch immediately:
# Fedora: refresh metadata and upgrade flatpak to 1.18.6 or later
sudo dnf upgrade --refresh flatpak
# Verify
dnf info flatpak | grep -i version
# Expected: 1.18.6 or higher
Additional hardening and verification steps:
- Audit for artifacts before assuming a clean state. If vulnerable Flatpak versions were installed alongside untrusted third-party remotes, run the setuid audit above. The patch prevents new exploitation; it does not remove files already planted.
- Review configured remotes. Enumerate remotes with
flatpak remotes -dand remove any that are not explicitly trusted. This vulnerability's realistic attack vector is a malicious or compromised package source — shrinking the remote attack surface directly reduces exposure. - Prefer user installations where feasible.
--userinstalls do not write to root-owned paths and constrain install-time filesystem impact. System-wide installs remain common on managed fleets; evaluate policy accordingly. - Pin and verify upstream sources. For organizations building their own Flatpaks, verify runtime and extension integrity and treat
extra-datamanifests as untrusted input in build pipelines. - Reference advisories:
- Fedora advisory: https://linuxsecurity.com/advisories/fedora/fedora-flatpak-2026-333e4d33d7
- GitHub Security Advisory: GHSA-p4mw-6jfq-r82r
- CVE: CVE-2026-133842
- No CISA KEV deadline applies at time of publication — the CVE is not KEV-listed. Do not let the absence of a federal mandate drive your prioritization; an unauthenticated install-time root primitive on desktop Linux estates deserves same-cycle patching.
Final Assessment
CVE-2026-133842 is a reminder that install-time trust boundaries are as critical as runtime sandboxing. Flatpak users trusted the installer to be safe even when the payload was not — and that assumption failed. The fix is available, the artifact detection is high-signal, and the audit is a five-minute operation per host. Patch, audit for setuid artifacts, review your remotes, and move on. If you find a planted setuid binary under /var/lib/flatpak, you are no longer in a vulnerability-management conversation — you are in incident response.
Related Resources
Security Arsenal Penetration Testing Services AlertMonitor Platform Book a SOC Assessment vulnerability-management Intel Hub
Is your security operations ready?
Get a free SOC assessment or see how AlertMonitor cuts through alert noise with automated triage.