summaryrefslogtreecommitdiffhomepage
path: root/tun/wintun
AgeCommit message (Collapse)Author
2019-08-02wintun: handle error for deadgwdetectJason A. Donenfeld
2019-07-23wintun: get interface path properly with cfgmgrJason A. Donenfeld
2019-07-23wintun: simplify resolution of dev nodeJason A. Donenfeld
2019-07-22wintun: enable sharing of pnp nodeJason A. Donenfeld
2019-07-19tun: windows: get rid of retry logicJason A. Donenfeld
Things work fine on Windows 8.
2019-07-18tun: windows: switch to NDIS device objectJason A. Donenfeld
2019-07-18wintun: calculate path of NDIS device object symbolic linkJason A. Donenfeld
2019-06-18tun: windows: never retry open on Windows 10Jason A. Donenfeld
2019-06-11wintun: increase registry timeoutJason A. Donenfeld
2019-06-10wintun: add helper for cleaning upJason A. Donenfeld
2019-06-10wintun: simplify error matching and remove dumb commentsJason A. Donenfeld
2019-06-10wintun: fix comments and remove hwnd paramJason A. Donenfeld
This now looks more idiomatic.
2019-06-10setupapi: add SetDeviceRegistryPropertyString descriptionSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-06-10setupapi: unify ERROR_INSUFFICIENT_BUFFER handlingSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-06-10wintun: allow controlling GUIDJason A. Donenfeld
2019-06-10setupapi: add DeviceInstanceID()Jason A. Donenfeld
2019-06-06global: fixup TODO comment spacingJason A. Donenfeld
2019-06-06wintun: guid functions are upstreamJason A. Donenfeld
2019-06-06wintun: simplify DeleteInterface method signatureSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-06-05wintun: don't run HrRenameConnection in separate threadJason A. Donenfeld
It's very slow, but unfortunately we haven't a choice. NLA needs this to have completed.
2019-06-04setupapi, wintun: replace syscall with golang.org/x/sys/windowsSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-06-04wintun: set DI_QUIETINSTALL flag for GUI-less device managementSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-06-04setupapi: define PropChangeParams structSimon Rozman
This structure is required for calling DIF_PROPERTYCHANGE installer class. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-24wintun: revise GetInterface()Simon Rozman
- Make foreign interface found error numeric to ease condition detection. - Update GetInterface() documentation. - Make tun.CreateTUN() quit when foreign interface found before attempting to create a Wintun interface with a duplicate name. Creation is futile. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-23wintun: never return nil, nilJason A. Donenfeld
2019-05-22setupapi: trim "Get" from gettersSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-17wintun: don't try to flush interface, but rather deleteJason A. Donenfeld
2019-05-17wintun: make certain methods privateJason A. Donenfeld
2019-05-14global: regroup all importsJason A. Donenfeld
2019-05-11wintun: registry: fix nitsJason A. Donenfeld
2019-05-11wintun: registry: revise value readingSimon Rozman
- Make getStringValueRetry() reusable for reading any value type. This merges code from GetIntegerValueWait(). - expandString() >> toString() and extend to support REG_MULTI_SZ (to return first value of REG_MULTI_SZ). Furthermore, doing our own UTF-16 to UTF-8 conversion works around a bug in windows/registry's GetStringValue() non-zero terminated string handling. - Provide toInteger() analogous to toString() - GetStringValueWait() tolerates and reads REG_MULTI_SZ too now. It returns REG_MULTI_SZ[0], making GetFirstStringValueWait() redundant. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-10wintun: call HrRenameConnection in another threadJason A. Donenfeld
2019-05-10wintun: enumerate faster by using COMPATDRIVER instead of CLASSDRIVERJason A. Donenfeld
2019-05-10wintun: destroy devinfolist after usageJason A. Donenfeld
2019-05-10wintun: registry: replace REG_NOTIFY with NOTIFYSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-10wintun: IpConfig is a MULTI_SZ, and fix errorsJason A. Donenfeld
2019-05-10wintun: poll for device keyJason A. Donenfeld
It's actually pretty hard to guess where it is.
2019-05-10wintun: fix scope of error objectJason A. Donenfeld
2019-05-10wintun: wait for interface registry key on device creationSimon Rozman
By using RegNotifyChangeKeyValue(). Also disable dead gateway detection. Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-09wintun: fix GUID leading zero paddingSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-05-03setupapi: safer aliasing of slice typesJason A. Donenfeld
2019-05-03wintun: work around GetInterface staleness bugJason A. Donenfeld
2019-05-02wintun: don't retry when not creatingJason A. Donenfeld
The only time we're trying to counteract the race condition is when we're creating a driver. When we're simply looking up all drivers, it doesn't make sense to retry.
2019-04-29wintun: try harder to open registry keyJason A. Donenfeld
This sucks. Can we please find a deterministic way of doing this instead?
2019-04-19setupapi: Fix struct size mismatchesSimon Rozman
Signed-off-by: Simon Rozman <simon@rozman.si>
2019-04-19setupapi: actually fix padding by rounding up to sizeof(void*)Jason A. Donenfeld
2019-04-18setupapi: Revise DrvInfoDetailData struct size calculationSimon Rozman
Go adds trailing padding to DrvInfoDetailData struct in GOARCH=386 which confuses SetupAPI expecting exactly sizeof(SP_DRVINFO_DETAIL_DATA). Signed-off-by: Simon Rozman <simon@rozman.si>
2019-04-13windows: use proper constants from updated x/sysJason A. Donenfeld
2019-04-01wintun: rename device using undocumented API that netsh.exe usesJason A. Donenfeld
2019-04-01wintun: add more retry loopsJason A. Donenfeld