3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-11-22 06:29:23 +01:00

unit: Add test case #6 for RSNE parser

This commit is contained in:
Denis Kenzior 2015-01-15 22:03:50 -06:00
parent 7dd7ff7094
commit c8fb0b21f1

View File

@ -348,6 +348,21 @@ static const struct ie_rsne_info_test ie_rsne_info_test_5 = {
.akm_suites = IE_RSN_AKM_SUITE_8021X,
};
/* 802.11, Section 8.4.2.27.1; last example */
static const unsigned char rsne_data_6[] = {
0x30, 0x1a, 0x01, 0x00, 0x00, 0x0f, 0xac, 0x04, 0x01, 0x00, 0x00, 0x0f,
0xac, 0x04, 0x01, 0x00, 0x00, 0x0f, 0xac, 0x01, 0x80, 0x00, 0x00, 0x00,
0x00, 0x0f, 0xac, 0x06,
};
static const struct ie_rsne_info_test ie_rsne_info_test_6 = {
.data = rsne_data_6,
.data_len = sizeof(rsne_data_6),
.group_cipher = IE_RSN_CIPHER_SUITE_CCMP,
.pairwise_ciphers = IE_RSN_CIPHER_SUITE_CCMP,
.akm_suites = IE_RSN_AKM_SUITE_8021X,
};
static void ie_test_rsne_info(const void *data)
{
const struct ie_rsne_info_test *test = data;
@ -383,6 +398,8 @@ int main(int argc, char *argv[])
ie_test_rsne_info, &ie_rsne_info_test_4);
l_test_add("/ie/RSN Info Parser/Test Case 5",
ie_test_rsne_info, &ie_rsne_info_test_5);
l_test_add("/ie/RSN Info Parser/Test Case 6",
ie_test_rsne_info, &ie_rsne_info_test_6);
return l_test_run();
}