CVE-2025-68973
NixOS vulnerability analysis and mitigation

Overview

CVE-2025-68973 is an out-of-bounds write vulnerability in GnuPG's ASCII armor parser, caused by a double-increment logic error in the armor_filter function within g10/armor.c. The bug, introduced in 1999, causes an index variable to be incremented twice where only one increment is intended, resulting in memory corruption when processing specially crafted input. It affects GnuPG versions through 2.4.8 (fixed in 2.4.9) and through 2.2.50 for the ExtendedLTS branch (fixed in 2.2.51). The vulnerability was publicly disclosed on December 28, 2025, and carries a CVSS v3.1 base score of 7.0 (High) (Feedly, GnuPG Commit).

Technical details

The root cause is a logic error (CWE-675: Multiple Operations on Resource in Single-Operation Context; CWE-787: Out-of-bounds Write) in the armor_filter function in g10/armor.c. The vulnerable code path contains a for loop where both the output buffer index n and the source buffer position afx->buffer_pos are incremented via n++ in the loop condition and buf[n++] = afx->buffer[afx->buffer_pos++] in the body — resulting in n being incremented twice per iteration. This causes every other byte in the output buffer to be uninitialized garbage and can write data beyond the intended buffer boundary. The code path is only reachable with specially crafted input, and the upstream commit notes that no fuzzing had previously triggered it (GnuPG Commit, oss-security). The fix removes the erroneous n++ from the loop increment expression, leaving only the body-level increment.

Impact

Successful exploitation could allow a local attacker with low privileges to trigger memory corruption in GnuPG's armor parsing code, potentially leading to arbitrary code execution or system compromise. The vulnerability affects confidentiality, integrity, and availability at a high level, as arbitrary code execution in the context of the GnuPG process could expose private keys, allow tampering with cryptographic operations, or crash the application. Downstream products incorporating GnuPG — including IBM CICS TX, IBM Netezza Appliance, IBM API Connect, IBM Instana, Oracle Linux, Red Hat Enterprise Linux, Debian, Ubuntu, SUSE, and Splunk AppDynamics agents — are also affected (Feedly, IBM Advisory).

Exploitability

As of the time of disclosure, there is no public proof-of-concept exploit and no evidence of active in-the-wild exploitation (Feedly Executive Summary). The EPSS score is approximately 0.012% (0.000120), indicating a very low probability of exploitation in the near term. The vulnerability requires local access with low privileges and high attack complexity, limiting its immediate risk. It is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog. A test case using base64+gzipped crafted input was provided in the upstream fix commit to demonstrate uninitialized memory access under Valgrind (GnuPG Commit).

Exploitation steps

  1. Reconnaissance: Identify systems running GnuPG versions prior to 2.4.9 (or prior to 2.2.51 for ExtendedLTS) with local access available.
  2. Craft malicious input: Prepare a specially crafted ASCII-armored PGP message that triggers the double-increment code path in armor_filter. The upstream commit provides a base64+gzipped test payload that demonstrates uninitialized memory access.
  3. Trigger the vulnerability: Feed the crafted armored input to GnuPG (e.g., via gpg --decrypt or gpg --verify) as a low-privileged local user, causing the armor_filter function to write out-of-bounds data into the I/O buffer.
  4. Achieve memory corruption: The double-increment causes every other byte in the output buffer to contain uninitialized data, potentially corrupting adjacent memory structures.
  5. Escalate to code execution: With a carefully crafted payload and knowledge of memory layout, an attacker may be able to control the corrupted memory region to redirect execution flow and achieve arbitrary code execution in the GnuPG process context (GnuPG Commit, oss-security).

Indicators of compromise

  • Logs: GnuPG error output referencing "invalid armor" or corrupt input when processing armored messages; unexpected crashes or segmentation faults in the gpg process.
  • Process: Unusual child processes spawned by gpg or gpg2; gpg processes consuming abnormal memory or crashing unexpectedly.
  • File System: Unexpected files written to directories where GnuPG operates, particularly if output file paths are manipulated; core dump files (core) generated by the gpg process.
  • Network: Outbound connections from systems where GnuPG is used in automated pipelines, following processing of externally sourced armored data (may indicate post-exploitation activity).

Mitigation and workarounds

The primary remediation is to upgrade GnuPG to version 2.4.9 or later (stable branch) or 2.2.51 or later (ExtendedLTS branch). The fix is a one-line change in g10/armor.c removing the erroneous double-increment in the armor_filter loop (GnuPG Commit). Major Linux distributions have released updated packages: Red Hat (RHSA-2026:0697, RHSA-2026:0719, RHSA-2026:0728, and others), Debian, Ubuntu, SUSE, Slackware, Fedora, Oracle Linux, and Amazon Linux 2. Downstream vendors including IBM (CICS TX, Netezza, API Connect, Instana) and Splunk (AppDynamics agents) have also released patches (IBM Advisory, Splunk Advisory). As a workaround where patching is not immediately possible, restrict local user access to systems running vulnerable GnuPG versions and avoid processing untrusted armored input.

Community reactions

The vulnerability was part of a broader batch of GnuPG security issues disclosed via the gpg.fail website and the oss-security mailing list in late December 2025, which attracted significant community attention (oss-security). Security researchers on Mastodon and Bluesky noted the disclosure, and the CISA published a vulnerability bulletin (SB25-363) referencing the issue. The GnuPG maintainer acknowledged the bug dates back to 1999 and was introduced during a major rewrite of armor.c, noting in the commit message that "memory corruption can never be tolerated as it always has the potential for remote code execution" (GnuPG Commit). Multiple Linux distribution security teams responded promptly with updated packages across January–February 2026.

Additional resources

Linux Distribution fix status

Fix availability across major Linux distributions and their releases.

Debian

Fixed

bookworm

gnupg2: 2.2.40-1.1+deb12u2

Fixed

sid

gnupg2: 2.4.8-5

Fixed

trixie

gnupg2: 2.4.7-21+deb13u1

Fixed

RHEL / CentOS

Fixed

OpenShift

Not Affected

RHEL 8

:baseos:gnupg2-0:2.2.20-4.el8_10.src

Fixed

RHEL 9

:appstream:gnupg2-0:2.3.3-2.el9_0.1.src

Fixed

RHEL 10

gnupg2-0:2.4.5-2.el10_0.1.src

Fixed

Alpine

Fixed

edge

gnupg: 2.4.9-r0

Fixed

v3.20

gnupg: 2.4.9-r0

Fixed

v3.21

gnupg: 2.4.9-r0

Fixed

v3.22

gnupg: 2.4.9-r0

Fixed

v3.23

gnupg: 2.4.9-r0

Fixed

SourceThis report was generated using AI

Related NixOS vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-86738CRITICAL9.3
  • NixOS logoNixOS
  • snipe-it
NoYesSep 08, 2026
CVE-2026-86734HIGH7.1
  • NixOS logoNixOS
  • snipe-it
NoYesSep 08, 2026
CVE-2026-86735MEDIUM5.9
  • NixOS logoNixOS
  • snipe-it
NoYesSep 08, 2026
CVE-2026-86737MEDIUM5.3
  • NixOS logoNixOS
  • snipe-it
NoYesSep 08, 2026
CVE-2026-86736MEDIUM5.3
  • NixOS logoNixOS
  • snipe-it
NoYesSep 08, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management