From 92e7dbad21a8e68ebc02cd87ddba6f8cba61f8c0 Mon Sep 17 00:00:00 2001 From: Bill Zissimopoulos Date: Wed, 11 Oct 2017 16:28:50 -0700 Subject: [PATCH] sys: Create and Rename requests should include the originating process PID --- src/sys/create.c | 2 ++ src/sys/fileinfo.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/sys/create.c b/src/sys/create.c index 4f92972a..0301f2cd 100644 --- a/src/sys/create.c +++ b/src/sys/create.c @@ -579,6 +579,8 @@ NTSTATUS FspFsvolCreatePrepare( /* get a pointer to the current process so that we can close the impersonation token later */ Process = PsGetCurrentProcess(); ObReferenceObject(Process); + + /* get the originating process ID stored in the IRP */ OriginatingProcessId = IoGetRequestorProcessId(Irp); /* send the user-mode handle to the user-mode file system */ diff --git a/src/sys/fileinfo.c b/src/sys/fileinfo.c index 8b4724ed..309aa8ba 100644 --- a/src/sys/fileinfo.c +++ b/src/sys/fileinfo.c @@ -1605,6 +1605,8 @@ NTSTATUS FspFsvolSetInformationPrepare( /* get a pointer to the current process so that we can close the impersonation token later */ Process = PsGetCurrentProcess(); ObReferenceObject(Process); + + /* get the originating process ID stored in the IRP */ OriginatingProcessId = IoGetRequestorProcessId(Irp); /* send the user-mode handle to the user-mode file system */