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

unit: test-arc4: test RC4 both directions

Tests that the data both encrypts and decrypts.
This commit is contained in:
James Prestwood 2022-10-26 11:56:55 -07:00 committed by Denis Kenzior
parent 1f9d9e1eb1
commit 98b684b417

View File

@ -92,6 +92,8 @@ static void arc4_skip_test(const void *data)
assert(arc4_skip(test->key, 16, test->offset, buf, sizeof(buf), buf));
assert(!memcmp(buf, test->result, sizeof(buf)));
assert(arc4_skip(test->key, 16, test->offset, buf, sizeof(buf), buf));
assert(l_memeqzero(buf, 16));
}
int main(int argc, char *argv[])