大网数据广告活动
服务器运维问答

Multiple domains with wrong SSL certificate on the load balancer

· 52CE 我爱测

Let me preface that I am not a load balancer expert, but I know that if you offload an SSL certificate on the load balancer you have multiple advantages. One of our clients wants to cache many websites through a CDN using SSL. Fo…

问题原文

原帖链接 · Francesco Gallarotti · CC BY-SA 3.0

Let me preface that I am not a load balancer expert, but I know that if you offload an SSL certificate on the load balancer you have multiple advantages.

One of our clients wants to cache many websites through a CDN using SSL. For the sake of argument, let's pretend the sites are https://siteone.com and https://sitetwo.com

They want to install on the load balancer a "wrong certificate" (for example a certificate with CN: origin.oursites.com) so that they don't have to continue to update the certificate every time that a new site is added to the CDN caching. They say that this can be done because the CDN allows for a mismatch of certificate.

My question, and it might be a stupid one, is the following: if the certificate don't match, how can the load balance decrypt each package and find out the exact URL that is being requested and figure out which servers should the package being sent to? What am I missing?

Can you please help me understand if this is really feasible and, if so, why does it work, please?

Thanks in advance, // Francesco

已采纳解答

原帖链接 · Håkan Lindqvist · CC BY-SA 3.0

First of all, regarding "if the certificate don't match, how can the load balance decrypt each package", it's rather the case that the validation of the certificate is a precondition to exchanging the (symmetric) encryption keys. If you remove the validation step (or parts of it) it makes it more likely that you succeed in establishing the encrypted connection, not the other way around.
The problem is that now you have a working encrypted connection, but you don't actually know who the other party is; it could be the party you tried to connect to but it could also be anyone else who was able to intercept your connection.

If the CDN allows a mismatched certificate at the origin, without any further qualifications, then that's horrible security practice.
This would allow for trivial man-in-the-middle attacks (as per above) as absolutely anyone can present a signed but mismatched certificate and be accepted as the origin.

If, however, the CDN has some other means of validating the origin certificate, such as pinning (recognizing the certificate itself rather than relying on the chain of trust + matching subject name) this one valid certificate used for these origins, and with that in place then ignoring the subject name, that would be fine as it wouldn't allow for anyone else's mismatched certificates to be accepted. It actually changes the validation to an overall much more strict model.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2017-06-04)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。