11 , libnetfilter_conntrack
22 stdenv.mkDerivation rec {
23 pname = "netsniff-ng";
26 src = fetchFromGitHub {
30 sha256 = "10ih8amaqspy0zwg7hqvypa1v7ixpjl0n608cyfgyfzffp73lbqf";
38 gnumake42 # fails with make 4.4
47 libnetfilter_conntrack
55 # ./configure is not autoGNU but some home-brewn magic
57 patchShebangs configure
58 substituteInPlace configure --replace "which" "command -v"
59 NACL_INC_DIR=${libsodium.dev}/include/sodium NACL_LIB=sodium ./configure
62 enableParallelBuilding = true;
64 # All files installed to /etc are just static data that can go in the store
65 makeFlags = [ "PREFIX=$(out)" "ETCDIR=$(out)/etc" ];
68 # trafgen and bpfc can call out to cpp to process config files.
69 wrapProgram "$out/sbin/trafgen" --prefix PATH ":" "${stdenv.cc}/bin"
70 wrapProgram "$out/sbin/bpfc" --prefix PATH ":" "${stdenv.cc}/bin"
72 ln -sv ${geolite-legacy}/share/GeoIP/GeoIP.dat $out/etc/netsniff-ng/country4.dat
73 ln -sv ${geolite-legacy}/share/GeoIP/GeoIPv6.dat $out/etc/netsniff-ng/country6.dat
74 ln -sv ${geolite-legacy}/share/GeoIP/GeoIPCity.dat $out/etc/netsniff-ng/city4.dat
75 ln -sv ${geolite-legacy}/share/GeoIP/GeoIPCityv6.dat $out/etc/netsniff-ng/city6.dat
76 ln -sv ${geolite-legacy}/share/GeoIP/GeoIPASNum.dat $out/etc/netsniff-ng/asname4.dat
77 ln -sv ${geolite-legacy}/share/GeoIP/GeoIPASNumv6.dat $out/etc/netsniff-ng/asname6.dat
78 rm -v $out/etc/netsniff-ng/geoip.conf # updating databases after installation is impossible
82 description = "Swiss army knife for daily Linux network plumbing";
84 netsniff-ng is a free Linux networking toolkit. Its gain of performance
85 is reached by zero-copy mechanisms, so that on packet reception and
86 transmission the kernel does not need to copy packets from kernel space
87 to user space and vice versa. The toolkit can be used for network
88 development and analysis, debugging, auditing or network reconnaissance.
90 homepage = "http://netsniff-ng.org/";
91 license = with licenses; [ gpl2Only ];
92 platforms = platforms.linux;