Legacy driver conversion needs means to identify process sending I

  • Follow


I am still converting a massive and old WDM driver.  We found where the old 
driver copies the Irp->Tail.Overlay.OriginalFileObject in order to identify 
which process sent the WDFREQUEST.  While inspecting MSDN's docs on the IRP 
struct, we noted that the OriginalFileObject member of Tail.Overlay is not 
recommended for driver usage.  So here is my question:

What is the ideal way for a KMDF driver to determine which instance of our 
DLL (which user mode app) sent the WDFREQUEST?

What our driver must do is enforce that one and only one app open certain 
items like channels on our boards.

OriginalFileObject was chosen many moons ago by another engineer for unknown 
reasons with unknown guidance.  I need to have a means to positively and 
uniquely identify which HANDLE was used in the call to 
DeviceIoControl(hDevice, ...) ---OR--- uniquely identify the process by its 
process ID.

As always, all input is appreciated.  John Bond
0
Reply Utf 1/5/2010 5:01:01 PM


0 Replies
255 Views

(page loaded in 0.014 seconds)

Similiar Articles:







7/30/2012 4:42:19 PM


Reply: