-
Notifications
You must be signed in to change notification settings - Fork 10
Home
Welcome to the Divert.Net wiki!
There isn't much to place here, everything is set up very simply. However, there is one minor thing to note. The Visual Studio project file for Divert.Net expects to find a release of WinDivert at PROJECT_ROOT_DIR\deps\windivert\
. That is to say, you need to download a release of WinDivert and extract the contents of the archive to the previously mentioned directory.
Once you've done that, you need to rename the amd64
folder to x64
, and be sure to copy WinDivert64.sys
from the x64
directory into the x86
directory. This is because it's perfectly plausible to have a 32 bit application linking against the 32 bit WinDivert.dll
, but running on a 64 bit system.
The WinDivert.dll
library will automatically select the appropriate driver (.sys file) based on the machine architecture it's running on. In the event that it cannot find the appropriate driver, it'll crash. So, just include the 64 bit version even in your 32 bit programs.
In the end, you should have a directory structure like so:
Divert.Net\deps\windivert\CHANGELOG
Divert.Net\deps\windivert\doc
Divert.Net\deps\windivert\include
Divert.Net\deps\windivert\LICENSE
Divert.Net\deps\windivert\out.txt
Divert.Net\deps\windivert\README
Divert.Net\deps\windivert\VERSION
Divert.Net\deps\windivert\x64
Divert.Net\deps\windivert\x86
Divert.Net\deps\windivert\doc\WinDivert.html
Divert.Net\deps\windivert\include\windivert.h
Divert.Net\deps\windivert\x64\netdump.exe
Divert.Net\deps\windivert\x64\netfilter.exe
Divert.Net\deps\windivert\x64\passthru.exe
Divert.Net\deps\windivert\x64\webfilter.exe
Divert.Net\deps\windivert\x64\WinDivert.dll
Divert.Net\deps\windivert\x64\WinDivert.lib
Divert.Net\deps\windivert\x64\WinDivert64.sys
Divert.Net\deps\windivert\x86\netdump.exe
Divert.Net\deps\windivert\x86\netfilter.exe
Divert.Net\deps\windivert\x86\passthru.exe
Divert.Net\deps\windivert\x86\webfilter.exe
Divert.Net\deps\windivert\x86\WinDivert.dll
Divert.Net\deps\windivert\x86\WinDivert.lib
Divert.Net\deps\windivert\x86\WinDivert32.sys
Divert.Net\deps\windivert\x86\WinDivert64.sys