将 Amazon SES 与 Microsoft Windows Server IIS SMTP 集成 - Amazon Simple Email Service

本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。

将 Amazon SES 与 Microsoft Windows Server IIS SMTP 集成

您可以将 Microsoft Windows Server 的 IIS SMTP 服务器配置为通过 Amazon SES 发送电子邮件。这些说明是使用 Microsoft Windows Server 2012 在 Amazon EC2 实例上编写的。您可以在 Microsoft Windows Server 2008 和 Microsoft Windows Server 2008 R2 上使用相同配置。

注意

Windows Server 是第三方应用程序,不由 Amazon Web Services 开发或支持。本节中的步骤仅供参考,如有变更,恕不另行通知。

将 Microsoft Windows Server IIS SMTP 服务器与 Amazon SES 集成
  1. 首先,使用以下说明设置 Microsoft Windows Server 2012。

    1. Amazon EC2 管理控制台中,启动新的 Microsoft Windows Server 2012 Base Amazon EC2 实例。

    2. 按照 Amazon EC2 Windows 实例入门中的说明,使用远程桌面连接到实例并登录。

    3. 启动服务器管理器控制面板。

    4. 安装 Web Server 角色。请确保包含 IIS 6 Management Compatibility tools (Web Server 复选框下的一个选项)。

    5. 安装 SMTP Server 特征。

  2. 接下来,使用以下说明配置 IIS SMTP 服务。

    1. 返回到服务器管理器控制面板。

    2. Tools 菜单中,选择 Internet Information Services (IIS) 6.0 Manager

    3. 右键单击 SMTP Virtual Server #1,然后选择 Properties

    4. Access 选项卡的 Relay Restrictions 下,选择 Relay

    5. Relay Restrictions 对话框中,选择 Add

    6. Single Computer 下,输入 127.0.0.1 作为 IP 地址。您现在已授予此服务器访问权限,以通过 IIS SMTP 服务将电子邮件中继到 Amazon SES。

      在此过程中,我们假定电子邮件是在此服务器上生成的。如果生成电子邮件的应用程序在其他服务器上运行,则您必须在 IIS SMTP 中为该服务器授予中继访问权限。

      注意

      要将 SMTP 中继扩展到私有子网,对于 Relay Restriction,请使用 Single Computer 127.0.0.1 和 Group of Computers 172.1.1.0 – 255.255.255.0 (在网络掩码部分中)。对于 Connection,请使用 Single Computer 127.0.0.1 和 Group of Computers 172.1.1.0 – 255.255.255.0 (在网络掩码部分中)。

  3. 最后,使用以下说明将服务器配置为通过 Amazon SES 发送电子邮件。

    1. 返回到 SMTP Virtual Server #1 Properties 对话框,然后选择 Delivery 选项卡。

    2. Delivery 选项卡上,选择 Outbound Security

    3. 选择 Basic Authentication(基本身份验证),然后输入您的 Amazon SES SMTP 凭证。您可以使用获取 Amazon SES SMTP 凭证中的过程从 Amazon SES 控制台获取这些凭证。

      重要

      您的 SMTP 凭证与您的 AWS 访问密钥 ID 和私有访问密钥不同。请勿尝试使用您的 AWS 凭据通过 SMTP 端点对自己进行身份验证。有关凭证的更多信息,请参阅Amazon SES 凭证的类型

    4. 确保已选中 TLS encryption

    5. 返回到 Delivery 选项卡。

    6. 选择 Outbound Connections

    7. Outbound Connections 对话框中,确保端口为 25 或 587。

    8. 选择 Advanced (高级)

    9. 对于 Smart host (智能主机) 名称,输入您将使用的 Amazon SES 端点(例如,email-smtp.us-west-2.amazonaws.com)。有关可用 Amazon SES AWS 区域 的终端节点网址列表,请参阅中的AWS 一般参考亚马逊简单电子邮件服务 (Amazon SES) Service。

    10. 返回到服务器管理器控制面板。

    11. 在服务器管理器控制面板上,右键单击 SMTP Virtual Server #1,然后重新启动该服务以选择新配置。

    12. 通过此服务器发送电子邮件。您可以检查邮件标头,以确认邮件已通过 Amazon SES 送达。