amazon-web-services - 在 AWS ELB 实例中终止 SSL

标签 amazon-web-services ssl amazon-elb pki

我需要在 AWS ELB 实例上终止 SSL。 IT/Ops 向我提供了一个包含以下内容的 ZIP 文件:

  • DigiCertCA2.pem
  • TrustedRoot.pem
  • wildcard_example_com.crt
  • wildcard_example_com.csr
  • wildcard_example_com.key
  • wildcard_example_com.pem

(实际上域显然不是 example.com ;但这是我们自己域的通配符证书。)

根据ELB/SSL docs :

If you have a certificate ready to upload, select Upload a new SSL Certificate to AWS Identity and Access Management (IAM). Enter the name of the certificate. In Private Key, copy and paste the contents of the private key file (PEM-encoded). In Public Key Certificate, copy and paste the contents of the public key certificate file (PEM-encoded). In Certificate Chain, copy and paste the contents of the certificate chain file (PEM-encoded), unless you are using a self-signed certificate and it's not important that browsers implicitly accept the certificate.

但是,我不确定哪个证书是“证书链文件”,或者是否有必要。我相信这些证书是由根/受信任的 CA 签署的(不是自签名的)。

我不喜欢是在 Web 控制台还是在 AWS CLI 工具中执行此操作,但是我需要对我的特定文件执行哪些步骤/操作才能使用 SSL 正确配置 ELB?

最佳答案

首先,不要通过旧的 IAM 服务方法执行此操作,使用新的 AWS ACM 服务来管理证书。 ACM 服务也有一个很好的 Web 界面来执行此操作。

您从中获得证书的公司应该能够告诉您哪个文件是链文件,是的,如果您希望浏览器正确地将您的 SSL 证书视为有效,则需要链文件。我做了一些搜索,找到了 this blog post其中讨论了在 AWS 中使用 Digicert 证书。看起来你的文件如下:

  • wildcard_example_com.key = 私钥文件
  • wildcard_example_com.crt = 公钥文件
  • DigiCertCA2.pem 和 TrustedRoot.pem 合并 = 证书链

关于amazon-web-services - 在 AWS ELB 实例中终止 SSL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40530052/

相关文章:

amazon-web-services - 如何在 AWS ELB 日志中获取完整的 POST 正文?

amazon-web-services - 将自定义 CloudFormation 资源替换为官方资源

amazon-web-services - Mesos、Marathon、云和 10 个数据中心——如何相互交流?

java - 使用存储类 Glacier 访问 S3 对象

javascript - Keystone JS : localhost is not in the certs altnames

ruby-on-rails - Rails s3 桶 SSL

amazon-web-services - 如果我从前端代理所有连接,是否需要在后端安装 SSL?

使用自定义 keystore .jks 文件和密码的 SSL 连接并将请求发送到 URL

amazon-web-services - 在 AWS EC2 负载均衡器上安装通配符证书

amazon-ec2 - 使用用户定义的参数来控制 AWS ELB 实例的自动扩展