#ifndef _NTREGAPI_H
/**
* Opens an existing registry key.
*
* @param[out] KeyHandle A pointer to a handle that receives the key handle.
* @param[in] DesiredAccess The access mask that specifies the desired access rights.
* @param[in] ObjectAttributes A pointer to an OBJECT_ATTRIBUTES structure that specifies the object attributes.
* @return NTSTATUS Successful or errant status.
* @remarks NtOpenKey ignores the security information in the ObjectAttributes structure.
*/
NTSYSCALLAPI
NTSTATUS
NTAPI
NtOpenKey(
_Out_ PHANDLE KeyHandle,
_In_ ACCESS_MASK DesiredAccess,
_In_ POBJECT_ATTRIBUTES ObjectAttributes
);
View code on GitHub
#ifndef _NTZWAPI_H
NTSYSCALLAPI
NTSTATUS
NTAPI
ZwOpenKey(
_Out_ PHANDLE KeyHandle,
_In_ ACCESS_MASK DesiredAccess,
_In_ POBJECT_ATTRIBUTES ObjectAttributes
);
View code on GitHub
This function is documented in Windows Driver Kit.
See ZwOpenKey
in NT DDK or 2000 DDK for detailed description.