nixpkgs/pkgs/tools/security/rustscan/default.nix

38 lines
862 B
Nix
Raw Normal View History

2020-08-28 21:04:10 +02:00
{ lib
, fetchFromGitHub
, rustPlatform
, nmap
}:
rustPlatform.buildRustPackage rec {
pname = "rustscan";
2020-09-29 12:07:10 +02:00
version = "1.10.0";
2020-08-28 21:04:10 +02:00
src = fetchFromGitHub {
owner = "RustScan";
repo = pname;
rev = "${version}";
2020-09-29 12:07:10 +02:00
sha256 = "1x6vi3d250jhy75ybp8gm6cq9ncv0jig5c1v12r26raflhkh7fk3";
2020-08-28 21:04:10 +02:00
};
2020-09-29 12:07:10 +02:00
cargoSha256 = "0q4p4pa1lh8kw5gmiim0zmmvs3l1kl319a3ji7gmj2fisha4319k";
2020-08-28 21:04:10 +02:00
postPatch = ''
substituteInPlace src/main.rs \
--replace 'Command::new("nmap")' 'Command::new("${nmap}/bin/nmap")'
'';
checkFlags = [
"--skip=infer_ulimit_lowering_no_panic"
"--skip=google_dns_runs"
2020-09-21 19:18:14 +02:00
"--skip=parse_correct_host_addresses"
2020-08-28 21:04:10 +02:00
];
meta = with lib; {
description = "Faster Nmap Scanning with Rust";
homepage = "https://github.com/RustScan/RustScan";
license = licenses.gpl3Only;
maintainers = [ maintainers.SuperSandro2000 ];
};
}