LMTPD problems

Jonathan Marsden jonathan at bach.xc.org
Fri Feb 21 16:49:57 EST 2003


On 21 Feb 2003, James Miller writes:

> Would the LOGFILE statement go into the .procmailrc recipe?

Yes.  Running the command "man procmailrc" will provide more details,
if you need them.

> It seems to me LMTPD is rejecting the messages because of header
> problems.

Only because what you are sending to lmtpd is not a valid message.
lmtpd won't care about the *content* of headers (other than if they
contain illegal 8bit chars), only the syntax of the message.

> Are there any know issues between cyrus and mimedefang?

That combination works fine here.  But I'm not adding procmail to the
mix.

> I really don't want Cyrus doing any validation for me.

Then you'd end up with a mailstore containing invalid messages, and
later on clients would choke on them... better by far to reject
invalid mail before it gets into the mailstore, surely!  There are
good reasons why RFCs for mail exist.

> I simply want it to deliver the _@#%@#$_ messages into the
> mailstores.. is there a way to turn off all of the message/header
> validation checks?

AFAIK, there aren't any "checks" per se other than for 8 bit chars.
It's just that you need to give lmtpd a valid mail message to work
with.  IMO it is 100% reasonable for an LMTP daemon to insist that you
feed it only correctly formatted messages, and to reject those which
are bad.

I suggest doing this one step at a time.

1) Can you deliver hand-created correctly formatted messages to cyrus
via lmtpd (via deliver -l)?  For example:

    11:29:14 root at testing:/home/jonathan# /usr/libexec/cyrus/deliver -l
    220 testing.net LMTP Cyrus v2.2.prealpha-GRC-RPM-2.2-cvs.20030115 ready
    lhlo junk
    250-testing.net
    250-8BITMIME
    250-ENHANCEDSTATUSCODES
    250-PIPELINING
    250-SIZE
    250-AUTH EXTERNAL
    250 IGNOREQUOTA
    MAIL FROM: <jonathan at xc.org>
    501 5.5.4 Syntax error in parameters
    mail from:<jonathan at xc.org>
    250 2.1.0 ok
    rcpt to:<tester0 at testing.net>
    250 2.1.5 ok
    data
    354 go ahead
    Subject: test

    a test
    .
    250 2.1.5 Ok
    quit
    221 2.0.0 bye
    11:34:46 root at testing:/home/jonathan# 

If that works, then lmtpd is doing its job.  If not, then forget
procmail and MIMEdefang and all that other stuff, and get lmtpd
working first.  If you wish, at this stage you can try providing more
and more complex messages with various headers (after the data
command) and see which ones are valid and which ones are not.

2) Configure your MTA to just deliver mail to cyrus via LMTP.  No
procmail, no antivirus stuff, just "deliver the _@#%@#$_ messages" as
you put it!  Does *that* work?

3) Add MIMEdefang as a sendmail milter or whatever other way you call
it at your site.  Does *that* work?

4) Add procmail.  Does *that* work?

If you proceed stepwise like this, it will be a lot easier to
determine where the problem lies.  The chances are high that some of
your mail processing is resulting in invalid messages, which lmtpd
then (correctly) rejects.

Jonathan
--
Jonathan Marsden       	| Internet: jonathan at xc.org	| Making electronic 
1252 Judson Street  	| Phone: +1 (909) 795-3877	| communications work 
Redlands, CA 92374     	| Fax:   +1 (909) 795-0327	| reliably for Christian 
USA            		| http://www.xc.org/jonathan	| missions worldwide 




More information about the Info-cyrus mailing list