atom feed14 messages in net.sourceforge.lists.courier-users[courier-users] Unknown User = EX_TEM...
FromSent OnAttachments
Griffiths, JonJul 24, 2001 7:28 am 
Sam VarshavchikJul 24, 2001 2:56 pm 
Daniel RoesenJul 24, 2001 4:21 pm 
Oliver BlasnikJul 25, 2001 12:44 am 
Griffiths, JonJul 25, 2001 2:33 am 
Griffiths, JonJul 25, 2001 2:56 am 
Daniel RoesenJul 25, 2001 3:30 am 
Xavier BeaudouinJul 25, 2001 3:41 am 
Sam VarshavchikJul 25, 2001 4:46 am 
Oliver BlasnikJul 25, 2001 7:30 am 
Daniel RoesenJul 25, 2001 8:29 am 
Griffiths, JonJul 25, 2001 10:00 am 
Sam VarshavchikJul 25, 2001 2:15 pm 
Oliver BlasnikJul 25, 2001 2:58 pm 
Subject:[courier-users] Unknown User = EX_TEMPFAIL??
From:Griffiths, Jon (Jon.@sunrise.net)
Date:Jul 24, 2001 7:28:25 am
List:net.sourceforge.lists.courier-users

Hi,

I have an LDAP set up & all seems to be working OK for it. Correctly addressed mail is delivered fine to maildir format by maildrop (1.3.4), and read by courier IMAP4/POP3 -> Thanks Mr Sam!

However, this is the crux of the matter. If I get an incorrectly addressed user, with the correct domain, I get this in the logs:

Jul 24 13:56:52 jon maildrop[27922]: Invalid user specified. Jul 24 13:56:52 jon sendmail[27919]: f6OANx626166: to=<comp@XXYY.com>, delay=01:32:53, xdelay=00:00:00, mailer=local, pri=392405, dsn=4.0.0, stat=Deferred: local mailer (/usr/local/bin/maildrop) exited with EX_TEMPFAIL

Now it seems to me that maildrop is not presenting the correct error code for invalid user. The users are _only_ in the LDAP and the mailer flags are as follows:

Mlocal, P=/usr/local/bin/maildrop, F=l, #Delivery agent is local (final) delivery F=s, #Strip quotation marks F=5, #Use rule set 5 after local aliasing F=P, #Need Return-Path: in header F=h, #Preserve uppercase in hostname F=n, #Don't use UNIX-style From in header F=D, #Specifies need for Date: header F=F, #Specifies need for From: header F=M, #Specifies need for Message-ID: header F=S, #Assume specified uid and gid S=10/30,R=20/40, T=DNS/RFC822/X-Unix, A=maildrop -d $u

And maildrop is installed as:

-r-sr-xr-x 1 root mail 142840 Jul 19 21:49 /usr/local/bin/maildrop

Can someone explain why I am being returned an EX_TEMPFAIL? I may just have missed something in one of the RFCs, let's face it they are not greatly interesting to read :-), however an invalid user would appear to me to be a fairly permanent error.

I have found the relevant piece in maildrop-1.3.4/maildrop/main.C but cannot see why this result (invalid user) is regarded as a temporary problem. I have modified the section very slightly:

static void nouser() { // Jon Griffiths to trap Perm failure for invalid user // errexit=EX_TEMPFAIL; // throw "Invalid user specified."; exit(67); }

This seems to work, generating the following logs:

Jul 24 16:15:18 jon sendmail[15283]: f6OEAH615179: to=<comp@Griff-IT.com>, delay=00:05:01, xdelay=00:00:00, mailer=local, pri=122425, dsn=5.1.1, stat=User unknown Jul 24 16:15:18 jon sendmail[15283]: f6OEAH615179: f6OEFD415283: DSN: User unknown

However, I do not know enough C/C++ to be able to put this in properly. This is a one off fix, and there may be (almost certainly) better ways to do it. Obviously the code 67 is valid for my Linux system, but may need changing depending on platform, which will require more work in the configure area I presume.

Regards,

Jon Griffiths Messaging Consultant

--------------------------------------------- sunrise communications AG internet and e-business Sonnentalstrasse 5 8600 Dübendorf

Phone +41 1 300 8452 Mobile +41 76 508 6015