tests: More ieee802_11_parse_elems() coverage for new elements

Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
Jouni Malinen 2016-12-26 00:48:34 +02:00
parent 09af451bd0
commit 901e6fabcb

View File

@ -53,6 +53,31 @@ static const struct ieee802_11_parse_test_data parse_tests[] = {
18, ParseOK, 9 },
{ (u8 *) "\x8b\x00", 2, ParseOK, 1 },
{ (u8 *) "\xdd\x04\x00\x90\x4c\x04", 6, ParseUnknown, 1 },
{ (u8 *) "\xed\x00", 2, ParseOK, 1 },
{ (u8 *) "\xef\x00", 2, ParseOK, 1 },
{ (u8 *) "\xef\x01\x11", 3, ParseOK, 1 },
{ (u8 *) "\xf0\x00", 2, ParseOK, 1 },
{ (u8 *) "\xf1\x00", 2, ParseOK, 1 },
{ (u8 *) "\xf1\x02\x11\x22", 4, ParseOK, 1 },
{ (u8 *) "\xf2\x00", 2, ParseOK, 1 },
{ (u8 *) "\xff\x00", 2, ParseUnknown, 1 },
{ (u8 *) "\xff\x01\x00", 3, ParseUnknown, 1 },
{ (u8 *) "\xff\x01\x01", 3, ParseOK, 1 },
{ (u8 *) "\xff\x02\x01\x00", 4, ParseOK, 1 },
{ (u8 *) "\xff\x01\x02", 3, ParseOK, 1 },
{ (u8 *) "\xff\x04\x02\x11\x22\x33", 6, ParseOK, 1 },
{ (u8 *) "\xff\x01\x04", 3, ParseOK, 1 },
{ (u8 *) "\xff\x01\x05", 3, ParseOK, 1 },
{ (u8 *) "\xff\x0d\x05\x11\x22\x33\x44\x55\x55\x11\x22\x33\x44\x55\x55",
15, ParseOK, 1 },
{ (u8 *) "\xff\x01\x06", 3, ParseOK, 1 },
{ (u8 *) "\xff\x02\x06\x00", 4, ParseOK, 1 },
{ (u8 *) "\xff\x01\x07", 3, ParseOK, 1 },
{ (u8 *) "\xff\x09\x07\x11\x22\x33\x44\x55\x66\x77\x88", 11,
ParseOK, 1 },
{ (u8 *) "\xff\x01\x0c", 3, ParseOK, 1 },
{ (u8 *) "\xff\x02\x0c\x00", 4, ParseOK, 1 },
{ (u8 *) "\xff\x01\x0d", 3, ParseOK, 1 },
{ NULL, 0, ParseOK, 0 }
};