diff --git a/pkgs/tools/misc/starship/default.nix b/pkgs/tools/misc/starship/default.nix index ce82cb7745c7..93db870a2607 100644 --- a/pkgs/tools/misc/starship/default.nix +++ b/pkgs/tools/misc/starship/default.nix @@ -1,6 +1,7 @@ { lib , stdenv , fetchFromGitHub +, fetchpatch , rustPlatform , installShellFiles , cmake @@ -22,6 +23,14 @@ rustPlatform.buildRustPackage rec { hash = "sha256-3IO9hHuhzJsCHU/6BA5ylEKQI2ik6ZiRul/iO/vzii4="; }; + patches = [ + (fetchpatch { + name = "CVE-2024-41815.patch"; + url = "https://github.com/starship/starship/commit/cfc58161e0ec595db90af686ad77a73df6d44d74.patch"; + hash = "sha256-JlhrcCsvIMH1XnFsx2b65Kbbe9Hsy7ffUMha1BISwtI="; + }) + ]; + nativeBuildInputs = [ installShellFiles cmake ]; buildInputs = lib.optionals stdenv.isDarwin [ Security Foundation Cocoa ];