Now that several quantum-resistant asymmetric algorithms are in the process of being standardized (or indeed are already standardized), and Google has integrated the recently standardized ML-KEM algorithm into their BoringSSL library (which I understand is used by Chrome desktop) - have any Hybrid Encryption Schemes been formally (or informally) defined which implement them?
I've been experimenting with ML-KEM and I understand it as follows...
- Alice generates a
ML-KEMkey pair, resulting inaliceSecretKeyandalicePublicKey. And makesalicePublicKeyavailable to anyone who wants it. - Bob wants to send a private message to Alice, so he starts be obtaining
alicePublicKey - Bob
encapsulatesalicePublicKey, which producesmlKemcipherText, andbobSharedKey - Bob encrypts his message to Alice, using some AEAD scheme like AES-GCM, with
bobSharedKeyas the symmetric key, and prependingmlKemcipherTextto the output, as well as specifyingmlKemcipherTextas the AAD (additional associated data) when encrypting.
So the final pseudocode would look something like:
cipherText = AESGCMEncrypt(data: message, key: bobSharedKey, nonce: randomNonce, aad: mlKemcipherText)
And the final output would be something like:
finalCipherText = mlKemcipherText | nonce | cipherText
Alice then receives finalCipherText from Bob:
- Alice removes
mlKemcipherTextand thenoncefrom the leading bytes offinalCipherText(based on the length of each) - Alice
decapsulatesmlKemcipherTextwithaliceSecretKey, which producesaliceSharedKey(which matchesbobSharedKey)
Alice then decrypts the bytes which remain of mlKemcipherText, with:
clearText = AESGCMDecrypt(data: mlKemcipherText, key: aliceSharedKey, nonce:nonce, aad: mlKemcipherText)
Alice knows that the message hasn't been tampered with, although she can't be sure that it came from Bob (but that's beyond the context of this question).
Does this scheme seem sound? Is there something I've overlooked? Is there a similar scheme which has been formalized which I can refer to?