Downloading And Configuring Windivert & WinSparkle - TechnikEmpire/HttpFilteringEngine GitHub Wiki

##Background HttpFilteringEngine uses WinDivert, a packet diversion driver build on top of the Windows Filtering Platform, for analyzing and diverting network traffic through itself. Stahp It, the WPF application that uses HttpFilteringEngine on Windows, uses WinSparkle as an easy self-updating mechanism. Unlike the rest of the components used by this project, we will only download precompiled binaries for both of these dependencies.

The reason for this with WinDivert is simple. Being setup for compiling and signing drivers is quite involved, plus we don't have certificates for signing our own versions of WinDivert. The reason for downloading precompiled versions of WinSparkle is even simpler: sheer unadulterated old fashioned laziness.

Getting The Precompiled Releases

First, download a current release of WinDivert. At the time of this writing, the most current version is RC 1.2. Extract the contents to HTTPFILTERINGENGINE_BASE_DIR\deps\windivert\msvc. Unlike other stages, you need to copy the contents directly to HTTPFILTERINGENGINE_BASE_DIR\deps\windivert\msvc so that it directly contains child folders such as include, x86 etc. You do not want HTTPFILTERINGENGINE_BASE_DIR\deps\windivert\msvc\WinDivert-1.2.0-rc-MSVC\CONTENTS. The reason for this difference is that we're not compiling sources here, where we would have the compiler output copied to ``HTTPFILTERINGENGINE_BASE_DIR\deps\LIB_NAME\msvc`.

Next, just to maintain the current format, rename HTTPFILTERINGENGINE_BASE_DIR\deps\windivert\msvc\amd64 to HTTPFILTERINGENGINE_BASE_DIR\deps\windivert\msvc\x64. This is necessary for the MSVC project to automatically discover and use the correct versions for different targets.

Next, download WinSparkle. At the time of this writing, the most current version is 0.4. Extract the archive contents to HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle so that directly contains folders like include and x64. Just like with WinDivert, you do not want HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle\Winsparkle-0.4\CONTENTS.

Again, for continuity and for automatic discovery of platform-specific binaries, create a folder HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle\x86 and then move the folder HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle\Release into it, so you wind up with HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle\x86\Release\OBJECTS. This way, the 32 and 64 bit versions of Winsparkle reside at:

  • HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle\x86\Release
  • HTTPFILTERINGENGINE_BASE_DIR\StahpIt\deps\winsparkle\x64\Release

Those steps are a little messy but, continuity is important!

You Survived and Win 100 Internet Points

That's it, the HttpFilteringEngine and StahpIt MSVC project files will automatically include the correct dependencies based on target architecture. You should now be able to open and build either of these projects without issue.