Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests: tls: add missing AES256-GCM cipher

Add tests for TLSv1.2 and TLSv1.3 with AES256-GCM cipher

Signed-off-by: Vadim Fedorenko <vfedorenko@novek.ru>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Vadim Fedorenko and committed by
Jakub Kicinski
13bf99ab d76c51f9

+18
+18
tools/testing/selftests/net/tls.c
··· 32 32 struct tls12_crypto_info_sm4_gcm sm4gcm; 33 33 struct tls12_crypto_info_sm4_ccm sm4ccm; 34 34 struct tls12_crypto_info_aes_ccm_128 aesccm128; 35 + struct tls12_crypto_info_aes_gcm_256 aesgcm256; 35 36 }; 36 37 size_t len; 37 38 }; ··· 67 66 tls12->len = sizeof(struct tls12_crypto_info_aes_ccm_128); 68 67 tls12->aesccm128.info.version = tls_version; 69 68 tls12->aesccm128.info.cipher_type = cipher_type; 69 + break; 70 + case TLS_CIPHER_AES_GCM_256: 71 + tls12->len = sizeof(struct tls12_crypto_info_aes_gcm_256); 72 + tls12->aesgcm256.info.version = tls_version; 73 + tls12->aesgcm256.info.cipher_type = cipher_type; 70 74 break; 71 75 default: 72 76 break; ··· 283 277 { 284 278 .tls_version = TLS_1_3_VERSION, 285 279 .cipher_type = TLS_CIPHER_AES_CCM_128, 280 + }; 281 + 282 + FIXTURE_VARIANT_ADD(tls, 12_aes_gcm_256) 283 + { 284 + .tls_version = TLS_1_2_VERSION, 285 + .cipher_type = TLS_CIPHER_AES_GCM_256, 286 + }; 287 + 288 + FIXTURE_VARIANT_ADD(tls, 13_aes_gcm_256) 289 + { 290 + .tls_version = TLS_1_3_VERSION, 291 + .cipher_type = TLS_CIPHER_AES_GCM_256, 286 292 }; 287 293 288 294 FIXTURE_SETUP(tls)