-1

Please correct me if I'm mistaken, but I've reached the conclusion that CA-signed certificates in the current Internet Public Key Infrastructure do not add any more security compared to servers providing self-signed certificates or raw public keys and clients performing no certificate validation.

CA-signed certificates are supposed to provide authenticity of the server. When the client validates the certificate back to a trusted root CA certificate, the client can be reasonably sure he can establish a communication channel visible only to the entity possessing the private key of the certificate (confidentiality and integrity), AND that the entity possessing the private key also controls the domain name listed in the certificate (authenticity).

One type of attack that TLS/PKI seem to focus on and claim to counter is the man-in-the-middle attack. Assuming an adversary has the ability to send/receive packets to/from an address that is not his (the whole point of using TLS/PKI in the first place), this adversary can easily "prove" to a trusted CA that he controls a domain that he does not actually control the DNS entries for.

For example in the ACME protocol, the adversary can simply complete challenges while impersonating the IP of the domain in question, and obtain a certificate from a trusted CA like LetsEncrypt. Any capable adversary can do this at any time, and the actual domain owner is completely unaware. Even if the domain under attack has an EV certificate, the adversary can provide the illegitimately obtained DV certificate, and the connection will proceed without errors (and display a secure padlock in web browsers, for example).

TLS with no certificate validation could still be used for confidentiality and integrity for some server of uncertain authenticity, but since certificates don't provide authenticity anyway, what is the actual point of the additional overhead of certificates in the first place?

10
  • This is like saying that because you could die in a car accident even while using a seat belt, using seat belts is pointless. May 8, 2021 at 5:49
  • 1
    If I find out that my seatbelt is broken, I'm going to complain that using it is pointless. May 8, 2021 at 8:11
  • 1
    A certain aspect of it is, as I've explained as well. But considering how you don't actually address any specific points I make, you only read a few keywords and reach your own conclusions, nothing I ever say will influence your opinion I guess. May 8, 2021 at 8:35
  • 1
    You are claiming that "Internet Public Key Infrastructure do not add any more security compared to servers providing self-signed certificates" given it's not completely flawless, because there might be a problem under very specific conditions i.e. someone gaining MitM position on the server side. Having some PKI compared to not having a PKI at all (which you suggest as the alternative) still has huge security benefits. May 8, 2021 at 8:50
  • 1
    The only reason to use any cryptography in the first place is because of MitM between the server and client. It's not "just a problem under very specific conditions". Someone who is capable of MitM, if they exist, can very easily obtain a certificate from LetsEncrypt, and can therefore act as a CA-validated HTTPS server for the domain it targeted. I agree that usually MitM's do not happen. Then again, MitM's usually don't happen for unencrypted plaintext either. Yet why do we use TLS? Because it can happen, albeit rare. CA validation is just a step that does effectively nothing. May 8, 2021 at 8:57

1 Answer 1

4

One type of attack that TLS/PKI seem to focus on and claim to counter is the man-in-the-middle attack. Assuming an adversary has the ability to send/receive packets to/from an address that is not his (the whole point of using TLS/PKI in the first place), this adversary can easily "prove" to a trusted CA that he controls a domain that he does not actually control the DNS entries for.

You kind of assuming an adversary here with universal access to arbitrary infrastructure and the ability to fake arbitrary source IP address or hijack arbitrary connections at any time. Such broad capabilities are not common, very expensive to obtain and are usually only possible for a few well-financed government agencies with deeper ties to infrastructure providers, if at all.

The typical attacker just sits at the local WiFi hotspot or maybe at the level of the ISP serving their home customers. In this case the attacker can only MITM a few connections, i.e. typically only the connections from some mobile or desktop users accessing web sites or retrieving their mail. This kind of access does not allow it to hijack or fake the connections between the server and the CA which is used an domain validation of certificates.

... but since certificates don't provide authenticity anyway

I agree that the system is not perfect, i.e. short take overs of a domain, compromising the server side of the website to grab the certificates and keys or DNS cache pollution affecting CA happend in the past. But while these should be considered a risk the system itself usually works, i.e. it provides no perfect trust but much more trust than a blindly accepted self-signed certificate.

But even a blindly accepted self-signed certificate provides more trust than no certificate at all, because it makes it possible to detect if the server has changed (different certificate). This is the idea behind Trust on First Use (TOFU).

In summary, certificate provide security: self-signed certificates provide more security than no certificates, and certificates issued by publicly trusted CA provide more security than self-signed certificates. None of this is provides perfect security though.

7
  • In the ACME protocol, the "http-01" challenge uses unencrypted port 80 HTTP to validate ownership of a domain. So, do unencrypted port 80 MitM attacks require "broad capabilities that are not common, very expensive to obtain and only possible for few agencies"? I understand the typical WiFi hotspot hacker probably can't do that sort of thing, but my assumption was that protocols like TLS were only made because of that exact type of MitM attack being at least fairly possible. I'm on board with a TOFU approach, I just think CA validation is a false sense of added security. May 8, 2021 at 8:09
  • 1
    @CinoltYuklair: The hard part is being able to MITM the relevant part of the infrastructure first. This is not as trivial as doing MITM attacks in a open WiFi hotspot. And the attacker needs to be either being able to MITM large part of the internet or be near the specific server (like: on the server) since the ACME challenge is checked from multiple places. And again: it is not perfect, but it is much better than blindly trusting self-signed certificates. May 8, 2021 at 9:51
  • 1
    @CinoltYuklair: "...my assumption was that protocols like TLS were only made because of that exact type of MitM attack being at least fairly possible ..." - TLS was not made to address only the hard to do attacks. It had to address the easy attacks first, since there was nothing what protected from these. The less trusted networks are usually where the client is and attacks there are more easy and common. TLS handles this part well. Attacks in data centers, ISP level etc are much harder and also much harder to be hidden long term. May 8, 2021 at 10:00
  • 1
    So essentially, the answer is just "don't worry about MitM's between servers and CA's because they just don't happen that often". What if the server is hosted on a residential internet? I'm guessing residential internets are more prone to MitM than data centers so residential servers shouldn't host TLS-based servers? I don't know exactly how that determination can be made case-by-case but OK. I guess confidence in certificate validity is based on an ad-hoc determination that an MitM could not happen in certificate issuance. May 8, 2021 at 10:21
  • Security isn't a single technology, but a collection of risk-based measurements and practices. The TLS PKI isn't meant to solve every problem there exists, but it's rather one of the tools. Hosting a server at home isn't only prone to MitM, but one could also easily tamper the hardware while you were buying groceries. TLS doesn't save anyone from opsec failures. But not using it guarantees the failure. May 8, 2021 at 10:32

Not the answer you're looking for? Browse other questions tagged .