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