ReactOS
0.4.15-dev-2155-g06f57e1
|
#include <ntdef.h>
#include <ntifs.h>
#include <bugcodes.h>
#include <wine/unicode.h>
#include <wchar.h>
#include "hivedata.h"
#include "cmdata.h"
Go to the source code of this file.
Classes | |
struct | _HV_HIVE_CELL_PAIR |
struct | _HV_TRACK_CELL_REF |
Macros | |
#define | _CMLIB_DEBUG_ 1 |
#define | CMLTRACE(x, ...) if (x & CmlibTraceLevel) DbgPrint(__VA_ARGS__) |
#define | PAGED_CODE() |
#define | _WINDEF_ |
#define | _WINBASE_ |
#define | _WINNLS_ |
#define | CMLIB_HCELL_DEBUG 0x01 |
#define | ROUND_UP(a, b) ((((a)+(b)-1)/(b))*(b)) |
#define | ROUND_DOWN(a, b) (((a)/(b))*(b)) |
#define | TAG_CM ' MC' |
#define | TAG_KCB 'bkMC' |
#define | TAG_CMHIVE 'vHMC' |
#define | TAG_CMSD 'DSMC' |
#define | CMAPI NTAPI |
#define | STATIC_CELL_PAIR_COUNT 4 |
#define | ASSERT_VALUE_BIG(h, s) ASSERTMSG("Big keys not supported!\n", !CmpIsKeyValueBig(h, s)); |
#define | HvReleaseCell(h, c) |
Typedefs | |
typedef struct _HV_HIVE_CELL_PAIR | HV_HIVE_CELL_PAIR |
typedef struct _HV_HIVE_CELL_PAIR * | PHV_HIVE_CELL_PAIR |
typedef struct _HV_TRACK_CELL_REF | HV_TRACK_CELL_REF |
typedef struct _HV_TRACK_CELL_REF * | PHV_TRACK_CELL_REF |
Variables | |
ULONG | CmlibTraceLevel |
typedef struct _HV_HIVE_CELL_PAIR * PHV_HIVE_CELL_PAIR |
typedef struct _HV_TRACK_CELL_REF * PHV_TRACK_CELL_REF |
Definition at line 17 of file cminit.c.
Referenced by CmiInitializeHive().
BOOLEAN NTAPI CmpAddSubKey | ( | IN PHHIVE | Hive, |
IN HCELL_INDEX | Parent, | ||
IN HCELL_INDEX | Child | ||
) |
Definition at line 1467 of file cmindex.c.
Referenced by CmiAddSubKey(), CmpCreateLinkNode(), CmpDeepCopyKeyInternal(), and CmpDoCreate().
NTSTATUS NTAPI CmpAddValueToList | ( | IN PHHIVE | Hive, |
IN HCELL_INDEX | ValueCell, | ||
IN ULONG | Index, | ||
IN HSTORAGE_TYPE | StorageType, | ||
IN OUT PCHILD_LIST | ChildList | ||
) |
Definition at line 207 of file cmvalue.c.
Referenced by CmiAddValueKey(), CmpCopyKeyValueList(), and CmpSetValueKeyNew().
Definition at line 34 of file registry.c.
Referenced by CmiInitializeHive(), and RegImportBinaryHive().
LONG NTAPI CmpCompareCompressedName | ( | IN PCUNICODE_STRING | SearchName, |
IN PWCHAR | CompressedName, | ||
IN ULONG | NameLength | ||
) |
Definition at line 109 of file cmname.c.
Referenced by CmpDoCompareKeyName(), CmpFindNameInList(), CmpFindValueByNameFromCache(), and CmpGetNameControlBlock().
Definition at line 95 of file cmname.c.
Referenced by BiEnumerateSubKeys(), CmpAddDriverToList(), CmpAddSubKey(), CmpConstructName(), CmpGetHiveName(), CmpIsSafe(), CmpMarkIndexDirty(), CmpQueryKeyData(), CmpQueryKeyDataFromCache(), CmpQueryKeyValueData(), CmpQueryNameInformation(), CmpRemoveSubKey(), and RegEnumKey().
ULONG NTAPI CmpComputeHashKey | ( | IN ULONG | Hash, |
IN PCUNICODE_STRING | Name, | ||
IN BOOLEAN | AllowSeparators | ||
) |
Definition at line 460 of file cmindex.c.
Referenced by CmpAddToLeaf(), and CmpFindSubKeyByHash().
VOID NTAPI CmpCopyCompressedName | ( | OUT PWCHAR | Destination, |
IN ULONG | DestinationLength, | ||
IN PWCHAR | Source, | ||
IN ULONG | SourceLength | ||
) |
Definition at line 56 of file cmname.c.
Referenced by BiEnumerateSubKeys(), CmpAddDriverToList(), CmpAddSubKey(), CmpGetHiveName(), CmpIsSafe(), CmpMarkIndexDirty(), CmpQueryKeyData(), CmpQueryKeyValueData(), CmpQueryNameInformation(), CmpRemoveSubKey(), and RegEnumKey().
NTSTATUS NTAPI CmpCopyKeyValueList | ( | IN PHHIVE | SourceHive, |
IN PCHILD_LIST | SrcValueList, | ||
IN PHHIVE | DestinationHive, | ||
IN OUT PCHILD_LIST | DestValueList, | ||
IN HSTORAGE_TYPE | StorageType | ||
) |
Definition at line 521 of file cmvalue.c.
Referenced by CmpDeepCopyKeyInternal().
Definition at line 21 of file cmname.c.
Referenced by CmCreateRootNode(), CmiAddValueKey(), CmiCreateSubKey(), CmpCreateLinkNode(), CmpCreateRootNode(), CmpDoCreateChild(), and CmpSetValueKeyNew().
BOOLEAN NTAPI CmpFindNameInList | ( | IN PHHIVE | Hive, |
IN PCHILD_LIST | ChildList, | ||
IN PUNICODE_STRING | Name, | ||
OUT PULONG ChildIndex | OPTIONAL, | ||
OUT PHCELL_INDEX | CellIndex | ||
) |
Definition at line 149 of file cmname.c.
Referenced by BiGetRegistryValue(), CmDeleteValueKey(), CmpFindValueByName(), CmSetValueKey(), RegDeleteValueW(), and RegSetValueExW().
HCELL_INDEX NTAPI CmpFindSubKeyByName | ( | IN PHHIVE | Hive, |
IN PCM_KEY_NODE | Parent, | ||
IN PCUNICODE_STRING | SearchName | ||
) |
Definition at line 683 of file cmindex.c.
Referenced by BiLoadHive(), BiOpenKey(), CmGetSystemControlValues(), CmpDoCreate(), CmpFindControlSet(), CmpFindDrivers(), CmpIsSafe(), CmpParseKey(), CmpSortDriverList(), CmpWalkPath(), RegOpenKey(), and RegpCreateOrOpenKey().
HCELL_INDEX NTAPI CmpFindSubKeyByNumber | ( | IN PHHIVE | Hive, |
IN PCM_KEY_NODE | Node, | ||
IN ULONG | Number | ||
) |
Definition at line 600 of file cmindex.c.
Referenced by BiEnumerateSubKeys(), CmEnumerateKey(), CmpDeepCopyKeyInternal(), CmpFindDrivers(), and RegEnumKey().
HCELL_INDEX NTAPI CmpFindValueByName | ( | IN PHHIVE | Hive, |
IN PCM_KEY_NODE | KeyNode, | ||
IN PUNICODE_STRING | Name | ||
) |
Definition at line 99 of file cmvalue.c.
Referenced by CmGetSystemControlValues(), CmpAddDriverToList(), CmpFindControlSet(), CmpFindTagIndex(), CmpGetSymbolicLink(), CmpIsLoadType(), CmpIsSafe(), CmpSortDriverList(), RegQueryValue(), and RegQueryValueExW().
Definition at line 47 of file registry.c.
Referenced by CmiInitializeHive(), and RegImportBinaryHive().
Definition at line 159 of file cmkeydel.c.
Referenced by BiDeleteKey(), CmDeleteKey(), CmpUnlinkHiveFromMaster(), and RegDeleteKeyW().
Definition at line 65 of file cmse.c.
Referenced by CmpFreeKeyByCell().
Definition at line 73 of file cmvalue.c.
Referenced by CmDeleteValueKey(), CmiAddValueKey(), CmpCopyKeyValueList(), CmpFreeKeyByCell(), CmpSetValueKeyNew(), and RegDeleteValueW().
Definition at line 44 of file cmvalue.c.
Referenced by CmpFreeValue(), and CmpSetValueKeyExisting().
BOOLEAN NTAPI CmpGetValueData | ( | IN PHHIVE | Hive, |
IN PCM_KEY_VALUE | Value, | ||
OUT PULONG | Length, | ||
OUT PVOID * | Buffer, | ||
OUT PBOOLEAN | BufferAllocated, | ||
OUT PHCELL_INDEX | CellToRelease | ||
) |
Definition at line 125 of file cmvalue.c.
Referenced by CmpFindTagIndex(), CmpGetSymbolicLink(), CmpGetValueDataFromCache(), and CmpValueToData().
Definition at line 324 of file cmlib.h.
Referenced by CmGetSystemControlValues(), CmpCopyValue(), CmpFreeValueData(), CmpGetValueData(), CmpMarkValueDataDirty(), CmpQueryKeyValueData(), and CmpSetValueKeyExisting().
BOOLEAN NTAPI CmpMarkIndexDirty | ( | IN PHHIVE | Hive, |
HCELL_INDEX | ParentKey, | ||
HCELL_INDEX | TargetKey | ||
) |
Definition at line 19 of file cmvalue.c.
Referenced by CmDeleteValueKey(), CmpMarkKeyDirty(), CmpSetValueKeyExisting(), and RegDeleteValueW().
Definition at line 74 of file cmname.c.
Referenced by CmCreateRootNode(), CmiAddValueKey(), CmiCreateSubKey(), CmpCreateLinkNode(), CmpCreateRootNode(), CmpDoCreateChild(), and CmpSetValueKeyNew().
Definition at line 19 of file cmse.c.
Referenced by CmpFreeSecurityDescriptor().
BOOLEAN NTAPI CmpRemoveSubKey | ( | IN PHHIVE | Hive, |
IN HCELL_INDEX | ParentKey, | ||
IN HCELL_INDEX | TargetKey | ||
) |
Definition at line 1696 of file cmindex.c.
Referenced by CmpFreeKeyByCell().
NTSTATUS NTAPI CmpRemoveValueFromList | ( | IN PHHIVE | Hive, |
IN ULONG | Index, | ||
IN OUT PCHILD_LIST | ChildList | ||
) |
Definition at line 320 of file cmvalue.c.
Referenced by CmDeleteValueKey(), and RegDeleteValueW().
Definition at line 135 of file cminit.c.
Referenced by BiInitializeAndValidateHive(), and HvInitialize().
NTSTATUS NTAPI CmpSetValueDataNew | ( | IN PHHIVE | Hive, |
IN PVOID | Data, | ||
IN ULONG | DataSize, | ||
IN HSTORAGE_TYPE | StorageType, | ||
IN HCELL_INDEX | ValueCell, | ||
OUT PHCELL_INDEX | DataCell | ||
) |
Definition at line 289 of file cmvalue.c.
Referenced by CmpSetValueKeyNew().
PCELL_DATA NTAPI CmpValueToData | ( | IN PHHIVE | Hive, |
IN PCM_KEY_VALUE | Value, | ||
OUT PULONG | Length | ||
) |
Definition at line 167 of file cmvalue.c.
Referenced by BiGetRegistryValue(), CmpAddDriverToList(), CmpFindControlSet(), CmpFindTagIndex(), CmpIsLoadType(), CmpIsSafe(), CmpSortDriverList(), and RepGetValueData().
HCELL_INDEX CMAPI HvAllocateCell | ( | PHHIVE | RegistryHive, |
ULONG | Size, | ||
HSTORAGE_TYPE | Storage, | ||
IN HCELL_INDEX | Vicinity | ||
) |
Referenced by CmCreateRootNode(), CmiAddValueKey(), CmiCreateSecurityKey(), CmiCreateSubKey(), CmpAddSubKey(), CmpAddValueToList(), CmpCopyCell(), CmpCreateLinkNode(), CmpCreateRootNode(), CmpDoCreateChild(), CmpSetValueDataNew(), CmpSetValueKeyExisting(), CmpSetValueKeyNew(), CmpSplitLeaf(), and RegSetValueExW().
Definition at line 623 of file hiveinit.c.
Referenced by CmiInitializeHive(), CmpDestroyHive(), and CmUnloadKey().
VOID CMAPI HvFreeCell | ( | PHHIVE | RegistryHive, |
HCELL_INDEX | CellOffset | ||
) |
Definition at line 441 of file hivecell.c.
Referenced by CmCreateRootNode(), CmiAddValueKey(), CmiCreateSubKey(), CmpCopyKeyValueList(), CmpCopyValue(), CmpDeepCopyKeyInternal(), CmpDoCreateChild(), CmpFreeKeyBody(), CmpFreeKeyByCell(), CmpFreeSecurityDescriptor(), CmpFreeValue(), CmpFreeValueData(), CmpRemoveSubKey(), CmpRemoveValueFromList(), CmpSetValueKeyNew(), CmpSplitLeaf(), HvReallocateCell(), and RegSetValueExW().
PVOID CMAPI HvGetCell | ( | PHHIVE | RegistryHive, |
HCELL_INDEX | CellOffset | ||
) |
Definition at line 67 of file hivecell.c.
Referenced by BiEnumerateSubKeys(), BiGetRegistryValue(), BiLoadHive(), BiOpenKey(), CmCreateRootNode(), CmDeleteKey(), CmDeleteValueKey(), CmEnumerateKey(), CmEnumerateValueKey(), CmGetSystemControlValues(), CmiAddSubKey(), CmiAddValueKey(), CmiCreateSecurityKey(), CmiCreateSubKey(), CmpAddDriverToList(), CmpAddSubKey(), CmpAddToLeaf(), CmpAddValueToList(), CmpCleanUpSubKeyInfo(), CmpCompareNewValueDataAgainstKCBCache(), CmpConstructName(), CmpCopyCell(), CmpCopyKeyValueList(), CmpCopyValue(), CmpCreateLinkNode(), CmpCreateRegistryRoot(), CmpCreateRootNode(), CmpDeepCopyKeyInternal(), CmpDoCompareKeyName(), CmpDoCreate(), CmpDoCreateChild(), CmpDoFindSubKeyByNumber(), CmpFindControlSet(), CmpFindDrivers(), CmpFindNameInList(), CmpFindSubKeyByName(), CmpFindSubKeyByNumber(), CmpFindSubKeyInRoot(), CmpFindTagIndex(), CmpFreeKeyBody(), CmpFreeKeyByCell(), CmpFreeSecurityDescriptor(), CmpFreeValue(), CmpGetHiveName(), CmpGetSymbolicLink(), CmpGetValueData(), CmpGetValueKeyFromCache(), CmpGetValueListFromCache(), CmpHandleExitNode(), CmpIsLoadType(), CmpIsSafe(), CmpMarkIndexDirty(), CmpMarkKeyDirty(), CmpParseKey(), CmpPrepareIndexOfKeys(), CmpPrepareKey(), CmpQueryKeyData(), CmpQueryKeyDataFromCache(), CmpRemoveSecurityCellList(), CmpRemoveSubKey(), CmpRemoveValueFromList(), CmPrepareHive(), CmpSelectLeaf(), CmpSetValueDataNew(), CmpSetValueKeyExisting(), CmpSetValueKeyNew(), CmpSortDriverList(), CmpSplitLeaf(), CmpUnlinkHiveFromMaster(), CmpWalkPath(), CmQueryKey(), CmSetValueKey(), HvpFindFree(), HvpRemoveFree(), HvReallocateCell(), RegDeleteKeyW(), RegDeleteValueW(), RegEnumKey(), RegImportBinaryHive(), RegOpenKey(), RegpCreateOrOpenKey(), RegQueryValue(), RegQueryValueExW(), and RegSetValueExW().
Referenced by CmpAddToLeaf(), CmpCopyCell(), CmpSetValueKeyExisting(), CmpSplitLeaf(), and RegSetValueExW().
NTSTATUS CMAPI HvInitialize | ( | PHHIVE | RegistryHive, |
ULONG | OperationType, | ||
ULONG | HiveFlags, | ||
ULONG | FileType, | ||
PVOID HiveData | OPTIONAL, | ||
PALLOCATE_ROUTINE | Allocate, | ||
PFREE_ROUTINE | Free, | ||
PFILE_SET_SIZE_ROUTINE | FileSetSize, | ||
PFILE_WRITE_ROUTINE | FileWrite, | ||
PFILE_READ_ROUTINE | FileRead, | ||
PFILE_FLUSH_ROUTINE | FileFlush, | ||
ULONG Cluster | OPTIONAL, | ||
PCUNICODE_STRING FileName | OPTIONAL | ||
) |
Definition at line 522 of file hiveinit.c.
Referenced by BiInitializeAndValidateHive(), CmGetSystemControlValues(), CmiInitializeHive(), CmpInitializeHive(), and RegImportBinaryHive().
Definition at line 43 of file hivecell.c.
Definition at line 126 of file hivecell.c.
Referenced by CmDeleteKey(), CmDeleteValueKey(), CmpAddValueToList(), CmpRemoveSubKey(), CmpRemoveValueFromList(), CmpSetValueKeyExisting(), CmpSetValueKeyNew(), RegDeleteKeyW(), and RegDeleteValueW().
BOOLEAN CMAPI HvMarkCellDirty | ( | PHHIVE | RegistryHive, |
HCELL_INDEX | CellOffset, | ||
BOOLEAN | HoldingLock | ||
) |
Definition at line 100 of file hivecell.c.
Referenced by CmDeleteValueKey(), CmiAddSubKey(), CmiAddValueKey(), CmpAddSubKey(), CmpAddToLeaf(), CmpCreateLinkNode(), CmpDoCreate(), CmpMarkIndexDirty(), CmpMarkKeyDirty(), CmpMarkValueDataDirty(), CmpSelectLeaf(), CmpSetValueKeyExisting(), CmpSetValueKeyNew(), CmpSplitLeaf(), CmSetValueKey(), HvAllocateCell(), HvFreeCell(), RegDeleteValueW(), and RegSetValueExW().
PHBIN CMAPI HvpAddBin | ( | PHHIVE | RegistryHive, |
ULONG | Size, | ||
HSTORAGE_TYPE | Storage | ||
) |
Definition at line 12 of file hivebin.c.
Referenced by HvAllocateCell().
Definition at line 279 of file hivecell.c.
Referenced by HvpInitializeMemoryHive().
ULONG CMAPI HvpHiveHeaderChecksum | ( | PHBASE_BLOCK | HiveHeader | ) |
Definition at line 17 of file hivesum.c.
Referenced by CmCreateRootNode(), HvIsInPlaceBaseBlockValid(), HvpVerifyHiveHeader(), HvpWriteHive(), and HvpWriteLog().
HCELL_INDEX CMAPI HvReallocateCell | ( | PHHIVE | RegistryHive, |
HCELL_INDEX | CellOffset, | ||
ULONG | Size | ||
) |
Definition at line 394 of file hivecell.c.
Referenced by CmpAddToLeaf(), CmpAddValueToList(), CmpRemoveValueFromList(), CmpSetValueKeyExisting(), and CmpSplitLeaf().
VOID CMAPI HvReleaseFreeCellRefArray | ( | IN OUT PHV_TRACK_CELL_REF | CellRef | ) |
Definition at line 607 of file hivecell.c.
Referenced by CmEnumerateKey(), and CmQueryKey().
Definition at line 243 of file hivewrt.c.
Referenced by CmFlushKey(), CmLoadKey(), CmpDoFlushAll(), and CmpDoFlushNextHive().
BOOLEAN CMAPI HvTrackCellRef | ( | IN OUT PHV_TRACK_CELL_REF | CellRef, |
IN PHHIVE | Hive, | ||
IN HCELL_INDEX | Cell | ||
) |
Definition at line 527 of file hivecell.c.
Referenced by CmEnumerateKey(), and CmQueryKey().
Definition at line 285 of file hivewrt.c.
Referenced by CmSaveKey(), CmSaveMergedKeys(), and ExportBinaryHive().