From: Mathieu on
Hello,

I need to intercept an event of signal exit of a Windows process since
handle processid,
or whether the process is still active according to the variable handle
returned by the PsGetCurrentProcessID.

Why:
I developed a driver disk mapping on a user-mode process and when I left
the process in task manager (mstask.exe), my driver detects if the
process is still existing, if not the case, it must set the flag on my
logical drive mapped to it is inaccessible and it does not expect the
data sent by my process managing the logical drive.

In function KeWaitForSingleObject can i pass a HANDLE returned by
PsGetCurrentProcessId?

Otherwise how to detect if the handle process is always exists returned
by previously existing PsGetCurrentProcessID?

Thank you