From 7c6591b4f69a8b6a6f503c1ab0cd87f353a54189 Mon Sep 17 00:00:00 2001 From: Simon Rozman Date: Wed, 27 Mar 2019 15:17:54 +0100 Subject: Update documentation Device name actually uses LUID index only. Not an entire LUID. IfType in LUID is always 53 (IF_TYPE_PROP_VIRTUAL). Signed-off-by: Simon Rozman --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index df77951..6dad8f9 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ If you already have `wintun.vcxproj.user` file, just add the `` s ## Usage -After loading the driver and creating a network interface the typical way using [SetupAPI](https://docs.microsoft.com/en-us/windows-hardware/drivers/install/setupapi), open `\\.\Device\WINTUN%d` as Local System, where `%d` is the [LUID](https://docs.microsoft.com/en-us/windows/desktop/api/ifdef/ns-ifdef-_net_luid_lh) of the network device. You may then [`ReadFile`](https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-readfile) and [`WriteFile`](https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-writefile) bundles of packets of the following format: +After loading the driver and creating a network interface the typical way using [SetupAPI](https://docs.microsoft.com/en-us/windows-hardware/drivers/install/setupapi), open `\\.\Device\WINTUN%d` as Local System, where `%d` is the [LUID](https://docs.microsoft.com/en-us/windows/desktop/api/ifdef/ns-ifdef-_net_luid_lh) index of the network device. You may then [`ReadFile`](https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-readfile) and [`WriteFile`](https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-writefile) bundles of packets of the following format: ``` +------------------------------+ -- cgit v1.2.3-59-g8ed1b