CVE-2022-21682 | flatpak-builder can access files outside the build directory.

Flatpak is a Linux application sandboxing and distribution framework. A path traversal vulnerability affects versions of Flatpak prior to 1.12.3 and 1.10.6. flatpak-builder applies `finish-args` last in the build. At this point the build directory will have the full access that is specified in the manifest, so running `flatpak build` against it will gain those permissions. Normally this will not be done, so this is not problem. However, if `--mirror-screenshots-url` is specified, then flatpak-builder will launch `flatpak build --nofilesystem=host appstream-utils mirror-screenshots` after finalization, which can lead to issues even with the `--nofilesystem=host` protection. In normal use, the only issue is that these empty directories can be created wherever the user has write permissions. However, a malicious application could replace the `appstream-util` binary and potentially do something more hostile. This has been resolved in Flatpak 1.12.3 and 1.10.6 by changing the behaviour of `--nofilesystem=home` and `--nofilesystem=host`.

Published: 2022-01-13 Last update: 2024-11-21 Assigner: [email protected] Source: [email protected]

Conclusion & alert: CVE-2022-21682 is rated Moderate Risk (58.2/100): CVSS High severity, with medium exploitation likelihood (EPSS 1.71%). Core evidence: EPSS rose +1.38% over the last day, indicating growing attacker interest. Mandatory action: Review affected assets and schedule remediation.

Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.

Exploit prediction scoring system (EPSS) score for CVE-2022-21682

EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).

# Date Old EPSS score New EPSS score Delta (New - Old)
1 2026-06-15 0.34% 1.71% +1.38%
2 2026-01-20 0.36% 0.34% -0.02%
3 2025-12-28 0.36%

Full EPSS history (18 records total)

Common vulnerability scoring system (CVSS) metrics for CVE-2022-21682

CVSS metrics for this CVE.

Base score Version Severity Vector Exploitability Impact Score source
7.7 3.1 HIGH
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:L)
Once they can reach the bug, pulling it off is straightforward—no weird race conditions or rare setup.
Privileges required (PR:L)
A normal user session is enough; they don’t have to be admin.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:C)
Breaking this can reach past the original component and bite other resources—bigger blast radius.
Confidentiality (C:N)
Doesn’t really leak secrets in a meaningful way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:N)
Service keeps running; no real outage angle.
3.1 4.0 [email protected]
6.5 3.1 MEDIUM
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:L)
Once they can reach the bug, pulling it off is straightforward—no weird race conditions or rare setup.
Privileges required (PR:L)
A normal user session is enough; they don’t have to be admin.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:U)
Damage stays in the same “trust bubble” as the broken component—no big spill into unrelated systems.
Confidentiality (C:N)
Doesn’t really leak secrets in a meaningful way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:N)
Service keeps running; no real outage angle.
2.8 3.6 [email protected]
4.0 2.0 MEDIUM
AV:N/AC:L/Au:S/C:N/I:P/A:N Click to expand
Access vector (AV:N)
Can be exploited remotely over network reachability.
Access complexity (AC:L)
Exploitation conditions are straightforward and predictable.
Authentication (AU:S)
A single authentication is required.
Confidentiality impact (C:N)
No confidentiality impact.
Integrity impact (I:P)
Partial integrity impact.
Availability impact (A:N)
No availability impact.
8.0 2.9 [email protected]

Weakness enumeration for CVE-2022-21682

OS Trackers for CVE-2022-21682

vendor priority summary link
alpine CVE-2022-21682: 2 source package rows (flatpak, flatpak-builder); 23 state rows across 7 repos (3.17-community, 3.18-community, 3.19-community, 3.20-community, 3.21-community, 3.22-community, edge-community); fixed 23, open 0. https://security.alpinelinux.org/vuln/CVE-2022-21682
debian not yet assigned CVE-2022-21682 not yet assigned priority: Debian including 1 source packages (flatpak), 5 status rows across 5 suites (bookworm, bullseye, forky, sid, trixie): resolved 5. https://security-tracker.debian.org/tracker/CVE-2022-21682
gentoo high CVE-2022-21682: 1 GLSA(s) (202312-12), 1 atom(s) (sys-apps/flatpak); latest impact high. https://bugs.gentoo.org/buglist.cgi?quicksearch=CVE-2022-21682
redhat medium https://access.redhat.com/security/cve/CVE-2022-21682
suse medium CVE-2022-21682 severity moderate: SUSE including 58 source package names (flatpak, flatpak-1.10.7-4.12.1, …), 169 product×package rows across 35 product lines (SUSE CaaS Platform 4.0, SUSE Enterprise Storage 6, … (35 product lines)): Fixed 122, Will Not Fix 40, Known Not Affected 7. https://www.suse.com/security/cve/CVE-2022-21682/
ubuntu low CVE-2022-21682 low priority: Ubuntu including 1 source packages (flatpak), 15 status rows across 15 suites (bionic, focal, hirsute, impish, jammy, kinetic, lunar, mantic, noble, oracular, plucky, questing, trusty, upstream, xenial): not-affected 6, ignored 5, needs-triage 3, released 1. https://ubuntu.com/security/CVE-2022-21682

Affected software / configurations for CVE-2022-21682

Vendor Product Version Raw CPE
flatpak flatpak < 1.10.7 cpe:2.3:a:flatpak:flatpak:*:*:*:*:*:*:*:*
flatpak flatpak >= 1.11.1, < 1.12.4 cpe:2.3:a:flatpak:flatpak:*:*:*:*:*:*:*:*
flatpak flatpak-builder < 1.2.2 cpe:2.3:a:flatpak:flatpak-builder:*:*:*:*:*:*:*:*
fedoraproject fedora 35 cpe:2.3:o:fedoraproject:fedora:35:*:*:*:*:*:*:*
redhat enterprise_linux 8.0 cpe:2.3:o:redhat:enterprise_linux:8.0:*:*:*:*:*:*:*
debian debian_linux 9.0 cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*
debian debian_linux 10.0 cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:*
debian debian_linux 11.0 cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:*

References for CVE-2022-21682

cvelogic Threat Intelligence