blob: 73dbd4277e0b48f65d16a80b1d9dde032dcf49d9 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
module Network.WireGuard.Internal.Constant where
authLength :: Int
authLength = 16
aeadLength :: Int -> Int
aeadLength payload = payload + authLength
keyLength :: Int
keyLength = 32
timestampLength :: Int
timestampLength = 12
mac1Length :: Int
mac1Length = 16
mac2Length :: Int
mac2Length = 16
maxQueuedUdpPackets :: Int
maxQueuedUdpPackets = 4096
udpReadBufferLength :: Int
udpReadBufferLength = 4096
tunReadBufferLength :: Int
tunReadBufferLength = 4096
retryMaxWaitTime :: Int
retryMaxWaitTime = 5 * 1000000 -- 5 seconds
handshakeRetryTime :: Int
handshakeRetryTime = 5
handshakeStopTime :: Int
handshakeStopTime = 90
sessionRenewTime :: Int
sessionRenewTime = 120
sessionExpireTime :: Int
sessionExpireTime = 180
sessionKeepaliveTime :: Int
sessionKeepaliveTime = 10
maxActiveSessions :: Int
maxActiveSessions = 2
heartbeatWaitTime :: Int
heartbeatWaitTime = 250 * 1000 -- 0.25 second
|