On linux, it's possible to create a tun interface using a tun driver which provides a "network interface psuedo-device" that can be treated as a regular network interface. Is there a way to do this programmatically on windows? Is there a way to do this without writing my own driver?
-
How did u do that on linux ? – MKT Feb 15 '14 at 07:47
-
For windows 7/8 http://superuser.com/questions/339465/creating-a-virtual-nic-on-windows-7/339475#339475 – laggingreflex Oct 30 '14 at 04:09
4 Answers
You can do this on XP with the Microsoft Loopback Adapter which is a driver for a virtual network card.
On newer Windows version: Installing the Microsoft Loopback Adapter in Windows 8 and Windows Server 2012

- 4,114
- 4
- 36
- 31

- 190,537
- 57
- 313
- 299
-
Is there anything better, it seems to require restarts? Where as I can see that Virtualbox can create adapters without needing restarts. – CMCDragonkai Jun 14 '14 at 11:22
-
For windows 7/8 http://superuser.com/questions/339465/creating-a-virtual-nic-on-windows-7/339475#339475 – laggingreflex Oct 30 '14 at 04:02
-
1Cannot downvote as I do not have enough reputation but the link doesn't work anymore. – soyeb84 Dec 30 '18 at 21:36
@Tim
Depending on the licensing you might be able to use the TUN/TAP driver that is part of OpenVPN, see here for details.

- 13,917
- 9
- 40
- 42
In the Singularity project, Microsoft research communicates with the singularity VM through a "loopback" adapter. Maybe that'd help?
Running it is easy so it may be something fun to do anyway. :)

- 87
- 2
- 7
Microsoft KM-TEST Loopback Adapter
not sure if that can be done programatically, but for manually setup: you can use a "Microsoft KM-TEST Loopback Adapter" on windows 11 (works on older windows versions, too, i guess)
- right click start button -> Device manager
- select your PC at the top (otherwise menu item will be missing)
- menu "Action" -> "Add legacy hardware"
- next -> "install the hardware that I manually selectron from a list (Advanced)" -> next
- select "network adapters" -> next -> wait until list is loaded
- In the Manufacturer list, select Microsoft. In the Model list, select Microsoft KM-TEST Loopback Adapter
- next -> finish
- can be found where the other network adapters are. It is usually called "Ethernet 2" or something like that.
- can be uninstalled in the device manager
source: https://consumer.huawei.com/en/support/content/en-us00693656/

- 2,431
- 21
- 32