On Tue, 2004-06-01 at 11:10, Andrzej Filip wrote:
> Tor Slettnes wrote:
> > require_files = /usr/sbin/mbpath
> > condition = ${run {/usr/sbin/mbpath -q -s user.${lc:$local_part}}{1}{0}}
> I think that callouts are "less costly" than executing an external program.
True. It is however possible (but uglier) to perform a less costly
version of the above:
require_files = ${lc:/var/spool/cyrus/mail/${substr_0_1:$local_part}/user/$local_part}
In this example, user "foo"'s mailbox is in /var/spool/cyrus/mail/f/user/foo.
> I designed my solution specially for supporting cyrus virtual domains so it is
> not best fit for "local transport" replacement.
Point taken.
> BTW Is there any chance to make exim provide a few simple "built in" filters ?
> [e.g. to strip some chars (\0) ]
Well, I tried using PCRE in an ACL (by way of Exiscan-ACL), akin to:
deny message = Your message contains invalid characters
regex = \\000
(And various permutations, using [[^::print::]], etc...). However, it
seems that the PCRE library stops matching at the first occurence of a
NUL character in the string to be matched. The "pcretest" utility seems
to confirm this.
-tor