diff options
author | Michael Scheidell <scheidell@FreeBSD.org> | 2012-02-10 14:37:30 +0000 |
---|---|---|
committer | Michael Scheidell <scheidell@FreeBSD.org> | 2012-02-10 14:37:30 +0000 |
commit | 1793f6d69a6c4412b1239ae8535b4f8708afc7d8 (patch) | |
tree | 3a4e77c331b837525f2bfba6aeec28fc4128f44e /security/swatch | |
parent | f46d4c4e4b656f80956caa18006f5a8fa53f704d (diff) | |
download | ports-1793f6d69a6c4412b1239ae8535b4f8708afc7d8.tar.gz ports-1793f6d69a6c4412b1239ae8535b4f8708afc7d8.zip |
- patch swatch.rc to check for buffer overflow in cmdarg with long _flags lines
- add p5-File-Tail dependency
- Bump PORTREVISION
PR: ports/164529
Submitted by: scheidell
Approved by: joseph@randomnetworks.com (maintainer timeout, 15 days), gabor (mentor)
Notes
Notes:
svn path=/head/; revision=290860
Diffstat (limited to 'security/swatch')
-rw-r--r-- | security/swatch/Makefile | 5 | ||||
-rw-r--r-- | security/swatch/files/swatch.in | 13 |
2 files changed, 13 insertions, 5 deletions
diff --git a/security/swatch/Makefile b/security/swatch/Makefile index aaaa671c30f2..0b86a75e9251 100644 --- a/security/swatch/Makefile +++ b/security/swatch/Makefile @@ -7,7 +7,7 @@ PORTNAME= swatch PORTVERSION= 3.2.3 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= security sysutils MASTER_SITES= SF @@ -17,7 +17,8 @@ COMMENT= The Simple WATCHer and filter BUILD_DEPENDS= \ ${SITE_PERL}/Date/Format.pm:${PORTSDIR}/devel/p5-TimeDate \ ${SITE_PERL}/Date/Manip.pm:${PORTSDIR}/devel/p5-Date-Manip \ - ${SITE_PERL}/Date/Calc.pm:${PORTSDIR}/devel/p5-Date-Calc + ${SITE_PERL}/Date/Calc.pm:${PORTSDIR}/devel/p5-Date-Calc \ + ${SITE_PERL}/File/Tail.pm:${PORTSDIR}/devel/p5-File-Tail RUN_DEPENDS:= ${BUILD_DEPENDS} PERL_CONFIGURE= yes diff --git a/security/swatch/files/swatch.in b/security/swatch/files/swatch.in index 038701a44ea7..e5c3fbdf7bba 100644 --- a/security/swatch/files/swatch.in +++ b/security/swatch/files/swatch.in @@ -4,6 +4,7 @@ # # PROVIDE: swatch # REQUIRE: DAEMON +# KEYWORD: shutdown # # To enable multiple instance of swatch, add lines like below to # /etc/rc.conf. @@ -22,14 +23,20 @@ name=swatch rcvar=swatch_enable -command=%%PREFIX%%/bin/swatch -procname=%%LOCALBASE%%/bin/perl - load_rc_config ${name} +# set some defaults +: ${swatch_enable:="NO"} + +command=%%PREFIX%%/bin/swatch + if [ -n "${swatch_rules}" ]; then for i in ${swatch_rules}; do eval swatch_flags=\$swatch_${i}_flags + len=`echo "0${command} ${swatch_flags} (perl)0" | wc -c` + if [ $len -ge 255 ];then + procname=%%LOCALBASE%%/bin/perl + fi eval swatch_user=\$swatch_${i}_user eval swatch_chdir=\$swatch_${i}_chdir eval pidfile=\$swatch_${i}_pidfile |