尝试连接到我的 postfix 服务器时出现“503 5.5.1 错误:未启用身份验证”

edo*_*tan 4 postfix centos saslauthd dyndns sasl

我有以下几点:

postfix-2.10.1-6.el7.x86_64
cyrus-sasl-lib-2.1.26-17.el7.x86_64
cyrus-sasl-plain-2.1.26-17.el7.x86_64
cyrus-sasl-2.1.26-17.el7.x86_64
Run Code Online (Sandbox Code Playgroud)

我的 postconf -n 是:

   alias_database = hash:/etc/aliases
   alias_maps = hash:/etc/aliases
   command_directory = /usr/sbin
   config_directory = /etc/postfix
   daemon_directory = /usr/libexec/postfix
   data_directory = /var/lib/postfix
   debug_peer_level = 2
   debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin ddd         $daemon_directory/$process_name $process_id & sleep 5
  html_directory = no
  inet_interfaces = all
  inet_protocols = all
  mail_owner = postfix
  mailq_path = /usr/bin/mailq.postfix
  manpage_directory = /usr/share/man
  mydestination = $myhostname, localhost.$mydomain, localhost
  newaliases_path = /usr/bin/newaliases.postfix
  queue_directory = /var/spool/postfix
  readme_directory = /usr/share/doc/postfix-2.10.1/README_FILES
  relayhost = smtp.dynect.net:25
  sample_directory = /usr/share/doc/postfix-2.10.1/samples
  sendmail_path = /usr/sbin/sendmail.postfix
  setgid_group = postdrop
  smtp_sasl_auth_enable = yes
  smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
  unknown_local_recipient_reject_code = 550
Run Code Online (Sandbox Code Playgroud)

我的 /etc/sysconfig/saslauthd 有:

SOCKETDIR=/run/saslauthd
MECH=pam
FLAGS=
Run Code Online (Sandbox Code Playgroud)

我的 /etc/sasl2/smtpd.conf 有:

pwcheck_method: saslauthd
mech_list: plain login    
Run Code Online (Sandbox Code Playgroud)

当我尝试从远程服务器登录时,出现以下错误:

telnet 10.65.60.23 25
Trying 10.65.60.23...
Connected to 10.65.60.23.
Escape character is '^]'.
220 jira.radwarecloud.com ESMTP Postfix
EHLO local.domain.name
250-jira.radwarecloud.com
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
auth login
503 5.5.1 Error: authentication not enabled
Run Code Online (Sandbox Code Playgroud)

我在这里错过了什么???谢谢!埃拉德。

mas*_*oeh 5

要在通过接收电子邮件smtpd时启用 SASL ,您需要将此参数

smtpd_sasl_auth_enable = yes
Run Code Online (Sandbox Code Playgroud)

要在通过发送电子邮件smtp时启用 SASL ,您需要将此参数

smtp_sasl_auth_enable = yes
Run Code Online (Sandbox Code Playgroud)

postconf上面的输出中,您只放置了smtp_sasl_auth_enablenot smtpd_sasl_auth_enable。这就是 postfix 抱怨错误的原因

错误:未启用身份验证


Til*_*idt 2

AUTH 不是基本 SMTP 的一部分,而是 ESMTP 的一部分。因此,为了使用 AUTH,您需要使用 EHLO 而不是 HELO 启动 SMTP 会话。