aboutsummaryrefslogtreecommitdiffstats
path: root/device/cookie.go (unfollow)
Commit message (Collapse)AuthorFilesLines
2019-08-29wintun: keep reference to pool in wintun objectJason A. Donenfeld1-7/+9
2019-08-29wintun: introduce adapter poolsSimon Rozman2-26/+50
This makes wintun package reusable for non-WireGuard applications. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-08-28wintun: simplify rename logicJason A. Donenfeld1-5/+4
2019-08-28wintun: give better errors when ndis interface listing failsJason A. Donenfeld1-2/+2
2019-08-28wintun: also check for numbered suffix and friendly nameJason A. Donenfeld1-9/+22
2019-08-28wintun: upgrade deleting all interfaces and make it reusableSimon Rozman1-4/+29
DeleteAllInterfaces() didn't check if SPDRP_DEVICEDESC == "WireGuard Tunnel". It deleted _all_ Wintun adapters, not just WireGuard's. Furthermore, the DeleteAllInterfaces() was upgraded into a new function called DeleteMatchingInterfaces() for selectively deletion. This will be used by WireGuard to clean stale Wintun adapters. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-08-27wintun: cleanup earlierJason A. Donenfeld1-19/+20
2019-08-27wintun: rename duplicate adapters instead of ourselvesJason A. Donenfeld4-0/+118
2019-08-26wintun: match suffix numbersJason A. Donenfeld1-1/+8
2019-08-25device: getsockname on linux to determine portJason A. Donenfeld1-0/+10
It turns out Go isn't passing the pointer properly so we wound up with a zero port every time.
2019-08-24wintun: make description consistent across fieldsJason A. Donenfeld2-13/+10
2019-08-22wintun: try multiple names until one isn't a duplicateJason A. Donenfeld1-4/+12
2019-08-21wintun: use nci.dll directly instead of buggy netshellJason A. Donenfeld5-84/+102
2019-08-20wintun: set friendly a bit betterJason A. Donenfeld1-22/+10
This is still wrong, but NETSETUPPKEY_Driver_FriendlyName seems a bit tricky to use.
2019-08-19wintun: also set friendly name after setting interface nameJason A. Donenfeld1-8/+23
2019-08-19wintun: defer requires unique variableJason A. Donenfeld1-33/+22
2019-08-19wintun: set adapter description nameJason A. Donenfeld1-0/+24
2019-08-19tun: windows: don't spin unless we really need itJason A. Donenfeld1-10/+42
2019-08-05version: bump snapshot0.0.20190805Jason A. Donenfeld1-1/+1
2019-08-05device: drop lock before expiring keysJason A. Donenfeld1-4/+11
2019-08-05uapi: skip peers with invalid keysJason A. Donenfeld2-4/+16
2019-08-03tun: windows: spin for only a millisecond/80Jason A. Donenfeld1-1/+1
Performance stays the same as before.
2019-08-02wintun: merge opening device registry keySimon Rozman1-21/+15
This also introduces waiting for key to appear on initial access. See if this resolves the issue caused by HDD power-up delay resulting in failure to create the adapter. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-08-02wintun: simplify checking reboot requirementSimon Rozman1-18/+7
We never checked checkReboot() reported error anyway. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-08-02wintun: refactor `err == nil` error checkingSimon Rozman2-133/+166
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-08-02wintun: handle error for deadgwdetectJason A. Donenfeld1-2/+3
2019-08-02tun: darwin: do not attempt to close tun.event twiceJason A. Donenfeld1-4/+1
Previously it was possible for this to race. It turns out we really don't need to set anything to -1 anyway.
2019-07-23wintun: get interface path properly with cfgmgrJason A. Donenfeld4-30/+93
2019-07-23tun: windows: styleJason A. Donenfeld1-1/+1
2019-07-23wintun: simplify resolution of dev nodeJason A. Donenfeld1-13/+10
2019-07-22wintun: enable sharing of pnp nodeJason A. Donenfeld1-1/+1
2019-07-22tun: windows: close event handle on shutdownJason A. Donenfeld1-0/+1
2019-07-19ipc: windows: match SDDL of WDK and make monkeyableJason A. Donenfeld1-11/+3
2019-07-19tun: windows: get rid of retry logicJason A. Donenfeld2-218/+100
Things work fine on Windows 8.
2019-07-19tun: windows: use specific IOCTL codeJason A. Donenfeld1-1/+1
2019-07-18device: do not crash on nil'd bind in windows bindingJason A. Donenfeld1-0/+5
2019-07-18tun: windows: open file at startup timeJason A. Donenfeld1-0/+9
2019-07-18tun: windows: silently drop packet when ring is fullJason A. Donenfeld1-2/+2
2019-07-18tun: windows: switch to NDIS device objectJason A. Donenfeld2-7/+6
2019-07-18wintun: calculate path of NDIS device object symbolic linkJason A. Donenfeld1-0/+20
2019-07-18tun: openbsd: don't change MTU when it's already the expected sizeMichael Zeltner1-4/+7
Allows for running wireguard-go as non-root user. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2019-07-18tun: windows: spin for a bit before falling back to event objectJason A. Donenfeld1-4/+19
2019-07-17tun: windows: implement ring buffersSimon Rozman1-186/+184
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-07-11device: immediately rekey all peers after changing device private keyJason A. Donenfeld2-0/+25
Reported-by: Derrick Pallas <derrick@pallas.us>
2019-07-08README: update windows infoJason A. Donenfeld1-1/+1
2019-07-05tun: windows: registration of write buffer no longer requiredJason A. Donenfeld2-14/+1
2019-07-05tun: windows: decrease alignment to 4Jason A. Donenfeld1-3/+3
2019-07-04tun: windows: delay initial writeJason A. Donenfeld1-16/+22
Otherwise we provoke Wintun 0.3.
2019-07-01device: receive: uniform message for source address checkJason A. Donenfeld1-1/+1
2019-07-01tun: windows: packetNum is unusedJason A. Donenfeld1-3/+0