1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-23 09:10:43 +00:00

- update pkg-list for milter [1]

- Update of CYRUS_LOOKUP patch [2]
PR:		71948, 71995
Submitted by:	[1] Jose M Rodriguez, [2] Michael O. Boev
This commit is contained in:
Dirk Meyer 2004-10-12 04:21:01 +00:00
parent 47a5694889
commit 7bac1ad54a
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=118771
3 changed files with 83 additions and 39 deletions

View File

@ -8,16 +8,19 @@ before accepting any mail to be relayed to cyrus.
They are based on the idea and work by
Andrzej Filip
Andrzej Filip, http://anfi.homeunix.net/sendmail/rtcyrus2.html
and
Mike Boev, http://tric.ru/users/mike/ckuser_cyrus/
published at
http://anfi.homeunix.net/sendmail/rtcyrus2.html.
Please, use this url to learn all configuration details
Please, use these urls to learn all configuration details
(although a quick recipe is provided below) and may be to give
credits to the author.
credits to the authors.
******************************************************************
IMPORTANT:
Now that the mrs_cyrus.m4 has been updated, you may need to adjust
the modifications you made to your .mc file if you used the old one!
See http://anfi.homeunix.net/sendmail/rtcyrus2.html for current
installation instructions.
******************************************************************
HOW TO :
@ -52,29 +55,25 @@ SENDMAIL_WITH_SOCKETMAP= yes
and a couple of others.
2. As per the `install-configure' from Cyrus IMAP server's documentation,
in the simplest case, you add:
in the simplest case, you added:
define(`confLOCAL_MAILER', `cyrusv2')dnl
MAILER(`cyrusv2')dnl
to your sendmail's .mc file to make local delivery to Cyrus mailboxes.
Per the instructions, provided by Andrzej Filip (see the above URL),
these lines should become:
Now, simply add (somewhere near other FEATURES, before MAILER lines):
define(`LOCAL_RELAY',`mrs_cyrus_user:stripdom')dnl
FEATURE(`mrs')dnl
FEATURE(`mrs_cyrus')dnl
MODIFY_MAILER_FLAGS(`CYRUSV2',`-A5')dnl
MAILER(`cyrusv2')dnl
FEATURE(`ckuser_cyrus')dnl
for sendmail to start rejecting local addresses for nonexisting and
full mailboxes. Rebuild your sendmail.cf, restart sendmail, and enjoy!
If your configuration is more complicated than the above two lines,
read Andrzej's article. It contains more examples.
If your configuration is more complicated than just defining Cyrus
as your local mailer, read Andrzej's article. It covers more of the
other cases.
******************************************************************
2004, April 8th
2004, September 16th
Michael O. Boev,
mike@tric.ru.

View File

@ -1,23 +1,48 @@
*** cf/m4/proto.m4 2004/03/09 15:49:38 1.1
--- cf/m4/proto.m4 2004/03/10 20:29:48
***************
*** 1299,1304 ****
--- 1299,1307 ----
R< error : $- : $+ > $* $#error $@ $(dequote $1 $) $: $2
R< error : $+ > $* $#error $: $1
R< local : $* > $* $>CanonLocal < $1 > $2
+ ifdef(`_MRS_RELAY_',`dnl
+ R< $={MRS} : $* > $* $@ $> $1 < $2 > $3
+ dnl')
dnl it is $~[ instead of $- to avoid matches on IPv6 addresses
R< $~[ : $+ @ $+ > $*<$*>$* $# $1 $@ $3 $: $2<@$3> use literal user
R< $~[ : $+ > $* $# $1 $@ $2 $: $3 try qualified mailer
--- /dev/null Wed Apr 7 20:03:20 2004
+++ cf/feature/mrs.m4 Tue Mar 23 14:00:30 2004
@@ -0,0 +1,25 @@
diff -ruN cf.orig/feature/ckuser_cyrus.m4 cf/feature/ckuser_cyrus.m4
--- cf.orig/feature/ckuser_cyrus.m4 Thu Jan 1 07:00:00 1970
+++ cf/feature/ckuser_cyrus.m4 Wed Sep 22 19:53:53 2004
@@ -0,0 +1,34 @@
+divert(-1)
+# Written by Mike Boev <mike@tric.ru>, 2004.
+# Homepage: http://tric.ru/users/mike/ckuser_cyrus/
+# Inspired by: mrs_cyrus.m4 by Andrzej Adam Filip
+#
+# By using this file, you agree to the terms and conditions set
+# forth in the LICENSE file which can be found at the top level of
+# the sendmail distribution.
+#
+divert(0)
+VERSIONID(`Id: ckuser_cyrus.m4,v 1.4 2004/09/21 19:02:17 m Exp ')
+divert(-1)
+define(`CYRUS_SMMAPD_SOCKET',
+ ifelse(len(X`'_ARG_), `1', `local:/var/imap/socket/smmapd', _ARG_))
+
+MODIFY_MAILER_FLAGS(`CYRUSV2',`+5')
+
+LOCAL_CONFIG
+# Cyrus smmapd(8)'s map for verifying mailboxes of local recipients
+Kcyrus socket -a<OK> -T<TMPF> CYRUS_SMMAPD_SOCKET
+
+LOCAL_RULESETS
+SLocal_localaddr
+R$+ $: $> "ckuser_cyrus" $1
+
+Sckuser_cyrus
+#Query smmapd(8)
+R$+ $: <!> $1 $| $(cyrus $1 $: $)
+#Cyrus OK, skip
+R<!> $* $| $* <OK> $@ $1
+#Over quota or lookup failure
+R<!> $* $| $* <TMPF> $# error $@ 4.3.0 $: "451 TEMPFAIL."
+#Mailbox doesn't exist or its ACL forbids posting
+R<!> $* $| $* $# error $@ 5.1.1 $: "550 Mailbox is not available."
diff -ruN cf.orig/feature/mrs_cyrus.m4 cf/feature/mrs_cyrus.m4
--- cf.orig/feature/mrs_cyrus.m4 Thu Jan 1 07:00:00 1970
+++ cf/feature/mrs_cyrus.m4 Wed Sep 22 19:55:05 2004
@@ -0,0 +1,77 @@
+divert(-1)
+dnl
+dnl Updates: http://anfi.homeunix.net/sendmail/mrs.html
+dnl Updates: http://anfi.webhop.net/sendmail/mrs.html
+dnl
+dnl By using this file, you agree to the terms and conditions set
+dnl forth in the LICENSE file which can be found at the top level of
@ -70,7 +95,7 @@
+define(`_MRS_CYRUS_',`')
+
+divert(0)
+VERSIONID(`$Id: mrs_cyrus.m4,v 8.7 2004/04/01 14:29:50 anfi Exp $')
+VERSIONID(`$Id: mrs_cyrus.m4,v 8.8 2004/08/11 18:20:05 anfi Exp $')
+divert(-1)
+define(`CYRUS_SMMAPD_SOCKET',
+ ifelse(len(X`'_ARG_), `1', `/var/imap/socket/smmapd', _ARG_))
@ -93,7 +118,7 @@
+R<$*> $+ <@$*> $| $* <TMPF> $# error $@ 4.3.0 $: "451 Temporary system failure. Please try again later."
+R<$*> $+ <@$*> $| $* <OK> $# cyrusv2 $@ dummy $: $4
+R<$*> $+ <@$*> $| $* $: <$1> $2 <@$3>
+R<stripdom> $+ <@stripdom> $@ $1
+R<dummy> $+ <@dummy> $@ $1
+R< $~[ : $* > $* $>MailerToTriple < $1 : $2 > $3
+R< $+ > $* $>MailerToTriple < $1 > $2
+R< > $* $# error $@ 5.1.1 $: "550 User unknown"
@ -117,3 +142,16 @@
+R<dummy> $+ <@$={VirtCyrus}> $| $* $# error $@ 5.1.1 $: "550 User unknown"
+R<dummy> $=L <@$*> $# ifdef(`confLOCAL_MAILER',confLOCAL_MAILER,`local') $: @$1
+R<dummy> $* <@$*> $# ifdef(`confLOCAL_MAILER',confLOCAL_MAILER,`local') $: $1
diff -ruN cf.orig/m4/proto.m4 cf/m4/proto.m4
--- cf.orig/m4/proto.m4 Wed Sep 22 20:15:04 2004
+++ cf/m4/proto.m4 Wed Sep 22 19:52:41 2004
@@ -1315,6 +1315,9 @@
R< error : $- : $+ > $* $#error $@ $(dequote $1 $) $: $2
R< error : $+ > $* $#error $: $1
R< local : $* > $* $>CanonLocal < $1 > $2
+ifdef(`_MRS_RELAY_',`dnl
+R< $={MRS} : $* > $* $@ $> $1 < $2 > $3
+dnl')
dnl it is $~[ instead of $- to avoid matches on IPv6 addresses
R< $~[ : $+ @ $+ > $*<$*>$* $# $1 $@ $3 $: $2<@$3> use literal user
R< $~[ : $+ > $* $# $1 $@ $2 $: $3 try qualified mailer

View File

@ -22,14 +22,21 @@ lib/libmilter.a
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_delrcpt.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_getpriv.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_getsymval.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_insheader.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_main.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_opensocket.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_progress.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_quarantine.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_register.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_replacebody.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_setbacklog.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_setconn.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_setdbg.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_setmlreply.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_setpriv.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_setreply.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_settimeout.html
%%PORTDOCS%%share/doc/sendmail/libmilter/smfi_stop.html
%%PORTDOCS%%share/doc/sendmail/libmilter/xxfi_abort.html
%%PORTDOCS%%share/doc/sendmail/libmilter/xxfi_body.html
%%PORTDOCS%%share/doc/sendmail/libmilter/xxfi_close.html