-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
milter-spamd is a sendmail milter plugin that passes mails through
SpamAssassin's spamd, rejecting mails inline that are considered spam. ok sturm@
- Loading branch information
Daniel Hartmeier
committed
May 24, 2004
1 parent
05dd935
commit 287830e
Showing
9 changed files
with
150 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# $OpenBSD: Makefile,v 1.1 2004/05/24 07:35:47 dhartmei Exp $ | ||
|
||
.if !exists(/usr/lib/libmilter.a) | ||
IGNORE="Fatal: milter required, see instructions in DESCR" | ||
.endif | ||
|
||
COMMENT= "sendmail milter plugin for SpamAssassin spamd" | ||
|
||
DISTNAME= milter-spamd-0.3 | ||
CATEGORIES= mail | ||
MASTER_SITES= http://www.benzedrine.cx/ | ||
|
||
HOMEPAGE= http://www.benzedrine.cx/milter-spamd.html | ||
|
||
MAINTAINER= Daniel Hartmeier <[email protected]> | ||
|
||
# BSD | ||
PERMIT_PACKAGE_CDROM= Yes | ||
PERMIT_PACKAGE_FTP= Yes | ||
PERMIT_DISTFILES_CDROM= Yes | ||
PERMIT_DISTFILES_FTP= Yes | ||
|
||
NO_REGRESS= Yes | ||
|
||
do-configure: | ||
@perl -pi -e 's,/etc/mi,${SYSCONFDIR}/mi,g' ${WRKSRC}/milter-spamd.{8,c} | ||
|
||
do-install: | ||
${INSTALL_PROGRAM} ${WRKSRC}/milter-spamd ${PREFIX}/libexec | ||
${INSTALL_MAN} ${WRKSRC}/milter-spamd.8 ${PREFIX}/man/man8 | ||
|
||
.include <bsd.port.mk> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
MD5 (milter-spamd-0.3.tar.gz) = e2adc28256a92053d96c8915bcae1141 | ||
RMD160 (milter-spamd-0.3.tar.gz) = 1596ebcfb5f386bbc85197ccb21326194518ab2a | ||
SHA1 (milter-spamd-0.3.tar.gz) = 2c18cd949f46c10f094241ee5f2d3b419104c6ce |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/bin/sh | ||
# $OpenBSD: DEINSTALL,v 1.1 2004/05/24 07:35:47 dhartmei Exp $ | ||
# | ||
# milter-spamd de-installation | ||
|
||
PATH=/bin:/usr/bin:/sbin:/usr/sbin | ||
DIR=/var/spool/milter-spamd | ||
USER=_milter-spamd | ||
GROUP=_milter-spamd | ||
|
||
echo | ||
echo "+---------------" | ||
echo "| To completely deinstall the $1 package you need to perform" | ||
echo "| these steps as root:" | ||
echo "|" | ||
echo "| userdel $USER" | ||
echo "| groupdel $GROUP" | ||
echo "| rm -rf $DIR" | ||
echo "+---------------" | ||
echo | ||
|
||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
milter-spamd is a sendmail milter plugin that passes mails through | ||
SpamAssassin's spamd, rejecting mails inline that are considered | ||
spam. | ||
|
||
In order to build milter-spamd, sendmail needs to be compiled with | ||
milter support, installing the libmilter library: | ||
|
||
# cd /usr/src/gnu/usr.sbin/sendmail | ||
# make clean cleandir | ||
# [set the environment variable WANT_LIBMILTER to 1] | ||
# make obj && make && make install | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#!/bin/sh | ||
# $OpenBSD: INSTALL,v 1.1 2004/05/24 07:35:47 dhartmei Exp $ | ||
# | ||
# Pre/post-installation setup of milter-spamd | ||
|
||
PATH=/bin:/usr/bin:/sbin:/usr/sbin | ||
DIR=/var/spool/milter-spamd | ||
USER=_milter-spamd | ||
GROUP=_milter-spamd | ||
ID=532 | ||
|
||
do_usergroup_install() | ||
{ | ||
# Create milter-spamd user and group | ||
groupinfo -e $GROUP | ||
if [ $? -eq 0 ]; then | ||
echo "===> Using $GROUP group for milter-spamd" | ||
else | ||
echo "===> Creating $GROUP group for milter-spamd" | ||
groupadd -g $ID $GROUP | ||
fi | ||
userinfo -e $USER | ||
if [ $? -eq 0 ]; then | ||
echo "===> Using $USER user for milter-spamd" | ||
else | ||
echo "===> Creating $USER user for milter-spamd" | ||
useradd -g $GROUP -d /nonexistent -L daemon \ | ||
-c 'milter-spamd Account' -s /sbin/nologin \ | ||
-u $ID $USER 2>&1| grep nonexistant >&2 | ||
fi | ||
} | ||
|
||
do_install() | ||
{ | ||
install -d -o $USER -g $GROUP -m 700 $DIR | ||
} | ||
|
||
if [ $# -ne 2 ]; then | ||
echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2 | ||
exit 1 | ||
fi | ||
|
||
case $2 in | ||
PRE-INSTALL) | ||
do_usergroup_install | ||
if [ ! -d $DIR ]; then | ||
do_install | ||
fi | ||
;; | ||
POST-INSTALL) | ||
;; | ||
*) | ||
echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2 | ||
exit 1 | ||
;; | ||
esac | ||
|
||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
+--------------- | ||
| milter-spamd has been installed as ${PREFIX}/libexec/milter-spamd. | ||
| See milter-spamd(8) for instructions on how to register the plugin. | ||
| | ||
| To start the plugin automatically on startup, one can use: | ||
| | ||
| /etc/rc.conf.local | ||
| milter_spamd="" | ||
| | ||
| /etc/rc.local | ||
| if [ X"${milter_spamd}" != X"NO" -a \ | ||
| -x ${PREFIX}/libexec/milter-spamd ]; then | ||
| echo -n ' milter-spamd' | ||
| ${PREFIX}/libexec/milter-spamd ${milter_spamd} | ||
| fi | ||
+--------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@comment $OpenBSD: PLIST,v 1.1 2004/05/24 07:35:47 dhartmei Exp $ | ||
libexec/milter-spamd | ||
man/man8/milter-spamd.8 |