aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoger Pau Monne <roger.pau@entel.upc.edu>2012-02-07 20:50:30 +0100
committerNatanael Copa <ncopa@alpinelinux.org>2012-02-08 20:28:33 +0000
commit7d74afef79b993b035ccd5f4ea5c3e0ba632b079 (patch)
treeb62f17e4c90cded5d8a85d73f3394a6c4ac4c50b
parent0b095f9fe2ee5aad3158e1e979ad13f442f9f4c3 (diff)
downloadaports-7d74afef79b993b035ccd5f4ea5c3e0ba632b079.tar.bz2
aports-7d74afef79b993b035ccd5f4ea5c3e0ba632b079.tar.xz
testing/sshguard: fix parsing of busybox syslog
-rw-r--r--testing/sshguard/APKBUILD8
-rw-r--r--testing/sshguard/parser.patch11
2 files changed, 16 insertions, 3 deletions
diff --git a/testing/sshguard/APKBUILD b/testing/sshguard/APKBUILD
index 089c5874cd..c6a69b480e 100644
--- a/testing/sshguard/APKBUILD
+++ b/testing/sshguard/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=sshguard
pkgver=1.5
-pkgrel=0
+pkgrel=1
pkgdesc="Log monitor that blocks with iptables on bad behaviour"
url="http://www.sshguard.net/"
arch="all"
@@ -14,7 +14,8 @@ install=""
subpackages="$pkgname-doc"
source="http://downloads.sourceforge.net/project/sshguard/sshguard/sshguard-$pkgver/sshguard-$pkgver.tar.bz2
sshguard.initd
- sshguard.confd"
+ sshguard.confd
+ parser.patch"
_builddir="$srcdir"/sshguard-$pkgver
prepare() {
@@ -46,4 +47,5 @@ package() {
md5sums="11b9f47f9051e25bdfe84a365c961ec1 sshguard-1.5.tar.bz2
13eb7c7e7a91cc347dbd6ff111d662c4 sshguard.initd
-02dc914d310ea759a66ebb136f495e4e sshguard.confd"
+02dc914d310ea759a66ebb136f495e4e sshguard.confd
+84ff8858abb8d5a673037cf592bb6794 parser.patch"
diff --git a/testing/sshguard/parser.patch b/testing/sshguard/parser.patch
new file mode 100644
index 0000000000..51f9915e18
--- /dev/null
+++ b/testing/sshguard/parser.patch
@@ -0,0 +1,11 @@
+--- sshguard-1.5/src/parser/attack_scanner.l
++++ sshguard-1.5-mod/src/parser/attack_scanner.l
+@@ -107,7 +107,7 @@
+ */
+
+ /* handle entries with PID and without PID from processes other than sshguard */
+-{TIMESTAMP_SYSLOG}[ ]+([a-zA-Z0-9]|{WORD}|{HOSTADDR})[ ]+{PROCESSNAME}"["{NUMBER}"]: "{SOLARIS_MSGID_TAG}? {
++{TIMESTAMP_SYSLOG}[ ]+([a-zA-Z0-9]|{WORD}|{HOSTADDR})[ ]+([a-zA-Z0-9]|{WORD}|{HOSTADDR})[ ]+{PROCESSNAME}"["{NUMBER}"]: "{SOLARIS_MSGID_TAG}? {
+ /* extract PID */
+ yylval.num = getsyslogpid(yytext, yyleng);
+ return SYSLOG_BANNER_PID;