将子域指向 Cloudfront 时连接不安全

Connection not secured when pointing a subdomain to Cloudfront

我有一个托管在外部服务器上的域名,我想使用 Cloudfront 将一个子域指向一个 S3 存储桶。

我已经能够将我的域指向我的 S3 存储桶(子域。s3.amazonaws.com)但它不是HTTPS 安全,这就是为什么我在 AWS 上创建了一个 SSL 证书,一个链接到我的 S3 存储桶的 CloudFront 分发,我指向我的子域(assets.example.com) 到我的 Cloudfront 域 (xxx.cloudfront.net).

但是现在,当我尝试访问我的子域时,出现以下错误:

我该如何解决这个问题?我的 Cloudfront 发行版是否配置错误?

https://aws.amazon.com/premiumsupport/knowledge-center/cloudfront-domain-https/ --> 建议您检查每一点(例如,您的 S3 存储桶名称中没有句号)

可能也值得检查密码的可比性:https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/secure-connections-supported-viewer-protocols-ciphers.html#secure-connections-supported-ciphers

您可能不会将 assets.example.com 添加到 CloudFront 的 CNAME/Alternate 域名字段。

CloudFront CNAME

另外,CloudFront 上需要一个主题为 assets.example.com 的证书。