Unable to activate the adapter by using Npcap instead of Winpcap

2k Views Asked by At

I am trying to use Sharppcap in order to pack and send UDP packages. I am able to send packages by Windows Loopback Adapter but it limits the byte length to 1500. However, I need to send larger packages in order to be faster. I installed Npcap to increase this number but it made me uninstall Winpcap driver and now an exception is thrown when I try to open the Npcap Loopback adapter:

CurrDev.Open(DeviceMode.Promiscuous, readTimeoutMilliseconds);

Exception: SharpPcap.PcapException: 'Unable to activate the adapter (rpcap://\Device\NPF_{DB15D668-E692-46D9-9A6F-FD6747CD11AD}). Return code: -1'

Bonus Question: I am aiming to send 10 Gb/sec with Ethernet. Any other ideas how can I reach that speed?

1

There are 1 best solutions below

1
On

I had the same problem on Windows 10 as you have. The solution that worked for me:

  1. Remove the currently installed npcap driver (0.995)
  2. Install version 0.991 (https://nmap.org/npcap/dist/npcap-0.991.exe)

I've found this solution on https://github.com/chmorgan/sharppcap/issues/71 Credits to https://github.com/larswilliam Hope it helps.