fix nonce usage in the AEAD, use the AEAD provided by qtls for Initials

This commit is contained in:
Marten Seemann
2019-01-06 10:56:33 +07:00
parent 2cb72ad098
commit b4356d7348
6 changed files with 23 additions and 49 deletions

View File

@@ -250,6 +250,11 @@ func aeadAESGCM12(key, fixedNonce []byte) cipher.AEAD {
return ret
}
// AEADAESGCM13 creates a new AES-GCM AEAD for TLS 1.3
func AEADAESGCM13(key, fixedNonce []byte) cipher.AEAD {
return aeadAESGCM13(key, fixedNonce)
}
func aeadAESGCM13(key, fixedNonce []byte) cipher.AEAD {
aes, err := aes.NewCipher(key)
if err != nil {