ndisfilter-driver

Network Layer address - in LWF


I need to know the Network Address of the NIC in Light Weight Filter Driver, I find "OID_GEN_NETWORK_LAYER_ADDRESSES" that gives Network Layer Address, but MSDN documentation says it is Miniport Driver, Is there a way we can retrieve the Network Layer address in the Light Weight Filter Driver.


Solution

  • You can use OIDs, but it'll be much easier to look in NDIS_FILTER_ATTACH_PARAMETERS::CurrentMacAddress. That's given to your driver in its FilterAttach handler.