mirror of
https://github.com/veracrypt/VeraCrypt.git
synced 2026-10-09 18:16:35 -05:00
Windows Driver: Protect captured subject context during processing of user access token.
This commit is contained in:
1 parent
2f2cb6b7ae
commit
dc6c279339
1 file changed
+2
@@ -2653,6 +2653,7 @@ NTSTATUS MountDevice (PDEVICE_OBJECT DeviceObject, MOUNT_STRUCT *mount)
|
||||
PACCESS_TOKEN accessToken;
|
||||
|
||||
SeCaptureSubjectContext (&subContext);
|
||||
SeLockSubjectContext(&subContext);
|
||||
accessToken = SeQuerySubjectContextToken (&subContext);
|
||||
|
||||
if (!accessToken)
|
||||
@@ -2678,6 +2679,7 @@ NTSTATUS MountDevice (PDEVICE_OBJECT DeviceObject, MOUNT_STRUCT *mount)
|
||||
}
|
||||
}
|
||||
|
||||
SeUnlockSubjectContext(&subContext);
|
||||
SeReleaseSubjectContext (&subContext);
|
||||
|
||||
if (NT_SUCCESS (ntStatus))
|
||||
|
||||
Reference in new issue
Block a user