ReactOS 0.4.15-dev-5672-gf73ac17
regutil.h
Go to the documentation of this file.
1/*
2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS Setup Library
4 * FILE: base/setup/lib/regutil.h
5 * PURPOSE: Registry utility functions
6 * PROGRAMMERS: Hermes Belusca-Maito (hermes.belusca@sfr.fr)
7 */
8
9#pragma once
10
11/*
12 * This function is similar to the one in dlls/win32/advapi32/reg/reg.c
13 * TODO: I should review both of them very carefully, because they may need
14 * some adjustments in their NtCreateKey calls, especially for CreateOptions
15 * stuff etc...
16 */
22
23/*
24 * Should be called under SE_BACKUP_PRIVILEGE privilege
25 */
29 IN PCWSTR RegistryKey,
30 IN BOOLEAN IsHiveNew,
31 IN HANDLE ProtoKeyHandle
32/*
33 IN PUCHAR Descriptor,
34 IN ULONG DescriptorLength
35*/
36 );
37
38/* Adapted from ntoskrnl/config/cmsysini.c:CmpLinkKeyToHive() */
42 IN PCWSTR LinkKeyName,
43 IN PCWSTR TargetKeyName);
44
48 IN PCWSTR LinkKeyName);
49
50/*
51 * Should be called under SE_RESTORE_PRIVILEGE privilege
52 */
56 IN PCWSTR RegMountPoint,
57 // IN HANDLE RootDirectory OPTIONAL,
59 IN PCWSTR RegistryKey
60/*
61 IN PUCHAR Descriptor,
62 IN ULONG DescriptorLength
63*/
64 );
65
66/*
67 * Should be called under SE_RESTORE_PRIVILEGE privilege
68 */
72 IN PCWSTR RegMountPoint,
73 IN ULONG Flags);
74
75/*
76 * Should be called under SE_RESTORE_PRIVILEGE privilege
77 */
80 // IN HANDLE RootKey OPTIONAL,
81 // // IN HANDLE RootDirectory OPTIONAL,
83 IN PCWSTR RegistryKey /* ,
84 IN PCWSTR RegMountPoint */);
85
86/* EOF */
unsigned char BOOLEAN
LONG NTSTATUS
Definition: precomp.h:26
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
Definition: conport.c:36
_Must_inspect_result_ _Out_ PNDIS_STATUS _In_ NDIS_HANDLE _In_ ULONG _Out_ PNDIS_STRING _Out_ PNDIS_HANDLE KeyHandle
Definition: ndis.h:4715
ULONG ACCESS_MASK
Definition: nt_native.h:40
UNICODE_STRING NtSystemRoot
Definition: init.c:75
PVOID *typedef PHANDLE
Definition: ntsecpkg.h:455
NTSTATUS DisconnectRegistry(IN HANDLE RootKey OPTIONAL, IN PCWSTR RegMountPoint, IN ULONG Flags)
Definition: regutil.c:432
NTSTATUS VerifyRegistryHive(IN PUNICODE_STRING NtSystemRoot, IN PCWSTR RegistryKey)
Definition: regutil.c:455
NTSTATUS CreateNestedKey(PHANDLE KeyHandle, ACCESS_MASK DesiredAccess, POBJECT_ATTRIBUTES ObjectAttributes, ULONG CreateOptions)
Definition: regutil.c:33
NTSTATUS CreateRegistryFile(IN PUNICODE_STRING NtSystemRoot, IN PCWSTR RegistryKey, IN BOOLEAN IsHiveNew, IN HANDLE ProtoKeyHandle)
Definition: regutil.c:140
NTSTATUS CreateSymLinkKey(IN HANDLE RootKey OPTIONAL, IN PCWSTR LinkKeyName, IN PCWSTR TargetKeyName)
Definition: regutil.c:254
NTSTATUS DeleteSymLinkKey(IN HANDLE RootKey OPTIONAL, IN PCWSTR LinkKeyName)
Definition: regutil.c:318
NTSTATUS ConnectRegistry(IN HANDLE RootKey OPTIONAL, IN PCWSTR RegMountPoint, IN PUNICODE_STRING NtSystemRoot, IN PCWSTR RegistryKey)
Definition: regutil.c:391
static PMEMKEY RootKey
Definition: registry.c:55
PULONG MinorVersion OPTIONAL
Definition: CrossNt.h:68
const uint16_t * PCWSTR
Definition: typedefs.h:57
#define IN
Definition: typedefs.h:39
uint32_t ULONG
Definition: typedefs.h:59
_Must_inspect_result_ _In_ WDFDEVICE _In_ ULONG _In_ ACCESS_MASK DesiredAccess
Definition: wdfdevice.h:2658
_Must_inspect_result_ _In_opt_ WDFKEY _In_ PCUNICODE_STRING _In_ ACCESS_MASK _In_ ULONG CreateOptions
Definition: wdfregistry.h:118
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170