4 ms·
Not thwarted exactly, but the problem is that the question "Is this certificate still good?" has three possible answers: 1. "Yes, it's still good" 2. "No, it'
by tialaramex 7y ago
Not thwarted exactly, but the problem is that the question "Is this certificate still good?" has three possible answers:
1. "Yes, it's still good"
2. "No, it's revoked"
3. "There was a network problem so I'm not sure"
Of course bad guys who know you'd get answer 2 can most likely ensure you have answer 3 instead. So the only safe thing to do is treat 2 and 3 the same. If we're not sure this certificate is fine then it's not fine. But in practice answer 3 is common anyway. For some users it may happen essentially all the time. So browser vendors don't like to treat 2 and 3 the same, even though that's the only safe option and that can thwart the effectiveness of revocation.
There's definitely further opportunity for improved tooling here. Perhaps this incident will drive it (Let's Encrypt's sheer volume can help in this way).
- willglynn 7y agoOCSP is a request/response protocol intended to answer certificate validity questions. It works as you describe, and failures cannot be treated as errors. An attacker who stole a certificate can use it even after revocation by blocking access the relevant OCSP responder. https://tools.ietf.org/html/rfc2560 https://tools.ietf.org/html/rfc2560 OCSP stapling is a mechanism by which a TLS server can make OCSP requests ahead of time and serve the response in-band. TLS clients get a certificate signed by the CA as usual, as well as a recent OCSP response signed by the CA attesting to its continued validity. OCSP stapling allows TLS clients like browsers to know a certificate's revocation status without having to make an extra request, but it changes nothing for an attacker who stole a certificate since they can simply not use it. https://tools.ietf.org/html/rfc6066#section-8 https://tools.ietf.org/html/rfc6066#section-8 OCSP Must Staple is an option that can be included on a certificate stating "I promise to use OCSP stapling". An attacker who stole a "must staple" certificate can either include an OCSP response indicating the certificate is revoked, or they can omit an OCSP response which the TLS client will treat as a hard error. https://tools.ietf.org/html/rfc7633 https://tools.ietf.org/html/rfc7633 In short, RFC 7633 makes certificate revocation work. Web browsers and web servers support this today. If you use Let's Encrypt's `certbot`, pass it `--must-staple`.
- tialaramex 7y agoIf you have Must Staple but don't have monitoring in place to detect that your OCSP responses are growing stale before they expire (or worse, you use Apache HTTPD which will happily replace a GOOD OCSP response with a newer BAD one) then you'd still be screwed here when Let's Encrypt revokes certificates. You need at least effective monitoring and a good OCSP stapling implementation (IIS is supposedly pretty good at this) or else stapling is sadly going to make life worse for you not better.
- wbond 7y agoSo in the case that revocation now works, why is there a continued push to shorten certificate lifetimes?
- pfg 7y agoMultiple reasons: 1. Firefox remains the only mainstream browser to support OCSP Must Staple. 2. OCSP Must Staple does not cover all threat models: if an attacker gains the ability to temporarily issue certificates for the victim's domain (rather than obtaining the private key of an existing certificate), they can request a certificate without the OCSP Must Staple extension. A more effective method would be something like the Expect-Staple header[1] (in enforce mode). 3. It allows the ecosystem to move significantly faster. In a world where all certificates expire after 3 months, phasing out insecure hash algorithms (in certificates) would no longer take many years. 4. It encourages regular key rotation (even if it's not enforced) [1]: https://scotthelme.co.uk/designing-a-new-security-header-expect-staple/ https://scotthelme.co.uk/designing-a-new-security-header-exp...