一个 IP 上的虚拟主机是否可以使用 SSL?

发布于 2024-10-22 03:13:24 字数 173 浏览 1 评论 0原文

一个被赞成的答案声称:

<块引用>

[SSL] 破坏了基于名称的虚拟主机。使用 SSL,它就是一个站点 - 一个 IP 地址。

这是真的吗?提供 SSL 证书的共享主机是否会租用整个 IP 范围?

An upvoted SO answer claims:

[SSL] breaks name based virtual hosting. With SSL, it's one site - one IP address.

Is that true? Does shared hosting that offers SSL certificates lease whole IP ranges?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

风和你 2024-10-29 03:13:24

使用 SSL,服务器始终在发送应用程序数据之前进行身份验证。 HTTP 请求的“Host”标头是应用程序数据。因此,一般来说,您不能将 HTTPS 与虚拟主机一起使用。

但是,如果一方控制虚拟托管的所有站点,则可以创建一个证书,其中列出了“主题备用名称”扩展中的所有虚拟主机名。需要强调的是,由于只有一对密钥,因此使用单个私钥来验证所有主机。该密钥应由单一所有者控制。

另外,Sripathi Krishnan 指出有TLS 扩展(当前 RFC 6066 中指定)允许浏览器在第一次握手完成之前向服务器提示要显示哪个服务器证书。但是,此扩展并未得到普遍支持。

With SSL, the server is always authenticated before application data is sent. The "Host" header of the HTTP request is application data. So, in general, you can't use HTTPS with virtual hosting.

However, if one party controls all of the sites that are hosted virtually, a single certificate can be created that lists all of the virtual host names in the "subject alternative name" extension. To emphasize, since there is only one key pair, a single private key is used to authenticate all of the hosts. This key should be controlled by a single owner.

Alternatively, Sripathi Krishnan pointed out that there is a TLS extension (currently specified in RFC 6066) that allows the browser to hint to the server which server certificate to present before the first handshake is completed. However, this extension is not universally supported.

梦开始←不甜 2024-10-29 03:13:24

如果您查看 A2Hosting SSL 服务,您会发现除了共享主机之外,它们还要求您拥有专用 IP 地址,仅此而已。
所以是的,只要您维护一个专用的 IP 地址,您就可以获得 ssl 证书。

http://www.a2hosting.com/services/ssl-hosting

If you look at A2Hosting SSL services, they require you to have a dedicated IP address besides shared hosting and that's it.
So yes, as long as you maintain a dedicated IP address you can obtain an ssl certificate.

http://www.a2hosting.com/services/ssl-hosting

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文