Hi All,
I had a question regarding the user space process id and kernel space process id …
In user space we have a function which basically returns a number which is of type DWORD
DWORD GetProcessId( HANDLE Process);
and in kernel mode we have a function which return a HANDLE
HANDLE PsGetCurrentProcessId( VOID );
Does both the function return the same value…???
Consider the case were in a kernel mode module requires to know the process which invoked the function is the same as the one which registered for the kernel mode functionality …meaning
Application first makes a register call with a processid which it gets from user mode function…Then application makes the system call to kernel space module, in the kernel module i use PsGetCurrentProcessId to get the process id to validate if the process which requested a functionality from the kernel mode module is the same as the one registered to it …
can i do this …
Jagadish