tcpdump
tcpdump copied to clipboard
[DRAFT] Test if tcpdump.exe works
[skip ci]
The tcpdump.exe don't run:
Release\tcpdump.exe --version
Command exited with code -1073741515
(Same when using "Debug".)
-1073741515 == 0xffffffffc0000135, both values yield search results discussing location of Windows libraries and setting of PATH.
Thanks, and missing DLLs also.
Investigation with Dependencies (https://github.com/lucasg/Dependencies)
SDK=WpdPack --> wpcap.dll (NOT_FOUND). But no unattended installation possible with WinPcap_4_1_3.exe.
SDK=npcap-sdk-1.12 --> wpcap.dll (NOT_FOUND). It seems that npcap-1.79.exe in silent mode needs a Npcap OEM version.
-1073741515 == 0xffffffffc0000135, both values yield search results discussing location of Windows libraries and setting of
PATH.
And as a 32-bit value, it's 0xc0000135, which is, according to the list of NT status values, STATUS_DLL_NOT_FOUND.
SDK=WpdPack --> wpcap.dll (NOT_FOUND). But no unattended installation possible with WinPcap_4_1_3.exe. SDK=npcap-sdk-1.12 --> wpcap.dll (NOT_FOUND). It seems that npcap-1.79.exe in silent mode needs a Npcap OEM version.
Yes - in both cases, I think the intent is to have commercial applications using WinPcap or Npcap pay for the ability to silently install the driver and libraries as part of their installer, to help support the project. That's definitely the case for Npcap.
Note that, in order to do capture tests, the WinPcap/Npcap driver would also have to be installed. For reading capture files, that might not be necessary, so that may be OK for tcpdump tests.
so that may be OK for tcpdump tests.
Any way to build without the capture function ? (Because currently tcpdump.exe needs wpcap.dll)
Any way to build without the capture function ?
"Build" as in "build libpcap" or "build" as in "build tcpdump"?
Libpcap can be built without capture support - if using CMake, passing -DPCAP_TYPE=none to CMake should be sufficient.
Then you'd want to build tcpdump to link with the libpcap that you built.
(Because currently tcpdump.exe needs wpcap.dll)
Tcpdump's going to need some libpcap library, even if you're only building it to run the tests.
Next test: extract wpcap.dll from installer, copy it in \Windows\system32 and see...
If (please check that first) the licence does not forbid it, you could extract the required files once on a Windows PC, put them here and let the CI script download them from there into the correct place of the CI filesystem instead of the installers.
extract
wpcap.dllfrom installer, copy it in \Windows\system32 and see...
Copying is not enough. Installation required.
Libpcap can be built without capture support - if using CMake, passing
-DPCAP_TYPE=noneto CMake should be sufficient.
-DPCAP_TYPE=null ?
Tcpdump's going to need some libpcap library, even if you're only building it to run the tests.
Yes, sure.