nixpkgs/pkgs/development/tools/rust/cargo-audit/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

44 lines
1020 B
Nix
Raw Normal View History

2021-07-03 22:51:42 +00:00
{ lib
, rustPlatform
, fetchCrate
2021-07-03 22:51:42 +00:00
, pkg-config
, openssl
, stdenv
2021-07-03 22:51:42 +00:00
, Security
}:
rustPlatform.buildRustPackage rec {
pname = "cargo-audit";
version = "0.17.2";
src = fetchCrate {
inherit pname version;
sha256 = "sha256-fSdh8yCV+2AdAtF4eO2z8+uxOAf2N0IxqIFLw4B8dKE=";
};
cargoSha256 = "sha256-YCEQaUcTmZ9zTdGcDQkaVI0Dc8oIBvt840s3x9PUlrg=";
2021-07-03 22:51:42 +00:00
nativeBuildInputs = [
pkg-config
];
2021-07-03 22:51:42 +00:00
buildInputs = [
openssl
] ++ lib.optionals stdenv.isDarwin [
Security
];
buildFeatures = [ "binary-scanning" "fix" ];
# The tests require network access which is not available in sandboxed Nix builds.
doCheck = false;
meta = with lib; {
description = "Audit Cargo.lock files for crates with security vulnerabilities";
homepage = "https://rustsec.org";
changelog = "https://github.com/rustsec/rustsec/blob/cargo-audit/v${version}/cargo-audit/CHANGELOG.md";
2022-05-23 17:46:32 +00:00
license = with licenses; [ mit /* or */ asl20 ];
maintainers = with maintainers; [ basvandijk figsoda jk ];
};
}