Помогите! который день бьюсь, не знаю где грабли?
хотел настроить связку postfix+sasl2+mysql+courier
все работает, кроме auth sasl
имеем:
postfix-1.1.11
main.cf
alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
debug_peer_level = 2
disable_vrfy_command = yes
inet_interfaces = all
local_recipient_maps = unix:passwd.byname $alias_maps $virtual_mailbox_maps
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
mydestination = localhost, $myhostname, localhost.$mydomain, mysql:/etc/postfix/mysql-mydestination.cf
mydomain = domain
myhostname = mail.domain
mynetworks = 192.168.0.0/16
mynetworks_style = subnet
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-1.1.11/README_FILES
sample_directory = /usr/share/doc/postfix-1.1.11/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_always_send_ehlo = yes
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = mysql:/etc/postfix/mysql-sasl.cf
smtpd_client_restrictions = permit_mynetworks, permit_sasl_authenticated
smtpd_helo_required = yes
smtpd_helo_restrictions = permit_mynetworks
smtpd_recipient_restrictions = permit_mynetworks, permit_mx_backup, permit_sasl_authenticated, reject
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sender_login_maps =
smtpd_sender_restrictions = permit_mynetworks, permit_sasl_authenticated
transport_maps = mysql:/etc/postfix/mysql-transport.cf
virtual_create_maildirsize = yes
virtual_gid_maps = mysql:/etc/postfix/mysql-virtual-gid.cf
virtual_mailbox_base = /
virtual_mailbox_limit = 11000000
virtual_mailbox_limit_inbox = no
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql-mailboxsize.cf
virtual_mailbox_limit_override = yes
virtual_mailbox_maps = mysql:/etc/postfix/mysql-virtual-maps.cf
virtual_maildir_extended = yes
virtual_maps = mysql:/etc/postfix/mysql-virtual.cf
virtual_minimum_uid = 500
virtual_uid_maps = mysql:/etc/postfix/mysql-virtual-uid.cf
mysql-sasl.cf
user = postfix
password = passwd
dbname = mail
table = users
select_field = passwd
where_field = email
hosts = 127.0.0.1
additional_conditions = and active = '1'
база данных mysql:
таблица users
| email | passwd | uid | gid | maildir | enabled | quota |
| test@mail.domain | test | 1000 | 12 | /var/spool/mail/domain/test/| 1 |
2048000 |
sasl2
/usr/lib/sasl2/smtpd.conf
pwcheck_method: auxprop
auxprop_plugin: sql
mech_list: login
sql_engine: mysql
sql_hostnames: localhost
sql_user: postfix
sql_passwd: passwd
sql_database: mail
sql_statement: SELECT clear FROM mail WHERE email = '%u@%r'
sql_verbose: yes
log_level= 9
запускаем клиент, пытаемся отправить письмо...
Ошибка отправки:
Ошибка при аутентификации на сервере.
Вероятная причина этого - неверный пароль.
Ответ сервера: "Error: authentication failed "
смотрим логи постфикса:
Mar 3 18:32:42 localhost postfix/smtpd[4800]: warning: SASL authentication problem: unrecognized plaintext verifier auxprop
Mar 3 18:32:42 localhost postfix/smtpd[4800]: warning: unknown[192.168.1.1]: SASL LOGIN authentication failed
запросов к базе в логах не наблюдаю :(
куда копать???