Subject: Re: Re: postfix/sasl working but "no user in db"
To: segv <segv@netctl.net>
From: ptiJo <joel@carnat.net>
List: netbsd-users
Date: 07/27/2005 21:09:38
--vtzGhvizbBRQ85DL
Content-Type: text/plain; charset=iso-8859-15
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Wed, Jul 27 2005 - 19:47, segv wrote:
> On Wed, 27 Jul 2005 17:59:38 +0200
> Joel CARNAT <joel@carnat.net> wrote:
>=20
> > Hi,
> >=20
> > I've configured my postfix with SASL.
> > It (seem to) works OK :
> > -> mail for $mydestination are delivered
> > -> mails from $mynetworks are delivered
> > -> mail_relay is authorized only for user created with saslpasswd2
> >=20
> > What I don't get is why postfix keeps complaining about "no user in db"
> > When it does validate the login/pass I give him :
> > ********************
> > postfix/smtpd[28738]: warning: SASL authentication failure: no user in =
db
> > client=3Dunknown [x.x.x.x], sasl_method=3DCRAM-MD5, sasl_username=3Dtes=
tuser@here.domain.tld
> > ********************
>=20
> 1. what are the permissions on /usr/pkg/etc/sasldb.db file? postfix must =
be
> able to read the file
>=20

yep, I checked this one :
-rw-r-----  1 root  postfix   16K Jul 27 15:42 /usr/pkg/etc/sasldb.db

> 2. in /usr/pkg/etc/postfix/main.cf if you set 'myhostname' to
> 'mail.mydomain.net' you should also specify that domain when you run
> saslpasswd2, i.e.
>=20
> 	/usr/pkg/sbin/saslpasswd2 -c -u mail.mydomain.net username
>=20

myhostname=3Dbagheera.tumfatig.net, this it's hostname.
and the exact saslpasswd2 command was :
# sudo saslpasswd2 -c -u bagheera.tumfatig.net -a smtpauth testuser

> I remember having authenication problems with postfix/cyrus-imapd when the
> hostname did not match exactly.

I google-found quite many references but with no solution :(
And as it works, it looks like postfix (or sasl) tries something (not
well configured) before using sasldb.db - but I can't find what ;(


--vtzGhvizbBRQ85DL
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (NetBSD)

iD8DBQFC59vy0/VH7L7F7Y4RAkl4AJ0TNSntLaiP23J+qr86ujPi4Djb3ACfS5xY
+BCipgCQXp2JAgI+PY5MAIE=
=CvOB
-----END PGP SIGNATURE-----

--vtzGhvizbBRQ85DL--