#ifndef _NTREGAPI_H
/**
* Unloads a registry key.
*
* @param TargetKey Pointer to the object attributes of the target key.
* @return NTSTATUS Successful or errant status.
*/
NTSYSCALLAPI
NTSTATUS
NTAPI
NtUnloadKey(
_In_ POBJECT_ATTRIBUTES TargetKey
);
View code on GitHub
#ifndef _NTZWAPI_H
NTSYSCALLAPI
NTSTATUS
NTAPI
ZwUnloadKey(
_In_ POBJECT_ATTRIBUTES TargetKey
);
View code on GitHub
Function NtUnloadKey
unloads previously loaded Hive file from registry structure. All changes made to keys and values under this Hive are stored.
Pointer to OBJECT_ATTRIBUTES
structure contains path and name of Hive root key.
Privilege: SE_RESTORE_PRIVILEGE