Postfix 554 :中继访问被拒绝

Postfix 554 :中继访问被拒绝

我正在尝试设置 postfix,但遇到了一些问题……以下是我的文件

vim /etc/postfix/main.cf

relayhost = [smtp.gmail.com]:587
smtp_connection_cache_destinations = smtp.gmail.com
smtp_sasl_auth_enable=yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_tls_security_options = noanonymous
tls_random_source = dev:/dev/urandom
smtp_tls_CAfile= /etc/pki/CA/cacert.pem
smtp_tls_security_level = may
smtp_tls_scert_verifydepth = 9


append_dot_mydomain = no
readme_directory = no

myhostname = maggie.deliverypath.com
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = maggie.deliverypath.com, localhost.deliverypath.com, , localhost
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all

我也有 Gmail 密码信息

 vim /etc/postfix/sasl_passwd

 gmail-smtp.l.google.com [email protected]:somepass
 smtp.gmail.com [email protected]:somepass

然后我尝试遵循这个文章我得到了这个输出

telnet mail.demoslice.com 25
Trying 67.207.128.80...
Connected to www.slicehost.com.
Escape character is '^]'.
220 www.slicehost.com ESMTP Postfix (Ubuntu)
HELO test.demoslice.com
250 www.slicehost.com
MAIL FROM:<[email protected]>
250 Ok
RCPT TO:<[email protected]>
554 <[email protected]>: Relay access denied

它开始了

service postfix start
 * Starting Postfix Mail Transport Agent postfix
...done.

然后屏幕冻结了,我什么也做不了......有什么想法吗?

答案1

看起来您正在针对 mail.demoslice.com 进行测试。请尝试针对您自己的邮件服务器进行测试 :)

另外,我不知道你的意思then the screen gets frozen and i cant do anything....

答案2

鉴于您没有进行任何身份验证,除非您从 my_network 主机之一连接,否则中继访问将被拒绝。因此 telnet localhost 25 将获得进一步的帮助,或者使用 rcpt 来[电子邮件保护]服务器上有

相关内容