Postfix SMTP AUTH Problem

Alexander Dalloz ad+lists at uni-x.org
Tue Aug 22 21:30:09 UTC 2006


Chong Yu Meng schrieb:

>Hi all,
>
>I am trying to configure SMTP AUTH on an FC5 development system and I'm
>seeing something strange and hoping someone can help.
>
>This is my environment:
>Postfix version: 2.2.8-1.2
>Cyrus SASL: 2.1.21
>
>My Postfix is configured to host virtual domains (cymulacrum.cym and
>virago.cym) and delivers mail via lmtp to Cyrus IMAP. The authentication
>system I am using is not PAM but sasldb2. I have created the following
>accounts inside sasldb2:
>
>[root at aeonflux log]# sasldblistusers2 
>admin at aeonflux.localdomain: userPassword
>tom at cymulacrum.cym: userPassword
>dick at cymulacrum.cym: userPassword
>harry at virago.cym: userPassword
>jill at virago.cym: userPassword
>admin at virago.cym: userPassword
>admin at cymulacrum.cym: userPassword
>jack at virago.cym: userPassword
>
>Now, I have already configured Postfix for SMTP AUTH and I am able to
>successfully authenticate with admin at aeonflux.localdomain, by using:
>username: admin
>password: admin
>
>But when I try to authenticate using:
>username: tom at cymulacrum.cym
>password: tom (yes, the password is correct -- I'm using weak passwords
>because this is for a tutorial I am conducting)
>
>I get an authentication error. I get errors for all the other accounts
>except the one above. I suspect that I have to define the realm
>somewhere instead of just using the "@domain", but I really don't know
>where to begin looking. 
>
>Any help would be greatly appreciated!
>
Yes, the realm (domain) in the sasldb2 matters. You have to SMTP AUTH 
with the full username as listed by sasldblistuser2. The fact that the 
first listed one works without the realm given is simply that that is 
your default realm.

If you encode for testing using perl, be sure to escape the "@" character:

perl -MMIME::Base64 -e 'print encode_base64("tom\@cymulacrum.cym\0tom\@cymulacrum.cym\0testpass");

Alexander





More information about the fedora-list mailing list