aboutsummaryrefslogtreecommitdiffstats
path: root/security/bruteforceblocker/Makefile
blob: a20fbfb9a5a140d447aa8eb2e0a5bda13fa3a62f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# New ports collection makefile for:    bruteforceblocker
# Date created:             20 April 2005
# Whom:                 Daniel Gerzo <danger@rulez.sk>
#
# $FreeBSD$
#

PORTNAME=   bruteforceblocker
PORTVERSION=    1.2.3
CATEGORIES= security
MASTER_SITES=   http://danger.rulez.sk/projects/bruteforceblocker/ \
        ${MASTER_SITE_LOCAL}
MASTER_SITE_SUBDIR= pav

MAINTAINER= danger@FreeBSD.org
COMMENT=    Checks for SSH bruteforce and blocks given IPs

RUN_DEPENDS=    ${SITE_PERL}/${PERL_ARCH}/Unix/Syslog.pm:${PORTSDIR}/sysutils/p5-Unix-Syslog \
        ${SITE_PERL}/Sys/Hostname/Long.pm:${PORTSDIR}/sysutils/p5-Sys-Hostname-Long \
        ${SITE_PERL}/LWP/UserAgent.pm:${PORTSDIR}/www/p5-libwww \
        ${SITE_PERL}/${PERL_ARCH}/Net/DNS.pm:${PORTSDIR}/dns/p5-Net-DNS

NO_BUILD=   yes
USE_PERL5_RUN=  yes

WRKSRC=     ${WRKDIR}/${PORTNAME}
PKGMESSAGE= ${WRKDIR}/pkg-message
SUB_FILES=  pkg-message

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 502106
IGNORE=     requires at least FreeBSD 5.2
.endif

do-install:
    ${INSTALL_SCRIPT} ${WRKSRC}/${PORTNAME}.pl ${PREFIX}/sbin/${PORTNAME}
    ${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.conf ${PREFIX}/etc/${PORTNAME}.conf-dist
.if !defined(NOPORTDOCS)
    @${MKDIR} ${DOCSDIR}
.for FILE in INSTALL CHANGELOG CREDITS
    ${INSTALL_DATA} ${WRKSRC}/${FILE} ${DOCSDIR}
.endfor
.endif

post-install:
    @if [ ! -f ${PREFIX}/etc/${PORTNAME}.conf ]; then \
        ${CP} -p ${PREFIX}/etc/${PORTNAME}.conf-dist ${PREFIX}/etc/${PORTNAME}.conf ; \
    fi
.if !defined(BATCH)
    @${CAT} ${PKGMESSAGE}
.endif

.include <bsd.port.post.mk>