バウンスメールに対する SMTP 応答の設定

バウンスメールに対する SMTP 応答の設定

良い一日、

メール サーバーの場合、メール サーバーが送信するすべてのバウンス メールを読む必要があります。バウンスが発生すると、550 メールボックスが見つからないなどの SMTP エラー応答を含む応答が返されます。

たとえば、電子メール アドレスがルーティング不可能な場合など、自分の SMTP サーバーから送信された電子メールが返送される場合には、必ずしもこのようになるわけではありません。非常に簡潔な応答コードが返され、まったく応答コードが返されないこともあります。

アップデート

バウンスメールの例:

This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

  [email protected]
    SMTP error from remote mail server after RCPT TO:<[email protected]>:
    host mx4.hotmail.com [65.55.33.135]: 550 Requested action not taken:
    mailbox unavailable


  ------ This is a copy of the message, including all the headers. ------

もう一つの例:

This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

  [email protected]


------ This is a copy of the message, including all the headers. ------

ご覧のとおり、myowndomain.com から送信されたメールには空の応答があります。メールボックスが見つからないため、両方ともバウンスしています。

私の質問は、myowndomain.com のメール サーバーが、バウンス メールの応答コードを生成する際に、より詳細な情報を提供することは可能でしょうか。可能であれば、Exim や Postfix、その他の SMTP ソフトウェアでこれをどのように設定すればよいでしょうか。

答え1

まだ試していない場合は、Postfix を試してみてください。デフォルトでは、詳細なバウンス メッセージが送信されます (hotmail と同様)。

さらにPostfixを設定してカスタムバウンスメッセージを送信することもできます http://www.postfix.org/bounce.5.html

無効な受信者に対する私の Postfix サーバーの応答:

This is the mail system at host mail.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

               The mail system

<[email protected]>: unknown user: "fakeuser"

関連情報