diff options
-rw-r--r-- | mail/Makefile | 1 | ||||
-rw-r--r-- | mail/dovecot-antispam/Makefile | 52 | ||||
-rw-r--r-- | mail/dovecot-antispam/distinfo | 3 | ||||
-rw-r--r-- | mail/dovecot-antispam/files/patch-dspam-exec.c | 20 | ||||
-rw-r--r-- | mail/dovecot-antispam/pkg-descr | 16 | ||||
-rw-r--r-- | mail/dovecot-antispam/pkg-message | 16 | ||||
-rw-r--r-- | mail/dovecot-antispam/pkg-plist | 3 |
7 files changed, 111 insertions, 0 deletions
diff --git a/mail/Makefile b/mail/Makefile index 1a5cae60447a..89b9b124629d 100644 --- a/mail/Makefile +++ b/mail/Makefile @@ -88,6 +88,7 @@ SUBDIR += dkimap4 SUBDIR += dkimproxy SUBDIR += dovecot + SUBDIR += dovecot-antispam SUBDIR += dovecot-sieve SUBDIR += drac SUBDIR += drbl diff --git a/mail/dovecot-antispam/Makefile b/mail/dovecot-antispam/Makefile new file mode 100644 index 000000000000..74fb193d568e --- /dev/null +++ b/mail/dovecot-antispam/Makefile @@ -0,0 +1,52 @@ +# New ports collection makefile for: dovecot-antispam +# Date created: Sat Jan 5 16:31:30 MSK 2008 +# Whom: Denis Shaposhnikov <dsh@wizard.volgograd.ru> +# +# $FreeBSD$ +# + +PORTNAME= dovecot-antispam +PORTVERSION= 20071029 +CATEGORIES= mail +MASTER_SITES= http://ports.internal.vlink.ru/distfiles/ \ + ${MASTER_SITE_LOCAL} +MASTER_SITE_SUBDIR= ehaupt + +MAINTAINER= dsh@wizard.volgograd.ru +COMMENT= Dovecot plugin to train dspam about spam or false positives + +BUILD_DEPENDS= ${NONEXISTENT}:${PORTSDIR}/mail/dovecot:configure +RUN_DEPENDS= dovecot>=1.0.10:${PORTSDIR}/mail/dovecot + +USE_BZIP2= yes +USE_GMAKE= yes +USE_LDCONFIG= ${PREFIX}/lib/dovecot/imap + +MAN7= dovecot-antispam.7 + +OPTIONS+= DSPAM "direct dspam training" on +OPTIONS+= MAILTRAIN "send mail to special addresses for training" off + +do-install: + ${INSTALL_DATA} ${WRKSRC}/lib90_antispam_plugin.so \ + ${PREFIX}/lib/dovecot/imap/ + ${INSTALL_MAN} ${WRKSRC}/antispam.7 \ + ${MANPREFIX}/man/man7/dovecot-antispam.7 + + @${CAT} ${PKGMESSAGE} + +.include <bsd.port.pre.mk> + +do-configure: + DOVECOT=`${MAKE} -C ${PORTSDIR}/mail/dovecot -V WRKSRC` && \ + ${ECHO} "DOVECOT=$$DOVECOT" > ${WRKSRC}/.config + ${ECHO} "DOVECOT_VERSION=1.0" >> ${WRKSRC}/.config +.if defined(WITH_DSPAM) + ${ECHO} "BACKEND=dspam-exec" >> ${WRKSRC}/.config +.endif +.if defined(WITH_MAILTRAIN) + ${ECHO} "BACKEND=mailtrain" >> ${WRKSRC}/.config +.endif + ${ECHO} "PLUGINNAME=antispam" >> ${WRKSRC}/.config + +.include <bsd.port.post.mk> diff --git a/mail/dovecot-antispam/distinfo b/mail/dovecot-antispam/distinfo new file mode 100644 index 000000000000..f82312a51732 --- /dev/null +++ b/mail/dovecot-antispam/distinfo @@ -0,0 +1,3 @@ +MD5 (dovecot-antispam-20071029.tar.bz2) = 128b94b34f81807192256cfed5b3e809 +SHA256 (dovecot-antispam-20071029.tar.bz2) = 7134526bd3edb999c1292f64654f1510b993a82da3fca1c3db442e47ed9a0464 +SIZE (dovecot-antispam-20071029.tar.bz2) = 17205 diff --git a/mail/dovecot-antispam/files/patch-dspam-exec.c b/mail/dovecot-antispam/files/patch-dspam-exec.c new file mode 100644 index 000000000000..277e5f23874b --- /dev/null +++ b/mail/dovecot-antispam/files/patch-dspam-exec.c @@ -0,0 +1,20 @@ +--- dspam-exec.c.orig 2007-10-29 14:09:16.000000000 +0300 ++++ dspam-exec.c 2008-01-05 18:38:37.000000000 +0300 +@@ -127,7 +127,7 @@ + + argv[0] = (char *)dspam_binary; + argv[1] = "--source=error"; +- argv[2] = "--stdout"; ++ argv[2] = "--deliver="; + argv[3] = (char *)class_arg; + argv[4] = (char *)sign_arg; + +@@ -136,7 +136,7 @@ + * not good with stderr debuggin since we then write to + * stderr which our parent takes as a bug + */ +- debug("%s --source=error --stdout %s %s ...", ++ debug("%s --source=error --deliver= %s %s ...", + dspam_binary, class_arg, sign_arg); + #endif + diff --git a/mail/dovecot-antispam/pkg-descr b/mail/dovecot-antispam/pkg-descr new file mode 100644 index 000000000000..3911232abd4e --- /dev/null +++ b/mail/dovecot-antispam/pkg-descr @@ -0,0 +1,16 @@ +The dovecot antispam plugin watches a defined spam folder (defaults to +"SPAM"). Instead of moving mail into special folders or forwarding +them to special mail addresses for retraining, the plugin offers two +actions for the user: + + 1. moving mail out of the SPAM folder and + + 2. moving mail into the SPAM folder. + +The dovecot plugin watches these actions (and additionally prohibits +APPENDs to the SPAM folder, more for technical reasons than others) +and tells the spam classifier that it made an error and needs to +re-clas- sify the message (as spam/not spam depending on which way it +was moved.) + +WWW: http://johannes.sipsolutions.net/Projects/dovecot-antispam diff --git a/mail/dovecot-antispam/pkg-message b/mail/dovecot-antispam/pkg-message new file mode 100644 index 000000000000..2af0912f09b4 --- /dev/null +++ b/mail/dovecot-antispam/pkg-message @@ -0,0 +1,16 @@ +--------------------------------------------------------------------- + +This port assumes you are known with Dovecot and have it installed and +running on the system you have installed this plugin on. + +You can enable the plugin with this directive in your dovecot.conf: + + protocol imap { + mail_plugins = antispam + } + +Further information on configuration can be found at: + + man 7 dovecot-antispam + +--------------------------------------------------------------------- diff --git a/mail/dovecot-antispam/pkg-plist b/mail/dovecot-antispam/pkg-plist new file mode 100644 index 000000000000..df1a6f894205 --- /dev/null +++ b/mail/dovecot-antispam/pkg-plist @@ -0,0 +1,3 @@ +lib/dovecot/imap/lib90_antispam_plugin.so +@dirrmtry lib/dovecot/imap +@dirrmtry lib/dovecot |