diff options
author | jlam <jlam> | 2007-08-10 17:57:03 +0000 |
---|---|---|
committer | jlam <jlam> | 2007-08-10 17:57:03 +0000 |
commit | 14faeaf9063ca7942d80db055db53f64fd8d8965 (patch) | |
tree | e9e9f6ebc45bf0e078a550f9c6b5236f2b1ef1ab /mail/courier-mta | |
parent | e903278f6d1503fb2774d7ef5d468bcf4b07893b (diff) | |
download | pkgsrc-14faeaf9063ca7942d80db055db53f64fd8d8965.tar.gz |
Update mail/courier-mta to 0.56.0. Changes from version 0.53.2 include:
+ Drop the uucp module from the default option set.
+ Patch the webmlm sources to not use "stdin" and "stdout" as function or
member names as they can be macros according to the C standards.
* webadmin: Remove check that prevents multiple virtual domains to
be aliased to the same account.
* webmlmd: new CGI module that can manage a Courier mailing list
created with couriermlm.
* Rewrite and code cleanup of couriermlm.
* Use domain name, not MX hostname, for looking up authenticated
SMTP passwords in esmtpauthclient
Diffstat (limited to 'mail/courier-mta')
31 files changed, 439 insertions, 172 deletions
diff --git a/mail/courier-mta/MESSAGE b/mail/courier-mta/MESSAGE index f84f4debf14..f4aff392b38 100644 --- a/mail/courier-mta/MESSAGE +++ b/mail/courier-mta/MESSAGE @@ -1,5 +1,5 @@ =========================================================================== -$NetBSD: MESSAGE,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +$NetBSD: MESSAGE,v 1.2 2007/08/10 17:57:03 jlam Exp $ It is recommended that Courier-MTA be installed together with Courier-IMAP and SqWebMail -- together, they form an integrated mail/groupware @@ -10,11 +10,11 @@ through a web CGI application. There are two things which must be done to make the Courier ``webadmin'' CGI application accessible through your HTTP server: - (1) Copy the ``courierwebadmin'' CGI binary to the appropriate place in - your HTTP document root, e.g. ${PREFIX}/libexec/cgi-bin, then - Courier webadmin would be accessible through: + (1) Copy the ``webadmin'' CGI binary to the appropriate place in + your HTTP document root, e.g. ${PREFIX}/libexec/cgi-bin. The + Courier webadmin would be accessible through, e.g.: - http://your.domain.com/cgi-bin/courierwebadmin + http://your.domain.com/cgi-bin/webadmin (2) Install a password to protect the ``webadmin'' CGI application by creating a one-line file containing the plaintext password at: @@ -24,4 +24,11 @@ CGI application accessible through your HTTP server: This file should be owned by ${COURIER_USER}:${COURIER_GROUP} with read-only permissions restricted to the owner (mode 0400). +Courier mailing lists may be managed through the ``webmlm'' CGI +application. Copy the ``webmlm'' CGI binary to the appropriate place +in your HTTP document root, e.g. ${PREFIX}/libexc/cgi-bin. The Courier +webmlm would be accessible through, e.g.: + + http://your.domain.com/cgi-bin/webmlm + =========================================================================== diff --git a/mail/courier-mta/Makefile b/mail/courier-mta/Makefile index c533307f158..07ec72580a3 100644 --- a/mail/courier-mta/Makefile +++ b/mail/courier-mta/Makefile @@ -1,7 +1,7 @@ -# $NetBSD: Makefile,v 1.9 2007/08/02 22:07:32 jlam Exp $ +# $NetBSD: Makefile,v 1.10 2007/08/10 17:57:03 jlam Exp $ DISTNAME= courier-${COURIER_VERSION} -PKGREVISION= 4 +PKGNAME= ${DISTNAME:S/-/-mta-/} CATEGORIES= mail MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=courier/} EXTRACT_SUFX= .tar.bz2 @@ -13,8 +13,8 @@ COMMENT= Courier mail transport agent HOMEPAGE= http://www.courier-mta.org/ DEPENDS+= courier-maildir>=${COURIER_VERSION}:../../mail/courier-maildir -DEPENDS+= couriertcpd>=${COURIER_VERSION}nb2:../../net/couriertcpd -DEPENDS+= maildrop>=2.0.2:../../mail/maildrop +DEPENDS+= couriertcpd>=${COURIER_VERSION}:../../net/couriertcpd +DEPENDS+= maildrop>=2.0.4:../../mail/maildrop USE_TOOLS+= gmake openssl:run perl:run USE_LANGUAGES= c c++ @@ -69,7 +69,8 @@ SUBST_STAGE.courier= pre-configure SUBST_CLASSES+= perms SUBST_FILES.perms= courier/perms.sh.in -SUBST_SED.perms+= -e "s,@ROOT_USER@,"${ROOT_USER:Q}",g" \ +SUBST_SED.perms+= -e "s,@REAL_ROOT_USER@,"${REAL_ROOT_USER:Q}",g" \ + -e "s,@ROOT_USER@,"${ROOT_USER:Q}",g" \ -e "s,@ROOT_GROUP@,"${ROOT_GROUP:Q}",g" SUBST_STAGE.perms= pre-configure @@ -87,14 +88,12 @@ post-extract: ${CP} ${FILESDIR}/mailer.conf ${WRKDIR}/mailer.conf post-build: - ${CAT} /dev/null > ${WRKDIR}/locallowercase - ${ECHO} ${PREFIX:Q}"/bin/maildrop" > ${WRKDIR}/maildropfilter + ${TOUCH} ${WRKDIR}/locallowercase post-install: - cd ${WRKSRC}/courier && \ - ${SETENV} ${MAKE_ENV} ${MAKE_PROGRAM} install-permissions + cd ${WRKSRC}/courier && \ + ${SETENV} ${MAKE_ENV} ${MAKE_PROGRAM} install-permissions ${INSTALL_DATA} ${WRKDIR}/mailer.conf ${EGDIR} ${INSTALL_DATA} ${WRKDIR}/locallowercase ${EGDIR}/locallowercase - ${INSTALL_DATA} ${WRKDIR}/maildropfilter ${EGDIR}/maildropfilter .include "../../mk/bsd.pkg.mk" diff --git a/mail/courier-mta/Makefile.common b/mail/courier-mta/Makefile.common index 47fe4dd2992..537de578aa2 100644 --- a/mail/courier-mta/Makefile.common +++ b/mail/courier-mta/Makefile.common @@ -1,6 +1,6 @@ -# $NetBSD: Makefile.common,v 1.5 2007/08/02 22:07:32 jlam Exp $ +# $NetBSD: Makefile.common,v 1.6 2007/08/10 17:57:03 jlam Exp $ -COURIER_VERSION= 0.53.2 +COURIER_VERSION= 0.56.0 .include "../../mk/bsd.prefs.mk" diff --git a/mail/courier-mta/PLIST b/mail/courier-mta/PLIST index ab4366c0980..95c99e9ae07 100644 --- a/mail/courier-mta/PLIST +++ b/mail/courier-mta/PLIST @@ -1,4 +1,4 @@ -@comment $NetBSD: PLIST,v 1.3 2006/06/09 22:12:18 jlam Exp $ +@comment $NetBSD: PLIST,v 1.4 2007/08/10 17:57:03 jlam Exp $ bin/cancelmsg bin/courier-config bin/couriermlm @@ -7,15 +7,18 @@ bin/mailq bin/rmail bin/sendmail bin/testmxlookup +bin/webmlmd +bin/webmlmd.rc libexec/courier/aliascombine libexec/courier/aliascreate libexec/courier/aliasexp -libexec/courier/cgi-bin/courierwebadmin libexec/courier/courierd libexec/courier/filters/dupfilter libexec/courier/filters/perlfilter libexec/courier/submit libexec/courier/submitmkdir +libexec/courier/webmail/webadmin +libexec/courier/webmail/webmlm man/man1/cancelmsg.1 man/man1/couriermlm.1 man/man1/dot-forward.1 @@ -43,7 +46,6 @@ man/man8/makepercentrelay.8 man/man8/makesmtpaccess-msa.8 man/man8/makesmtpaccess.8 man/man8/mkesmtpdcert.8 -man/man8/pop3d.8 man/man8/submit.8 sbin/aliaslookup sbin/courier @@ -51,8 +53,8 @@ sbin/courierfilter sbin/filterctl sbin/makealiases sbin/makehosteddomains -sbin/showconfig -sbin/showmodules +sbin/courier-showconfig +sbin/courier-showmodules share/courier/courierctl.start share/courier/couriermlm/adminrequest.tmpl share/courier/couriermlm/confsubj.tmpl @@ -65,16 +67,18 @@ share/courier/couriermlm/idxheaderhtml.tmpl share/courier/couriermlm/idxheadertxt.tmpl share/courier/couriermlm/idxsubject.tmpl share/courier/couriermlm/modrejbody.tmpl -share/courier/couriermlm/modreject.tmpl share/courier/couriermlm/modrejheader.tmpl share/courier/couriermlm/modsubject.tmpl share/courier/couriermlm/modtext.tmpl share/courier/couriermlm/modtext2.tmpl +share/courier/couriermlm/style.css.tmpl share/courier/couriermlm/sub.tmpl share/courier/couriermlm/sub2.tmpl share/courier/couriermlm/sub3.tmpl share/courier/couriermlm/sub4.tmpl share/courier/couriermlm/sub5.tmpl +share/courier/couriermlm/suback.tmpl +share/courier/couriermlm/subjrequest.tmpl share/courier/couriermlm/subreportfooter.tmpl share/courier/couriermlm/subreporthdr.tmpl share/courier/couriermlm/subreporthdr1.tmpl @@ -87,6 +91,21 @@ share/courier/couriermlm/warn1headers.tmpl share/courier/couriermlm/warn1text.tmpl share/courier/couriermlm/warn1text2.tmpl share/courier/couriermlm/warn2msg.tmpl +share/courier/couriermlm/webmlm.tmpl +share/courier/couriermlm/webmlm.tmpl.html +share/courier/couriermlm/webmlmconfirm.html +share/courier/couriermlm/webmlmerror.tmpl.html +share/courier/couriermlm/webmlmidx.html +share/courier/couriermlm/webmlmlistadmin.tmpl.html +share/courier/couriermlm/webmlmlistadminmod.tmpl.html +share/courier/couriermlm/webmlmlistadminpw.tmpl.html +share/courier/couriermlm/webmlmlistindex.tmpl.html +share/courier/couriermlm/webmlmnotprocessed.html +share/courier/couriermlm/webmlmpleasewait.tmpl.html +share/courier/couriermlm/webmlmprocessed.html +share/courier/couriermlm/webmlmrequestreceived.tmpl.html +share/courier/couriermlm/webmlmsubinfo.tmpl.html +share/courier/couriermlm/webmlmsublist.tmpl.html share/courier/courierwebadmin/admin-00machine.html share/courier/courierwebadmin/admin-00machine.pl share/courier/courierwebadmin/admin-05local.html @@ -154,7 +173,6 @@ share/doc/courier/cvs.html share/doc/courier/documentation.html share/doc/courier/dot-courier.html share/doc/courier/dot-forward.html -share/doc/courier/download.php share/doc/courier/draft-varshavchik-exdata-smtpext.txt share/doc/courier/draft-varshavchik-security-smtpext.txt share/doc/courier/draft-varshavchik-verp-smtpext.txt @@ -205,6 +223,7 @@ share/examples/courier/rfcerr2046.txt share/examples/courier/rfcerr2047.txt share/examples/courier/rfcerrheader.txt share/examples/courier/smtpaccess/default +share/examples/courier/webmlmrc.dist share/examples/rc.d/courier share/examples/rc.d/courierd share/examples/rc.d/courierfilter diff --git a/mail/courier-mta/distinfo b/mail/courier-mta/distinfo index 1d7f49e59ee..61c99b7c175 100644 --- a/mail/courier-mta/distinfo +++ b/mail/courier-mta/distinfo @@ -1,16 +1,20 @@ -$NetBSD: distinfo,v 1.2 2006/06/09 22:12:18 jlam Exp $ +$NetBSD: distinfo,v 1.3 2007/08/10 17:57:03 jlam Exp $ -SHA1 (courier-0.53.2.tar.bz2) = 89c6a9a57467adf8c1ac815a5ffacf47e5e694a3 -RMD160 (courier-0.53.2.tar.bz2) = a6efce3a8d6572923190ea49ed6085906317ebd8 -Size (courier-0.53.2.tar.bz2) = 6942557 bytes -SHA1 (patch-aa) = 13c353d22a0c14fb0f769658223795c1d4d8fcf4 -SHA1 (patch-ab) = d02d396512cec5be8e3cedceb36da0127461a533 -SHA1 (patch-ac) = e20e3af10138adf53628fcb08c1657386b93edd3 -SHA1 (patch-ad) = b0e88586d90e071ac135443634153131f548e05f -SHA1 (patch-ae) = 5a5d6b6aea3cca9d9f577d8da9ba463dd64e6902 -SHA1 (patch-af) = e17ce772bc92ec45507fed340d33856f71fbe3f6 -SHA1 (patch-ag) = 9044e5f36e9604d4d7b751bcc9042149080d61d2 -SHA1 (patch-ah) = 9f2001e1e309b2557640d8ecc9187ed793d0c5dd +SHA1 (courier-0.56.0.tar.bz2) = 536f24db9f33f8d93445c03dd4edb50c7ec2f6b2 +RMD160 (courier-0.56.0.tar.bz2) = ce8e2d99f5b7baf500d748c18fbd126df8331398 +Size (courier-0.56.0.tar.bz2) = 7022057 bytes +SHA1 (patch-aa) = 53b2fbf9414f3a853ec32006affdab66217ae85f +SHA1 (patch-ab) = 42aa037beab3b57a2e470f1587274ef797b2a770 +SHA1 (patch-ac) = d220279beaff057b74bdf9b50a0c99f21afd7f7b +SHA1 (patch-ad) = c0fcc00a60102782c315ac3e847b565adaa7b73d +SHA1 (patch-ae) = e52ab2f6a4e253dc4a28291db6744ea2593f2fc3 +SHA1 (patch-af) = 446b4db2e6e22461c243481bd5c39ffba68fd4b6 +SHA1 (patch-ah) = 78e0db8d5319d985d7e8aec4c1240561fead3a00 SHA1 (patch-ai) = 5324b99ebc0492c77f67a8c627ceb3c3efa9d852 -SHA1 (patch-aj) = 4b2901f200f6d68a8377a85f7c3962cf9851ca8f -SHA1 (patch-ak) = 8ba39a1ef912399e5f5fc224a43d36142780d09c +SHA1 (patch-aj) = 0ec994bfb79ca133555a3d300f8a264648591e1b +SHA1 (patch-al) = 8c37ddbb5e3c358ee0920adc27441e38b4efa143 +SHA1 (patch-am) = be7557ba7c4e282a40e8baee62f425a203ac26bb +SHA1 (patch-an) = 1afb599c8f5289dda9f060f0aa97f7e0ef49e776 +SHA1 (patch-ao) = c859c61370fbc4a774456b629fb3f05ee1a32621 +SHA1 (patch-ap) = 8696818dc2994f8dbe523034ed1c713101693291 +SHA1 (patch-aq) = 26b3c6ed014673af035f7d38e479e318fc447157 diff --git a/mail/courier-mta/files/courier.sh b/mail/courier-mta/files/courier.sh index 16a3f3db14c..816b94e4d89 100644 --- a/mail/courier-mta/files/courier.sh +++ b/mail/courier-mta/files/courier.sh @@ -1,6 +1,6 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courier.sh,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +# $NetBSD: courier.sh,v 1.2 2007/08/10 17:57:04 jlam Exp $ # # KEYWORD: nostart # @@ -42,7 +42,7 @@ reverse_commands() COMMAND_LIST= COMMAND_LIST="$COMMAND_LIST courierfilter" -COMMAND_LIST="$COMMAND_LIST courierldapaliasd" +COMMAND_LIST="$COMMAND_LIST @COURIERLDAPALIASD@" COMMAND_LIST="$COMMAND_LIST courierd" COMMAND_LIST="$COMMAND_LIST courieresmtp" COMMAND_LIST="$COMMAND_LIST courieresmtpmsa" @@ -52,6 +52,7 @@ COMMAND_LIST="$COMMAND_LIST courierimaps" COMMAND_LIST="$COMMAND_LIST courierpop" COMMAND_LIST="$COMMAND_LIST courierpops" COMMAND_LIST="$COMMAND_LIST sqwebmail" +COMMAND_LIST="$COMMAND_LIST webmlm" name="courier" start_cmd="forward_commands" diff --git a/mail/courier-mta/files/courierd.sh b/mail/courier-mta/files/courierd.sh index e94a71b8523..1823c0bb7e4 100644 --- a/mail/courier-mta/files/courierd.sh +++ b/mail/courier-mta/files/courierd.sh @@ -1,11 +1,11 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courierd.sh,v 1.3 2006/06/17 19:38:43 jlam Exp $ +# $NetBSD: courierd.sh,v 1.4 2007/08/10 17:57:04 jlam Exp $ # # Courier core processes # # PROVIDE: courierd -# REQUIRE: courierfilter courierldapaliasd +# REQUIRE: authdaemond courierfilter @COURIERLDAPALIASD@ # KEYWORD: shutdown . /etc/rc.subr @@ -15,12 +15,13 @@ rcvar=${name} command="@PREFIX@/sbin/${name}" ctl_command="@PREFIX@/sbin/courier" -restart_cmd="courierd_doit restart" -start_precmd="courierd_prestart" -start_cmd="courierd_doit start" -stop_cmd="courierd_doit stop" +restart_cmd="${name}_doit restart" +start_precmd="${name}_prestart" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" -mkdir_perms() { +mkdir_perms() +{ dir="$1"; user="$2"; group="$3"; mode="$4" @TEST@ -d $dir || @MKDIR@ $dir @CHOWN@ $user $dir @@ -28,7 +29,8 @@ mkdir_perms() { @CHMOD@ $mode $dir } -courierd_prestart() { +courierd_prestart() +{ # Courier mail submission directories mkdir_perms @COURIER_STATEDIR@/msgq \ @COURIER_USER@ @COURIER_GROUP@ 0750 diff --git a/mail/courier-mta/files/courieresmtp.sh b/mail/courier-mta/files/courieresmtp.sh index c1480540249..17aa7810b4f 100644 --- a/mail/courier-mta/files/courieresmtp.sh +++ b/mail/courier-mta/files/courieresmtp.sh @@ -1,6 +1,6 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courieresmtp.sh,v 1.2 2006/06/17 19:26:48 jlam Exp $ +# $NetBSD: courieresmtp.sh,v 1.3 2007/08/10 17:57:04 jlam Exp $ # # Courier ESMTP services daemon # @@ -17,8 +17,8 @@ ctl_command="@PREFIX@/sbin/esmtpd" pidfile="@VARBASE@/run/esmtp.pid" required_files="@PKG_SYSCONFDIR@/esmtpd @PKG_SYSCONFDIR@/esmtpd-ssl" -start_cmd="courieresmtp_doit start" -stop_cmd="courieresmtp_doit stop" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" courieresmtp_doit() { diff --git a/mail/courier-mta/files/courieresmtpmsa.sh b/mail/courier-mta/files/courieresmtpmsa.sh index 4f59dae201e..87081fc3b59 100644 --- a/mail/courier-mta/files/courieresmtpmsa.sh +++ b/mail/courier-mta/files/courieresmtpmsa.sh @@ -1,6 +1,6 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courieresmtpmsa.sh,v 1.2 2006/06/17 19:26:48 jlam Exp $ +# $NetBSD: courieresmtpmsa.sh,v 1.3 2007/08/10 17:57:04 jlam Exp $ # # Courier ESMTP-MSA (RFC 2476) services daemon # @@ -17,8 +17,8 @@ ctl_command="@PREFIX@/sbin/esmtpd-msa" pidfile="@VARBASE@/run/esmtpd-msa.pid" required_files="@PKG_SYSCONFDIR@/esmtpd @PKG_SYSCONFDIR@/esmtpd-msa" -start_cmd="courieresmtpmsa_doit start" -stop_cmd="courieresmtpmsa_doit stop" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" courieresmtpmsa_doit() { diff --git a/mail/courier-mta/files/courieresmtps.sh b/mail/courier-mta/files/courieresmtps.sh index d3d20e8f3f6..a0138b2a578 100644 --- a/mail/courier-mta/files/courieresmtps.sh +++ b/mail/courier-mta/files/courieresmtps.sh @@ -1,6 +1,6 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courieresmtps.sh,v 1.2 2006/06/17 19:26:48 jlam Exp $ +# $NetBSD: courieresmtps.sh,v 1.3 2007/08/10 17:57:04 jlam Exp $ # # Courier ESMTP/SSL services daemon # @@ -17,8 +17,8 @@ ctl_command="@PREFIX@/sbin/esmtpd-ssl" pidfile="@VARBASE@/run/esmtpd-ssl.pid" required_files="@PKG_SYSCONFDIR@/esmtpd @PKG_SYSCONFDIR@/esmtpd-ssl" -start_cmd="courieresmtps_doit start" -stop_cmd="courieresmtps_doit stop" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" courieresmtps_doit() { diff --git a/mail/courier-mta/files/courierfilter.sh b/mail/courier-mta/files/courierfilter.sh index 9e351792d87..17999d549f3 100644 --- a/mail/courier-mta/files/courierfilter.sh +++ b/mail/courier-mta/files/courierfilter.sh @@ -1,6 +1,6 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courierfilter.sh,v 1.3 2006/06/17 19:38:43 jlam Exp $ +# $NetBSD: courierfilter.sh,v 1.4 2007/08/10 17:57:04 jlam Exp $ # # Courier mail filter daemon # @@ -15,12 +15,13 @@ rcvar=${name} command="@PREFIX@/sbin/${name}" pidfile="@VARBASE@/run/${name}.pid" -restart_cmd="courierfilter_doit restart" -start_precmd="courierfilter_prestart" -start_cmd="courierfilter_doit start" -stop_cmd="courierfilter_doit stop" +restart_cmd="${name}_doit restart" +start_precmd="${name}_prestart" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" -mkdir_perms() { +mkdir_perms() +{ dir="$1"; user="$2"; group="$3"; mode="$4" @TEST@ -d $dir || @MKDIR@ $dir @CHOWN@ $user $dir @@ -28,7 +29,8 @@ mkdir_perms() { @CHMOD@ $mode $dir } -courierfilter_prestart() { +courierfilter_prestart() +{ # Courier filter directories mkdir_perms @COURIER_STATEDIR@/allfilters \ @COURIER_USER@ @COURIER_GROUP@ 0750 diff --git a/mail/courier-mta/files/courierldapaliasd.sh b/mail/courier-mta/files/courierldapaliasd.sh index 12c1e339d3f..9bcfbe699bb 100644 --- a/mail/courier-mta/files/courierldapaliasd.sh +++ b/mail/courier-mta/files/courierldapaliasd.sh @@ -1,6 +1,6 @@ #!@RCD_SCRIPTS_SHELL@ # -# $NetBSD: courierldapaliasd.sh,v 1.3 2006/06/17 19:38:43 jlam Exp $ +# $NetBSD: courierldapaliasd.sh,v 1.4 2007/08/10 17:57:04 jlam Exp $ # # Courier LDAP mail aliasing daemon # @@ -16,12 +16,13 @@ command="@PREFIX@/sbin/${name}" pidfile="@COURIER_STATEDIR@/tmp/ldapaliasd.pid" required_files="@PKG_SYSCONFDIR@/ldapaliasrc" -restart_cmd="courierldapaliasd_doit restart" -start_precmd="courierldapaliasd_prestart" -start_cmd="courierldapaliasd_doit start" -stop_cmd="courierldapaliasd_doit stop" +restart_cmd="${name}_doit restart" +start_precmd="${name}_prestart" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" -mkdir_perms() { +mkdir_perms() +{ dir="$1"; user="$2"; group="$3"; mode="$4" @TEST@ -d $dir || @MKDIR@ $dir @CHOWN@ $user $dir diff --git a/mail/courier-mta/files/webmlm.sh b/mail/courier-mta/files/webmlm.sh new file mode 100644 index 00000000000..fb9d664ffbd --- /dev/null +++ b/mail/courier-mta/files/webmlm.sh @@ -0,0 +1,67 @@ +#!@RCD_SCRIPTS_SHELL@ +# +# $NetBSD: webmlm.sh,v 1.1 2007/08/10 17:57:04 jlam Exp $ +# +# Courier mailing list management daemon +# +# PROVIDE: webmlm +# REQUIRE: DAEMON +# KEYWORD: shutdown + +. /etc/rc.subr + +name="webmlm" +rcvar=${name} +command="@PREFIX@/sbin/courierlogger" +ctl_command="@PREFIX@/bin/webmlmd.rc" +pidfile="@COURIER_STATEDIR@/webmlm.pid" +required_files="@PKG_SYSCONFDIR@/webmlmrc" + +restart_cmd="${name}_doit restart" +start_precmd="${name}_prestart" +start_cmd="${name}_doit start" +stop_cmd="${name}_doit stop" + +mkdir_perms() +{ + dir="$1"; user="$2"; group="$3"; mode="$4" + @TEST@ -d $dir || @MKDIR@ $dir + @CHOWN@ $user $dir + @CHGRP@ $group $dir + @CHMOD@ $mode $dir +} + +webmlmd_prestart() +{ + @MKDIR@ @COURIER_STATEDIR@ + mkdir_perms @COURIER_STATEDIR@/webmlm \ + @COURIER_USER@ @COURIER_GROUP@ 0755 +} + +webmlm_doit() +{ + action=$1 + + case $action in + restart|start) + for f in $required_files; do + if [ ! -r "$f" ]; then + @ECHO@ 1>&2 "$0: WARNING: $f is not readable" + return 1 + fi + done + case $action in + restart) @ECHO@ "Restarting ${name}." ;; + start) @ECHO@ "Starting ${name}." ;; + esac + ;; + stop) + @ECHO@ "Stopping ${name}." + ;; + esac + + ${ctl_command} @PREFIX@/bin/webmlmd $action +} + +load_rc_config $name +run_rc_command "$1" diff --git a/mail/courier-mta/options.mk b/mail/courier-mta/options.mk index 0e271ec1c3a..231c4c44af6 100644 --- a/mail/courier-mta/options.mk +++ b/mail/courier-mta/options.mk @@ -1,12 +1,11 @@ -# $NetBSD: options.mk,v 1.5 2007/07/04 20:54:41 jlam Exp $ +# $NetBSD: options.mk,v 1.6 2007/08/10 17:57:03 jlam Exp $ # Global and legacy options PKG_OPTIONS_VAR= PKG_OPTIONS.courier-mta PKG_SUPPORTED_OPTIONS= courier-dsn courier-esmtp courier-local \ courier-uucp ldap -PKG_SUGGESTED_OPTIONS= courier-dsn courier-esmtp courier-local \ - courier-uucp +PKG_SUGGESTED_OPTIONS= courier-dsn courier-esmtp courier-local .include "../../mk/bsd.options.mk" @@ -120,11 +119,13 @@ PKG_FAIL_REASON+= "[courier/options.mk] No mail transports specified." . include "../../databases/openldap-client/buildlink3.mk" CONFIGURE_ARGS+= --with-ldapaliasd PLIST_SRC+= ${PKGDIR}/PLIST.ldap +FILES_SUBST+= COURIERLDAPALIASD=courierldapaliasd RCD_SCRIPTS+= courierldapaliasd CONF_FILES_PERMS+= ${EGDIR}/ldapaliasrc.dist \ ${PKG_SYSCONFDIR}/ldapaliasrc \ ${COURIER_USER} ${COURIER_GROUP} 0640 .else +FILES_SUBST+= COURIERLDAPALIASD= CONFIGURE_ARGS+= --without-ldapaliasd .endif diff --git a/mail/courier-mta/patches/patch-aa b/mail/courier-mta/patches/patch-aa index 4e1245c71f3..e0fd0a5979d 100644 --- a/mail/courier-mta/patches/patch-aa +++ b/mail/courier-mta/patches/patch-aa @@ -1,53 +1,62 @@ -$NetBSD: patch-aa,v 1.2 2006/06/09 22:12:18 jlam Exp $ +$NetBSD: patch-aa,v 1.3 2007/08/10 17:57:04 jlam Exp $ ---- courier/Makefile.in.orig 2006-06-09 14:58:20.000000000 -0400 +--- courier/Makefile.in.orig 2007-06-23 07:56:06.000000000 -0400 +++ courier/Makefile.in -@@ -52,17 +52,17 @@ build_triplet = @build@ +@@ -50,18 +50,18 @@ build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ pkglibexec_PROGRAMS = aliasexp$(EXEEXT) aliascombine$(EXEEXT) \ - aliascreate$(EXEEXT) sqwebmaild$(EXEEXT) submit$(EXEEXT) \ -- @EXTRAPKGLIB@ $(am__empty) --webmail_PROGRAMS = webmail$(EXEEXT) + aliascreate$(EXEEXT) submit$(EXEEXT) \ -+ $(am__empty) -+webmail_PROGRAMS = + @EXTRAPKGLIB@ $(am__empty) +-webmail_PROGRAMS = webmail$(EXEEXT) webmlm$(EXEEXT) ++webmail_PROGRAMS = webmlm$(EXEEXT) EXTRA_PROGRAMS = courierldapaliasd$(EXEEXT) bin_PROGRAMS = cancelmsg$(EXEEXT) mailq$(EXEEXT) sendmail$(EXEEXT) \ testmxlookup$(EXEEXT) dotforward$(EXEEXT) couriermlm$(EXEEXT) \ -- courier-config$(EXEEXT) @couriertls@ @EXTRABIN@ -+ courier-config$(EXEEXT) - sbin_PROGRAMS = courier$(EXEEXT) showconfig$(EXEEXT) \ - showmodules$(EXEEXT) aliaslookup$(EXEEXT) @COURIERLDAPALIASD@ \ -- @EXTRASBIN@ $(am__empty) +- webmlmd$(EXEEXT) courier-config$(EXEEXT) @couriertls@ \ ++ webmlmd$(EXEEXT) courier-config$(EXEEXT) \ + @EXTRABIN@ $(am__empty) +-sbin_PROGRAMS = courier$(EXEEXT) showconfig$(EXEEXT) \ +- showmodules$(EXEEXT) aliaslookup$(EXEEXT) @COURIERLDAPALIASD@ \ ++sbin_PROGRAMS = courier$(EXEEXT) courier-showconfig$(EXEEXT) \ ++ courier-showmodules$(EXEEXT) aliaslookup$(EXEEXT) @COURIERLDAPALIASD@ \ + @EXTRASBIN@ $(am__empty) -cmdlib_PROGRAMS = submitmkdir$(EXEEXT) courierd$(EXEEXT) @EXTRACMDLIB@ -+ $(am__empty) -+cmdlib_PROGRAMS = submitmkdir$(EXEEXT) courierd$(EXEEXT) ++cmdlib_PROGRAMS = submitmkdir$(EXEEXT) courierd$(EXEEXT) @EXTRACMDLIB@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(srcdir)/courier.h.in $(srcdir)/courierctl.start.in \ -@@ -402,7 +402,7 @@ RFCERRTXTIN = rfcerrheader.txt +@@ -420,7 +420,7 @@ BUILT_SOURCES = prefix.h exec_prefix.h s + uidgid.h configargs.h sort.h webmlmdhandlerslist.H + RFCERRTXTIN = rfcerrheader.txt RFCERRTXTNOIN = rfcerr2045.txt rfcerr2046.txt rfcerr2047.txt - extrapkglib = makedatprog courierpop3login pcpd +-extrapkglib = makedatprog courierpop3login pcpd ++extrapkglib = pkglibexecdir = $(libexecdir)/courier --webmaildir = $(libexecdir)/courier/webmail -+webmaildir = $(pkglibexecdir)/cgi-bin + webmaildir = $(libexecdir)/courier/webmail webmail_SOURCES = - sqwebmaild_SOURCES = +@@ -428,22 +428,19 @@ sqwebmaild_SOURCES = -@@ -413,16 +413,14 @@ extrabin = maildrop lockmail reformail r + # Don't forget to change perms.sh.in, if webmailimagedir moves. + webmailimagedir = $(datadir)/sqwebmail/images +-extrabin = maildrop lockmail reformail reformime mailbot mimegpg \ +- imapd makemime deliverquota maildirmake maildiracl maildirkw ++extrabin = - extrasbin = couriertcpd$(EXEEXT) - sbinscripts = sharedindexsplit sharedindexinstall webmaild --sbin_SCRIPTS = @SBINSCRIPTS@ -+sbin_SCRIPTS = + bin_SCRIPTS = webmlmd.rc +-extrasbin = couriertcpd$(EXEEXT) +-sbinscripts = sharedindexsplit sharedindexinstall webmaild ++extrasbin = ++sbinscripts = + sbin_SCRIPTS = @SBINSCRIPTS@ EXTRA_SCRIPTS = -sysconf_DATA = pop3d.authpam imapd.authpam webmail.authpam imapd.cnf pop3d.cnf \ +sysconf_DATA = \ courierd.dist @LDAPALIASRC@ \ - imapd.dist imapd-ssl.dist pop3d.dist pop3d-ssl.dist \ -- quotawarnmsg.example $(RFCERRTXTNOIN) $(RFCERRTXTIN) -+ $(RFCERRTXTNOIN) $(RFCERRTXTIN) +- quotawarnmsg.example $(RFCERRTXTNOIN) $(RFCERRTXTIN) webmlmrc.dist ++ $(RFCERRTXTNOIN) $(RFCERRTXTIN) webmlmrc.dist databindir = $(datadir) -databin_SCRIPTS = courierctl.start makedat makealiases makehosteddomains \ @@ -55,8 +64,30 @@ $NetBSD: patch-aa,v 1.2 2006/06/09 22:12:18 jlam Exp $ +databin_SCRIPTS = courierctl.start makealiases makehosteddomains mlmdatadir = $(datadir)/couriermlm - mlmdata_DATA = adminrequest.tmpl confsubj.tmpl digestsubj.tmpl fetch.tmpl \ -@@ -1673,27 +1671,10 @@ install-exec-hook: + mlmdata_DATA = \ +@@ -499,7 +496,7 @@ mlmdata_DATA = \ + webmlmsublist.tmpl.html \ + webmlm.tmpl.html + +-extracmdlib = courierpop3d imaplogin ++extracmdlib = + cmdlibdir = @libexecdir@/courier + + # Subdirectories +@@ -1652,6 +1649,12 @@ couriertls$(EXEEXT): ../tcpd/couriertls$ + courierpop3login$(EXEEXT): ../imap/pop3login$(EXEEXT) + cp -f ../imap/pop3login$(EXEEXT) courierpop3login$(EXEEXT) + ++courier-showconfig$(EXEEXT): showconfig$(EXEEXT) ++ cp -f showconfig$(EXEEXT) courier-showconfig$(EXEEXT) ++ ++courier-showmodules$(EXEEXT): showmodules$(EXEEXT) ++ cp -f showmodules$(EXEEXT) courier-showmodules$(EXEEXT) ++ + sort.h: + echo '#define SORT "$(SORT)"' >sort.h + +@@ -1813,33 +1816,16 @@ install-exec-hook: $(localstatedir)/track\ $(localstatedir)/msgs $(localstatedir)/msgq ; do \ $(mkinstalldirs) $(DESTDIR)$$d || :; done @@ -77,16 +108,22 @@ $NetBSD: patch-aa,v 1.2 2006/06/09 22:12:18 jlam Exp $ ; do rm -f $(DESTDIR)$(sbindir)/$$f ; \ $(LN_S) $(datadir)/$$f $(DESTDIR)$(sbindir)/$$f ; done - rm -f $(DESTDIR)$(sbindir)/webgpg ; $(LN_S) $(datadir)/sqwebmail/webgpg $(DESTDIR)$(sbindir)/webgpg -- $(INSTALL_PROGRAM) ../webadmin/webadmin $(DESTDIR)$(webmaildir)/webadmin + $(INSTALL_PROGRAM) ../webadmin/webadmin $(DESTDIR)$(webmaildir)/webadmin - mkdir -p $(DESTDIR)$(sysconfdir)/shared - chmod 755 $(DESTDIR)$(sysconfdir)/shared - mkdir -p $(DESTDIR)$(sysconfdir)/shared.tmp - chmod 755 $(DESTDIR)$(sysconfdir)/shared.tmp -+ $(INSTALL_PROGRAM) ../webadmin/webadmin $(DESTDIR)$(webmaildir)/courierwebadmin install-data-hook: -$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/aliases -@@ -1711,10 +1692,6 @@ install-data-hook: + -$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/smtpaccess +- -$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/aliasdir + echo @MAILDROP@ >$(DESTDIR)$(sysconfdir)/maildrop ++ echo @MAILDROP@ >$(DESTDIR)$(sysconfdir)/maildropfilter + test -f $(DESTDIR)$(sysconfdir)/enablefiltering && exit 0; \ + echo esmtp >$(DESTDIR)$(sysconfdir)/enablefiltering + test -f $(DESTDIR)$(sysconfdir)/aliases/system && exit 0; \ +@@ -1851,10 +1837,6 @@ install-data-hook: rm -f $(DESTDIR)$(bindir)/rmail $(LN_S) sendmail $(DESTDIR)$(bindir)/rmail -$(mkinstalldirs) $(DESTDIR)@mandir@/man8 diff --git a/mail/courier-mta/patches/patch-ab b/mail/courier-mta/patches/patch-ab index 82e2eb8d810..6d9b235f678 100644 --- a/mail/courier-mta/patches/patch-ab +++ b/mail/courier-mta/patches/patch-ab @@ -1,8 +1,8 @@ -$NetBSD: patch-ab,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +$NetBSD: patch-ab,v 1.2 2007/08/10 17:57:04 jlam Exp $ ---- courier/configure.orig 2006-02-25 12:28:52.000000000 -0500 +--- courier/configure.orig 2007-06-23 07:56:05.000000000 -0400 +++ courier/configure -@@ -22684,9 +22684,9 @@ done +@@ -21745,9 +21745,9 @@ done if test "$testmode" = "0" then diff --git a/mail/courier-mta/patches/patch-ac b/mail/courier-mta/patches/patch-ac index e8f2bf1e50e..26d8a4e9220 100644 --- a/mail/courier-mta/patches/patch-ac +++ b/mail/courier-mta/patches/patch-ac @@ -1,17 +1,17 @@ -$NetBSD: patch-ac,v 1.2 2006/06/09 22:12:18 jlam Exp $ +$NetBSD: patch-ac,v 1.3 2007/08/10 17:57:04 jlam Exp $ ---- courier/doc/Makefile.in.orig 2006-04-12 19:26:24.000000000 -0400 +--- courier/doc/Makefile.in.orig 2007-05-12 23:03:54.000000000 -0400 +++ courier/doc/Makefile.in @@ -141,7 +141,7 @@ target_alias = @target_alias@ version = @version@ htmldocdir = @datadir@/htmldoc CLEANFILES = permissions.dat --miscfiles = japanese_flag.png bg.gif icon.gif manpage.css \ -+miscfiles = japanese_flag.png bg.gif icon.gif \ +-miscfiles = japanese_flag.png chinese_flag.png bg.gif icon.gif manpage.css \ ++miscfiles = japanese_flag.png chinese_flag.png bg.gif icon.gif \ draft-varshavchik-exdata-smtpext.txt \ draft-varshavchik-verp-smtpext.txt \ draft-varshavchik-security-smtpext.txt \ -@@ -179,65 +179,37 @@ htmlin = \ +@@ -179,66 +179,39 @@ htmlin = \ courier.html \ courierldapaliasd.html \ couriermlm.html \ @@ -56,13 +56,14 @@ $NetBSD: patch-ac,v 1.2 2006/06/09 22:12:18 jlam Exp $ - reformime.html \ sendmail.html \ submit.html \ - testmxlookup.html + testmxlookup.html \ + webmlmd.html htmldoc_DATA = $(nohtmlin) $(htmlin) -man1 = sendmail.1 preline.1 maildirmake.1 cancelmsg.1 lockmail.1 maildrop.1 \ - mailq.1 mailbot.1 makemime.1 mimegpg.1 maildiracl.1 \ - makedat.1 reformail.1 reformime.1 couriermlm.1 testmxlookup.1 \ -- dot-forward.1 couriertls.1 couriertcpd.1 maildirkw.1 +- dot-forward.1 couriertls.1 couriertcpd.1 maildirkw.1 webmlmd.1 - -man5 = dot-courier.5 maildir.5 -man7 = localmailfilter.7 maildirquota.7 maildropgdbm.7 maildropfilter.7 \ @@ -70,25 +71,25 @@ $NetBSD: patch-ac,v 1.2 2006/06/09 22:12:18 jlam Exp $ +man1 = sendmail.1 preline.1 cancelmsg.1 \ + mailq.1 \ + couriermlm.1 testmxlookup.1 \ -+ dot-forward.1 ++ dot-forward.1 webmlmd.1 -man8 = aliaslookup.8 courier.8 courierldapaliasd.8 courierpop3d.8 \ -- deliverquota.8 \ +man5 = dot-courier.5 +man7 = localmailfilter.7 + +man8 = aliaslookup.8 courier.8 courierldapaliasd.8 \ + deliverquota.8 \ esmtpd.8 makeacceptmailfor.8 makehosteddomains.8\ - mkesmtpdcert.8 mkimapdcert.8 mkpop3dcert.8 \ + mkesmtpdcert.8 \ makealiases.8 makepercentrelay.8 makesmtpaccess.8 \ - pop3d.8 submit.8 imapd.8 -+ pop3d.8 submit.8 ++ submit.8 BUILT_SOURCES = \ aliaslookup.html aliaslookup.8 \ -@@ -263,7 +235,7 @@ BUILT_SOURCES = \ - testmxlookup.html testmxlookup.1 +@@ -265,7 +238,7 @@ BUILT_SOURCES = \ + webmlmd.html.in webmlmd.1.in EXTRA_DIST = $(nohtmlin) $(BUILT_SOURCES) -man_LINKS = $(man8dir)/courierpop3login.8 \ @@ -96,7 +97,7 @@ $NetBSD: patch-ac,v 1.2 2006/06/09 22:12:18 jlam Exp $ $(man1dir)/rmail.1 $(man1dir)/dotforward.1 \ $(man8dir)/makesmtpaccess-msa.8 \ $(man8dir)/esmtpd-msa.8 -@@ -1125,8 +1097,7 @@ preline.1: preline.1.in +@@ -1139,8 +1112,7 @@ preline.1: preline.1.in install-man-extra: cd $(DESTDIR)$(man8dir) ; \ diff --git a/mail/courier-mta/patches/patch-ad b/mail/courier-mta/patches/patch-ad index d8fcaea4963..b60bae8843b 100644 --- a/mail/courier-mta/patches/patch-ad +++ b/mail/courier-mta/patches/patch-ad @@ -1,13 +1,18 @@ -$NetBSD: patch-ad,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +$NetBSD: patch-ad,v 1.2 2007/08/10 17:57:04 jlam Exp $ ---- courier/filters/Makefile.in.orig 2006-01-29 12:33:24.000000000 -0500 +--- courier/filters/Makefile.in.orig 2007-02-25 23:21:06.000000000 -0500 +++ courier/filters/Makefile.in -@@ -234,7 +234,7 @@ htmldocdir = @datadir@/htmldoc +@@ -229,11 +229,12 @@ SUBDIRS = libfilter perlfilter + CLEANFILES = $(htmldoc_DATA) $(man_MANS) filtersocketdir.h filteractivedir.h \ + pidfile.h permissions.dat + ++pkglibexecdir = $(libexecdir)/courier + htmldocdir = @datadir@/htmldoc htmldoc_DATA = courierfilter.html courierperlfilter.html dupfilter.html databindir = $(datadir) databin_SCRIPTS = filterctl -filterbindir = $(libexecdir)/filters -+filterbindir = $(libexecdir)/courier/filters ++filterbindir = $(pkglibexecdir)/filters filtersocketdir = $(localstatedir)/filters allfiltersocketdir = $(localstatedir)/allfilters filterconfdir = $(sysconfdir)/filters diff --git a/mail/courier-mta/patches/patch-ae b/mail/courier-mta/patches/patch-ae index ea6fdda4c19..dc23360bec4 100644 --- a/mail/courier-mta/patches/patch-ae +++ b/mail/courier-mta/patches/patch-ae @@ -1,13 +1,15 @@ -$NetBSD: patch-ae,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +$NetBSD: patch-ae,v 1.2 2007/08/10 17:57:04 jlam Exp $ --- courier/filters/filterctl.in.orig 2004-01-31 23:46:27.000000000 -0500 +++ courier/filters/filterctl.in -@@ -12,7 +12,7 @@ sysconfdir="@sysconfdir@" +@@ -11,8 +11,9 @@ libexecdir="@libexecdir@" + sysconfdir="@sysconfdir@" localstatedir="@localstatedir@" piddir="@piddir@" ++pkglibexecdir="@libexecdir@/courier" -filterbindir="${libexecdir}/filters" -+filterbindir="${libexecdir}/courier/filters" ++filterbindir="${pkglibexecdir}/filters" filteractivedir="${sysconfdir}/filters/active" pidfile="${piddir}/courierfilter.pid" diff --git a/mail/courier-mta/patches/patch-af b/mail/courier-mta/patches/patch-af index 295e5ba4117..f4ee1268a0c 100644 --- a/mail/courier-mta/patches/patch-af +++ b/mail/courier-mta/patches/patch-af @@ -1,13 +1,14 @@ -$NetBSD: patch-af,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +$NetBSD: patch-af,v 1.2 2007/08/10 17:57:05 jlam Exp $ ---- courier/filters/perlfilter/Makefile.in.orig 2006-02-05 19:35:20.000000000 -0500 +--- courier/filters/perlfilter/Makefile.in.orig 2007-02-25 23:21:34.000000000 -0500 +++ courier/filters/perlfilter/Makefile.in -@@ -206,7 +206,7 @@ target_alias = @target_alias@ +@@ -205,7 +205,8 @@ target_alias = @target_alias@ EXTRA_DIST = perlfilter-wrapper.pl perlfilter-example.pl BUILT_SOURCES = filtersocketdir.h wrapperpl.h xsinit.c CLEANFILES = $(BUILT_SOURCES) permissions.dat -filterbindir = $(libexecdir)/filters -+filterbindir = $(libexecdir)/courier/filters ++pkglibexecdir = $(libexecdir)/courier ++filterbindir = $(pkglibexecdir)/filters scriptdir = $(datadir) script_SCRIPTS = perlfilter-wrapper.pl perlfilter-example.pl filtersocketdir = $(localstatedir)/filters diff --git a/mail/courier-mta/patches/patch-ag b/mail/courier-mta/patches/patch-ag deleted file mode 100644 index fcd352e70fb..00000000000 --- a/mail/courier-mta/patches/patch-ag +++ /dev/null @@ -1,12 +0,0 @@ -$NetBSD: patch-ag,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ - ---- courier/module.esmtp/mkesmtpdcert.in.orig 2000-09-18 13:24:01.000000000 -0400 -+++ courier/module.esmtp/mkesmtpdcert.in -@@ -17,6 +17,7 @@ then - exit 1 - fi - -+umask 077 - cp /dev/null @datadir@/esmtpd.pem - chmod 600 @datadir@/esmtpd.pem - chown @mailuser@ @datadir@/esmtpd.pem diff --git a/mail/courier-mta/patches/patch-ah b/mail/courier-mta/patches/patch-ah index 3b674239007..c09df25f681 100644 --- a/mail/courier-mta/patches/patch-ah +++ b/mail/courier-mta/patches/patch-ah @@ -1,8 +1,8 @@ -$NetBSD: patch-ah,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ +$NetBSD: patch-ah,v 1.2 2007/08/10 17:57:05 jlam Exp $ ---- courier/module.local/deliver.c.orig 2005-02-03 21:44:59.000000000 -0500 +--- courier/module.local/deliver.c.orig 2006-05-28 11:29:52.000000000 -0400 +++ courier/module.local/deliver.c -@@ -633,7 +633,7 @@ static int docommand(const char *extensi +@@ -635,7 +635,7 @@ static int docommand(const char *extensi const char *defaultmail, int recursion_level) { @@ -11,7 +11,7 @@ $NetBSD: patch-ah,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ const char *p; const char *hostp; pid_t pid; -@@ -725,7 +725,9 @@ const char *shell=getenv("SHELL"); +@@ -727,7 +727,9 @@ const char *shell=getenv("SHELL"); envs[17]=courier_malloc(strlen(shell) +sizeof("SHELL=")); strcat(strcpy(envs[17], "SHELL="), shell); diff --git a/mail/courier-mta/patches/patch-aj b/mail/courier-mta/patches/patch-aj index 1bd9627cab6..89bfbc3f550 100644 --- a/mail/courier-mta/patches/patch-aj +++ b/mail/courier-mta/patches/patch-aj @@ -1,8 +1,8 @@ -$NetBSD: patch-aj,v 1.2 2006/06/09 22:12:18 jlam Exp $ +$NetBSD: patch-aj,v 1.3 2007/08/10 17:57:05 jlam Exp $ ---- courier/perms.sh.in.orig 2006-04-12 20:21:48.000000000 -0400 +--- courier/perms.sh.in.orig 2007-06-15 22:21:24.000000000 -0400 +++ courier/perms.sh.in -@@ -10,115 +10,45 @@ prefix="@prefix@" +@@ -10,119 +10,47 @@ prefix="@prefix@" exec_prefix="@exec_prefix@" PERMS=" @@ -35,6 +35,7 @@ $NetBSD: patch-aj,v 1.2 2006/06/09 22:12:18 jlam Exp $ -@sysconfdir@/imapd.cnf 600 config -@sysconfdir@/sqwebmaild.dist 644 config -@sysconfdir@/webmail.authpam 644 config +-@sysconfdir@/webmlmrc.dist 644 config -@sysconfdir@/quotawarnmsg.example 444 -@sysconfdir@/rfcerrheader.txt 444 config -@sysconfdir@/rfcerr2045.txt 444 config @@ -57,11 +58,10 @@ $NetBSD: patch-aj,v 1.2 2006/06/09 22:12:18 jlam Exp $ -@libexecdir@/courier/pcpd 555 x bin bin -@libexecdir@/courier/webmail 700 x root bin -@libexecdir@/courier/webmail/webmail 555 x root bin + @libexecdir@/courier/webmail/webmlm 555 x root bin -@libexecdir@/courier/sqwebmaild 555 -@libexecdir@/courier/sqwebpasswd 2755 --@libexecdir@/courier/webmail/webadmin 4555 x root bin -+@libexecdir@/courier/cgi-bin 700 x root bin -+@libexecdir@/courier/cgi-bin/courierwebadmin 4555 x root bin + @libexecdir@/courier/webmail/webadmin 4555 x root bin -@sbindir@ 755 x bin bin @sbindir@/courier 555 @@ -95,6 +95,8 @@ $NetBSD: patch-aj,v 1.2 2006/06/09 22:12:18 jlam Exp $ -@bindir@/mimegpg 555 @bindir@/couriermlm 555 @bindir@/dotforward 555 + @bindir@/webmlmd 555 + @bindir@/webmlmd.rc 555 -@datadir@/makedat 555 x bin bin -@bindir@/makedat 555 @@ -120,13 +122,13 @@ $NetBSD: patch-aj,v 1.2 2006/06/09 22:12:18 jlam Exp $ @datadir@/couriermlm 755 @datadir@/couriermlm/adminrequest.tmpl 644 -@@ -168,11 +98,20 @@ do +@@ -190,11 +118,20 @@ do if test "$USER" = "" then USER="@mailuser@" + elif test "$USER" = "root" + then -+ USER="@ROOT_USER@" ++ USER="@REAL_ROOT_USER@" + elif test "$USER" = "bin" + then + USER="@ROOT_USER@" @@ -141,7 +143,7 @@ $NetBSD: patch-aj,v 1.2 2006/06/09 22:12:18 jlam Exp $ fi case $FILE in -@@ -193,26 +132,7 @@ do +@@ -215,26 +152,7 @@ do echo $FILE $MODE $USER $GROUP $SPECIAL done diff --git a/mail/courier-mta/patches/patch-ak b/mail/courier-mta/patches/patch-ak deleted file mode 100644 index 3d1525e5292..00000000000 --- a/mail/courier-mta/patches/patch-ak +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ak,v 1.1.1.1 2006/04/28 18:10:21 jlam Exp $ - ---- courier/webadmin/admin-47webmail.pl.orig 2005-02-15 21:43:31.000000000 -0500 -+++ courier/webadmin/admin-47webmail.pl -@@ -123,7 +123,7 @@ if ($cgi->param("submit")) - { - DeleteConfigFile("calendarmode"); - } -- changed("test -x ${libexecdir}/courier/pcpd || exit 0; ${sbindir}/webmaild stop; ${sbindir}/webmaild start"); -+ changed("test -x ${libexecdir}/courier/pcpd || exit 0; ${sbindir}/sqwebmaild stop; ${sbindir}/sqwebmaild start"); - $errmsg="\@SAVED\@"; - } - diff --git a/mail/courier-mta/patches/patch-al b/mail/courier-mta/patches/patch-al new file mode 100644 index 00000000000..d77d4d8f40d --- /dev/null +++ b/mail/courier-mta/patches/patch-al @@ -0,0 +1,13 @@ +$NetBSD: patch-al,v 1.1 2007/08/10 17:57:05 jlam Exp $ + +--- courier/courier.c.orig 2006-05-27 00:52:51.000000000 -0400 ++++ courier/courier.c +@@ -197,7 +197,7 @@ int main(int argc, char **argv) + #endif + execl( DATADIR "/courierctl.start", + "courierctl.start", (char *)0); +- perror("exec"); ++ perror("exec: " DATADIR "/courierctl.start"); + _exit(1); + } + _exit(0); diff --git a/mail/courier-mta/patches/patch-am b/mail/courier-mta/patches/patch-am new file mode 100644 index 00000000000..947a232351f --- /dev/null +++ b/mail/courier-mta/patches/patch-am @@ -0,0 +1,14 @@ +$NetBSD: patch-am,v 1.1 2007/08/10 17:57:05 jlam Exp $ + +--- courier/cmlm2.C.orig 2007-04-30 23:01:57.000000000 -0400 ++++ courier/cmlm2.C +@@ -10,6 +10,9 @@ + #include "rfc822/rfc2047.h" + #include "unicode/unicode.h" + #include <fcntl.h> ++#if HAVE_LANGINFO_H ++#include <langinfo.h> ++#endif + #include <unistd.h> + + #include <fstream> diff --git a/mail/courier-mta/patches/patch-an b/mail/courier-mta/patches/patch-an new file mode 100644 index 00000000000..b0cf2b5bf62 --- /dev/null +++ b/mail/courier-mta/patches/patch-an @@ -0,0 +1,42 @@ +$NetBSD: patch-an,v 1.1 2007/08/10 17:57:05 jlam Exp $ + +--- courier/webmlmd.C.orig 2007-06-15 22:21:24.000000000 -0400 ++++ courier/webmlmd.C +@@ -953,10 +953,10 @@ static void sendsubunsub(std::string ext + + if (ctlmsg.start(ext, address, "ctlmsg")) + { +- FILE *stdin=ctlmsg.stdin(); ++ FILE *standard_input=ctlmsg.standard_input(); + + ctlmsg.mk_received_header(); +- fprintf(stdin, "\nSubscription request received.\n"); ++ fprintf(standard_input, "\nSubscription request received.\n"); + + if (ctlmsg.wait()) + { +@@ -1100,10 +1100,10 @@ static void listrequest2(std::string lis + if (confirm.start(method + "-" + token, "", + "ctlmsg")) + { +- FILE *stdin=confirm.stdin(); ++ FILE *standard_input=confirm.standard_input(); + + confirm.mk_received_header(); +- fprintf(stdin, ++ fprintf(standard_input, + "Subject: yes -- confirmed by WebMLM\n" + "\n" + "Confirmed\n"); +@@ -1117,9 +1117,9 @@ static void listrequest2(std::string lis + char buf[1024]; + bool isfirst=true; + +- FILE *stdout=confirm.stdout(); ++ FILE *standard_output=confirm.standard_output(); + +- while (fgets(buf, sizeof(buf), stdout)) ++ while (fgets(buf, sizeof(buf), standard_output)) + { + if (isfirst) + { diff --git a/mail/courier-mta/patches/patch-ao b/mail/courier-mta/patches/patch-ao new file mode 100644 index 00000000000..2db7ab6fd18 --- /dev/null +++ b/mail/courier-mta/patches/patch-ao @@ -0,0 +1,15 @@ +$NetBSD: patch-ao,v 1.1 2007/08/10 17:57:05 jlam Exp $ + +--- courier/webmlmdcmlm.H.orig 2007-05-19 20:04:55.000000000 -0400 ++++ courier/webmlmdcmlm.H +@@ -62,8 +62,8 @@ namespace webmlmd { + ); + bool wait(); + +- FILE *stdin() { return stdin_filep.fp; } +- FILE *stdout() { return stdout_filep.fp; } ++ FILE *standard_input() { return stdin_filep.fp; } ++ FILE *standard_output() { return stdout_filep.fp; } + + void mk_received_header(); + diff --git a/mail/courier-mta/patches/patch-ap b/mail/courier-mta/patches/patch-ap new file mode 100644 index 00000000000..e9d3db4e134 --- /dev/null +++ b/mail/courier-mta/patches/patch-ap @@ -0,0 +1,30 @@ +$NetBSD: patch-ap,v 1.1 2007/08/10 17:57:06 jlam Exp $ + +--- courier/webmlmdmod.C.orig 2007-05-19 20:04:55.000000000 -0400 ++++ courier/webmlmdmod.C +@@ -286,10 +286,10 @@ std::string webmlmd::do_mod_accept(std:: + + if (ctlmsg.start("moderate", "", "ctlmsg")) + { +- FILE *stdin=ctlmsg.stdin(); ++ FILE *standard_input=ctlmsg.standard_input(); + + ctlmsg.mk_received_header(); +- fprintf(stdin, "Subject: yes\n\n" ++ fprintf(standard_input, "Subject: yes\n\n" + "==CUT HERE==\n\n==CUT HERE==\n\n" + "[%s]\n" + "[%s]\n", +@@ -329,10 +329,10 @@ std::string webmlmd::do_mod_reject(std:: + + if (ctlmsg.start("moderate", "", "ctlmsg")) + { +- FILE *stdin=ctlmsg.stdin(); ++ FILE *standard_input=ctlmsg.standard_input(); + + ctlmsg.mk_received_header(); +- fprintf(stdin, "Subject: %s\n\n" ++ fprintf(standard_input, "Subject: %s\n\n" + "==CUT HERE==\n\n%s==CUT HERE==\n\n" + "[%s]\n" + "[%s]\n", diff --git a/mail/courier-mta/patches/patch-aq b/mail/courier-mta/patches/patch-aq new file mode 100644 index 00000000000..c28cb8240ab --- /dev/null +++ b/mail/courier-mta/patches/patch-aq @@ -0,0 +1,22 @@ +$NetBSD: patch-aq,v 1.1 2007/08/10 17:57:06 jlam Exp $ + +--- courier/webmlmdsublist.C.orig 2007-06-15 22:21:24.000000000 -0400 ++++ courier/webmlmdsublist.C +@@ -319,7 +319,7 @@ static void dodel(WSubList &sub_list) + + unsubscribe.mk_received_header(); + +- FILE *fp=unsubscribe.stdin(); ++ FILE *fp=unsubscribe.standard_input(); + + fprintf(fp, + "Subject: admin unsubscribe\n" +@@ -578,7 +578,7 @@ HANDLER("SUBINFO", emit_subinfo) + + char linebuf[256]; + +- while (fgets(linebuf, sizeof(linebuf), subinfo.stdout())) ++ while (fgets(linebuf, sizeof(linebuf), subinfo.standard_output())) + { + std::cout << webmlmd::html_escape(linebuf); + } diff --git a/mail/courier-mta/pkginstall.mk b/mail/courier-mta/pkginstall.mk index b884c847e2c..26daf15a07c 100644 --- a/mail/courier-mta/pkginstall.mk +++ b/mail/courier-mta/pkginstall.mk @@ -1,4 +1,4 @@ -# $NetBSD: pkginstall.mk,v 1.3 2007/06/15 18:29:06 jlam Exp $ +# $NetBSD: pkginstall.mk,v 1.4 2007/08/10 17:57:03 jlam Exp $ # Convenience definition used below for a file or directory owned by the # courier user and group. @@ -7,7 +7,7 @@ COURIER_OWNED= ${COURIER_USER} ${COURIER_GROUP} REQD_DIRS+= ${DATADIR} ${DOCDIR} ${EGDIR} \ ${LIBEXECDIR} ${LIBEXECDIR}/modules -REQD_DIRS_PERMS+= ${LIBEXECDIR}/cgi-bin \ +REQD_DIRS_PERMS+= ${LIBEXECDIR}/webmail \ ${REAL_ROOT_USER} ${REAL_ROOT_GROUP} 0700 MAKE_DIRS+= ${VARBASE}/run ${COURIER_STATEDIR} @@ -38,12 +38,17 @@ OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/webadmin/removed \ ${COURIER_OWNED} 0700 ### +### Courier webmlmd directories +### +OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/webmlm ${COURIER_OWNED} 0755 + +### ### Courier setuid and setgid binaries ### SPECIAL_PERMS+= bin/cancelmsg ${COURIER_OWNED} 6555 SPECIAL_PERMS+= bin/mailq ${COURIER_OWNED} 2555 SPECIAL_PERMS+= bin/sendmail ${SETUID_ROOT_PERMS} -SPECIAL_PERMS+= libexec/courier/cgi-bin/courierwebadmin \ +SPECIAL_PERMS+= libexec/courier/webmail/webadmin \ ${SETUID_ROOT_PERMS} SPECIAL_PERMS+= libexec/courier/submitmkdir ${COURIER_OWNED} 4550 |