How to get plus formatted addresses delivered to sub-folders

Dan White dwhite at olp.net
Fri Jun 18 17:54:10 EDT 2010


On 18/06/10 15:14 -0400, James B. Byrne wrote:
>OS = CentOS-5.5
>MTA = sendmail-8.13.1-3.3
>IMAPD = cyrus-imapd-2.2.12-10

>What I would like to have happen, given this entry in virtusertable:
>
>@.domain.tld              %1 at other_domain.tld
>
>and this entry in the IMAP directory tree:
>
>/var/spool/imap/b/user/bylmbx001/delivery/test
>
>and a message with this email address:
>
>bylmbx001+delivery+test at domain.tld
>
>is to have the message placed directly in
>
>/var/spool/imap/b/user/bylmbx001/delivery/test
>
>The 'test' directory has the 'p' attribute set for the user 'anyone'.

># at least one LMTP is required for delivery
>lmtpunix cmd="lmtpd" listen="/var/lib/imap/socket/lmtp" prefork=1

I'm attaching a perl script I use (I don't recall which website I grabbed
it from) which will allow you to interact with your lmtp socket directly,
to isolate your Cyrus configuration.

For multi level plus addressing, you'll need to use your mailbox hierarchy
separator, like:

bylmbx001+delivery.test at domain.tld

See http://cyrusimap.web.cmu.edu/imapd/faq.html

This worked for me on a 2.3.16 install:

./telnet-unix.pl /var/lib/imap/socket/lmtp
220 zek Cyrus LMTP v2.3.16 server ready
lhlo test
250-zek
250-8BITMIME
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-SIZE
250-STARTTLS
250-AUTH EXTERNAL
250 IGNOREQUOTA
mail from:<ssmith at example.net>
250 2.1.0 ok
rcpt to:<jsmith+Super/SuperSecret>
250 2.1.5 ok
data
354 go ahead
From: <ssmith at example.net>
To: <jsmith at example.net>

Test
.
250 2.1.5 Ok
quit
221 2.0.0 bye

I have the 'anyone p' acl like you have, and the email ended up in the
right place.

-- 
Dan White
-------------- next part --------------
A non-text attachment was scrubbed...
Name: telnet-unix.pl
Type: text/x-perl
Size: 443 bytes
Desc: not available
Url : http://lists.andrew.cmu.edu/pipermail/info-cyrus/attachments/20100618/9a255475/attachment.bin 


More information about the Info-cyrus mailing list