From b41deedb6242acd17582ae41d4c87defe55cb618 Mon Sep 17 00:00:00 2001 From: Thomas Gerbet Date: Tue, 8 Oct 2024 22:12:22 +0200 Subject: [PATCH] unzip: apply patch for CVE-2021-4217 https://bugs.launchpad.net/ubuntu/+source/unzip/+bug/1957077 --- pkgs/tools/archivers/unzip/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/tools/archivers/unzip/default.nix b/pkgs/tools/archivers/unzip/default.nix index 2b353598a328..50e2261aa7d4 100644 --- a/pkgs/tools/archivers/unzip/default.nix +++ b/pkgs/tools/archivers/unzip/default.nix @@ -63,6 +63,11 @@ stdenv.mkDerivation rec { # Clang 16 makes implicit declarations an error by default for C99 and newer, causing the # configure script to fail to detect errno and the directory libraries on Darwin. ./implicit-declarations-fix.patch + (fetchurl { + name = "CVE-2021-4217.patch"; + url = "https://git.launchpad.net/ubuntu/+source/unzip/plain/debian/patches/CVE-2021-4217.patch?id=94a790fcbb5d6c53cdf5d786bcaa0b8dc10309b6"; + hash = "sha256-YKE4jVNSlrHLbszXNYYRtAQs0ly4AsodEz6tadMIVqE="; + }) ] ++ lib.optional enableNLS (fetchurl { url = "https://gitweb.gentoo.org/repo/gentoo.git/plain/app-arch/unzip/files/unzip-6.0-natspec.patch?id=56bd759df1d0c750a065b8c845e93d5dfa6b549d";