aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/cookie.h
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2018-06-23 19:02:18 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2018-06-23 19:12:51 +0200
commit68441fb05412baebbd17f407bf984ad7a81af630 (patch)
tree71fefcc3710232dea912be362cb83f383720edc0 /src/cookie.h
parentglobal: use ktime boottime instead of jiffies (diff)
downloadwireguard-monolithic-historical-68441fb05412baebbd17f407bf984ad7a81af630.tar.xz
wireguard-monolithic-historical-68441fb05412baebbd17f407bf984ad7a81af630.zip
global: use fast boottime instead of normal boottime
Generally if we're inaccurate by a few nanoseconds, it doesn't matter.
Diffstat (limited to 'src/cookie.h')
-rw-r--r--src/cookie.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cookie.h b/src/cookie.h
index e83c256..9f519ef 100644
--- a/src/cookie.h
+++ b/src/cookie.h
@@ -15,13 +15,13 @@ struct cookie_checker {
u8 secret[NOISE_HASH_LEN];
u8 cookie_encryption_key[NOISE_SYMMETRIC_KEY_LEN];
u8 message_mac1_key[NOISE_SYMMETRIC_KEY_LEN];
- ktime_t secret_birthdate;
+ u64 secret_birthdate;
struct rw_semaphore secret_lock;
struct wireguard_device *device;
};
struct cookie {
- ktime_t birthdate;
+ u64 birthdate;
bool is_valid;
u8 cookie[COOKIE_LEN];
bool have_sent_mac1;