CentOS サーバー構築マニュアル

home > CentOS5 > Postfix OP25B対策

Postfix OP25B対策




■認証方法の確認
[root@ns1 ~]# telnet プロバイダのSMTPサーバー 25
Trying xxx.xxx.xxx.xxx...
Connected to SMTPサーバー (xxx.xxx.xxx.xxx).
Escape character is '^]'.
220 SMTPサーバー ESMTP
ehlo localhost
250-SMTPサーバー
250-AUTH LOGIN PLAIN ←認証方法を確認
250-PIPELINING
250 8BITMIME
quit
221 SMTPサーバー
Connection closed by foreign host.
※黄色い部分は環境に合わせて変更してください。

ヒント ヒント

プロバイダがOP25Bを実施している場合のみ設定してください。(固定IPの場合は不要)
認証方法には、LOGIN PLAIN の他に DIGEST-MD5 CRAM-MD5 などがあります。

■PostfixのOP25B ( Outbound Port 25 Blocking ) 対応
[root@ns1 ~]# vi /etc/postfix/main.cf

#relayhost = [an.ip.add.ress]
↓
relayhost = [プロバイダのSMTPサーバー]:587 ←コメント解除&変更

↓最終行に下記を追加
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/ispauth
smtp_sasl_security_options = noanonymous
smtp_sasl_mechanism_filter = login, plain
[root@ns1 ~]# vi /etc/postfix/ispauth
↓下記を記入
[プロバイダのSMTPサーバー]:587 プロバイダのユーザーID:プロバイダのパスワード
[root@ns1 ~]# chmod 640 /etc/postfix/ispauth [root@ns1 ~]# postmap /etc/postfix/ispauth [root@ns1 ~]# /etc/rc.d/init.d/postfix reload
※黄色い部分は環境に合わせて変更してください。

ヒント ヒント

プロバイダのSMTPサーバーとユーザーID、パスワードはプロバイダにお問い合わせください。
例)Yahoo!BBのSMTPサーバー:ybbsmtp.mail.yahoo.co.jp



Home PageTop Forum Last updated 2008-05-12

Copyright centos.server-manual.com このサイトはリンクフリーです。ご自由にリンクしてください。