1 /* 2 * FreeLoader - registry.h 3 * 4 * Copyright (C) 2001 Eric Kohl 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License as published by 8 * the Free Software Foundation; either version 2 of the License, or 9 * (at your option) any later version. 10 * 11 * This program is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 * GNU General Public License for more details. 15 * 16 * You should have received a copy of the GNU General Public License along 17 * with this program; if not, write to the Free Software Foundation, Inc., 18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 19 */ 20 21 #ifndef __REGISTRY_H 22 #define __REGISTRY_H 23 24 #include <cmlib.h> 25 26 typedef HANDLE HKEY, *PHKEY; 27 28 #define HKEY_TO_HCI(hKey) ((HCELL_INDEX)(ULONG_PTR)(hKey)) 29 30 BOOLEAN 31 RegImportBinaryHive( 32 _In_ PVOID ChunkBase, 33 _In_ ULONG ChunkSize); 34 35 BOOLEAN 36 RegInitCurrentControlSet( 37 _In_ BOOLEAN LastKnownGood); 38 39 extern PHHIVE SystemHive; 40 extern HKEY CurrentControlSetKey; 41 42 /* 43 * LONG 44 * RegCloseKey( 45 * _In_ HKEY hKey); 46 */ 47 #define RegCloseKey(hKey) (ERROR_SUCCESS) 48 49 #if 0 50 LONG 51 RegEnumKey( 52 _In_ HKEY Key, 53 _In_ ULONG Index, 54 _Out_ PWCHAR Name, 55 _Inout_ PULONG NameSize, 56 _Out_opt_ PHKEY SubKey); 57 #endif 58 59 LONG 60 RegOpenKey( 61 _In_ HKEY ParentKey, 62 _In_z_ PCWSTR KeyName, 63 _Out_ PHKEY Key); 64 65 LONG 66 RegQueryValue( 67 _In_ HKEY Key, 68 _In_z_ PCWSTR ValueName, 69 _Out_opt_ PULONG Type, 70 _Out_opt_ PUCHAR Data, 71 _Inout_opt_ PULONG DataSize); 72 73 #if 0 74 LONG 75 RegEnumValue( 76 _In_ HKEY Key, 77 _In_ ULONG Index, 78 _Out_ PWCHAR ValueName, 79 _Inout_ PULONG NameSize, 80 _Out_opt_ PULONG Type, 81 _Out_opt_ PUCHAR Data, 82 _Inout_opt_ PULONG DataSize) 83 #endif 84 85 #endif /* __REGISTRY_H */ 86 87 /* EOF */ 88