CVE-2022-1271

An arbitrary file write vulnerability was found in GNU gzip's zgrep utility. When zgrep is applied on the attacker's chosen file name (for example, a crafted file name), this can overwrite an attacker's content to an arbitrary attacker-selected file. This flaw occurs due to insufficient validation when processing filenames with two or more newlines where selected content and the target file names are embedded in crafted multi-line file names. This flaw allows a remote, low privileged attacker to force zgrep to write arbitrary files on the system.

Published: 2022-08-31 Last update: 2025-06-09 Assigner: [email protected] Source: [email protected]

Conclusion & alert: CVE-2022-1271 is rated High Risk (70.1/100): CVSS High severity, with medium exploitation likelihood (EPSS 4.30%). Core evidence: EPSS rose +3.49% over the last day, indicating growing attacker interest. Mandatory action: High exploitation likelihood—assess exposure and prioritize 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-1271

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.81% 4.30% +3.49%
2 2026-02-07 0.72% 0.81% +0.10%
3 2026-01-19 0.72%

Full EPSS history (28 records total)

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

CVSS metrics for this CVE.

Base score Version Severity Vector Exploitability Impact Score source
8.8 3.1 HIGH
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H 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:H)
Serious risk that confidential data gets exposed in a big way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:H)
Could take the service down hard or make it unusable for people who depend on it.
2.8 5.9 [email protected]
8.8 3.1 HIGH
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H 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:H)
Serious risk that confidential data gets exposed in a big way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:H)
Could take the service down hard or make it unusable for people who depend on it.
2.8 5.9 134c704f-9b21-4f2e-91b3-4a467353bcc0

Weakness enumeration for CVE-2022-1271

OS Trackers for CVE-2022-1271

vendor priority summary link
alpine CVE-2022-1271: 2 source package rows (gzip, xz); 16 state rows across 8 repos (3.12-main, 3.17-main, 3.18-main, 3.19-main, 3.20-main, 3.21-main, 3.22-main, edge-main); fixed 16, open 0. https://security.alpinelinux.org/vuln/CVE-2022-1271
debian not yet assigned CVE-2022-1271 not yet assigned priority: Debian including 2 source packages (gzip, xz-utils), 10 status rows across 5 suites (bookworm, bullseye, forky, sid, trixie): resolved 10. https://security-tracker.debian.org/tracker/CVE-2022-1271
gentoo high CVE-2022-1271: 1 GLSA(s) (202209-01), 2 atom(s) (app-arch/gzip, app-arch/xz-utils); latest impact high. https://bugs.gentoo.org/buglist.cgi?quicksearch=CVE-2022-1271
redhat high https://access.redhat.com/security/cve/CVE-2022-1271
suse high CVE-2022-1271 severity important: SUSE including 573 source package names (0.23.0.3.2.201:liblzma5-5.2.3-150000.4.7.1, 0.23.1-12.3:gzip-1.10-150200.10.1, …), 1676 product×package rows across 500 product lines (Container bci/bci-base-fips, Container bci/bci-init, … (500 product lines)): Fixed 1477, Known Affected 184, Known Not Affected 15. https://www.suse.com/security/cve/CVE-2022-1271/
ubuntu medium CVE-2022-1271 medium priority: Ubuntu including 2 source packages (gzip, xz-utils), 14 status rows across 7 suites (bionic, focal, impish, jammy, trusty, upstream, xenial): released 12, needs-triage 2. https://ubuntu.com/security/CVE-2022-1271

Affected software / configurations for CVE-2022-1271

Vendor Product Version Raw CPE
gnu gzip < 1.12 cpe:2.3:a:gnu:gzip:*:*:*:*:*:*:*:*
redhat jboss_data_grid 7.0.0 cpe:2.3:a:redhat:jboss_data_grid:7.0.0:*:*:*:*:*:*:*
debian debian_linux 10.0 cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:*
tukaani xz < 5.2.5 cpe:2.3:a:tukaani:xz:*:*:*:*:*:*:*:*

References for CVE-2022-1271

cvelogic Threat Intelligence