IopApplyMutableTagToRegistryKey
NTSTATUS __stdcall IopApplyMutableTagToRegistryKey(HANDLE KeyHandle){
NTSTATUS result;
int KeyInformation;
UINT64 ResultLength;
KeyInformation = 0;
LODWORD(ResultLength) = 0;
if( !KeyHandle )
return -1073741811;
result = ZwQueryKey(KeyHandle, KeyHandleTagsInformation, &KeyInformation, 4ui64, &ResultLength);
if( result >= 0 )
{
if( (KeyInformation & 0x1000) != 0 )
{
return 0;
}
else
{
KeyInformation |= 0x1000u;
return ZwSetInformationKey(KeyHandle, KeySetHandleTagsInformation, &KeyInformation, 4ui64);
}
}
return result;
}Referenced by:
IoOpenDeviceInterfaceRegistryKey
IoOpenDeviceRegistryKey
IoOpenDriverRegistryKey