diff options
Diffstat (limited to 'pkgs/tools/security')
104 files changed, 181 insertions, 183 deletions
diff --git a/pkgs/tools/security/acsccid/default.nix b/pkgs/tools/security/acsccid/default.nix index 74a0c39cb2d7..8bf7ae948000 100644 --- a/pkgs/tools/security/acsccid/default.nix +++ b/pkgs/tools/security/acsccid/default.nix @@ -37,7 +37,7 @@ stdenv.mkDerivation rec { buildInputs = [ pcsclite libusb1 - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ libiconv ]; diff --git a/pkgs/tools/security/adreaper/default.nix b/pkgs/tools/security/adreaper/default.nix index 873760250618..4e7c554e9164 100644 --- a/pkgs/tools/security/adreaper/default.nix +++ b/pkgs/tools/security/adreaper/default.nix @@ -17,7 +17,7 @@ buildGoModule rec { vendorHash = "sha256-lU39kj/uz0l7Rodsu6+UMv2o579eu1KUbutUNZni7bM="; - postInstall = lib.optionalString (!stdenv.isDarwin) '' + postInstall = lib.optionalString (!stdenv.hostPlatform.isDarwin) '' mv $out/bin/ADReaper $out/bin/$pname ''; diff --git a/pkgs/tools/security/age-plugin-ledger/default.nix b/pkgs/tools/security/age-plugin-ledger/default.nix index 516edc55db39..c20429968f4e 100644 --- a/pkgs/tools/security/age-plugin-ledger/default.nix +++ b/pkgs/tools/security/age-plugin-ledger/default.nix @@ -29,7 +29,7 @@ rustPlatform.buildRustPackage rec { buildInputs = [ libusb1 openssl - ] ++ lib.optional stdenv.isDarwin AppKit; + ] ++ lib.optional stdenv.hostPlatform.isDarwin AppKit; nativeCheckInputs = [ rage diff --git a/pkgs/tools/security/age-plugin-yubikey/default.nix b/pkgs/tools/security/age-plugin-yubikey/default.nix index e69d4dc789fb..9022442f62a8 100644 --- a/pkgs/tools/security/age-plugin-yubikey/default.nix +++ b/pkgs/tools/security/age-plugin-yubikey/default.nix @@ -30,8 +30,8 @@ rustPlatform.buildRustPackage rec { buildInputs = [ openssl ] - ++ lib.optional stdenv.isLinux pcsclite - ++ lib.optionals stdenv.isDarwin [ + ++ lib.optional stdenv.hostPlatform.isLinux pcsclite + ++ lib.optionals stdenv.hostPlatform.isDarwin [ IOKit Foundation PCSC diff --git a/pkgs/tools/security/amber/default.nix b/pkgs/tools/security/amber/default.nix index 5cb96596564c..a02c0a7236cf 100644 --- a/pkgs/tools/security/amber/default.nix +++ b/pkgs/tools/security/amber/default.nix @@ -14,7 +14,7 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-Joy+SO1zR78Eh5eK2bxyT0l3hCuLX/J3u/UvN+++6vg="; - buildInputs = lib.optionals stdenv.isDarwin [ Security ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ Security ]; meta = with lib; { description = "Manage secret values in-repo via public key cryptography"; diff --git a/pkgs/tools/security/ares-rs/default.nix b/pkgs/tools/security/ares-rs/default.nix index 433cdaa5792a..b23f13de05ef 100644 --- a/pkgs/tools/security/ares-rs/default.nix +++ b/pkgs/tools/security/ares-rs/default.nix @@ -1,25 +1,26 @@ -{ lib -, rustPlatform -, fetchFromGitHub +{ + lib, + rustPlatform, + fetchFromGitHub, }: rustPlatform.buildRustPackage rec { pname = "ares-rs"; - version = "0.9.0"; + version = "0.10.0"; src = fetchFromGitHub { owner = "bee-san"; repo = "ares"; - rev = "refs/tags/${version}"; + rev = "refs/tags/v${version}"; hash = "sha256-F+uBGRL1G8kiNZUCsiPbISBfId5BPwShenusqkcsHug="; }; - cargoHash = "sha256-7zDq66oWT+j6t9LEBUoeby8MQ1Ihhvk3KLwWPQAThyc="; + cargoHash = "sha256-c50HCwWwW4Fyg6hC1JqBfKtwq6kgReSOIBYXvwm04yA="; meta = with lib; { description = "Automated decoding of encrypted text without knowing the key or ciphers used"; homepage = "https://github.com/bee-san/ares"; - changelog = "https://github.com/bee-san/Ares/releases/tag${version}"; + changelog = "https://github.com/bee-san/Ares/releases/tag/v${version}"; license = licenses.mit; maintainers = with maintainers; [ fab ]; mainProgram = "ares"; diff --git a/pkgs/tools/security/arti/default.nix b/pkgs/tools/security/arti/default.nix index 21d8ee4ae154..1e93dae95961 100644 --- a/pkgs/tools/security/arti/default.nix +++ b/pkgs/tools/security/arti/default.nix @@ -23,11 +23,11 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-I45SaawWAK7iTZDFhJT4YVO439D/3NmWLp3FtFmhLC0="; - nativeBuildInputs = lib.optionals stdenv.isLinux [ pkg-config ]; + nativeBuildInputs = lib.optionals stdenv.hostPlatform.isLinux [ pkg-config ]; buildInputs = [ sqlite ] - ++ lib.optionals stdenv.isLinux [ openssl ] - ++ lib.optionals stdenv.isDarwin [ CoreServices ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ openssl ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ CoreServices ]; cargoBuildFlags = [ "--package" "arti" ]; diff --git a/pkgs/tools/security/authoscope/default.nix b/pkgs/tools/security/authoscope/default.nix index b44f8bec2f7f..e30a00ff5be1 100644 --- a/pkgs/tools/security/authoscope/default.nix +++ b/pkgs/tools/security/authoscope/default.nix @@ -32,7 +32,7 @@ rustPlatform.buildRustPackage rec { libcap zlib openssl - ] ++ lib.optional stdenv.isDarwin Security; + ] ++ lib.optional stdenv.hostPlatform.isDarwin Security; postInstall = '' installManPage docs/${pname}.1 diff --git a/pkgs/tools/security/bettercap/default.nix b/pkgs/tools/security/bettercap/default.nix index db1104447951..5594bc106beb 100644 --- a/pkgs/tools/security/bettercap/default.nix +++ b/pkgs/tools/security/bettercap/default.nix @@ -25,7 +25,7 @@ buildGoModule rec { nativeBuildInputs = [ pkg-config ]; buildInputs = [ libpcap libusb1 ] - ++ lib.optionals stdenv.isLinux [ libnfnetlink libnetfilter_queue ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ libnfnetlink libnetfilter_queue ]; meta = with lib; { description = "Man in the middle tool"; diff --git a/pkgs/tools/security/boofuzz/default.nix b/pkgs/tools/security/boofuzz/default.nix index 5c2418cad665..b254b9d3d191 100644 --- a/pkgs/tools/security/boofuzz/default.nix +++ b/pkgs/tools/security/boofuzz/default.nix @@ -46,7 +46,7 @@ python3.pkgs.buildPythonApplication rec { "TestNoResponseFailure" "TestProcessMonitor" "TestSocketConnection" - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ "test_time_repeater" ]; diff --git a/pkgs/tools/security/browserpass/default.nix b/pkgs/tools/security/browserpass/default.nix index 463501a05eb0..4c58039e899a 100644 --- a/pkgs/tools/security/browserpass/default.nix +++ b/pkgs/tools/security/browserpass/default.nix @@ -20,7 +20,7 @@ buildGoModule rec { sha256 = "sha256-UZzOPRRiCUIG7uSSp9AEPMDN/+4cgyK47RhrI8oUx8U="; }; - nativeBuildInputs = [ makeWrapper ] ++ lib.optionals stdenv.isLinux [ autoPatchelfHook ]; + nativeBuildInputs = [ makeWrapper ] ++ lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ]; vendorHash = "sha256-CjuH4ANP2bJDeA+o+1j+obbtk5/NVLet/OFS3Rms4r0="; diff --git a/pkgs/tools/security/bws/default.nix b/pkgs/tools/security/bws/default.nix index 4621bb1da5d0..0482ee954583 100644 --- a/pkgs/tools/security/bws/default.nix +++ b/pkgs/tools/security/bws/default.nix @@ -32,17 +32,17 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ installShellFiles pkg-config - ] ++ lib.optionals stdenv.isLinux [ + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ perl ]; buildInputs = [ oniguruma - ] ++ lib.optionals stdenv.isLinux [ + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ openssl ] - ++ lib.optionals stdenv.isDarwin [ + ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.SystemConfiguration ]; diff --git a/pkgs/tools/security/cdk-go/default.nix b/pkgs/tools/security/cdk-go/default.nix index 93c0c1aa4964..0282bf20f79b 100644 --- a/pkgs/tools/security/cdk-go/default.nix +++ b/pkgs/tools/security/cdk-go/default.nix @@ -27,6 +27,6 @@ buildGoModule rec { license = with licenses; [ gpl2Only ]; maintainers = with maintainers; [ fab ]; mainProgram = "cdk"; - broken = stdenv.isDarwin; # needs to update gopsutil to at least v3.21.3 to include https://github.com/shirou/gopsutil/pull/1042 + broken = stdenv.hostPlatform.isDarwin; # needs to update gopsutil to at least v3.21.3 to include https://github.com/shirou/gopsutil/pull/1042 }; } diff --git a/pkgs/tools/security/cdxgen/default.nix b/pkgs/tools/security/cdxgen/default.nix index 3a6c14ea5f1c..6ea34ed4a834 100644 --- a/pkgs/tools/security/cdxgen/default.nix +++ b/pkgs/tools/security/cdxgen/default.nix @@ -27,7 +27,7 @@ stdenv.mkDerivation (finalAttrs: { node-gyp # required for sqlite3 bindings pnpm_9.configHook python3 # required for sqlite3 bindings - ] ++ lib.optional stdenv.isDarwin [ xcbuild ]; + ] ++ lib.optional stdenv.hostPlatform.isDarwin [ xcbuild ]; pnpmDeps = pnpm_9.fetchDeps { inherit (finalAttrs) pname version src; diff --git a/pkgs/tools/security/certdump/default.nix b/pkgs/tools/security/certdump/default.nix index 8615fda62b49..409650ac938b 100644 --- a/pkgs/tools/security/certdump/default.nix +++ b/pkgs/tools/security/certdump/default.nix @@ -41,6 +41,6 @@ buildDotnetModule rec { license = licenses.asl20; maintainers = [ maintainers.baloo ]; # net5 has no osx-arm64 target available - broken = stdenv.isDarwin && stdenv.isAarch64; + broken = stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64; }; } diff --git a/pkgs/tools/security/certinfo/default.nix b/pkgs/tools/security/certinfo/default.nix index f40b2a1eff01..3d48985d78a5 100644 --- a/pkgs/tools/security/certinfo/default.nix +++ b/pkgs/tools/security/certinfo/default.nix @@ -12,11 +12,11 @@ buildGoModule rec { }; # clipboard functionality not working on Darwin - doCheck = !(stdenv.isDarwin && stdenv.isAarch64); + doCheck = !(stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64); buildInputs = [ ] - ++ lib.optionals stdenv.isLinux [ libX11 ] - ++ lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Cocoa ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ libX11 ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.Cocoa ]; vendorHash = null; diff --git a/pkgs/tools/security/chainsaw/default.nix b/pkgs/tools/security/chainsaw/default.nix index b529956a9655..5789f488985c 100644 --- a/pkgs/tools/security/chainsaw/default.nix +++ b/pkgs/tools/security/chainsaw/default.nix @@ -19,7 +19,9 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-1w3DYP69aOphoqbsZIF9aX56Lftg2niKClmImLTa5DE="; - buildInputs = lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.CoreFoundation ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ + darwin.apple_sdk.frameworks.CoreFoundation + ]; ldflags = [ "-w" diff --git a/pkgs/tools/security/cherrybomb/default.nix b/pkgs/tools/security/cherrybomb/default.nix index 139ac5aea1ad..38783319e7c7 100644 --- a/pkgs/tools/security/cherrybomb/default.nix +++ b/pkgs/tools/security/cherrybomb/default.nix @@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-pj4+rG8XbrxVuNgnTVUTPmgrPBRSnoBnqFhOO/JGGWI="; - buildInputs = lib.optionals stdenv.isDarwin [ + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.Security ]; diff --git a/pkgs/tools/security/chipsec/default.nix b/pkgs/tools/security/chipsec/default.nix index 304b10ca8abb..73c1ade5bd63 100644 --- a/pkgs/tools/security/chipsec/default.nix +++ b/pkgs/tools/security/chipsec/default.nix @@ -12,7 +12,7 @@ python3.pkgs.buildPythonApplication rec { pname = "chipsec"; version = "1.10.6"; - disabled = !stdenv.isLinux; + disabled = !stdenv.hostPlatform.isLinux; src = fetchFromGitHub { owner = "chipsec"; diff --git a/pkgs/tools/security/clamav/default.nix b/pkgs/tools/security/clamav/default.nix index b44ccd5394a6..87471065098a 100644 --- a/pkgs/tools/security/clamav/default.nix +++ b/pkgs/tools/security/clamav/default.nix @@ -23,8 +23,8 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ cmake pkg-config rustc rust-bindgen rustfmt cargo python3 ]; buildInputs = [ zlib bzip2 libxml2 openssl ncurses curl libiconv libmilter pcre2 libmspack json_c check - ] ++ lib.optional stdenv.isLinux systemd - ++ lib.optional stdenv.isDarwin Foundation; + ] ++ lib.optional stdenv.hostPlatform.isLinux systemd + ++ lib.optional stdenv.hostPlatform.isDarwin Foundation; cmakeFlags = [ "-DSYSTEMD_UNIT_DIR=${placeholder "out"}/lib/systemd" diff --git a/pkgs/tools/security/cnspec/default.nix b/pkgs/tools/security/cnspec/default.nix index 098bd180b5a3..2d34dc01646c 100644 --- a/pkgs/tools/security/cnspec/default.nix +++ b/pkgs/tools/security/cnspec/default.nix @@ -6,18 +6,18 @@ buildGoModule rec { pname = "cnspec"; - version = "11.19.0"; + version = "11.23.0"; src = fetchFromGitHub { owner = "mondoohq"; repo = "cnspec"; rev = "refs/tags/v${version}"; - hash = "sha256-37i7lbkw70DpwCUvZtv6548l6csx3ozG+1gPTKhJQFg="; + hash = "sha256-oZCKNsbDdsqlh763/T23+A03Qt8f/XyC8MItMah+U3w="; }; proxyVendor = true; - vendorHash = "sha256-8+qS6fR/5oYHP1QhoHfByQ7AayYPYVg4xEtF3617aJM="; + vendorHash = "sha256-QqK527y4W+B7jhRoOkpt9QRyERA6Tn4Dwaq+gzN3k4U="; subPackages = [ "apps/cnspec" ]; diff --git a/pkgs/tools/security/cosign/default.nix b/pkgs/tools/security/cosign/default.nix index 24092e58423e..7d416cbdb6f8 100644 --- a/pkgs/tools/security/cosign/default.nix +++ b/pkgs/tools/security/cosign/default.nix @@ -23,8 +23,8 @@ buildGoModule rec { }; buildInputs = - lib.optional (stdenv.isLinux && pivKeySupport) (lib.getDev pcsclite) - ++ lib.optionals (stdenv.isDarwin && pivKeySupport) [ PCSC ]; + lib.optional (stdenv.hostPlatform.isLinux && pivKeySupport) (lib.getDev pcsclite) + ++ lib.optionals (stdenv.hostPlatform.isDarwin && pivKeySupport) [ PCSC ]; nativeBuildInputs = [ pkg-config installShellFiles ]; diff --git a/pkgs/tools/security/cyclonedx-gomod/default.nix b/pkgs/tools/security/cyclonedx-gomod/default.nix index 2a27f7b6a35b..a8f75da90f54 100644 --- a/pkgs/tools/security/cyclonedx-gomod/default.nix +++ b/pkgs/tools/security/cyclonedx-gomod/default.nix @@ -6,16 +6,16 @@ buildGoModule rec { pname = "cyclonedx-gomod"; - version = "1.7.0"; + version = "1.8.0"; src = fetchFromGitHub { owner = "CycloneDX"; repo = "cyclonedx-gomod"; rev = "refs/tags/v${version}"; - hash = "sha256-RM8ZH1mO+72ptoU7YKXlCZAyDhYZ7MFXyDYrqBQwsDI="; + hash = "sha256-s5kzyQPf29RZPnPtgFf4IVHnOtVZOtGSQqy1BNVVykQ="; }; - vendorHash = "sha256-1ibMneSOYs5C6Ul8m/rVXVFBJHZrH1D5eWRwVVJ6a+A="; + vendorHash = "sha256-Sz2NCznyD0tMuho9kr+U35I8bS/WK276nPdt83k1zfU="; ldflags = [ "-w" diff --git a/pkgs/tools/security/dieharder/default.nix b/pkgs/tools/security/dieharder/default.nix index 2cc5f719aa1d..c7804f0c5f4d 100644 --- a/pkgs/tools/security/dieharder/default.nix +++ b/pkgs/tools/security/dieharder/default.nix @@ -1,12 +1,12 @@ { lib, stdenv, fetchurl, gsl -, dieharder, testers }: +, testers }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "dieharder"; version = "3.31.1"; src = fetchurl { - url = "http://webhome.phy.duke.edu/~rgb/General/dieharder/dieharder-${version}.tgz"; + url = "http://webhome.phy.duke.edu/~rgb/General/dieharder/dieharder-${finalAttrs.version}.tgz"; hash = "sha256-bP8P+DlMVTVJrHQzNZzPyVX7JnlCYDFGIN+l5M1Lcn8="; }; @@ -23,7 +23,7 @@ stdenv.mkDerivation rec { buildInputs = [ gsl ]; passthru = { - tests.version = testers.testVersion { package = dieharder; }; + tests.version = testers.testVersion { package = finalAttrs.finalPackage; }; }; meta = with lib; { @@ -34,4 +34,4 @@ stdenv.mkDerivation rec { maintainers = with maintainers; [ zhaofengli ]; platforms = platforms.unix; }; -} +}) diff --git a/pkgs/tools/security/donkey/default.nix b/pkgs/tools/security/donkey/default.nix index f56811cc273f..e481744ee7d5 100644 --- a/pkgs/tools/security/donkey/default.nix +++ b/pkgs/tools/security/donkey/default.nix @@ -4,20 +4,19 @@ , coreutils , lib , testers -, donkey }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "donkey"; version = "1.2.0"; src = fetchFromGitLab { owner = "donkey"; repo = "donkey"; - rev = "tags/release/${version}"; + rev = "tags/release/${finalAttrs.version}"; hash = "sha256-2xgb9l0Eko39HJVROAWEIP3qLg5t/5h/rm2MoXoKnJI="; }; - sourceRoot = "${src.name}/src"; + sourceRoot = "${finalAttrs.src.name}/src"; buildInputs = [ libmd ]; @@ -27,7 +26,7 @@ stdenv.mkDerivation rec { export INSTALL_DATA="${coreutils}/bin/install -m 444" ''; - passthru.tests.version = testers.testVersion { package = donkey; }; + passthru.tests.version = testers.testVersion { package = finalAttrs.finalPackage; }; meta = with lib; { description = "Alternative for S/KEY's 'key' command"; @@ -51,4 +50,4 @@ The name "Donkey" is an acronym of "Don't Key". maintainers = with maintainers; [ raboof ]; platforms = platforms.all; }; -} +}) diff --git a/pkgs/tools/security/echidna/default.nix b/pkgs/tools/security/echidna/default.nix index a8e812219ba5..f3bfb9fbffee 100644 --- a/pkgs/tools/security/echidna/default.nix +++ b/pkgs/tools/security/echidna/default.nix @@ -110,7 +110,7 @@ mkDerivation ( mainProgram = "echidna-test"; } - // lib.optionalAttrs (stdenv.isDarwin && stdenv.isAarch64) { + // lib.optionalAttrs (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64) { # https://github.com/NixOS/nixpkgs/pull/304352 postInstall = with haskellPackages; '' diff --git a/pkgs/tools/security/feroxbuster/default.nix b/pkgs/tools/security/feroxbuster/default.nix index f4e361332e96..64975a04c9f4 100644 --- a/pkgs/tools/security/feroxbuster/default.nix +++ b/pkgs/tools/security/feroxbuster/default.nix @@ -34,7 +34,7 @@ rustPlatform.buildRustPackage rec { buildInputs = [ openssl - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ Security SystemConfiguration ]; diff --git a/pkgs/tools/security/firefox_decrypt/default.nix b/pkgs/tools/security/firefox_decrypt/default.nix index 2799a990975a..52dc4a9bd71f 100644 --- a/pkgs/tools/security/firefox_decrypt/default.nix +++ b/pkgs/tools/security/firefox_decrypt/default.nix @@ -29,7 +29,7 @@ buildPythonApplication rec { makeWrapperArgs = [ "--prefix" - (if stdenv.isDarwin then "DYLD_LIBRARY_PATH" else "LD_LIBRARY_PATH") + (if stdenv.hostPlatform.isDarwin then "DYLD_LIBRARY_PATH" else "LD_LIBRARY_PATH") ":" (lib.makeLibraryPath [ nss ]) ]; diff --git a/pkgs/tools/security/freeze/default.nix b/pkgs/tools/security/freeze/default.nix index 28ef21657009..e828ed79bf4c 100644 --- a/pkgs/tools/security/freeze/default.nix +++ b/pkgs/tools/security/freeze/default.nix @@ -22,7 +22,7 @@ buildGoModule rec { "-w" ]; - postInstall = lib.optionalString (!stdenv.isDarwin) '' + postInstall = lib.optionalString (!stdenv.hostPlatform.isDarwin) '' mv $out/bin/Freeze $out/bin/freeze ''; diff --git a/pkgs/tools/security/genpass/default.nix b/pkgs/tools/security/genpass/default.nix index 0c326c2dac66..f1e9a197680b 100644 --- a/pkgs/tools/security/genpass/default.nix +++ b/pkgs/tools/security/genpass/default.nix @@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-ls3tzZ+gtZQlObmbtwJDq6N/f5nY+Ps7RL5R/fR5Vgg="; - buildInputs = lib.optionals stdenv.isDarwin [ CoreFoundation libiconv Security ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ CoreFoundation libiconv Security ]; meta = with lib; { description = "Simple yet robust commandline random password generator"; diff --git a/pkgs/tools/security/gfshare/default.nix b/pkgs/tools/security/gfshare/default.nix index e0da2fdaf35b..caf04cee0d5c 100644 --- a/pkgs/tools/security/gfshare/default.nix +++ b/pkgs/tools/security/gfshare/default.nix @@ -24,6 +24,6 @@ stdenv.mkDerivation rec { license = licenses.mit; platforms = platforms.all; maintainers = [ maintainers.rraval ]; - broken = stdenv.isDarwin; # never built on Hydra https://hydra.nixos.org/job/nixpkgs/trunk/gfshare.x86_64-darwin + broken = stdenv.hostPlatform.isDarwin; # never built on Hydra https://hydra.nixos.org/job/nixpkgs/trunk/gfshare.x86_64-darwin }; } diff --git a/pkgs/tools/security/ggshield/default.nix b/pkgs/tools/security/ggshield/default.nix index af20cb3ff775..61c5daf41a23 100644 --- a/pkgs/tools/security/ggshield/default.nix +++ b/pkgs/tools/security/ggshield/default.nix @@ -7,14 +7,14 @@ python3.pkgs.buildPythonApplication rec { pname = "ggshield"; - version = "1.31.0"; + version = "1.32.0"; pyproject = true; src = fetchFromGitHub { owner = "GitGuardian"; repo = "ggshield"; rev = "refs/tags/v${version}"; - hash = "sha256-ShczC0DvAO92apkNq5oyYRbkqGdqwl6vaCY1hn8O6so="; + hash = "sha256-yqR5kgXhR4YUih46RuSlOmD2CgdN40QpUho6WTha60U="; }; pythonRelaxDeps = true; diff --git a/pkgs/tools/security/ghidra/build.nix b/pkgs/tools/security/ghidra/build.nix index 994cee822a16..b898147d9a21 100644 --- a/pkgs/tools/security/ghidra/build.nix +++ b/pkgs/tools/security/ghidra/build.nix @@ -112,7 +112,7 @@ stdenv.mkDerivation (finalAttrs: { python3 python3Packages.pip ] - ++ lib.optionals stdenv.isDarwin [ + ++ lib.optionals stdenv.hostPlatform.isDarwin [ xcbuild desktopToDarwinBundle ]; @@ -196,6 +196,6 @@ stdenv.mkDerivation (finalAttrs: { roblabla vringar ]; - broken = stdenv.isDarwin && stdenv.isx86_64; + broken = stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64; }; }) diff --git a/pkgs/tools/security/ghidra/default.nix b/pkgs/tools/security/ghidra/default.nix index 55f224da511b..8f39076b4eec 100644 --- a/pkgs/tools/security/ghidra/default.nix +++ b/pkgs/tools/security/ghidra/default.nix @@ -39,7 +39,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ makeWrapper icoutils - ] ++ lib.optionals stdenv.isLinux [ autoPatchelfHook ]; + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ]; buildInputs = [ stdenv.cc.cc.lib diff --git a/pkgs/tools/security/gitjacker/default.nix b/pkgs/tools/security/gitjacker/default.nix index 5303e169e8dd..83e8b91f8b28 100644 --- a/pkgs/tools/security/gitjacker/default.nix +++ b/pkgs/tools/security/gitjacker/default.nix @@ -22,7 +22,7 @@ buildGoModule rec { nativeCheckInputs = [ git ]; - doCheck = !stdenv.isDarwin; + doCheck = !stdenv.hostPlatform.isDarwin; preCheck = '' export PATH=$TMPDIR/usr/bin:$PATH diff --git a/pkgs/tools/security/gnupg/22.nix b/pkgs/tools/security/gnupg/22.nix index 5181f78e8a2e..e0fdf3361f9b 100644 --- a/pkgs/tools/security/gnupg/22.nix +++ b/pkgs/tools/security/gnupg/22.nix @@ -4,7 +4,7 @@ , adns, bzip2, gnutls, libusb1, openldap, readline, sqlite, zlib , enableMinimal ? false , withPcsc ? !enableMinimal, pcsclite -, guiSupport ? stdenv.isDarwin, pinentry +, guiSupport ? stdenv.hostPlatform.isDarwin, pinentry , nixosTests }: @@ -39,7 +39,7 @@ stdenv.mkDerivation rec { # Fix broken SOURCE_DATE_EPOCH usage - remove on the next upstream update sed -i 's/$SOURCE_DATE_EPOCH/''${SOURCE_DATE_EPOCH}/' doc/Makefile.am sed -i 's/$SOURCE_DATE_EPOCH/''${SOURCE_DATE_EPOCH}/' doc/Makefile.in - '' + lib.optionalString (stdenv.isLinux && withPcsc) '' + '' + lib.optionalString (stdenv.hostPlatform.isLinux && withPcsc) '' sed -i 's,"libpcsclite\.so[^"]*","${lib.getLib pcsclite}/lib/libpcsclite.so",g' scd/scdaemon.c ''; @@ -51,7 +51,7 @@ stdenv.mkDerivation rec { "GPGRT_CONFIG=${lib.getDev libgpg-error}/bin/gpgrt-config" ] ++ lib.optional guiSupport "--with-pinentry-pgm=${pinentry}/${pinentry.binaryPath or "bin/pinentry"}" - ++ lib.optional stdenv.isDarwin "--disable-ccid-driver"; + ++ lib.optional stdenv.hostPlatform.isDarwin "--disable-ccid-driver"; postInstall = if enableMinimal then '' diff --git a/pkgs/tools/security/gnupg/24.nix b/pkgs/tools/security/gnupg/24.nix index ef1b2e1db518..8c709e9b739a 100644 --- a/pkgs/tools/security/gnupg/24.nix +++ b/pkgs/tools/security/gnupg/24.nix @@ -4,8 +4,8 @@ , adns, bzip2, gnutls, libusb1, openldap, readline, sqlite, zlib , enableMinimal ? false , withPcsc ? !enableMinimal, pcsclite -, guiSupport ? stdenv.isDarwin, pinentry -, withTpm2Tss ? !stdenv.isDarwin && !enableMinimal, tpm2-tss +, guiSupport ? stdenv.hostPlatform.isDarwin, pinentry +, withTpm2Tss ? !stdenv.hostPlatform.isDarwin && !enableMinimal, tpm2-tss , nixosTests }: @@ -40,7 +40,7 @@ stdenv.mkDerivation rec { postPatch = '' sed -i 's,\(hkps\|https\)://keyserver.ubuntu.com,hkps://keys.openpgp.org,g' configure configure.ac doc/dirmngr.texi doc/gnupg.info-1 - '' + lib.optionalString (stdenv.isLinux && withPcsc) '' + '' + lib.optionalString (stdenv.hostPlatform.isLinux && withPcsc) '' sed -i 's,"libpcsclite\.so[^"]*","${lib.getLib pcsclite}/lib/libpcsclite.so",g' scd/scdaemon.c ''; @@ -54,7 +54,7 @@ stdenv.mkDerivation rec { ] ++ lib.optional guiSupport "--with-pinentry-pgm=${pinentry}/${pinentry.binaryPath or "bin/pinentry"}" ++ lib.optional withTpm2Tss "--with-tss=intel" - ++ lib.optional stdenv.isDarwin "--disable-ccid-driver"; + ++ lib.optional stdenv.hostPlatform.isDarwin "--disable-ccid-driver"; postInstall = if enableMinimal then '' diff --git a/pkgs/tools/security/go365/default.nix b/pkgs/tools/security/go365/default.nix index 381df6d74629..12fad051584d 100644 --- a/pkgs/tools/security/go365/default.nix +++ b/pkgs/tools/security/go365/default.nix @@ -17,7 +17,7 @@ buildGoModule rec { vendorHash = "sha256-Io+69kIW4DV2EkA73pjaTcTRbDSYBf61R7F+141Jojs="; - postInstall = lib.optionalString (!stdenv.isDarwin) '' + postInstall = lib.optionalString (!stdenv.hostPlatform.isDarwin) '' mv $out/bin/Go365 $out/bin/$pname ''; diff --git a/pkgs/tools/security/gopass/default.nix b/pkgs/tools/security/gopass/default.nix index fc16820d1c97..68b794214f6e 100644 --- a/pkgs/tools/security/gopass/default.nix +++ b/pkgs/tools/security/gopass/default.nix @@ -35,7 +35,7 @@ buildGoModule rec { git gnupg xclip - ] ++ lib.optional stdenv.isLinux wl-clipboard + ] ++ lib.optional stdenv.hostPlatform.isLinux wl-clipboard ); postInstall = '' diff --git a/pkgs/tools/security/gotestwaf/default.nix b/pkgs/tools/security/gotestwaf/default.nix index 28305ceb4e8e..6cbe088d6871 100644 --- a/pkgs/tools/security/gotestwaf/default.nix +++ b/pkgs/tools/security/gotestwaf/default.nix @@ -8,16 +8,16 @@ buildGoModule rec { pname = "gotestwaf"; - version = "0.4.19"; + version = "0.5.5"; src = fetchFromGitHub { owner = "wallarm"; repo = "gotestwaf"; rev = "refs/tags/v${version}"; - hash = "sha256-ax2HPhdaqawpFe2AZg3SVsEJLG7gEgL7632iRADpaa8="; + hash = "sha256-stGjxv9cgYxxclQpyytN6dhFm2G1Gxbf9MdyKw6gEC4="; }; - vendorHash = null; + vendorHash = "sha256-mPqCphweDF9RQibdjTaXXfXdO8NENHVMdIPxrJEw2g4="; # Some tests require networking as of v0.4.0 doCheck = false; @@ -28,11 +28,6 @@ buildGoModule rec { "-X=github.com/wallarm/gotestwaf/internal/version.Version=v${version}" ]; - postFixup = '' - # Rename binary - mv $out/bin/cmd $out/bin/${pname} - ''; - passthru.tests.version = testers.testVersion { command = "gotestwaf --version"; package = gotestwaf; @@ -41,10 +36,10 @@ buildGoModule rec { meta = with lib; { description = "Tool for API and OWASP attack simulation"; - mainProgram = "gotestwaf"; homepage = "https://github.com/wallarm/gotestwaf"; changelog = "https://github.com/wallarm/gotestwaf/releases/tag/v${version}"; license = licenses.mit; maintainers = with maintainers; [ fab ]; + mainProgram = "gotestwaf"; }; } diff --git a/pkgs/tools/security/gowitness/default.nix b/pkgs/tools/security/gowitness/default.nix index ab31281bbd28..d4b893d9f870 100644 --- a/pkgs/tools/security/gowitness/default.nix +++ b/pkgs/tools/security/gowitness/default.nix @@ -1,20 +1,21 @@ -{ lib -, buildGoModule -, fetchFromGitHub +{ + lib, + buildGoModule, + fetchFromGitHub, }: buildGoModule rec { pname = "gowitness"; - version = "2.5.1"; + version = "3.0.3"; src = fetchFromGitHub { owner = "sensepost"; repo = "gowitness"; rev = "refs/tags/${version}"; - hash = "sha256-37OorjzxDu27FNAz4LTtQdFjt0tL9jSb9tGZhlq797Q="; + hash = "sha256-yKG4qLjeZThFEMqMnUv4ryvM2e3uH5GLuVP3oa6XHtE="; }; - vendorHash = "sha256-Exw5NfR3nDYH+hWMPOKuVIRyrVkOJyP7Kwe4jzQwnsI="; + vendorHash = "sha256-PjbC10Dh3tDF0mP2k4ei6ZSS3ND2wAaB1+Llmj37TR8="; ldflags = [ "-s" @@ -23,10 +24,10 @@ buildGoModule rec { meta = with lib; { description = "Web screenshot utility"; - mainProgram = "gowitness"; homepage = "https://github.com/sensepost/gowitness"; changelog = "https://github.com/sensepost/gowitness/releases/tag/${version}"; license = licenses.gpl3Only; maintainers = with maintainers; [ fab ]; + mainProgram = "gowitness"; }; } diff --git a/pkgs/tools/security/gpg-tui/default.nix b/pkgs/tools/security/gpg-tui/default.nix index ba07ffb9e67f..5c4dd4620eaf 100644 --- a/pkgs/tools/security/gpg-tui/default.nix +++ b/pkgs/tools/security/gpg-tui/default.nix @@ -40,7 +40,7 @@ rustPlatform.buildRustPackage rec { ] ++ lib.optionals x11Support [ libxcb libxkbcommon - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ AppKit Foundation libiconv diff --git a/pkgs/tools/security/ibm-sw-tpm2/default.nix b/pkgs/tools/security/ibm-sw-tpm2/default.nix index 76123a7c893f..7792165d2587 100644 --- a/pkgs/tools/security/ibm-sw-tpm2/default.nix +++ b/pkgs/tools/security/ibm-sw-tpm2/default.nix @@ -6,7 +6,7 @@ }: let makefile = - if stdenv.isDarwin + if stdenv.hostPlatform.isDarwin then "makefile.mac" else "makefile"; in diff --git a/pkgs/tools/security/jwt-cli/default.nix b/pkgs/tools/security/jwt-cli/default.nix index 2dc57e8c0713..988864cbf7dc 100644 --- a/pkgs/tools/security/jwt-cli/default.nix +++ b/pkgs/tools/security/jwt-cli/default.nix @@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ installShellFiles ]; - buildInputs = lib.optional stdenv.isDarwin Security; + buildInputs = lib.optional stdenv.hostPlatform.isDarwin Security; postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' installShellCompletion --cmd jwt \ diff --git a/pkgs/tools/security/kbs2/default.nix b/pkgs/tools/security/kbs2/default.nix index ae16b3f00c9a..04c6923af041 100644 --- a/pkgs/tools/security/kbs2/default.nix +++ b/pkgs/tools/security/kbs2/default.nix @@ -23,18 +23,18 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-LcnvCWGVdBxhDgQDoGHXRppGeEpfjOv/F0dZMN2bOF8="; nativeBuildInputs = [ installShellFiles ] - ++ lib.optionals stdenv.isLinux [ python3 ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ python3 ]; buildInputs = [ ] - ++ lib.optionals stdenv.isLinux [ libxcb ] - ++ lib.optionals stdenv.isDarwin [ SystemConfiguration AppKit ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ libxcb ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ SystemConfiguration AppKit ]; preCheck = '' export HOME=$TMPDIR ''; checkFlags = [ "--skip=kbs2::config::tests::test_find_config_dir" ] - ++ lib.optionals stdenv.isDarwin [ "--skip=test_ragelib_rewrap_keyfile" ]; + ++ lib.optionals stdenv.hostPlatform.isDarwin [ "--skip=test_ragelib_rewrap_keyfile" ]; postInstall = '' mkdir -p $out/share/kbs2 diff --git a/pkgs/tools/security/keepwn/default.nix b/pkgs/tools/security/keepwn/default.nix index 9c878f37fd0c..8306cbe441ea 100644 --- a/pkgs/tools/security/keepwn/default.nix +++ b/pkgs/tools/security/keepwn/default.nix @@ -29,7 +29,7 @@ python3.pkgs.buildPythonApplication rec { termcolor ]; - postInstall = lib.optionalString (!stdenv.isDarwin) '' + postInstall = lib.optionalString (!stdenv.hostPlatform.isDarwin) '' mv $out/bin/KeePwn $out/bin/$pname ''; diff --git a/pkgs/tools/security/kepler/default.nix b/pkgs/tools/security/kepler/default.nix index e4d2fc914cf9..35e601dac163 100644 --- a/pkgs/tools/security/kepler/default.nix +++ b/pkgs/tools/security/kepler/default.nix @@ -30,7 +30,7 @@ rustPlatform.buildRustPackage rec { openssl postgresql zstd - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.Security ]; diff --git a/pkgs/tools/security/keybase/default.nix b/pkgs/tools/security/keybase/default.nix index d8457c487253..103066261a19 100644 --- a/pkgs/tools/security/keybase/default.nix +++ b/pkgs/tools/security/keybase/default.nix @@ -28,7 +28,7 @@ buildGoModule rec { }) ]; - buildInputs = lib.optionals stdenv.isDarwin [ AppKit AVFoundation AudioToolbox ImageIO CoreMedia Foundation CoreGraphics MediaToolbox ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ AppKit AVFoundation AudioToolbox ImageIO CoreMedia Foundation CoreGraphics MediaToolbox ]; tags = [ "production" ]; ldflags = [ "-s" "-w" ]; diff --git a/pkgs/tools/security/keyscope/default.nix b/pkgs/tools/security/keyscope/default.nix index ae5bd80e2964..b2bd09d1f44a 100644 --- a/pkgs/tools/security/keyscope/default.nix +++ b/pkgs/tools/security/keyscope/default.nix @@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ pkg-config ]; - buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ + buildInputs = [ openssl ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ DiskArbitration Foundation IOKit diff --git a/pkgs/tools/security/kpcli/default.nix b/pkgs/tools/security/kpcli/default.nix index 5a3b0a75862f..f7e636f8facc 100644 --- a/pkgs/tools/security/kpcli/default.nix +++ b/pkgs/tools/security/kpcli/default.nix @@ -22,7 +22,7 @@ stdenv.mkDerivation rec { makeWrapper $out/share/kpcli.pl $out/bin/kpcli --set PERL5LIB \ "${with perlPackages; makePerlPath ([ CaptureTiny Clipboard Clone CryptRijndael SortNaturally TermReadKey TermShellUI FileKeePass TermReadLineGnu XMLParser - ] ++ lib.optional stdenv.isDarwin MacPasteboard)}" + ] ++ lib.optional stdenv.hostPlatform.isDarwin MacPasteboard)}" ''; diff --git a/pkgs/tools/security/kubeclarity/default.nix b/pkgs/tools/security/kubeclarity/default.nix index 585b4d35cd69..25a6582695e7 100644 --- a/pkgs/tools/security/kubeclarity/default.nix +++ b/pkgs/tools/security/kubeclarity/default.nix @@ -26,7 +26,7 @@ buildGoModule rec { pkg-config ]; - buildInputs = lib.optionals stdenv.isLinux [ + buildInputs = lib.optionals stdenv.hostPlatform.isLinux [ btrfs-progs lvm2 ]; diff --git a/pkgs/tools/security/lethe/default.nix b/pkgs/tools/security/lethe/default.nix index ff9b297d5361..21875006f4fc 100644 --- a/pkgs/tools/security/lethe/default.nix +++ b/pkgs/tools/security/lethe/default.nix @@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-SFNNpbHZdDJvH95f+VWyVKnQp3OJwQmCOqHtLAhhkOk="; - buildInputs = lib.optional stdenv.isDarwin Security; + buildInputs = lib.optional stdenv.hostPlatform.isDarwin Security; meta = with lib; { description = "Tool to wipe drives in a secure way"; diff --git a/pkgs/tools/security/libacr38u/default.nix b/pkgs/tools/security/libacr38u/default.nix index 5211f42b96ef..45db3985d555 100644 --- a/pkgs/tools/security/libacr38u/default.nix +++ b/pkgs/tools/security/libacr38u/default.nix @@ -13,7 +13,7 @@ stdenv.mkDerivation { nativeBuildInputs = [ autoreconfHook pkg-config ]; buildInputs = [ pcsclite libusb-compat-0_1 ] - ++ lib.optional stdenv.isDarwin IOKit; + ++ lib.optional stdenv.hostPlatform.isDarwin IOKit; preBuild = '' makeFlagsArray=(usbdropdir="$out/pcsc/drivers"); diff --git a/pkgs/tools/security/maigret/default.nix b/pkgs/tools/security/maigret/default.nix index cdbf6df4dd0f..0936e0d98062 100644 --- a/pkgs/tools/security/maigret/default.nix +++ b/pkgs/tools/security/maigret/default.nix @@ -92,7 +92,7 @@ python3.pkgs.buildPythonApplication rec { "test_pdf_report" "test_self_check_db_negative_enabled" "test_self_check_db_positive_enable" - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ # AsyncioProgressbarExecutor is slower on darwin than it should be, # Upstream issue: https://github.com/soxoj/maigret/issues/679 "test_asyncio_progressbar_executor" diff --git a/pkgs/tools/security/masscan/default.nix b/pkgs/tools/security/masscan/default.nix index a6aa990c1d82..9606fe0f1156 100644 --- a/pkgs/tools/security/masscan/default.nix +++ b/pkgs/tools/security/masscan/default.nix @@ -27,7 +27,7 @@ stdenv.mkDerivation rec { }) ]; - postPatch = lib.optionalString stdenv.isDarwin '' + postPatch = lib.optionalString stdenv.hostPlatform.isDarwin '' # Fix broken install command substituteInPlace Makefile --replace "-pm755" "-pDm755" ''; diff --git a/pkgs/tools/security/mkp224o/default.nix b/pkgs/tools/security/mkp224o/default.nix index 53b0e38a0dca..318284a4318f 100644 --- a/pkgs/tools/security/mkp224o/default.nix +++ b/pkgs/tools/security/mkp224o/default.nix @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { { suffix = "donna"; configureFlags = ["--enable-donna"]; } ] ++ lib.optionals stdenv.hostPlatform.isx86 [ { suffix = "donna-sse2"; configureFlags = ["--enable-donna-sse2"]; } - ] ++ lib.optionals (!stdenv.isDarwin && stdenv.isx86_64) [ + ] ++ lib.optionals (!stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64) [ { suffix = "amd64-51-30k"; configureFlags = ["--enable-amd64-51-30k"]; } { suffix = "amd64-64-24k"; configureFlags = ["--enable-amd64-64-24k"]; } ]; diff --git a/pkgs/tools/security/monsoon/default.nix b/pkgs/tools/security/monsoon/default.nix index e17081487db2..78bf95ac6c8b 100644 --- a/pkgs/tools/security/monsoon/default.nix +++ b/pkgs/tools/security/monsoon/default.nix @@ -18,7 +18,7 @@ buildGoModule rec { vendorHash = "sha256-gdoOBW5MD94RiKINVtTDvBQRZaJ9tlgu0eh7MxuMezg="; # Tests fails on darwin - doCheck = !stdenv.isDarwin; + doCheck = !stdenv.hostPlatform.isDarwin; meta = with lib; { description = "Fast HTTP enumerator"; diff --git a/pkgs/tools/security/mpw/default.nix b/pkgs/tools/security/mpw/default.nix index 4ee765bdbdd1..5900c72bcff3 100644 --- a/pkgs/tools/security/mpw/default.nix +++ b/pkgs/tools/security/mpw/default.nix @@ -45,7 +45,7 @@ in stdenv.mkDerivation rec { # Some tests are expected to fail on ARM64 # See: https://gitlab.com/spectre.app/cli/-/issues/27#note_962950844 (mpw is a predecessor to spectre-cli and this issue is relevant to mpw as well) - doCheck = !(stdenv.isLinux && stdenv.isAarch64); + doCheck = !(stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64); checkPhase = '' runHook preCheck diff --git a/pkgs/tools/security/nbtscanner/default.nix b/pkgs/tools/security/nbtscanner/default.nix index b70f554f33fd..ec6d9a1d661b 100644 --- a/pkgs/tools/security/nbtscanner/default.nix +++ b/pkgs/tools/security/nbtscanner/default.nix @@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec { ./Cargo.lock.patch ]; - buildInputs = lib.optional stdenv.isDarwin Security; + buildInputs = lib.optional stdenv.hostPlatform.isDarwin Security; meta = with lib; { description = "NetBIOS scanner written in Rust"; diff --git a/pkgs/tools/security/netexec/default.nix b/pkgs/tools/security/netexec/default.nix index 33447f98516e..06163309b11b 100644 --- a/pkgs/tools/security/netexec/default.nix +++ b/pkgs/tools/security/netexec/default.nix @@ -101,6 +101,6 @@ python.pkgs.buildPythonApplication rec { # FIXME: failing fixupPhase: # $ Rewriting #!/nix/store/<hash>-python3-3.11.7/bin/python3.11 to #!/nix/store/<hash>-python3-3.11.7 # $ /nix/store/<hash>-wrap-python-hook/nix-support/setup-hook: line 65: 47758 Killed: 9 sed -i "$f" -e "1 s^#!/nix/store/<hash>-python3-3.11.7^#!/nix/store/<hash>-python3-3.11.7^" - broken = stdenv.isDarwin; + broken = stdenv.hostPlatform.isDarwin; }; } diff --git a/pkgs/tools/security/nitrokey-app2/default.nix b/pkgs/tools/security/nitrokey-app2/default.nix index c675bcc9824f..28d9c74e5dc2 100644 --- a/pkgs/tools/security/nitrokey-app2/default.nix +++ b/pkgs/tools/security/nitrokey-app2/default.nix @@ -26,7 +26,7 @@ python3.pkgs.buildPythonApplication rec { wrapQtAppsHook ]; - buildInputs = [ qtbase ] ++ lib.optionals stdenv.isLinux [ + buildInputs = [ qtbase ] ++ lib.optionals stdenv.hostPlatform.isLinux [ qtwayland ]; diff --git a/pkgs/tools/security/nuclei/default.nix b/pkgs/tools/security/nuclei/default.nix index a0535d313259..0168237aca8b 100644 --- a/pkgs/tools/security/nuclei/default.nix +++ b/pkgs/tools/security/nuclei/default.nix @@ -6,16 +6,16 @@ buildGoModule rec { pname = "nuclei"; - version = "3.3.2"; + version = "3.3.3"; src = fetchFromGitHub { owner = "projectdiscovery"; repo = "nuclei"; rev = "refs/tags/v${version}"; - hash = "sha256-CBZeo2k9ZA41NotA6XIhkIQkEDvcbSIBCnPSOYXlLDQ="; + hash = "sha256-Cbw/80WjdoxNzf/XvU4sHNeSnriww8cSGGVVF0pCi8Y="; }; - vendorHash = "sha256-ewjJ89tCeedlTGngB7yU8JbfoTnPUw5Pg2iMwjg1SgU="; + vendorHash = "sha256-jVt7KiUsUHASG7TVWV9G26Qe+H7Qf/kBz/sTwlh5Pc8="; subPackages = [ "cmd/nuclei/" ]; diff --git a/pkgs/tools/security/oath-toolkit/default.nix b/pkgs/tools/security/oath-toolkit/default.nix index 1e5b418c3f46..aa4255860469 100644 --- a/pkgs/tools/security/oath-toolkit/default.nix +++ b/pkgs/tools/security/oath-toolkit/default.nix @@ -3,7 +3,7 @@ let # TODO: Switch to OpenPAM once https://gitlab.com/oath-toolkit/oath-toolkit/-/issues/26 is addressed upstream securityDependency = - if stdenv.isDarwin then xmlsec + if stdenv.hostPlatform.isDarwin then xmlsec else pam; in stdenv.mkDerivation rec { @@ -17,7 +17,7 @@ in stdenv.mkDerivation rec { buildInputs = [ securityDependency ]; - configureFlags = lib.optionals stdenv.isDarwin [ "--disable-pam" ]; + configureFlags = lib.optionals stdenv.hostPlatform.isDarwin [ "--disable-pam" ]; passthru.updateScript = nix-update-script { }; diff --git a/pkgs/tools/security/onioncircuits/default.nix b/pkgs/tools/security/onioncircuits/default.nix index 048631e2b774..8693d35dfa99 100644 --- a/pkgs/tools/security/onioncircuits/default.nix +++ b/pkgs/tools/security/onioncircuits/default.nix @@ -48,7 +48,7 @@ python3.pkgs.buildPythonApplication rec { ''; meta = with lib; { - broken = stdenv.isDarwin; + broken = stdenv.hostPlatform.isDarwin; homepage = "https://tails.boum.org"; description = "GTK application to display Tor circuits and streams"; mainProgram = "onioncircuits"; diff --git a/pkgs/tools/security/onlykey/onlykey.nix b/pkgs/tools/security/onlykey/onlykey.nix index b154efb74712..b10d8718b7be 100644 --- a/pkgs/tools/security/onlykey/onlykey.nix +++ b/pkgs/tools/security/onlykey/onlykey.nix @@ -8,7 +8,7 @@ let nodeEnv = import ../../../development/node-packages/node-env.nix { inherit (pkgs) stdenv lib python2 runCommand writeTextFile writeShellScript; inherit pkgs nodejs; - libtool = if pkgs.stdenv.isDarwin then pkgs.cctools or pkgs.darwin.cctools else null; + libtool = if pkgs.stdenv.hostPlatform.isDarwin then pkgs.cctools or pkgs.darwin.cctools else null; }; in import ./node-packages.nix { diff --git a/pkgs/tools/security/opensc/default.nix b/pkgs/tools/security/opensc/default.nix index b767261b4e0a..412053af2b4b 100644 --- a/pkgs/tools/security/opensc/default.nix +++ b/pkgs/tools/security/opensc/default.nix @@ -2,7 +2,7 @@ , libiconv, pcsclite, libassuan, libXt , docbook_xsl, libxslt, docbook_xml_dtd_412 , Carbon, PCSC, buildPackages -, withApplePCSC ? stdenv.isDarwin +, withApplePCSC ? stdenv.hostPlatform.isDarwin }: stdenv.mkDerivation rec { @@ -21,7 +21,7 @@ stdenv.mkDerivation rec { zlib readline openssl libassuan libXt libxslt libiconv docbook_xml_dtd_412 ] - ++ lib.optional stdenv.isDarwin Carbon + ++ lib.optional stdenv.hostPlatform.isDarwin Carbon ++ (if withApplePCSC then [ PCSC ] else [ pcsclite ]); env.NIX_CFLAGS_COMPILE = "-Wno-error"; diff --git a/pkgs/tools/security/pass/default.nix b/pkgs/tools/security/pass/default.nix index 748ec2ccf3bf..fb8ef894bb18 100644 --- a/pkgs/tools/security/pass/default.nix +++ b/pkgs/tools/security/pass/default.nix @@ -3,7 +3,7 @@ , which, openssh, procps, qrencode, makeWrapper, pass , xclip ? null, xdotool ? null, dmenu ? null -, x11Support ? !stdenv.isDarwin , dmenuSupport ? (x11Support || waylandSupport) +, x11Support ? !stdenv.hostPlatform.isDarwin , dmenuSupport ? (x11Support || waylandSupport) , waylandSupport ? false, wl-clipboard ? null , ydotool ? null, dmenu-wayland ? null @@ -66,7 +66,7 @@ stdenv.mkDerivation rec { patches = [ ./set-correct-program-name-for-sleep.patch ./extension-dir.patch - ] ++ lib.optional stdenv.isDarwin ./no-darwin-getopt.patch; + ] ++ lib.optional stdenv.hostPlatform.isDarwin ./no-darwin-getopt.patch; nativeBuildInputs = [ makeWrapper ]; @@ -89,7 +89,7 @@ stdenv.mkDerivation rec { openssh procps qrencode - ] ++ lib.optional stdenv.isDarwin openssl + ] ++ lib.optional stdenv.hostPlatform.isDarwin openssl ++ lib.optional x11Support xclip ++ lib.optional waylandSupport wl-clipboard ++ lib.optionals (waylandSupport && dmenuSupport) [ ydotool dmenu-wayland ] @@ -124,7 +124,7 @@ stdenv.mkDerivation rec { -e 's@^GPGS=.*''$@GPG=${gnupg}/bin/gpg2@' \ -e '/which gpg/ d' \ tests/setup.sh - '' + lib.optionalString stdenv.isDarwin '' + '' + lib.optionalString stdenv.hostPlatform.isDarwin '' # 'pass edit' uses hdid, which is not available from the sandbox. rm -f tests/t0200-edit-tests.sh rm -f tests/t0010-generate-tests.sh diff --git a/pkgs/tools/security/pass/extensions/audit/default.nix b/pkgs/tools/security/pass/extensions/audit/default.nix index d3f196a20563..4aa96fe40909 100644 --- a/pkgs/tools/security/pass/extensions/audit/default.nix +++ b/pkgs/tools/security/pass/extensions/audit/default.nix @@ -44,7 +44,7 @@ python3.pkgs.buildPythonApplication rec { ]; # Tests freeze on darwin with: pass-audit-1.1 (checkPhase): EOFError - doCheck = !stdenv.isDarwin; + doCheck = !stdenv.hostPlatform.isDarwin; nativeCheckInputs = [ python3.pkgs.green pass diff --git a/pkgs/tools/security/pcsc-tools/default.nix b/pkgs/tools/security/pcsc-tools/default.nix index c696fad309a3..39efa566553d 100644 --- a/pkgs/tools/security/pcsc-tools/default.nix +++ b/pkgs/tools/security/pcsc-tools/default.nix @@ -8,7 +8,7 @@ , pkg-config , wrapGAppsHook3 , systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemd, systemd -, dbusSupport ? stdenv.isLinux, dbus +, dbusSupport ? stdenv.hostPlatform.isLinux, dbus , pcsclite , PCSC , wget @@ -42,7 +42,7 @@ stdenv.mkDerivation (finalAttrs: { dbus ] ++ [ perlPackages.perl pcsclite - ] ++ lib.optional stdenv.isDarwin PCSC + ] ++ lib.optional stdenv.hostPlatform.isDarwin PCSC ++ lib.optional systemdSupport systemd; nativeBuildInputs = [ diff --git a/pkgs/tools/security/pcsclite/default.nix b/pkgs/tools/security/pcsclite/default.nix index eedec6b239fd..955611a465c1 100644 --- a/pkgs/tools/security/pcsclite/default.nix +++ b/pkgs/tools/security/pcsclite/default.nix @@ -12,7 +12,7 @@ , polkit , systemdLibs , udev -, dbusSupport ? stdenv.isLinux +, dbusSupport ? stdenv.hostPlatform.isLinux , systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemdLibs , udevSupport ? dbusSupport , libusb1 @@ -96,7 +96,7 @@ stdenv.mkDerivation (finalAttrs: { buildInputs = [ python3 ] ++ lib.optionals systemdSupport [ systemdLibs ] ++ lib.optionals (!systemdSupport && udevSupport) [ udev ] - ++ lib.optionals stdenv.isDarwin [ Foundation IOKit ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ Foundation IOKit ] ++ lib.optionals dbusSupport [ dbus ] ++ lib.optionals polkitSupport [ polkit ] ++ lib.optionals (!udevSupport) [ libusb1 ]; diff --git a/pkgs/tools/security/proxmark3/default.nix b/pkgs/tools/security/proxmark3/default.nix index 94d9d76b9288..265f8e2cc753 100644 --- a/pkgs/tools/security/proxmark3/default.nix +++ b/pkgs/tools/security/proxmark3/default.nix @@ -26,13 +26,13 @@ assert withBlueshark -> stdenv.hostPlatform.isLinux; stdenv.mkDerivation (finalAttrs: { pname = "proxmark3"; - version = "4.18589"; + version = "4.18994"; src = fetchFromGitHub { owner = "RfidResearchGroup"; repo = "proxmark3"; rev = "v${finalAttrs.version}"; - hash = "sha256-e/FoyaHU/uH2yovEqtkrCXwHMlF94Acxl2lUA422Pig="; + hash = "sha256-LeVQnidlCGFwtgJZdGlIFEYgf3M3BtfxoBKsxSFEo2w="; }; patches = [ diff --git a/pkgs/tools/security/quill/default.nix b/pkgs/tools/security/quill/default.nix index 71ffc7af5c15..3aa2e6525b62 100644 --- a/pkgs/tools/security/quill/default.nix +++ b/pkgs/tools/security/quill/default.nix @@ -41,7 +41,7 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ pkg-config protobuf ]; buildInputs = [ openssl ] - ++ lib.optionals stdenv.isDarwin [ Security libiconv ]; + ++ lib.optionals stdenv.hostPlatform.isDarwin [ Security libiconv ]; meta = with lib; { homepage = "https://github.com/dfinity/quill"; diff --git a/pkgs/tools/security/rblake2sum/default.nix b/pkgs/tools/security/rblake2sum/default.nix index 9052ffb68a96..92b4f574749a 100644 --- a/pkgs/tools/security/rblake2sum/default.nix +++ b/pkgs/tools/security/rblake2sum/default.nix @@ -17,7 +17,7 @@ rustPlatform.buildRustPackage { cargoHash = "sha256-egwL3z7uB4AcRwPT0uPrenyh4FSxhbZKMdkPhRztMbs="; - buildInputs = lib.optionals stdenv.isDarwin [ Security ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ Security ]; meta = with lib; { description = "Recursive blake2 digest (hash) of a file-system path"; diff --git a/pkgs/tools/security/rblake3sum/default.nix b/pkgs/tools/security/rblake3sum/default.nix index 62f290cdf320..af04b2014403 100644 --- a/pkgs/tools/security/rblake3sum/default.nix +++ b/pkgs/tools/security/rblake3sum/default.nix @@ -17,7 +17,7 @@ rustPlatform.buildRustPackage { cargoHash = "sha256-SE/Zg/UEV/vhB/VDcn8Y70OUIoxbJBh6H2QgFMkWPc4="; - buildInputs = lib.optionals stdenv.isDarwin [ Security ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ Security ]; meta = with lib; { description = "Recursive blake3 digest (hash) of a file-system path"; diff --git a/pkgs/tools/security/rbw/default.nix b/pkgs/tools/security/rbw/default.nix index c04ed415fb9e..597b4c0adad1 100644 --- a/pkgs/tools/security/rbw/default.nix +++ b/pkgs/tools/security/rbw/default.nix @@ -36,15 +36,15 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ installShellFiles - ] ++ lib.optionals stdenv.isLinux [ pkg-config ]; + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ pkg-config ]; buildInputs = [ bash ] # for git-credential-rbw - ++ lib.optionals stdenv.isDarwin [ + ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk_11_0.frameworks.Security darwin.apple_sdk_11_0.frameworks.AppKit ]; - preConfigure = lib.optionalString stdenv.isLinux '' + preConfigure = lib.optionalString stdenv.hostPlatform.isLinux '' export OPENSSL_INCLUDE_DIR="${openssl.dev}/include" export OPENSSL_LIB_DIR="${lib.getLib openssl}/lib" ''; diff --git a/pkgs/tools/security/ripasso/cursive.nix b/pkgs/tools/security/ripasso/cursive.nix index b7cc5d969d08..fe216b91ff91 100644 --- a/pkgs/tools/security/ripasso/cursive.nix +++ b/pkgs/tools/security/ripasso/cursive.nix @@ -49,7 +49,7 @@ rustPlatform.buildRustPackage rec { gpgme xorg.libxcb nettle - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ AppKit Security ]; diff --git a/pkgs/tools/security/rucredstash/default.nix b/pkgs/tools/security/rucredstash/default.nix index 972695ad565e..43166eb0bf8e 100644 --- a/pkgs/tools/security/rucredstash/default.nix +++ b/pkgs/tools/security/rucredstash/default.nix @@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-TYobVjjzrK3gprZcYyY98EvdASkq4urB+WiLlbJbwmk="; - buildInputs = lib.optional stdenv.isDarwin Security; + buildInputs = lib.optional stdenv.hostPlatform.isDarwin Security; # Disable tests since it requires network access and relies on the # presence of certain AWS infrastructure diff --git a/pkgs/tools/security/rustscan/default.nix b/pkgs/tools/security/rustscan/default.nix index fc3ab5b2e013..6af9b974ac09 100644 --- a/pkgs/tools/security/rustscan/default.nix +++ b/pkgs/tools/security/rustscan/default.nix @@ -28,7 +28,7 @@ rustPlatform.buildRustPackage rec { patchShebangs fixtures/.rustscan_scripts/* ''; - buildInputs = lib.optional stdenv.isDarwin Security; + buildInputs = lib.optional stdenv.hostPlatform.isDarwin Security; nativeCheckInputs = [ perl diff --git a/pkgs/tools/security/saml2aws/default.nix b/pkgs/tools/security/saml2aws/default.nix index 14e408275e34..1afba85be34e 100644 --- a/pkgs/tools/security/saml2aws/default.nix +++ b/pkgs/tools/security/saml2aws/default.nix @@ -21,7 +21,7 @@ buildGoModule rec { vendorHash = "sha256-gtl8T8wXnpLgDZc6qSgFKpA+XbcLNHf20ieBkyNdE+s="; nativeBuildInputs = [ installShellFiles ]; - buildInputs = lib.optionals stdenv.isDarwin [ AppKit ]; + buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ AppKit ]; subPackages = [ "." diff --git a/pkgs/tools/security/schleuder/default.nix b/pkgs/tools/security/schleuder/default.nix index cce88366a372..8429cb0ea0d0 100644 --- a/pkgs/tools/security/schleuder/default.nix +++ b/pkgs/tools/security/schleuder/default.nix @@ -24,7 +24,7 @@ bundlerApp { }; meta = with lib; { - broken = stdenv.isDarwin; + broken = stdenv.hostPlatform.isDarwin; description = "Schleuder is an encrypting mailing list manager with remailing-capabilities"; longDescription = '' Schleuder is a group's email-gateway: subscribers can exchange diff --git a/pkgs/tools/security/scrypt/default.nix b/pkgs/tools/security/scrypt/default.nix index d1deaa0ec41d..d199ee37725e 100644 --- a/pkgs/tools/security/scrypt/default.nix +++ b/pkgs/tools/security/scrypt/default.nix @@ -33,7 +33,7 @@ stdenv.mkDerivation rec { doCheck = true; checkTarget = "test"; - nativeCheckInputs = lib.optionals stdenv.isLinux [ util-linux ]; + nativeCheckInputs = lib.optionals stdenv.hostPlatform.isLinux [ util-linux ]; meta = with lib; { description = "Encryption utility"; diff --git a/pkgs/tools/security/sequoia-chameleon-gnupg/default.nix b/pkgs/tools/security/sequoia-chameleon-gnupg/default.nix index 96d15250e163..81091848a93c 100644 --- a/pkgs/tools/security/sequoia-chameleon-gnupg/default.nix +++ b/pkgs/tools/security/sequoia-chameleon-gnupg/default.nix @@ -31,7 +31,7 @@ rustPlatform.buildRustPackage rec { nettle openssl sqlite - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.Security darwin.apple_sdk.frameworks.SystemConfiguration ]; diff --git a/pkgs/tools/security/sheesy-cli/default.nix b/pkgs/tools/security/sheesy-cli/default.nix index 9df5da79e8a6..a2dda4493852 100644 --- a/pkgs/tools/security/sheesy-cli/default.nix +++ b/pkgs/tools/security/sheesy-cli/default.nix @@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ libgpg-error gpgme gettext installShellFiles ]; - buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ Security ]; + buildInputs = [ openssl ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ Security ]; buildFeatures = [ "vault" "extract" "completions" "substitute" "process" ]; diff --git a/pkgs/tools/security/snowcrash/default.nix b/pkgs/tools/security/snowcrash/default.nix index 69d310afb9f9..b787b0da59b7 100644 --- a/pkgs/tools/security/snowcrash/default.nix +++ b/pkgs/tools/security/snowcrash/default.nix @@ -19,7 +19,7 @@ buildGoModule rec { subPackages = [ "." ]; - postFixup = lib.optionals (!stdenv.isDarwin) '' + postFixup = lib.optionals (!stdenv.hostPlatform.isDarwin) '' mv $out/bin/SNOWCRASH $out/bin/${pname} ''; diff --git a/pkgs/tools/security/softhsm/default.nix b/pkgs/tools/security/softhsm/default.nix index e4c428b90b9a..d755e131d8f0 100644 --- a/pkgs/tools/security/softhsm/default.nix +++ b/pkgs/tools/security/softhsm/default.nix @@ -19,7 +19,7 @@ stdenv.mkDerivation rec { ]; propagatedBuildInputs = - lib.optionals stdenv.isDarwin [ libobjc Security ]; + lib.optionals stdenv.hostPlatform.isDarwin [ libobjc Security ]; buildInputs = [ botan2 sqlite ]; diff --git a/pkgs/tools/security/solo2-cli/default.nix b/pkgs/tools/security/solo2-cli/default.nix index a241e8780101..387bf00e37bf 100644 --- a/pkgs/tools/security/solo2-cli/default.nix +++ b/pkgs/tools/security/solo2-cli/default.nix @@ -28,8 +28,8 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ installShellFiles pkg-config ]; buildInputs = [ ] - ++ lib.optionals stdenv.isLinux [ pcsclite udev ] - ++ lib.optionals stdenv.isDarwin [ PCSC IOKit CoreFoundation AppKit ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ pcsclite udev ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ PCSC IOKit CoreFoundation AppKit ]; postInstall = '' install -D 70-solo2.rules $out/lib/udev/rules.d/70-solo2.rules diff --git a/pkgs/tools/security/spectre-cli/default.nix b/pkgs/tools/security/spectre-cli/default.nix index 923046cdad4a..ba63b823e739 100644 --- a/pkgs/tools/security/spectre-cli/default.nix +++ b/pkgs/tools/security/spectre-cli/default.nix @@ -46,7 +46,7 @@ stdenv.mkDerivation rec { # Some tests are expected to fail on ARM64 # See: https://gitlab.com/spectre.app/cli/-/issues/27#note_962950844 - doCheck = !(stdenv.isLinux && stdenv.isAarch64); + doCheck = !(stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64); checkPhase = '' mv ../spectre-cli-tests ../spectre_tests.xml ./ diff --git a/pkgs/tools/security/ssdeep/default.nix b/pkgs/tools/security/ssdeep/default.nix index 68b8afdf6712..b3ec01ebdbbf 100644 --- a/pkgs/tools/security/ssdeep/default.nix +++ b/pkgs/tools/security/ssdeep/default.nix @@ -14,7 +14,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ autoreconfHook ]; # remove forbidden references to $TMPDIR - preFixup = lib.optionalString stdenv.isLinux '' + preFixup = lib.optionalString stdenv.hostPlatform.isLinux '' patchelf --shrink-rpath --allowed-rpath-prefixes "$NIX_STORE" "$out"/bin/* ''; diff --git a/pkgs/tools/security/ssh-mitm/default.nix b/pkgs/tools/security/ssh-mitm/default.nix index 6694a9edaae2..4c59595ec936 100644 --- a/pkgs/tools/security/ssh-mitm/default.nix +++ b/pkgs/tools/security/ssh-mitm/default.nix @@ -63,7 +63,7 @@ buildPythonApplication rec { setuptools sshpubkeys wrapt - ] ++ lib.optionals stdenv.isDarwin [ setuptools ]; + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ setuptools ]; # fix for darwin users nativeBuildInputs = [ installShellFiles ]; diff --git a/pkgs/tools/security/sshuttle/default.nix b/pkgs/tools/security/sshuttle/default.nix index 2090c4d396bd..e52453e8006d 100644 --- a/pkgs/tools/security/sshuttle/default.nix +++ b/pkgs/tools/security/sshuttle/default.nix @@ -42,7 +42,7 @@ python3Packages.buildPythonApplication rec { installManPage docs/_build/man/* wrapProgram $out/bin/sshuttle \ - --prefix PATH : "${lib.makeBinPath ([ coreutils openssh procps ] ++ lib.optionals stdenv.isLinux [ iptables nettools ])}" \ + --prefix PATH : "${lib.makeBinPath ([ coreutils openssh procps ] ++ lib.optionals stdenv.hostPlatform.isLinux [ iptables nettools ])}" \ ''; meta = with lib; { diff --git a/pkgs/tools/security/step-ca/default.nix b/pkgs/tools/security/step-ca/default.nix index 549cfa6a5224..f37c05f93fbb 100644 --- a/pkgs/tools/security/step-ca/default.nix +++ b/pkgs/tools/security/step-ca/default.nix @@ -32,8 +32,8 @@ buildGoModule rec { nativeBuildInputs = lib.optionals hsmSupport [ pkg-config ]; buildInputs = - lib.optionals (hsmSupport && stdenv.isLinux) [ pcsclite ] - ++ lib.optionals (hsmSupport && stdenv.isDarwin) [ PCSC ]; + lib.optionals (hsmSupport && stdenv.hostPlatform.isLinux) [ pcsclite ] + ++ lib.optionals (hsmSupport && stdenv.hostPlatform.isDarwin) [ PCSC ]; postPatch = '' substituteInPlace systemd/step-ca.service --replace "/bin/kill" "${coreutils}/bin/kill" diff --git a/pkgs/tools/security/step-kms-plugin/default.nix b/pkgs/tools/security/step-kms-plugin/default.nix index 3eaf3a9c9cb4..ba35b7c11087 100644 --- a/pkgs/tools/security/step-kms-plugin/default.nix +++ b/pkgs/tools/security/step-kms-plugin/default.nix @@ -48,6 +48,6 @@ buildGoModule rec { maintainers = with maintainers; [ qbit ]; mainProgram = "step-kms-plugin"; # can't find pcsclite header files - broken = stdenv.isDarwin; + broken = stdenv.hostPlatform.isDarwin; }; } diff --git a/pkgs/tools/security/swtpm/default.nix b/pkgs/tools/security/swtpm/default.nix index b39c43a8e1b6..6b1bdb4c03ab 100644 --- a/pkgs/tools/security/swtpm/default.nix +++ b/pkgs/tools/security/swtpm/default.nix @@ -41,14 +41,14 @@ stdenv.mkDerivation (finalAttrs: { openssl libtasn1 glib json-glib gnutls - ] ++ lib.optionals stdenv.isLinux [ + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ fuse libseccomp ]; configureFlags = [ "--localstatedir=/var" - ] ++ lib.optionals stdenv.isLinux [ + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ "--with-cuse" ]; diff --git a/pkgs/tools/security/tcpcrypt/default.nix b/pkgs/tools/security/tcpcrypt/default.nix index 8b00431b6cbe..1d34fdd4e710 100644 --- a/pkgs/tools/security/tcpcrypt/default.nix +++ b/pkgs/tools/security/tcpcrypt/default.nix @@ -19,12 +19,12 @@ stdenv.mkDerivation rec { outputs = [ "bin" "dev" "out" ]; nativeBuildInputs = [ autoreconfHook ]; buildInputs = [ openssl libpcap ] - ++ lib.optionals stdenv.isLinux [ libcap libnfnetlink libnetfilter_conntrack libnetfilter_queue ]; + ++ lib.optionals stdenv.hostPlatform.isLinux [ libcap libnfnetlink libnetfilter_conntrack libnetfilter_queue ]; enableParallelBuilding = true; meta = with lib; { - broken = stdenv.isDarwin; + broken = stdenv.hostPlatform.isDarwin; homepage = "http://tcpcrypt.org/"; description = "Fast TCP encryption"; platforms = platforms.all; diff --git a/pkgs/tools/security/thc-hydra/default.nix b/pkgs/tools/security/thc-hydra/default.nix index aa0e9fd8fb43..412691d2b940 100644 --- a/pkgs/tools/security/thc-hydra/default.nix +++ b/pkgs/tools/security/thc-hydra/default.nix @@ -23,7 +23,7 @@ stdenv.mkDerivation rec { --replace-fail "-lcurses" "-lncurses" ''; - env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.isDarwin "-Wno-undef-prefix"; + env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.hostPlatform.isDarwin "-Wno-undef-prefix"; nativeBuildInputs = lib.optionals withGUI [ pkg-config makeWrapper ]; diff --git a/pkgs/tools/security/tor/default.nix b/pkgs/tools/security/tor/default.nix index 30eb8360fe39..164526a8e133 100644 --- a/pkgs/tools/security/tor/default.nix +++ b/pkgs/tools/security/tor/default.nix @@ -41,7 +41,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ pkg-config ]; buildInputs = [ libevent openssl zlib xz zstd scrypt ] ++ - lib.optionals stdenv.isLinux [ libseccomp systemd libcap ]; + lib.optionals stdenv.hostPlatform.isLinux [ libseccomp systemd libcap ]; patches = [ ./disable-monotonic-timer-tests.patch ]; @@ -55,7 +55,7 @@ stdenv.mkDerivation rec { lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [ "--disable-tool-name-check" ] ++ # sandbox is broken on aarch64-linux https://gitlab.torproject.org/tpo/core/tor/-/issues/40599 - lib.optionals (stdenv.isLinux && stdenv.isAarch64) [ "--disable-seccomp" ] + lib.optionals (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64) [ "--disable-seccomp" ] ; NIX_CFLAGS_LINK = lib.optionalString stdenv.cc.isGNU "-lgcc_s"; @@ -72,7 +72,7 @@ stdenv.mkDerivation rec { # disable tests on linux aarch32 # https://gitlab.torproject.org/tpo/core/tor/-/issues/40912 - doCheck = !(stdenv.isLinux && stdenv.isAarch32); + doCheck = !(stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch32); postInstall = '' mkdir -p $geoip/share/tor diff --git a/pkgs/tools/security/tor/torsocks.nix b/pkgs/tools/security/tor/torsocks.nix index 0ad36688bd6b..8b09bfc3bf9b 100644 --- a/pkgs/tools/security/tor/torsocks.nix +++ b/pkgs/tools/security/tor/torsocks.nix @@ -40,7 +40,7 @@ stdenv.mkDerivation rec { sed -i \ -e 's,\(local app_path\)=`which $1`,\1=`type -P $1`,' \ src/bin/torsocks.in - '' + lib.optionalString stdenv.isLinux '' + '' + lib.optionalString stdenv.hostPlatform.isLinux '' sed -i \ -e 's,\(local getcap\)=.*,\1=${libcap}/bin/getcap,' \ src/bin/torsocks.in diff --git a/pkgs/tools/security/trufflehog/default.nix b/pkgs/tools/security/trufflehog/default.nix index 683e32288773..0362b8545d7e 100644 --- a/pkgs/tools/security/trufflehog/default.nix +++ b/pkgs/tools/security/trufflehog/default.nix @@ -8,16 +8,16 @@ buildGoModule rec { pname = "trufflehog"; - version = "3.82.2"; + version = "3.82.3"; src = fetchFromGitHub { owner = "trufflesecurity"; repo = "trufflehog"; rev = "refs/tags/v${version}"; - hash = "sha256-reQJE3UG1bWS3RrMW2c4nq/2AOQ3mYtbXVKu+cwzrJM="; + hash = "sha256-Kv7IS7kladdTbPPWbgylqPrqSdn4r9USUMm4rnC4H08="; }; - vendorHash = "sha256-h3thO9sYYv2yiVcBPEu36RiYgYNnumRc73bNXNOIdA4="; + vendorHash = "sha256-dRxnxwxQKdFNf6Ng0E2AQDef1zb3RlBH7glczfYKWMQ="; proxyVendor = true; diff --git a/pkgs/tools/security/vault/default.nix b/pkgs/tools/security/vault/default.nix index 32ad1196edca..007edb9c6abe 100644 --- a/pkgs/tools/security/vault/default.nix +++ b/pkgs/tools/security/vault/default.nix @@ -35,7 +35,7 @@ buildGoModule rec { postInstall = '' echo "complete -C $out/bin/vault vault" > vault.bash installShellCompletion vault.bash - '' + lib.optionalString stdenv.isLinux '' + '' + lib.optionalString stdenv.hostPlatform.isLinux '' wrapProgram $out/bin/vault \ --prefix PATH ${lib.makeBinPath [ gawk glibc ]} ''; diff --git a/pkgs/tools/security/vault/vault-bin.nix b/pkgs/tools/security/vault/vault-bin.nix index 7a829e1ad271..9cfdc187eaee 100644 --- a/pkgs/tools/security/vault/vault-bin.nix +++ b/pkgs/tools/security/vault/vault-bin.nix @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { dontConfigure = true; dontBuild = true; - dontStrip = stdenv.isDarwin; + dontStrip = stdenv.hostPlatform.isDarwin; installPhase = '' runHook preInstall diff --git a/pkgs/tools/security/vaultwarden/default.nix b/pkgs/tools/security/vaultwarden/default.nix index 137f9e6c9564..f28bc52fdbc7 100644 --- a/pkgs/tools/security/vaultwarden/default.nix +++ b/pkgs/tools/security/vaultwarden/default.nix @@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ pkg-config ]; buildInputs = [ openssl ] - ++ lib.optionals stdenv.isDarwin [ libiconv Security CoreServices SystemConfiguration ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ libiconv Security CoreServices SystemConfiguration ] ++ lib.optional (dbBackend == "mysql") libmysqlclient ++ lib.optional (dbBackend == "postgresql") postgresql; diff --git a/pkgs/tools/security/yubihsm-shell/default.nix b/pkgs/tools/security/yubihsm-shell/default.nix index 8567798ea82c..90af2f22068a 100644 --- a/pkgs/tools/security/yubihsm-shell/default.nix +++ b/pkgs/tools/security/yubihsm-shell/default.nix @@ -47,18 +47,18 @@ stdenv.mkDerivation rec { libedit curl openssl - ] ++ lib.optionals stdenv.isLinux [ + ] ++ lib.optionals stdenv.hostPlatform.isLinux [ pcsclite.dev - ] ++ lib.optionals stdenv.isDarwin [ + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.PCSC libiconv ]; - preBuild = lib.optionalString stdenv.isLinux '' + preBuild = lib.optionalString stdenv.hostPlatform.isLinux '' NIX_CFLAGS_COMPILE="$(pkg-config --cflags libpcsclite) $NIX_CFLAGS_COMPILE" ''; - cmakeFlags = lib.optionals stdenv.isDarwin [ + cmakeFlags = lib.optionals stdenv.hostPlatform.isDarwin [ "-DDISABLE_LTO=ON" ]; diff --git a/pkgs/tools/security/yubikey-agent/default.nix b/pkgs/tools/security/yubikey-agent/default.nix index f43e83e575e7..f2e290ade6db 100644 --- a/pkgs/tools/security/yubikey-agent/default.nix +++ b/pkgs/tools/security/yubikey-agent/default.nix @@ -12,12 +12,12 @@ buildGoModule rec { }; buildInputs = - lib.optional stdenv.isLinux (lib.getDev pcsclite) - ++ lib.optional stdenv.isDarwin (darwin.apple_sdk.frameworks.PCSC); + lib.optional stdenv.hostPlatform.isLinux (lib.getDev pcsclite) + ++ lib.optional stdenv.hostPlatform.isDarwin (darwin.apple_sdk.frameworks.PCSC); - nativeBuildInputs = lib.optionals stdenv.isLinux [ pkg-config ]; + nativeBuildInputs = lib.optionals stdenv.hostPlatform.isLinux [ pkg-config ]; - postPatch = lib.optionalString stdenv.isLinux '' + postPatch = lib.optionalString stdenv.hostPlatform.isLinux '' substituteInPlace main.go --replace 'notify-send' ${libnotify}/bin/notify-send ''; @@ -29,7 +29,7 @@ buildGoModule rec { ldflags = [ "-s" "-w" "-X main.Version=${version}" ]; - postInstall = lib.optionalString stdenv.isLinux '' + postInstall = lib.optionalString stdenv.hostPlatform.isLinux '' mkdir -p $out/lib/systemd/user substitute contrib/systemd/user/yubikey-agent.service $out/lib/systemd/user/yubikey-agent.service \ --replace 'ExecStart=yubikey-agent' "ExecStart=$out/bin/yubikey-agent" diff --git a/pkgs/tools/security/zmap/default.nix b/pkgs/tools/security/zmap/default.nix index 1749c9ef6d7f..b7a9986434eb 100644 --- a/pkgs/tools/security/zmap/default.nix +++ b/pkgs/tools/security/zmap/default.nix @@ -26,6 +26,6 @@ stdenv.mkDerivation rec { description = "Fast single packet network scanner designed for Internet-wide network surveys"; maintainers = with maintainers; [ ma27 ]; platforms = platforms.unix; - broken = stdenv.isDarwin; + broken = stdenv.hostPlatform.isDarwin; }; } |