sshguard: support dynamic firewall config and remove iptables dependency
This commit is contained in:
parent
506a304462
commit
ae060529d4
@ -1,5 +1,14 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
sv check iptables >/dev/null || exit 1
|
|
||||||
sv check socklog-unix >/dev/null || exit 1
|
|
||||||
|
|
||||||
exec sshguard -l /var/log/socklog/secure/current -b 200:/var/db/sshguard/blacklist.db 2>&1
|
# Defaults that mabe be overridden (or erased entirely) by configuration
|
||||||
|
LOGFILE="${LOGFILE:-/var/log/socklog/secure/current}"
|
||||||
|
BLACKLIST_SPEC="${BLACKLIST_SPEC:-200:/var/db/sshguard/blacklist.db}"
|
||||||
|
|
||||||
|
# Allow the firewall and logger backends to be specified
|
||||||
|
[ -f ./conf ] && . ./conf
|
||||||
|
|
||||||
|
# If specified, add blacklist spec and log source to OPTS
|
||||||
|
[ -n "$BLACKLIST_SPEC" ] && OPTS="-b $BLACKLIST_SPEC"
|
||||||
|
[ -n "$LOGFILE" ] && OPTS="-l $LOGFILE $OPTS"
|
||||||
|
|
||||||
|
exec sshguard $OPTS 2>&1
|
||||||
|
@ -1,10 +1,9 @@
|
|||||||
# Template file for 'sshguard'
|
# Template file for 'sshguard'
|
||||||
pkgname=sshguard
|
pkgname=sshguard
|
||||||
version=2.4.0
|
version=2.4.0
|
||||||
revision=1
|
revision=2
|
||||||
build_style=gnu-configure
|
build_style=gnu-configure
|
||||||
hostmakedepends="flex"
|
hostmakedepends="flex"
|
||||||
depends="iptables"
|
|
||||||
short_desc="Protects networked hosts from brute force attacks"
|
short_desc="Protects networked hosts from brute force attacks"
|
||||||
maintainer="Lodvær <lodvaer@gmail.com>"
|
maintainer="Lodvær <lodvaer@gmail.com>"
|
||||||
license="BSD-3-Clause"
|
license="BSD-3-Clause"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user