r/ComputerSecurity • u/tjthomas101 • Jun 15 '23
Why do we really need intermediate certificates and the chain of trust?
in SSL, I get that we need a chain of trust and root certificate is self-signed. But I still can't grasp why do we REALLY need it? Because aren't intermediate certificates are also issued by the same CA as root? Thus, does it make a difference if root just signs the SSL certs?
12
Upvotes
View all comments
Show parent comment
2
u/opperior Jun 16 '23
If the root is leaked, then it means that anyone could make a cert that looks like you made it. The trust is gone. Imagine if anyone could make a genuine Microsoft cert or Google cert or Facebook cert. No one could be sure that the site they visit, the program they are running, the email they received actually came from the company it claims to be from. As an example, drivers can't be installed on a Windows system unless it's signed by Microsoft or a trusted third party, but if anyone can sign any driver, then rootkits would become trivial to produce.
That means every certificate made by that root, and every certificate made my the intermediate certificates made by that root, are all essentially invalid. They must all be revoked, a new root certificate created, and then all the other certificates re-issued. A nightmare. No, an intermediate certificate can't save you here.
But if it's an intermediate certificate that gets leaked, much less hassle. You can make a new one from the root certificate, revoke the compromised intermediate certificate, then re-sign the previously issued certificates with the new intermediate certificate. You can do this because the root certificate is still trusted.
Thus the root certificate only comes out of hiding when a new intermediate certificate is needed. The rest of the time it is stored in a vault, inaccessible to any internet connected system, and only trusted people are allowed to take it out.