Страница 1 из 1

Проблема с postfix + sasl

Добавлено: 2008-10-03 22:35:12
helloworld
Какие то грабли непойму.

То, что добавил с стандартный конфиг /usr/local/etc/postfix/mail.cf

Код: Выделить всё

virtual_alias_maps = hash:/usr/local/etc/postfix/virtual
virtual_alias_domains = realbitches.ru, bigtits.ru

# SASL suppot
broken_sasl_auth_clients = yes
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_security_options = noanonymous

smtpd_helo_required = yes
disable_vrfy_command = yes

smtpd_recipient_restrictions =
        permit_sasl_authenticated,
        permit_mynetworks,
        reject_unknown_recipient_domain,
        reject_unauth_destination,
        reject_rbl_client      bl.spamcop.net

# tls config
smtp_use_tls = yes
smtpd_use_tls = yes
smtp_tls_note_starttls_offer = yes
smtpd_tls_key_file = /usr/local/etc/postfix/ssl/smtpd.pem
smtpd_tls_cert_file = /usr/local/etc/postfix/ssl/smtpd.pem
smtpd_tls_CAfile = /usr/local/etc/postfix/ssl/smtpd.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
/var/log/maillog

Код: Выделить всё

postfix/master[58460]: daemon started -- version 2.5.5, configuration /usr/local/etc/postfix
postfix/smtpd[58466]: warning: SASL: Connect to smtpd failed: No such file or directory
postfix/smtpd[58466]: fatal: no SASL authentication mechanisms
postfix/master[58460]: warning: process /usr/local/libexec/postfix/smtpd pid 58466 exit status 1
postfix/master[58460]: warning: /usr/local/libexec/postfix/smtpd: bad command startup -- throttling

ps axu | grep saslauthd

Код: Выделить всё

root    58695  0.0  0.5  2876  1340  ??  Is   12:20AM   0:00.01 /usr/local/sbin/saslauthd -a pam
root    58696  0.0  0.5  2876  1336  ??  I    12:20AM   0:00.00 /usr/local/sbin/saslauthd -a pam
root    58697  0.0  0.5  2876  1336  ??  I    12:20AM   0:00.00 /usr/local/sbin/saslauthd -a pam
root    58698  0.0  0.5  2876  1336  ??  I    12:20AM   0:00.00 /usr/local/sbin/saslauthd -a pam
root    58699  0.0  0.5  2876  1336  ??  I    12:20AM   0:00.00 /usr/local/sbin/saslauthd -a pam
# cat /usr/local/lib/sasl2/smtpd.conf

Код: Выделить всё

pwcheck_method: saslauthd
mech_list: PLAIN LOGIN
# pkg_info

Код: Выделить всё

cyrus-sasl-2.1.22_1 RFC 2222 SASL (Simple Authentication and Security Layer)
cyrus-sasl-saslauthd-2.1.22
postfix-2.5.5,1
/etc/rc.conf

Код: Выделить всё

postfix_enable="YES"
saslauthd_enable="YES"
saslauthd_flags="-a pam"
Сертификаты для tls, естественно, создал.
Настраивал такую же конфигурацию месяца 2 назад, все работает до сих пор.
Кто в курсе что сделатть то ?

Re: Проблема с postfix + sasl

Добавлено: 2008-10-03 22:40:07
helloworld
postfix собран с

Код: Выделить всё

                                            ? ?[X] PCRE      Perl Compatible Regular Expressions               ? ?
                                            ? ?[X] SASL2     Cyrus SASLv2 (Simple Auth. and Sec. Layer)        ? ?
                                            ? ?[X] DOVECOT   Dovecot SASL authentication method                ? ?
                                            ? ?[ ] SASLKRB   If your SASL req. Kerberos select this option     ? ?
                                            ? ?[ ] SASLKRB5  If your SASL req. Kerberos5 select this option    ? ?
                                            ? ?[ ] SASLKMIT  If your SASL req. MIT Kerberos5 select this option? ?
                                            ? ?[X] TLS       Enable SSL and TLS support                        ? ?
                                            ? ?[ ] BDB       Berkeley DB (choose version with WITH_BDB_VER)    ? ?
                                            ? ?[ ] MYSQL     MySQL maps (choose version with WITH_MYSQL_VER)   ? ?
                                            ? ?[ ] PGSQL     PostgreSQL maps (choose with DEFAULT_PGSQL_VER)   ? ?
                                            ? ?[ ] OPENLDAP  OpenLDAP maps (choose ver. with WITH_OPENLDAP_VER)? ?
                                            ? ?[ ] CDB       CDB maps lookups                                  ? ?
                                            ? ?[ ] NIS       NIS maps lookups                                  ? ?
                                            ? ?[ ] VDA       VDA (Virtual Delivery Agent)                      ? ?
                                            ? ?[ ] TEST      SMTP/LMTP test server and generator               ? ?
                                          

Re: Проблема с postfix + sasl

Добавлено: 2008-10-04 0:37:11
wnd
helloworld писал(а):Какие то грабли непойму.
та мы тут уже боролись

Код: Выделить всё

http://forum.lissyara.su/viewtopic.php?f=20&t=11315
пока результата нет.
Собственно говоря у меня работает с dovecot :roll:

Вроде по доку с postfix в main.cf должна быть строчка smtpd_sasl_path = smtpd

может поможет :cf:

Re: Проблема с postfix + sasl

Добавлено: 2008-10-04 9:42:56
helloworld
Проблема решилась путем внимательного чтения документации на официальном сайте. http://www.postfix.com/postconf.5.html#smtpd_sasl_type

Код: Выделить всё

# SASL support
smtpd_sasl_type = cyrus
smtpd_sasl_path = smtpd
broken_sasl_auth_clients = yes
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_security_options = noanonymous

Re: Проблема с postfix + sasl

Добавлено: 2008-10-05 9:13:33
wnd
Спасибо, похоже не дочитал http://www.postfix.com/SASL_README.html
Как-то оно там немножко размазано написано.