1

I need to create a virtual network adapter like "loopback adapter" or "virtualbox host-only network".

But I dont know what windows functions should I call to programatically create my own virtual adapter due to create a virtual NAT for my program.

I have been searching for documentation to do this but I didnt found anything, maybe somebody of you can help me.

The greatest information I have found corresponds to github projects like "npcap" or "softethervpn" but dont help me like a good docs can do.

Thank you.

1 Answers1

0

The NPFInstall.exe utility inside Npcap can install Npcap Loopback Adapter. But this adapter is actually a wrapper based on Microsoft Loopback Adapter. I don't know if this is what you want.

The specific command is:

NPFInstall.exe -il

hsluoyz
  • 2,739
  • 5
  • 35
  • 59
  • Yeah bro thank you for your answer, I saw your code which install the adapter, It is based on "devcon" rigth?, I saw that code too, there is the code I want, of course I want to install an adapter, but not "Npcap adapter" I want to install any signed adapter starting from "microsoft loopback adapter", I need to automatically install it from my program in order to use it as NAT (ofc there are more drivers I coud use to do this but maybe I get license problems so I think that the best is install MS loopback, what I am trying to do is automate the installation of the loopback adapter using c++ – ThisIsNotMyThirdAccount May 22 '17 at 18:40
  • Yes, there is a lot of code and functions so I have to understand it and try to create my own installer like you do and to download the .sys loopback driver. When I have time I will try that. Thank you and see you. – ThisIsNotMyThirdAccount May 23 '17 at 10:55