This is a repost of "Dash extenstion + RCPTCHECK?" summarizing the tests and results Chris Wilkes and I have come up with. However dispite our efforts it still just plain doesnt work.
The issue is that users in ldap with no qmailUID / GID will only ever read .qmail not .qmail-whatever. I have set up a minimal test box exibiting this issue to simplify things. the user "username" has mail: [EMAIL PROTECTED] mailAlternateAddress: [EMAIL PROTECTED] with this username-whatever delivers via .qmail, if I remove the mailAlternateAddress it will bounce with "Sorry, no mailbox here by that name. (#5.1.1)" however if I make a real user in /etc/passwd and /etc/group give it its own qmailUID / GID in ldap it works, but only if I leave mailAlternateAddress out. I have read some documentation that says leave it out, others that say it must be there, Chris says it must be there but in a "real" user it only works if its not. So I am confused. If anyone wants to have a look the test box it is at ssh [EMAIL PROTECTED] pass: test http://68.230.81.22:8000/phpldapadmin/ pass: test Do whatever you want, this box is nothing but a test case for this issue. ports 25(in and out),110,80 are all blocked by my isp. (just try to avoid the temptation of a rm -Rf /* so others can look too lol) first, here is the main section of my makefile -------------------------------------------- LDAPFLAGS=-DEXTERNAL_TODO -DDASH_EXT -DSMTPEXECCHECK -DALTQUEUE # Perhaps you have different ldap libraries, change them here LDAPLIBS=-L/usr/local/lib -lldap -llber # and change the location of the include files here LDAPINCLUDES=-I/usr/local/include # on Slowaris you need -lresolv and probably a LD_RUN_PATH added like this: #LDAPLIBS=-L/opt/OpenLDAP/lib -lldap -llber -lresolv -R/opt/OpenLDAP/lib # for example on my Linux box I use: #LDAPLIBS=-L/opt/OpenLDAP/lib -lldap -llber # if you need a special include-directory for ldap headers enable this #LDAPINCLUDES=-I/opt/OpenLDAP/include # ZLIB needed for -DDATA_COMPRESS and -DQMQP_COMPRESS #ZLIB=-lz # or you installed zlib in a different path you can use something like this #ZLIB=-L/opt/zlib/lib -lz #ZINCLUDES=-I/opt/zlib/include # TLS (SMTP encryption) in qmail-smtpd and qmail-remote, see TLS.readme # You need OpenSSL for this # use -DTLS_REMOTE to enable tls support in qmail-remote # use -DTLS_SMTPD to enable tls support in qmail-smtpd # use -DTLSDEBUG to enable additional tls debug information in qmail-remote #TLS=-DTLS_REMOTE -DTLS_SMTPD # Path to OpenSSL includes #TLSINCLUDES=-I/usr/local/include # Path to OpenSSL libraries #TLSLIBS=-L/usr/local/lib -lssl -lcrypto # Path to OpenSSL binary #OPENSSLBIN=/usr/local/bin/openssl #OPENSSLBIN=openssl # to make the Netscape download progress bar work with qmail-pop3d # uncomment the next line (allready done) MNW=-DMAKE_NETSCAPE_WORK # to enable the auto-maildir-make feature uncomment the next line #MDIRMAKE=-DAUTOMAILDIRMAKE # to enable the auto-homedir-make feature uncomment the next line #HDIRMAKE=-DAUTOHOMEDIRMAKE # on most systems we need this to make auth_pop and auth_imap SHADOWLIBS=-lcrypt # OpenBSD and other Systems do not have libcrypt, so comment the line out # if you get linking problems. # To use shadow passwords under some Linux OS, uncomment the next two lines. #SHADOWLIBS=-lcrypt -lshadow #SHADOWOPTS=-DPW_SHADOW # To use shadow passwords under Solaris, uncomment the SHADOWOPTS line. # to enable the possibility to log and debug imap and pop uncoment the # next line DEBUG=-DDEBUG # WARNING: you need a NONE DEBUG auth_* to run with inetd ---------------------------------------- cat defaultdomain domain.tld cat ldapdefaultdotmode dotonly cat defaultdelivery ./Maildir/ cat locals domain.tld mx1.domain.tld cat rcpthosts domain.tld mx1.domain.tld cat qmail-smtpd.rules 127.0.0.1:allow,RELAYCLIENT="",NOPBS="",RCPTCHECK="" :allow,NOPBS="",RCPTCHECK="" cat me mx1.domain.tld cat ldapgid 103 cat ldapuid 1009 mx1:/home/mailstore/username# find . ./.qmail-whatever ./Maildir ./Maildir/cur ./Maildir/new ./Maildir/tmp ./Maildir/.whatever ./Maildir/.whatever/cur ./Maildir/.whatever/new ./Maildir/.whatever/tmp ./.qmail mx1:/home/mailstore/username# ls -lan total 10 drwxrwx--- 3 1009 103 128 Sep 20 07:46 . drwxrwx--- 4 1009 103 104 Sep 19 12:58 .. -rw-r----- 1 1009 103 43 Sep 20 07:43 .qmail -rw-r----- 1 1009 103 21 Sep 19 12:41 .qmail-whatever drwx------ 6 1009 103 152 Sep 19 12:40 Maildir mx1:/home/mailstore/username# cat .qmail | set > /tmp/qmail-username.log ./Maildir/ mx1:/home/mailstore/username# cat .qmail-whatever ./Maildir/.whatever/ mx1:/home/mailstore/username# cat /tmp/qmail-username.log BASH=/bin/sh BASH_VERSINFO=([0]="2" [1]="05a" [2]="0" [3]="1" [4]="release" [5]="i386-pc-linux-gnu") BASH_VERSION='2.05a.0(1)-release' DIRSTACK=() DTLINE='Delivered-To: [EMAIL PROTECTED] ' EUID=1009 EXT= EXT2= EXT3= EXT4= GROUPS=() HOME=/home/mailstore/username HOST=domain.tld HOST2=domain HOST3=domain HOST4=domain HOSTNAME=mx1 HOSTTYPE=i386 IFS=' ' LOCAL=username-whatever MACHTYPE=i386-pc-linux-gnu [EMAIL PROTECTED] OPTERR=1 OPTIND=1 OSTYPE=linux-gnu PATH=/var/qmail/bin:/command:/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin POSIXLY_CORRECT=y PPID=15411 PS4='+ ' PWD=/home/mailstore/username QMAILDOTMODE=dotonly [EMAIL PROTECTED] RPLINE='Return-Path: <[EMAIL PROTECTED]> ' [EMAIL PROTECTED] SHELL=/bin/bash SHELLOPTS=braceexpand:hashall:interactive-comments:posix SHLVL=1 TERM=dumb UFLINE='From [EMAIL PROTECTED] Mon Sep 20 14:44:48 2004 ' UID=1009 USER=username _=/bin/sh mx1:/home/mailstore/username# /var/qmail/bin/qmail-ldaplookup -m [EMAIL PROTECTED] Searching ldap for: (&(objectClass=qmailuser)(|([EMAIL PROTECTED])([EMAIL PROTECTED]))) under dn: dc=domain, dc=tld Found 1 entry: dn: uid=username,ou=People,dc=domain,dc=tld ------------------------------------------------------- objectClass: inetOrgPerson objectClass: person objectClass: qmailUser objectClass: top mail: [EMAIL PROTECTED] mailAlternateAddress: [EMAIL PROTECTED] uid: username accountStatus: active mailHost: undefined homeDirectory: /home/mailstore/username aliasEmpty: using default qmailDotMode: dotonly qmailUID: 1009 qmailGID: 103 mailQuotaSize: 0 (unlimited) mailQuotaCount: 0 (unlimited) mailSizeMax: 0 (unlimited) mailReplyText: undefined -- Entelin <[EMAIL PROTECTED]>
