4 ms·
> GCM's security falls to pieces That's an exaggeration. Reusing the nonce in GCM allows decryption of messages with the same nonce. It does NOT compromise the
by cyberax 3y ago
> GCM's security falls to pieces
That's an exaggeration. Reusing the nonce in GCM allows decryption of messages with the same nonce. It does NOT compromise the key.
- idorosen 3y agoAllowing decryption of the messages sounds like falling to pieces to me...
- cyberax 3y agoMessages with duplicate nonces. Recovery of the authentication key may also allow message forgery (although it won't allow decryption).
- nmadden 3y agoMessage forgery does quite often lead to decryption actually - google “chosen ciphertext attack”.
- cyberax 3y agoNone of the modern symmetric ciphers are susceptible to chosen ciphertext attacks.
- nmadden 3y agoSay what now? GCM is itself vulnerable to CCA in a nonce reuse scenario - exactly the subject of this thread. Not to mention padding oracle attacks against CBC mode etc. Almost all modern symmetric ciphers achieve CCA security by combining the cipher with a MAC to create an AEAD mode. So if your AEAD mode gives up the MAC subkey, as GCM does under nonce reuse, then you lose all CCA security, and usually starting leaking details about plaintexts not long after.
- cyberax 3y agoSigh. If you're talking about crypto, then terms actually matter. GCM is not a symmetric cipher. It's a cipher mode. You can use GCM with any block cipher. OK, I assume that you meant AES-GCM. But GCM as a construction in itself is not vulnerable to chosen ciphertext attacks, as long as the underlying symmetric cipher is secure. GCM will lose the authentication property, if you know the authentication key, which you _might_ be able to get if you can mount a chosen _plaintext_ attack under conditions of nonce reuse. Simply getting a couple of random messages with the same nonce is NOT enough. AES-GCM as specified has a nonce that is large enough to not care about it in practical cases (e.g. TLS), and it can become a problem only in very unrealistic cases (attacker-controlled likely exabyte-sized plaintexts). These cases are maybe _juuuust_ in the realm of possibility, if you have access to a supercomputer, and you want to specifically design an application that is vulnerable to an attack, and then allow your adversary to covertly connect to your supercomputer cluster. To be clear, we're talking here about repurposing the entire NSA computing and storage power to host this single application, and allowing the attacker (e.g. Russian troll farms) to completely control the plaintexts that it transmits. Extending the nonce to 256 bits would move that from outside the realm of possibility even for a contrived scenario. It's not a bad idea, but it's also not at all an urgent one.
- deleted 3y ago[deleted]
- nmadden 3y ago> Simply getting a couple of random messages with the same nonce is NOT enough. Yes it is. You simply XOR the two auth tags and then compute the roots of the resulting polynomial (with known coefficients). There typically aren’t that many candidate roots to test. This has been known since GCM was first specified, see eg Joux’s comments: https://csrc.nist.gov/csrc/media/projects/block-cipher-techniques/documents/bcm/comments/800-38-series-drafts/gcm/joux_comments.pdf https://csrc.nist.gov/csrc/media/projects/block-cipher-techn... It’s clear from your comments here and elsewhere that you don’t know what you are talking about, so I’ll take tptacek’s advice and bow out here.
- tptacek 3y ago
- tptacek 3y agohttps://cryptopals.com/sets/8/challenges/63.txt https://cryptopals.com/sets/8/challenges/63.txt
- cyberax 3y agoYes, and? It allows recovery of the authentication key, but not the source AES key. The authentication key is _derived_ from the AES key, but they're not the same.
- tptacek 3y agoI don't think you can walk back your previous comment, which was pretty categorical. Either way, we're clear about the brittleness of GCM at this point, and there's little else for us to talk about.
- cyberax 3y agoBrittleness? Not really. It's not completely future-proof, and it would be easier if a larger nonce is standardized, but all realistic attacks require rather unlikely sets of circumstances. And no, you can't recover the encryption key (i.e. the thing that allows you to decrypt messages) from any weakness in the nonce choice.
- tptacek 3y agohttps://www.usenix.org/conference/woot16/workshop-program/presentation/bock https://www.usenix.org/conference/woot16/workshop-program/pr... I think you should stop digging. Sean and Hanno gave a Black Hat talk whose slides were unwillingly hosted on a GCHQ website because of this problem.
- cyberax 3y ago[flagged]
- 3y ago