-
Notifications
You must be signed in to change notification settings - Fork 544
Bluescreen on Windows 8.1 #565
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thanks for reporting this. Can you please provide some additional information as described in the Npcap User's Guide? The most useful information to debug this would be the kernel minidump from |
I appear to be having the same issue with npcap 1.60 on Windows 8.1. The machine becomes unstable very quickly after installing. And when I restart the PC all I have to do is wait about 3 minutes, and I'll get the BSOD with the error regarding NDIS.SYS. I don't have to start any applications. I had a very difficult time running DiagReport as the PC would blue screen when the utility was running. I've uninstalled 1.60 for now, and now back to running 1.55. Everything is fine. |
Hi, have the same issue. Fails in ndisCreateStringStreamEntry. I've sent a minidump to you. I have 2 other NDIS filters running for years with no issues (VirtualBox and Comodo) but I've disabled them in my adapter (had to do it anyway because Wireshark would not show the adapter and nmap would show WINDEVICE NONE). |
I have the same issue. Npcap 1.60 and Windows Server 2012 R2. I will send you a minidump. Oddly, this problem only started approximately 1 day after initial installation. Without Driver Verifier: The machine will bluescreen within a few minutes after rebooting with a SYSTEM_THREAD_EXCEPTION_NOT_HANDLED error with a reference to ndis.sys. I can confirm that "Raw 802.11 Packet Capture Support" seems to be the problem, as everything seems to work fine after I reinstalled without that option. |
Since Npcap is not in the call stack of the crash, it's nearly impossible to know what part of Npcap might be related. We made significant improvements and changes to the driver in Npcap 1.70 that may have addressed the issue. Can anyone confirm whether Npcap 1.70 fixes the problem? |
I can't as I have upgraded my operating system to Windows 10 since I reported what I ran into. Npcap 1.60 works fine in Windows 10. |
The problem still happens with Npcap 1.70 and Windows 8.1 host. Here are some details on it:
My system specs:
Crash minidump attached: minidump.zip
|
Thanks for the crash dumps. Unfortunately, we still cannot determine how or if Npcap is involved in these crashes. A complete memory dump ( Crash stack:
3rd-party drivers in common:
|
@jtippet any clues as to what NDIS is doing in that call stack? Is there any way Npcap (a modifying LWF, but also a LWF in the undocumented |
From what I can see in the minidump, NDIS is tripping over a bogus filter driver record named There's maybe a little gotcha from the asymmetry of the rules here:
That third bullet might come as a bit of a surprise if you're accustomed to the miniport world (bullet #2). So, concretely, audit your DriverEntry and ensure that, if NdisFRegisterFilterDriver succeeds:
If you call NdisFRegisterFilterDriver multiple times, then you need to have a corresponding NdisFDeregisterFilterDriver for each successful registration. And, for the record, note that from the moment you call NdisFRegisterFilterDriver, NDIS is allowed to call into your FilterAttach handler at any time. NDIS can keep calling into your FilterXxx handlers right up until NdisFDeregisterFilterDriver returns. So there's usually a right place to insert NdisFDeregisterFilterDriver -- if you deregister too late after you've already destroyed your other internal state (your internal locks, memory allocations, whatever), then you're racing against a FilterAttach. A good rule of thumb is to initialize nearly everything first, then register with NDIS; and for the cleanup path, do it all in reverse order. |
@jtippet Thanks so much for the insight! We definitely have run into the early FilterAttach issue before, as evidenced by this line in DriverEntry: npcap/packetWin7/npf/npf/Packet.c Lines 458 to 459 in f63c334
|
@jtippet I believe I have figured out what is going on. We made a change a while back (4bbdb85) to use the "null service" in our INF for the secondary functions of Npcap (this LWF for raw WiFi frame capture and the WFP callout driver for loopback traffic capture). The intent was to avoid having a "disabled service" installed in the Registry, since all functions (both LWFs and the WFP, plus the WDM driver that provides the interface with user software) run from a single binary, npcap.sys, with a single DriverEntry function that initiates all functions. However, I see in the disassembly that the read instruction is
Looking in the memory, I see that qword is the 8 bytes immediately before the FriendlyName for this LWF, so I attached a debugger to a good running system and looked for the FriendlyName within the memory block address for our primary LWF from It should not be a problem to back out our change for the next release, which should resolve the issue. |
Here's the original StackOverflow answer explaining how the AddService lines are supposed to work and why: https://stackoverflow.com/a/39170937/1183387 |
We believe this is resolved with Npcap 1.71 since @dmiller-nmap backed out the INF change as described above. So I'm closing this, but folks can still comment if for some reason you're still seeing the issue with 1.71. |
Can confirm the problem does not happen for me anymore. I have installed Npcap 1.71 with the same settings as before, so far so good. 👍 Many thanks! |
Bluescreen (ndis.sys) on Windows 8.1 with npcap 1,60
The text was updated successfully, but these errors were encountered: