summaryrefslogtreecommitdiff
path: root/etc/rc.d/spamlogd
blob: ced8f07edbd8e228ff53821136650a41220f2bf6 (plain)
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
#!/bin/ksh
#
# $OpenBSD: spamlogd,v 1.4 2018/01/11 21:09:26 rpe Exp $

daemon="/usr/libexec/spamlogd"

. /etc/rc.d/rc.subr

rc_reload=NO

rc_pre() {
	[[ ${spamd_flags} != NO && ${spamd_black} == NO ]]
	if pfctl -si | grep -q Enabled; then
		ifconfig pflog0 create
		if ifconfig pflog0; then
			ifconfig pflog0 up
		else
			return 1
		fi
	else
		return 1
	fi
}

rc_cmd $1