mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
f9c603db6e
As of now the Object Manager private service, ObpCloseHandleTableEntry, looks for OBJ_PROTECT_CLOSE attribute if a handle should not be closed. However, in ObDuplicateObject if an attribute of OBJ_PROTECT_CLOSE is found as it's been filled to the caller (see L2466) this attribute is removed from the attributes list of the new handle and ObpAccessProtectCloseBit access is granted to the newly duplicated object handle. With that being said ObpCloseHandleTableEntry indiscriminately closes the object handle albeit it shouldn't do so. As a matter of fact in Windows Server 2003 SP2 this service indeed checks for ObpAccessProtectCloseBit flag bit and if the condition is met then it returns STATUS_HANDLE_NOT_CLOSABLE as it should. Therefore we should do the same. Now NtClose can properly warn the calling thread the object handle can't be closed which fixes a testcase failure within NtDuplicateObject NTDLL APITEST where this function gives handle close protection bit as requested by the caller. |
||
---|---|---|
.. | ||
devicemap.c | ||
obdir.c | ||
obhandle.c | ||
obinit.c | ||
oblife.c | ||
oblink.c | ||
obname.c | ||
obref.c | ||
obsdcach.c | ||
obsecure.c | ||
obwait.c |