cyrus 2.2 and virtual domain resolution

Ilya mail at krel.org
Wed Feb 5 22:44:48 EST 2003


I have strange issues with virtualdomains. 
Some background:
Freebsd 4.7 
hostname is defaultdomain.com, and running "hostname" command returns defaultdomain.com
in imapd.conf
virtdomains: yes
defaultdomain: defaultdomain.com

I am using mysqlauxprop which runs this SQL statement: select password from xxx
where user=%u and domain=%r
some additional domains I have are example1.com example2.com example3.com

when I login to pop3 or imap as "user" which belongs to example1.com the log
shows:
select password from xxx where user=user and domain=com
Of course login fails.

Using user at defaultdomain.com or user at example1.com from command line always works. 
I know that cyrus would drop mail from mail.defaultdomain.com
but is it supposed to drop example from defaultdomain.com if the realm not supplied
explicitly?

Also trying to login to cyradmin:
cyradm --user user at defaultdomain.com --auth login --server localhost
produces failure with "domain=com" again.

But if I run:
 cyradm --user user at anything.defaultdomain.com --auth login --server localhost
the full "anything.defaultdomain.com" shows up in log!!!! (of course the login fails).
Or if I run user1 at example1.com the log shows "domain=example1.com" and I can
login.

A strange workaround for cyradmin and "user" is to setup a line like this in
/etc/hosts
127.0.0.1 whatever.defaultdomain.com example.com localhost
whatever.defaultdomain.com must be first, otherwise it wont work.

With the above line in /etc/hosts almost everything works ok:
mail is being delivered properly
i can login as "user at example1.com" to both pop3 (telnet) and imap (mutt and
imtest),
I can login to pop3 and imtest with "user" and "user at defaultdomain.com".
BUT when I use mutt to login as "user at defaultdomain.com" or "user" it fails again with
same "domain=com" in log.
Where as user at example1.com works fine.
I cannot understand why pop3 and imtest (with -r and without, as "user" and as
user at defaultdomain.com) works but mutt doesnt???


Anything I am doing wrong?




More information about the Info-cyrus mailing list