View | Details | Raw Unified | Return to bug 223052 | Differences between
and this patch

Collapse All | Expand All

(-)b/security/suricata/Makefile (+1 lines)
Lines 3-8 Link Here
3
3
4
PORTNAME=	suricata
4
PORTNAME=	suricata
5
PORTVERSION=	4.0.0
5
PORTVERSION=	4.0.0
6
PORTREVISION=	1
6
CATEGORIES=	security
7
CATEGORIES=	security
7
MASTER_SITES=	http://www.openinfosecfoundation.org/download/
8
MASTER_SITES=	http://www.openinfosecfoundation.org/download/
8
9
(-)b/security/suricata/files/suricata.in (-2 / +15 lines)
Lines 19-31 Link Here
19
#				Default: 8000
19
#				Default: 8000
20
# suricata_netmap (str):	Set to YES to enable netmap (Inline Mode)
20
# suricata_netmap (str):	Set to YES to enable netmap (Inline Mode)
21
#				Default: NO
21
#				Default: NO
22
22
# suricata_user (str):		Set the user to run suricata as
23
#				Default: root
24
# suricata_pidfile (str):	Pidfile to store pid of suricata process
25
#				Default: /var/run/suricata.pid
23
26
24
. /etc/rc.subr
27
. /etc/rc.subr
25
28
26
name="suricata"
29
name="suricata"
27
rcvar=suricata_enable
30
rcvar=suricata_enable
28
31
32
start_precmd="suricata_prestart"
29
command="%%PREFIX%%/bin/suricata"
33
command="%%PREFIX%%/bin/suricata"
30
34
31
load_rc_config $name
35
load_rc_config $name
Lines 35-40 load_rc_config $name Link Here
35
[ -z "$suricata_flags" ]	&& suricata_flags="-D"
39
[ -z "$suricata_flags" ]	&& suricata_flags="-D"
36
[ -z "$suricata_divertport" ]	&& suricata_divertport="8000"
40
[ -z "$suricata_divertport" ]	&& suricata_divertport="8000"
37
[ -z "$suricata_netmap" ]	&& suricata_netmap="NO"
41
[ -z "$suricata_netmap" ]	&& suricata_netmap="NO"
42
[ -z "$suricata_user" ]		&& suricata_user="root"
43
[ -z "$suricata_pidfile" ]	&& suricata_pidfile="/var/run/suricata.pid"
38
44
39
if [ -n "$suricata_interface" ]; then
45
if [ -n "$suricata_interface" ]; then
40
	for interface in $suricata_interface; do
46
	for interface in $suricata_interface; do
Lines 47-55 else Link Here
47
	info "Inline Mode on divert port $suricata_divertport (suricata_interface not defined)"
53
	info "Inline Mode on divert port $suricata_divertport (suricata_interface not defined)"
48
fi
54
fi
49
55
50
pidfile="/var/run/suricata.pid"
56
pidfile=$suricata_pidfile
51
suricata_flags="$suricata_flags --pidfile $pidfile"
57
suricata_flags="$suricata_flags --pidfile $pidfile"
52
58
53
[ -n "$suricata_conf" ]	&& suricata_flags="$suricata_flags -c $suricata_conf"
59
[ -n "$suricata_conf" ]	&& suricata_flags="$suricata_flags -c $suricata_conf"
54
60
61
suricata_prestart()
62
{
63
	if ! run_rc_command status > /dev/null; then
64
		rm -f "$pidfile"
65
	fi
66
}
67
55
run_rc_command "$1"
68
run_rc_command "$1"

Return to bug 223052