Index: Makefile =================================================================== RCS file: /home/ncvs/ports/mail/mailscanner/Makefile,v retrieving revision 1.58 diff -u -r1.58 Makefile --- Makefile 16 Jan 2007 21:13:02 -0000 1.58 +++ Makefile 9 Feb 2007 13:31:03 -0000 @@ -6,7 +6,7 @@ # PORTNAME= MailScanner -PORTVERSION= 4.57.6 +PORTVERSION= 4.58.9 PORTREVISION= 1 CATEGORIES= mail MASTER_SITES= http://www.mailscanner.info/files/4/tar/ @@ -122,7 +122,8 @@ nod32-autoupdate rav-autoupdate \ rav-wrapper sophos-autoupdate -USE_RC_SUBR= mailscanner.sh mta.sh +USE_RC_SUBR= mailscanner mta +SUB_LIST+= RC_SUBR_SUFFIX=${RC_SUBR_SUFFIX} post-extract: cd ${WRKSRC} && ${TAR} xvzf perl-tar/MailScanner-${PORTVERSION}-${PATCHLEVEL}.tar.gz > /dev/null && ${MV} MailScanner-${PORTVERSION}/* . @@ -277,6 +278,7 @@ # Sophos install script ${INSTALL_SCRIPT} ${FILESDIR}/Sophos.install.freebsd ${DOCSDIR} cd ${WRKSRC} && ${INSTALL_DATA} ${DOC_FILES} ${DOCSDIR} + cd ${FILESDIR} && ${INSTALL_DATA} CHANGES.port ${DOCSDIR} .endif cd ${FILESDIR} && \ ${INSTALL_MAN} ${MAN8} ${MAN5PREFIX}/man/man8 Index: distinfo =================================================================== RCS file: /home/ncvs/ports/mail/mailscanner/distinfo,v retrieving revision 1.40 diff -u -r1.40 distinfo --- distinfo 16 Jan 2007 21:13:02 -0000 1.40 +++ distinfo 9 Feb 2007 13:31:03 -0000 @@ -1,3 +1,3 @@ -MD5 (MailScanner-install-4.57.6-1.tar.gz) = b025773a1854140f75dca48a52818ed3 -SHA256 (MailScanner-install-4.57.6-1.tar.gz) = 52cbacb22c6a82fc39b2aef89b74774e504bb8d4baf5530c225369b08ee52754 -SIZE (MailScanner-install-4.57.6-1.tar.gz) = 7051901 +MD5 (MailScanner-install-4.58.9-1.tar.gz) = 5c641a7d76beaa0bb7d9efcb04f6b333 +SHA256 (MailScanner-install-4.58.9-1.tar.gz) = 4e4f362fc8778c9a0deaff696f8c966081c4bf08227f3bd036f39fbbe6d7010c +SIZE (MailScanner-install-4.58.9-1.tar.gz) = 7058345 Index: pkg-plist =================================================================== RCS file: /home/ncvs/ports/mail/mailscanner/pkg-plist,v retrieving revision 1.32 diff -u -r1.32 pkg-plist --- pkg-plist 16 Jan 2007 21:13:02 -0000 1.32 +++ pkg-plist 9 Feb 2007 13:31:04 -0000 @@ -22,6 +22,8 @@ lib/MailScanner/MailScanner/CustomFunctions/DavidHooton.pm lib/MailScanner/MailScanner/CustomFunctions/ZMRouterDirHash.pm lib/MailScanner/MailScanner/CustomFunctions/SpamWhitelist.pm +lib/MailScanner/MailScanner/CustomFunctions/LastSpam.pm +lib/MailScanner/MailScanner/CustomFunctions/Ruleset-from-Function.pm lib/MailScanner/MailScanner/Exim.pm lib/MailScanner/MailScanner/EximDiskStore.pm lib/MailScanner/MailScanner/GenericSpam.pm @@ -513,6 +515,7 @@ %%DATADIR%%/reports/sk/sender.size.report.txt.sample %%DATADIR%%/reports/sk/stored.size.message.txt.sample %%PORTDOCS%%%%DOCSDIR%%/README.FreeBSD.port +%%PORTDOCS%%%%DOCSDIR%%/CHANGES.port %%PORTDOCS%%%%DOCSDIR%%/Sophos.install.freebsd %%PORTDOCS%%%%DOCSDIR%%/INSTALL.FreeBSD %%PORTDOCS%%%%DOCSDIR%%/INSTALL.OpenBSD Index: files/CHANGES.port =================================================================== RCS file: /home/ncvs/ports/mail/mailscanner/files/CHANGES.port,v retrieving revision 1.12 diff -u -r1.12 CHANGES.port --- files/CHANGES.port 16 Jan 2007 21:13:03 -0000 1.12 +++ files/CHANGES.port 9 Feb 2007 13:31:04 -0000 @@ -1,3 +1,9 @@ +Version 4.58.9 +================ +- Upgrade to MailScanner 4.58 +- fix: CHANGES.port was not installed anymore +- startscripts now honor RC_SUBR_SUFFIX + Version 4.57.6_1 ================ - Upgrade to MailScanner 4.57 Index: files/mailscanner.in =================================================================== RCS file: files/mailscanner.in diff -N files/mailscanner.in --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/mailscanner.in 9 Feb 2007 13:31:04 -0000 @@ -0,0 +1,43 @@ +#! /bin/sh + +# PROVIDE: mailscanner +# REQUIRE: mta +# KEYWORD: shutdown + +# +# Add the following lines to /etc/rc.conf to enable mailscanner: +# mailscanner_enable (bool): Set to "NO" by default. +# Set it to "YES" to enable mailscanner +# mailscanner_configfile (path): Set to "%%PREFIX%%/etc/MailScanner/MailScanner.conf" by default. +# mailscanner_pidfile (path): Set to "/var/run/MailScanner.pid" by default. +# + +. %%RC_SUBR%% + +name="mailscanner" +rcvar=`set_rcvar` + +load_rc_config $name + +: ${mailscanner_enable="NO"} +: ${mailscanner_configfile="%%PREFIX%%/etc/MailScanner/MailScanner.conf"} +: ${mailscanner_pidfile="/var/run/MailScanner.pid"} + +command="%%PREFIX%%/sbin/mailscanner" +pidfile=${mailscanner_pidfile} +command_args="${mailscanner_configfile}" + +required_files="${mailscanner_configfile}" + +_ms_start_precmd() { + # Quietly try to raise the open_files limit + # + ulimit -n 2000 >/dev/null 2>&1 +} + +start_precmd=_ms_start_precmd + +procname="MailScanner" + +run_rc_command "$1" + Index: files/mailscanner.sh.in =================================================================== RCS file: files/mailscanner.sh.in diff -N files/mailscanner.sh.in --- files/mailscanner.sh.in 20 Feb 2006 20:47:12 -0000 1.3 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,43 +0,0 @@ -#! /bin/sh - -# PROVIDE: mailscanner -# REQUIRE: mta -# KEYWORD: shutdown - -# -# Add the following lines to /etc/rc.conf to enable mailscanner: -# mailscanner_enable (bool): Set to "NO" by default. -# Set it to "YES" to enable mailscanner -# mailscanner_configfile (path): Set to "%%PREFIX%%/etc/MailScanner/MailScanner.conf" by default. -# mailscanner_pidfile (path): Set to "/var/run/MailScanner.pid" by default. -# - -. %%RC_SUBR%% - -name="mailscanner" -rcvar=`set_rcvar` - -load_rc_config $name - -: ${mailscanner_enable="NO"} -: ${mailscanner_configfile="%%PREFIX%%/etc/MailScanner/MailScanner.conf"} -: ${mailscanner_pidfile="/var/run/MailScanner.pid"} - -command="%%PREFIX%%/sbin/mailscanner" -pidfile=${mailscanner_pidfile} -command_args="${mailscanner_configfile}" - -required_files="${mailscanner_configfile}" - -_ms_start_precmd() { - # Quietly try to raise the open_files limit - # - ulimit -n 2000 >/dev/null 2>&1 -} - -start_precmd=_ms_start_precmd - -procname="MailScanner" - -run_rc_command "$1" - Index: files/mta.in =================================================================== RCS file: files/mta.in diff -N files/mta.in --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/mta.in 9 Feb 2007 13:31:04 -0000 @@ -0,0 +1,151 @@ +#!/bin/sh +# +# mta.sh - start multiple MTA instances, e.g. for MailScanner + +# PROVIDE: mta +# REQUIRE: LOGIN cleanvar +# BEFORE: +# KEYWORD: shutdown + +# +# Add the following lines to /etc/rc.conf to enable mta at boot-up time: +# mta_enable (bool): Set to "NO" by default. +# Set it to "YES" to enable mta +# mta_type (str): Type of MTA (sendmail, exim, unknown), defaults to "sendmail" +# mta_profiles (string): Undefined by default. Define your profiles here. +# mta_flags (str): Set to "" by default. +# Extra flags passed to start command. +# mta_program (str): Path to program, defaults depending on $mta_type +# either to "/usr/sbin/sendmail" or "/usr/local/sbin/exim" +# mta_configfile (str): Config file, defaults depending on $mta_type either +# to "/etc/mail/sendmail.cf" or "/usr/local/etc/exim/configure" +# mta_pidfile (str): PID file, defaults depending on $mta_type either +# to "/var/run/sendmail.pid" or "/var/run/exim.pid" +# +# +# ATTENTION: All of the above entries are necessary in order for mta.sh to work correctly! +# + +# +# Examples: +# +# Exim, 2 instances (for MailScanner): +# +# mta_enable="YES" +# mta_type="exim" +# mta_profiles="incoming outgoing" +# mta_incoming_configfile="/usr/local/etc/exim/configure.in" +# mta_incoming_flags="-bd" +# mta_incoming_pidfile="/var/run/exim_in.pid" +# mta_outgoing_configfile="/usr/local/etc/exim/configure.out" +# mta_outgoing_flags="-q15m" +# mta_outgoing_pidfile="/var/run/exim_out.pid" +# +# Sendmail, 3 instances (for MailScanner): +# +# mta_enable="YES" +# mta_type="sendmail" +# mta_profiles="incoming outgoing submitqueue" +# mta_incoming_flags="-L sm-mta-in -bd -OPrivacyOptions=noetrn -OQueueDirectory=/var/spool/mqueue.in -ODeliveryMode=queueonly" +# mta_incoming_pidfile="/var/run/sendmail_in.pid" +# mta_incoming_configfile="/etc/mail/sendmail.cf" +# mta_outgoing_flags="-L sm-mta-out -q15m" +# mta_outgoing_pidfile="/var/run/sendmail_out.pid" +# mta_outgoing_configfile="/etc/mail/sendmail.cf" +# mta_submitqueue_flags="-L sm-msp-queue -Ac -q15m" +# mta_submitqueue_pidfile="/var/spool/clientmqueue/sm-client.pid" +# mta_submitqueue_configfile="/etc/mail/submit.cf" + +PATH=$PATH:/sbin:/usr/sbin; export PATH + +. %%RC_SUBR%% + +name="mta" +rcvar=`set_rcvar` + +_mta_rc_script="%%PREFIX%%/etc/rc.d/mta%%RC_SUBR_SUFFIX%%" + +load_rc_config $name + +: ${mta_enable="NO"} +: ${mta_type="sendmail"} +: ${mta_flags=""} + +case "${mta_type}" in + + sendmail) + _mta_program="/usr/sbin/sendmail" + _mta_configfile="/etc/mail/sendmail.cf" + _mta_pidfile="/var/run/sendmail.pid" + ;; + + exim) + _mta_program="/usr/local/sbin/exim" + _mta_configfile="/usr/local/etc/exim/configure" + _mta_pidfile="/var/run/exim.pid" + ;; +esac + +: ${mta_program=${_mta_program}} +: ${mta_configfile=${_mta_configfile}} +: ${mta_pidfile=${_mta_pidfile}} + +# support SIGHUP to reparse configuration file +extra_commands="reload" + +# command and arguments +command="${mta_program}" + +if [ -n "${2}" -o -n "$profile" ]; then + profile=${profile-$2} + export profile + if [ "x${mta_profiles}" != "x" ]; then + eval mta_configfile=\${mta_${profile}_configfile} + [ "x${mta_configfile}" = "x" ] && { + echo "You must define a configuration file (mta_${profile}_configfile)" + exit 1 + } + eval mta_enable=\${mta_${profile}_enable:-YES} + eval mta_flags=\${mta_${profile}_flags:-${mta_flags}} + eval mta_configfile=\${mta_${profile}_configfile:-${mta_configfile}} + eval mta_pidfile=\${mta_${profile}_pidfile:-${mta_pidfile}} + pidfile="${_pidprefix}.${profile}.pid" + else + echo "$_mta_rc_script: extra argument ignored" + fi +else + if [ "x${mta_profiles}" != "x" ]; then + for profile in ${mta_profiles}; do + echo "===> mta profile: ${profile}" + $_mta_rc_script $1 $profile + retcode=$? + if [ "$?" -ne 0 ]; then + failed="${profile} ({$retcode}) ${failed}" + else + success="${profile} ${success}" + fi + done + exit 0 + fi +fi + + +pidfile=${mta_pidfile} +required_files="${mta_configfile}" + +# select correct command arguments +case "${mta_type}" in + + sendmail) + command_args="-C'${mta_configfile}' -OPidFile='${pidfile}'" + ;; + + exim) + command_args="-C '${mta_configfile}' -oP '${pidfile}'" + ;; + + *) + command_args="" + ;; +esac +run_rc_command "$1" Index: files/mta.sh.in =================================================================== RCS file: files/mta.sh.in diff -N files/mta.sh.in --- files/mta.sh.in 27 Apr 2006 17:30:45 -0000 1.4 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,158 +0,0 @@ -#!/bin/sh -# -# mta.sh - start multiple MTA instances, e.g. for MailScanner - -# PROVIDE: mta -# REQUIRE: LOGIN cleanvar -# BEFORE: -# KEYWORD: shutdown - -# -# Add the following lines to /etc/rc.conf to enable mta at boot-up time: -# mta_enable (bool): Set to "NO" by default. -# Set it to "YES" to enable mta -# mta_type (str): Type of MTA (sendmail, exim, unknown), defaults to "sendmail" -# mta_profiles (string): Undefined by default. Define your profiles here. -# mta_flags (str): Set to "" by default. -# Extra flags passed to start command. -# mta_program (str): Path to program, defaults depending on $mta_type -# either to "/usr/sbin/sendmail" or "/usr/local/sbin/exim" -# mta_configfile (str): Config file, defaults depending on $mta_type either -# to "/etc/mail/sendmail.cf" or "/usr/local/etc/exim/configure" -# mta_pidfile (str): PID file, defaults depending on $mta_type either -# to "/var/run/sendmail.pid" or "/var/run/exim.pid" -# -# -# ATTENTION: All of the above entries are necessary in order for mta.sh to work correctly! -# - -# -# Examples: -# -# Exim, 2 instances (for MailScanner): -# -# mta_enable="YES" -# mta_type="exim" -# mta_profiles="incoming outgoing" -# mta_incoming_configfile="/usr/local/etc/exim/configure.in" -# mta_incoming_flags="-bd" -# mta_incoming_pidfile="/var/run/exim_in.pid" -# mta_outgoing_configfile="/usr/local/etc/exim/configure.out" -# mta_outgoing_flags="-q15m" -# mta_outgoing_pidfile="/var/run/exim_out.pid" -# -# Sendmail, 3 instances (for MailScanner): -# -# mta_enable="YES" -# mta_type="sendmail" -# mta_profiles="incoming outgoing submitqueue" -# mta_incoming_flags="-L sm-mta-in -bd -OPrivacyOptions=noetrn -OQueueDirectory=/var/spool/mqueue.in -ODeliveryMode=queueonly" -# mta_incoming_pidfile="/var/run/sendmail_in.pid" -# mta_incoming_configfile="/etc/mail/sendmail.cf" -# mta_outgoing_flags="-L sm-mta-out -q15m" -# mta_outgoing_pidfile="/var/run/sendmail_out.pid" -# mta_outgoing_configfile="/etc/mail/sendmail.cf" -# mta_submitqueue_flags="-L sm-msp-queue -Ac -q15m" -# mta_submitqueue_pidfile="/var/spool/clientmqueue/sm-client.pid" -# mta_submitqueue_configfile="/etc/mail/submit.cf" - -PATH=$PATH:/sbin:/usr/sbin; export PATH - -. %%RC_SUBR%% - -name="mta" -rcvar=`set_rcvar` - -_mta_rc_script="%%PREFIX%%/etc/rc.d/mta" -_mta_osversion="`sysctl -n kern.osreldate`" -if [ \( "$_mta_osversion" -lt "600101" \) -o \ - \( \( $_mta_osversion -ge 700000 \) -a \ - \( $_mta_osversion -lt 700007 \) \) ] -then - _mta_rc_script="${_mta_rc_script}.sh" -fi - -load_rc_config $name - -: ${mta_enable="NO"} -: ${mta_type="sendmail"} -: ${mta_flags=""} - -case "${mta_type}" in - - sendmail) - _mta_program="/usr/sbin/sendmail" - _mta_configfile="/etc/mail/sendmail.cf" - _mta_pidfile="/var/run/sendmail.pid" - ;; - - exim) - _mta_program="/usr/local/sbin/exim" - _mta_configfile="/usr/local/etc/exim/configure" - _mta_pidfile="/var/run/exim.pid" - ;; -esac - -: ${mta_program=${_mta_program}} -: ${mta_configfile=${_mta_configfile}} -: ${mta_pidfile=${_mta_pidfile}} - -# support SIGHUP to reparse configuration file -extra_commands="reload" - -# command and arguments -command="${mta_program}" - -if [ -n "${2}" -o -n "$profile" ]; then - profile=${profile-$2} - export profile - if [ "x${mta_profiles}" != "x" ]; then - eval mta_configfile=\${mta_${profile}_configfile} - [ "x${mta_configfile}" = "x" ] && { - echo "You must define a configuration file (mta_${profile}_configfile)" - exit 1 - } - eval mta_enable=\${mta_${profile}_enable:-YES} - eval mta_flags=\${mta_${profile}_flags:-${mta_flags}} - eval mta_configfile=\${mta_${profile}_configfile:-${mta_configfile}} - eval mta_pidfile=\${mta_${profile}_pidfile:-${mta_pidfile}} - pidfile="${_pidprefix}.${profile}.pid" - else - echo "$_mta_rc_script: extra argument ignored" - fi -else - if [ "x${mta_profiles}" != "x" ]; then - for profile in ${mta_profiles}; do - echo "===> mta profile: ${profile}" - $_mta_rc_script $1 $profile - retcode=$? - if [ "$?" -ne 0 ]; then - failed="${profile} ({$retcode}) ${failed}" - else - success="${profile} ${success}" - fi - done - exit 0 - fi -fi - - -pidfile=${mta_pidfile} -required_files="${mta_configfile}" - -# select correct command arguments -case "${mta_type}" in - - sendmail) - command_args="-C'${mta_configfile}' -OPidFile='${pidfile}'" - ;; - - exim) - command_args="-C '${mta_configfile}' -oP '${pidfile}'" - ;; - - *) - command_args="" - ;; -esac -run_rc_command "$1"