I'm new to NDIS LWF drivers but I had to move to them after determining that WFP on Win7 would not meet my requirements. So hopefully this isn't too basic of a question.
My requirements basically entail being able to promiscuously listen on a selected NIC on a multi-NIC system. I've modified the LWF sample to put the interfaces into promiscuous mode but I'm now stuck on how to set the specified adapter. I realize that LWF's sit on top of all adapters so it's not like a protocol where I could just call NdisOpenAdapterEx but I would assume there has to be some filtering mechanism to ignore certain adapters.
I need to be able to IOCTL to the driver the selected MAC address(es) of the interface I care about. Is it possible to load the driver but only have the filter running on specific interfaces or will I just have to just ignore calls coming from others that I don't care about in FilterReceiveNetBufferLists. It just seems like it would be more efficient to not have to have the FilterReceiveNetBufferLists callback if I won't do anything with it for a particular interface.
The things that are tripping me up are the fact that, FilterRestart is called automatically during DriverEntry (via NdisFRegisterFilterDriver) and that there doesn't seem to be NdisFPauseFilter (but there is a NdisFRestartFilter). Ideally, I'd like to be able to set the necessary params before any filtering begins and I'd like to stay away from using the registry during DriverEntry because I'll still need the ability to dynamically re-task as required.
And finally, just for a better understanding of NDIS internals, when a filter module is paused does the whole stack become paused or does NDIS route around the paused module?