I'm having trouble authenticating incoming SMTP authentication to my postfix server (using Cyrus SASL with a MySQL backend).

In my auth.log I get:

postfix/smtpd[3389]: sql auxprop plugin using mysql engine
postfix/smtpd[3389]: SQL engine 'mysql' not supported
postfix/smtpd[3389]: auxpropfunc error no mechanism available
postfix/smtpd[3389]: _sasl_plugin_load failed on sasl_auxprop_plug_init for plugin: sqlite
postfix/smtpd[3389]: sql plugin Parse the username <email>
postfix/smtpd[3389]: sql plugin try and connect to a host
postfix/smtpd[3389]: sql plugin trying to open db 'postfix' on host 'localhost'

And my /etc/postfix/sasl/smtpd.conf looks like this:

pwcheck_method: saslauthd
mech_list: plain login cram-md5 digest-md5
log_level: 7
allow_plaintext: true
auxprop_plugin: sql
sql_engine: mysql
sql_hostnames: localhost
sql_user: -removed-
sql_passwd: -removed-
sql_database: postfix
sql_select: select password from mailbox where username = '%u@%r'

Essentially I understand what it's saying, that it can't find a MySQL authentication module, however I have installed both libsasl2-modules-sql and postfix-mysql. What am I missing?

  • This question appears to be abandoned and unanswered, could you perhaps add more detail to your question? If this question no longer applies then you can either delete it or answer it yourself if you've solved the problem. Thanks! – coversnail Apr 9 '12 at 21:46

If you have ubuntu 12.04, your problem seems to be this:


The best option for me was to downgrade libsqlite0 db4.8-util libssl0.9.8 packages to 2.1.23 version.



You should probably be using: pwcheck_method: auxprop

I say probably because there is much confusion about configuring cyrus-sasl. The manuals say saslauthd is only for PLAIN and LOGIN, but there is evidence to the contrary!

Have you checked the presence of the sql plugin? Some distributions (eg Fedora) do not install the plugins by default. You need something like: /use/lib/sasl2/libsql.so

Also know that unless your client user names are of the form user@realm or realm is derived from your smtp default and not specified by the client, and possibly the -r parameter has not been provided to saslauthd (see the man page and figure out how -r is passed when saslauthd starts) then the realm will not be passed to the %r in your swl select! You can check the correct passing, or not, of %r by dumping select text when it arrives at your mysql server.

Welcome to e-mail configuration hell ;-) Hope this helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.