diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2021-04-21 21:22:18 -0600 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2021-04-22 00:02:45 -0600 |
commit | eb2d6d7d1479db283d2fcde7c5064a939036ae2a (patch) | |
tree | 953a4021ae4780a7e4325d284fc5defe6d3a2dd2 | |
parent | wg_noise: add selftest (diff) | |
download | wireguard-freebsd-eb2d6d7d1479db283d2fcde7c5064a939036ae2a.tar.xz wireguard-freebsd-eb2d6d7d1479db283d2fcde7c5064a939036ae2a.zip |
selftests: fixup headers
Also remove the stale entry from the TODO list.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
-rw-r--r-- | TODO.md | 1 | ||||
-rw-r--r-- | src/selftest/allowedips.c | 13 | ||||
-rw-r--r-- | src/selftest/cookie.c | 6 | ||||
-rw-r--r-- | src/selftest/counter.c | 6 |
4 files changed, 14 insertions, 12 deletions
@@ -7,7 +7,6 @@ - Work out `priv_check` from vnet perspective. (There's no `ns_capable()` on FreeBSD, just `capable()`, which makes it a bit weird for one jail to have permissions in another.) -- Port ratelimiter and counter [selftests](https://git.zx2c4.com/wireguard-linux/tree/drivers/net/wireguard/selftest). - Make code style consistent with one FreeBSD way, rather than a mix of styles. - Run ratelimiter gc in a properly scheduled manner. - Make sure noise state machine is correct. diff --git a/src/selftest/allowedips.c b/src/selftest/allowedips.c index 9678790..97011b0 100644 --- a/src/selftest/allowedips.c +++ b/src/selftest/allowedips.c @@ -1,17 +1,8 @@ -// SPDX-License-Identifier: GPL-2.0 -/* +/* SPDX-License-Identifier: MIT + * * Copyright (C) 2015-2021 Jason A. Donenfeld <Jason@zx2c4.com>. All Rights Reserved. */ -#include <sys/cdefs.h> -#include <sys/param.h> -#include <sys/types.h> -#include <sys/systm.h> -#include <sys/queue.h> -#include <sys/endian.h> -#include <netinet/in.h> -#include <net/radix.h> - #ifdef WG_ALLOWEDIPS_RANDOMIZED_TEST enum { NUM_PEERS = 2000, diff --git a/src/selftest/cookie.c b/src/selftest/cookie.c index ef92158..c24022e 100644 --- a/src/selftest/cookie.c +++ b/src/selftest/cookie.c @@ -1,3 +1,9 @@ +/* SPDX-License-Identifier: MIT + * + * Copyright (C) 2015-2021 Jason A. Donenfeld <Jason@zx2c4.com>. All Rights Reserved. + * Copyright (C) 2019-2021 Matt Dunwoodie <ncon@noconroy.net> + */ + #define MESSAGE_LEN 64 #define T_FAILED_ITER(test) do { \ printf("%s %s: fail, iter: %d\n", __func__, test, i); \ diff --git a/src/selftest/counter.c b/src/selftest/counter.c index 62f38d2..481122d 100644 --- a/src/selftest/counter.c +++ b/src/selftest/counter.c @@ -1,3 +1,9 @@ +/* SPDX-License-Identifier: MIT + * + * Copyright (C) 2015-2021 Jason A. Donenfeld <Jason@zx2c4.com>. All Rights Reserved. + * Copyright (C) 2019-2021 Matt Dunwoodie <ncon@noconroy.net> + */ + #define T_LIM (COUNTER_WINDOW_SIZE + 1) #define T_INIT do { \ bzero(&kp, sizeof(kp)); \ |