1 { stdenv, lib, fetchFromGitHub, autoconf, automake, curl, iprange, iproute2, iptables, iputils
2 , kmod, nettools, procps, tcpdump, traceroute, util-linux, whois
4 # If true, just install FireQOS without FireHOL
8 stdenv.mkDerivation rec {
12 src = fetchFromGitHub {
16 sha256 = "sha256-gq7l7QoUsK+j5DUn84kD9hlUTC4hz3ds3gNJc1tRygs=";
20 # configure tries to determine if `ping6` or the newer, combined
21 # `ping` is installed by using `ping -6` which would fail.
24 # put firehol config files in /etc/firehol (not $out/etc/firehol)
25 # to avoid error on startup, see #35114
26 ./firehol-sysconfdir.patch
28 # we must quote "$UNAME_CMD", or the dash in
29 # /nix/store/...-coreutils-.../bin/uname will be interpreted as
30 # IFS -> error. this might be considered an upstream bug but only
31 # appears when there are dashes in the command path
32 ./firehol-uname-command.patch
35 nativeBuildInputs = [ autoconf automake ];
37 curl iprange iproute2 iptables iputils kmod
38 nettools procps tcpdump traceroute util-linux whois
41 preConfigure = "./autogen.sh";
42 configureFlags = [ "--localstatedir=/var"
43 "--disable-doc" "--disable-man"
44 "--disable-update-ipsets" ] ++
45 lib.optionals onlyQOS [ "--disable-firehol" ];
48 description = "Firewall for humans";
50 FireHOL, an iptables stateful packet filtering firewall for humans!
51 FireQOS, a TC based bandwidth shaper for humans!
53 homepage = "https://firehol.org/";
54 license = licenses.gpl2;
55 maintainers = with maintainers; [ oxzi ];
56 platforms = platforms.linux;