Junglewise Threat Intelligence

CVE-2026-41989: GnuPG Libgcrypt heap buffer overflow in ECDH decryption

CVE-2026-41989 · Severity: medium · CVSS 6.7 · Published 2026-04-23

Technologies: Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP, Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP, Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP. Vendors: Siemens, GnuPG.

Executive brief

Libgcrypt is a widely used encryption library that provides the security foundation for many applications, including GnuPG and certain Siemens industrial controllers. A vulnerability in how it handles specific cryptographic keys could allow an attacker to crash a service or potentially gain unauthorized control by corrupting the system's memory. This could lead to a denial of service or impact the integrity of operations in environments relying on this library for secure communications.

Technical details

A heap-based buffer overflow exists in Libgcrypt's _gcry_ecc_mont_decodepoint() function within cipher/ecc-misc.c. The vulnerability is caused by a miscalculation of the destination offset during a zero-padding memset() operation when decoding opaque Curve25519 or X448 points. Specifically, when the input byte length is less than half the curve's coordinate size, the memset operation overruns the allocated buffer with zero bytes. An attacker can trigger this by providing a crafted ECDH ciphertext containing a short ephemeral public point via the gcry_pk_decrypt() API. While the written value is fixed to zero, the overflow can corrupt adjacent heap metadata, leading to a crash (DoS) or potentially arbitrary code execution through heap grooming. The issue is fixed in versions 1.12.2, 1.11.3, 1.10.4, and 1.8.13.

Affected products

  • GnuPG Libgcrypt 1.8.8 to 1.10.3, 1.11.0 to 1.11.2, 1.12.0 to 1.12.1
  • Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP V3.1.5, V3.1.6
  • Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP V3.1.5, V3.1.6
  • Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP V3.1.5, V3.1.6

Timeline

  • 2026-04-07: disclosed: Vulnerability reported to GnuPG security team by Bronson Yen of Calif.io
  • 2026-04-15: patched: Libgcrypt 1.12.2 and 1.8.13 released with fixes
  • 2026-04-21: patched: Libgcrypt 1.11.3 and 1.10.4 released with fixes
  • 2026-04-23: advisory: NVD publication date

References

Related threats