head 1.2; access; symbols pkgsrc-2026Q2:1.1.0.2; locks; strict; comment @ * @; 1.2 date 2026.07.03.11.30.46; author adam; state dead; branches; next 1.1; commitid g243QkTh70F7tcMG; 1.1 date 2026.06.22.20.08.57; author wiz; state Exp; branches 1.1.2.1; next ; commitid bx6ZZsWKc1J6HPKG; 1.1.2.1 date 2026.06.22.20.08.57; author bsiegert; state dead; branches; next 1.1.2.2; commitid 5FcxZEhEB3rVAyLG; 1.1.2.2 date 2026.06.28.11.23.21; author bsiegert; state Exp; branches; next ; commitid 5FcxZEhEB3rVAyLG; desc @@ 1.2 log @gnupg2: updated to 2.5.21 Noteworthy changes in version 2.5.21 (2026-07-02) * New and extended features: - gpg, gpgsm: Use partial file on decryption, remove on failure. Disable with "--compatibility-flags=no-partial-file-guard". - gpg: Use the INT_RCP_FPR subpacket in revocation signatures. - Create a pkgversioninfo.txt file when building using the speedo build system. * Bug fixes: - gpg: Fix potential use-after-free in batch key generation when handling the keyserver URL option. - gpgsm: Fix regression in gpgsm_verify with expired certificates. - gpgsm: Require a minimum tag length for GCM decryption. - scd: Limit the size of returned APDU objects from faulty cards. - scd: Fix condition to retrieve ATR. - scd:openpgp: Fix regression in CHV1 retry counter byte index. - agent: Make batch import of Kyber keys work. - dirmngr: Add a validation check in get_dns_cert_standard. - gpgconf: Raise an error on certain parse errors. - Fix use of usleep in file remove function on Windows. Regression since 2.5.13. @ text @$NetBSD: patch-sm_decrypt.c,v 1.1 2026/06/22 20:08:57 wiz Exp $ gpgsm: Require a minimum tag length for GCM decryption. * sm/decrypt.c (gpgsm_decrypt): Require a minimum authtaglen. -- Reported-by: Thai Duong This is similar to OpenSSL's CVE-id: CVE-2026-34182 https://github.com/gpg/gnupg/commit/4c7e68cf3d335328821bdbb70db309a60d0e4fd4 --- sm/decrypt.c.orig 2026-05-13 12:33:59.000000000 +0000 +++ sm/decrypt.c @@@@ -1447,7 +1447,14 @@@@ gpgsm_decrypt (ctrl_t ctrl, estream_t in_fp, estream_t } if (DBG_CRYPTO) log_printhex (authtag, authtaglen, "Authtag ...:"); - rc = gcry_cipher_checktag (dfparm.hd, authtag, authtaglen); + if (authtaglen < 12) + { + log_info ("authentication tag is too short (%zu octets)\n", + authtaglen); + rc = gpg_error (GPG_ERR_CHECKSUM); + } + else + rc = gcry_cipher_checktag (dfparm.hd, authtag, authtaglen); xfree (authtag); if (rc) log_error ("data is not authentic: %s\n", gpg_strerror (rc)); @ 1.1 log @gnupg2: add upstream patch for CVE-2026-34182 Bump PKGREVISION. @ text @d1 1 a1 1 $NetBSD$ @ 1.1.2.1 log @file patch-sm_decrypt.c was added on branch pkgsrc-2026Q2 on 2026-06-28 11:23:21 +0000 @ text @d1 30 @ 1.1.2.2 log @Pullup ticket #7141 - requested by taca security/gnupg2: security fix Revisions pulled up: - security/gnupg2/Makefile 1.178 - security/gnupg2/distinfo 1.98 - security/gnupg2/patches/patch-sm_decrypt.c 1.1 --- Module Name: pkgsrc Committed By: wiz Date: Mon Jun 22 20:08:57 UTC 2026 Modified Files: pkgsrc/security/gnupg2: Makefile distinfo Added Files: pkgsrc/security/gnupg2/patches: patch-sm_decrypt.c Log Message: gnupg2: add upstream patch for CVE-2026-34182 Bump PKGREVISION. @ text @a0 30 $NetBSD: patch-sm_decrypt.c,v 1.1 2026/06/22 20:08:57 wiz Exp $ gpgsm: Require a minimum tag length for GCM decryption. * sm/decrypt.c (gpgsm_decrypt): Require a minimum authtaglen. -- Reported-by: Thai Duong This is similar to OpenSSL's CVE-id: CVE-2026-34182 https://github.com/gpg/gnupg/commit/4c7e68cf3d335328821bdbb70db309a60d0e4fd4 --- sm/decrypt.c.orig 2026-05-13 12:33:59.000000000 +0000 +++ sm/decrypt.c @@@@ -1447,7 +1447,14 @@@@ gpgsm_decrypt (ctrl_t ctrl, estream_t in_fp, estream_t } if (DBG_CRYPTO) log_printhex (authtag, authtaglen, "Authtag ...:"); - rc = gcry_cipher_checktag (dfparm.hd, authtag, authtaglen); + if (authtaglen < 12) + { + log_info ("authentication tag is too short (%zu octets)\n", + authtaglen); + rc = gpg_error (GPG_ERR_CHECKSUM); + } + else + rc = gcry_cipher_checktag (dfparm.hd, authtag, authtaglen); xfree (authtag); if (rc) log_error ("data is not authentic: %s\n", gpg_strerror (rc)); @