nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib, stdenv, fetchurl, autoreconfHook, bison, flex}:
2
3stdenv.mkDerivation rec {
4 version = "2.4.3";
5 pname = "sshguard";
6
7 src = fetchurl {
8 url = "mirror://sourceforge/sshguard/${pname}-${version}.tar.gz";
9 sha256 = "sha256-ZAKd7/bekP3u+x9JfUFPDkBFB2aTqR2hpw63WV6X7+s=";
10 };
11
12 doCheck = true;
13
14 nativeBuildInputs = [ autoreconfHook bison flex ];
15
16 configureFlags = [ "--sysconfdir=/etc" ];
17
18 meta = with lib; {
19 description = "Protects hosts from brute-force attacks";
20 mainProgram = "sshguard";
21 longDescription = ''
22 SSHGuard can read log messages from various input sources. Log messages are parsed, line-by-line, for recognized patterns.
23 If an attack, such as several login failures within a few seconds, is detected, the offending IP is blocked.
24 '';
25 homepage = "https://sshguard.net";
26 license = licenses.bsd3;
27 maintainers = with maintainers; [ sargon ];
28 platforms = with platforms; linux ++ darwin ++ freebsd ++ netbsd ++ openbsd;
29 };
30}