nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 ncurses,
6}:
7
8stdenv.mkDerivation (finalAttrs: {
9 version = "1.2.2";
10 pname = "iptraf-ng";
11
12 src = fetchFromGitHub {
13 owner = "iptraf-ng";
14 repo = "iptraf-ng";
15 rev = "v${finalAttrs.version}";
16 sha256 = "sha256-SM1cJYNnZlGl3eWaYd8DlPrV4AL9nck1tjdOn0CHVUw=";
17 };
18
19 buildInputs = [ ncurses ];
20
21 makeFlags = [
22 "DESTDIR=$(out)"
23 "prefix=/usr"
24 "sbindir=/bin"
25 ];
26
27 hardeningDisable = [ "format" ];
28
29 meta = {
30 description = "Console-based network monitoring utility (fork of iptraf)";
31 longDescription = ''
32 IPTraf-ng is a console-based network monitoring utility. IPTraf-ng
33 gathers data like TCP connection packet and byte counts, interface
34 statistics and activity indicators, TCP/UDP traffic breakdowns, and LAN
35 station packet and byte counts. IPTraf-ng features include an IP traffic
36 monitor which shows TCP flag information, packet and byte counts, ICMP
37 details, OSPF packet types, and oversized IP packet warnings; interface
38 statistics showing IP, TCP, UDP, ICMP, non-IP and other IP packet counts,
39 IP checksum errors, interface activity and packet size counts; a TCP and
40 UDP service monitor showing counts of incoming and outgoing packets for
41 common TCP and UDP application ports, a LAN statistics module that
42 discovers active hosts and displays statistics about their activity; TCP,
43 UDP and other protocol display filters so you can view just the traffic
44 you want; logging; support for Ethernet, FDDI, ISDN, SLIP, PPP, and
45 loopback interfaces; and utilization of the built-in raw socket interface
46 of the Linux kernel, so it can be used on a wide variety of supported
47 network cards.
48 '';
49 homepage = "https://github.com/iptraf-ng/iptraf-ng";
50 license = lib.licenses.gpl2Only;
51 platforms = lib.platforms.linux;
52 maintainers = with lib.maintainers; [ devhell ];
53 mainProgram = "iptraf-ng";
54 };
55})