nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at devShellTools-shell 42 lines 937 B view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5}: 6 7stdenv.mkDerivation { 8 pname = "pwnat"; 9 # Latest release has an annoying segmentation fault bug, see: 10 # https://github.com/samyk/pwnat/pull/25 . Merging only #25 is impossible due 11 # to major code refactoring. 12 version = "2023-03-31"; 13 14 src = fetchFromGitHub { 15 owner = "samyk"; 16 repo = "pwnat"; 17 rev = "8ec62cdae53a2d573c9f9c906133ca45bbd3360a"; 18 sha256 = "sha256-QodNw3ab8/TurKamg6AgMfQ08aalp4j6q663B+sWmRM="; 19 }; 20 21 # See https://github.com/samyk/pwnat/issues/28 22 preBuild = '' 23 mkdir obj 24 ''; 25 26 installPhase = '' 27 runHook preInstall 28 29 install -D pwnat $out/bin/pwnat 30 31 runHook postInstall 32 ''; 33 34 meta = with lib; { 35 homepage = "http://samy.pl/pwnat/"; 36 description = "ICMP NAT to NAT client-server communication"; 37 license = lib.licenses.gpl3Plus; 38 maintainers = [ ]; 39 platforms = with platforms; linux; 40 mainProgram = "pwnat"; 41 }; 42}