395{
397 {
401
403 {
404 {
L"TestHive1",
L"\\Registry\\Machine\\TestHive1" },
405 {
L"TestHive2",
L"\\Registry\\Machine\\TestHive2" },
406 };
407
416
418
419
421
422
425 {
426 skip(
"RtlAdjustPrivilege(SE_RESTORE_PRIVILEGE) failed (Status 0x%08lx)\n",
Status);
427
428
430 return;
431 }
432
433
436 {
437 skip(
"RtlAdjustPrivilege(SE_BACKUP_PRIVILEGE) failed (Status 0x%08lx)\n",
Status);
439
440
442 return;
443 }
444
445
448 {
449 skip(
"CreateProtoHive() failed to create the proto-hive; Status 0x%08lx\n",
Status);
451 }
452
453
455 {
460 {
462
463 break;
464 }
465 }
466
467
469
470
473
474
475
476
477
478
483 {
484 DPRINT1(
"ConnectRegistry('%wZ\\%S', '%S') failed, Status 0x%08lx\n",
486 }
487
488
491
499 {
501 }
502 else
503 {
504 DPRINT1(
"CreateRegKey(%wZ) succeeded to %s the key (Status %lx)\n",
508 }
509
510
513
514
518
519
522
523
527
528
532 {
534 }
535
536
539
540
543
544
545
546
547
548
553 {
554 DPRINT1(
"ConnectRegistry('%wZ\\%S', '%S') failed, Status 0x%08lx\n",
556 }
557
558
561
569 {
571 }
572 else
573 {
574 DPRINT1(
"CreateRegKey(%wZ) succeeded to %s the key (Status %lx)\n",
578 }
579
580
583
584
587
588
591
592
596
597
601
602#if 0
603
606#endif
607
608
609
610
611
613
614
616 {
621 }
622
623
626
628}
static NTSTATUS ConnectRegistry(IN HANDLE RootKey OPTIONAL, IN PCWSTR RegMountPoint, IN HANDLE RootDirectory OPTIONAL, IN PUNICODE_STRING RootPath OPTIONAL, IN PCWSTR RegistryKey)
static NTSTATUS MyDeleteFile(IN HANDLE RootDirectory OPTIONAL, IN PUNICODE_STRING RootPath OPTIONAL, IN PCWSTR FileName, IN BOOLEAN ForceDelete)
static NTSTATUS CreateRegistryFile(IN HANDLE RootDirectory OPTIONAL, IN PUNICODE_STRING RootPath OPTIONAL, IN PCWSTR RegistryKey, IN HANDLE ProtoKeyHandle)
static VOID DestroyProtoHive(IN HANDLE KeyHandle)
#define REG_CREATED_NEW_KEY
static NTSTATUS CreateProtoHive(OUT PHANDLE KeyHandle)
static NTSTATUS DisconnectRegistry(IN HANDLE RootKey OPTIONAL, IN PCWSTR RegMountPoint, IN ULONG Flags)
static BOOLEAN RetrieveCurrentModuleNTDirectory(OUT PUNICODE_STRING NtPath)
#define ok_hex(expression, result)
#define ok_ntstatus(status, expected)
HIVE_LIST_ENTRY RegistryHives[]
struct _HIVE_LIST_ENTRY HIVE_LIST_ENTRY
#define GetProcAddress(x, y)
HMODULE WINAPI GetModuleHandleW(LPCWSTR lpModuleName)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define SE_BACKUP_PRIVILEGE
#define SE_RESTORE_PRIVILEGE
NTSYSAPI NTSTATUS NTAPI RtlAdjustPrivilege(_In_ ULONG Privilege, _In_ BOOLEAN NewValue, _In_ BOOLEAN ForThread, _Out_ PBOOLEAN OldValue)
NTSYSAPI VOID NTAPI RtlFreeUnicodeString(PUNICODE_STRING UnicodeString)
#define STATUS_KEY_DELETED
#define STATUS_HIVE_UNLOADED
#define STATUS_CANNOT_DELETE
STRSAFEAPI StringCchPrintfW(STRSAFE_LPWSTR pszDest, size_t cchDest, STRSAFE_LPCWSTR pszFormat,...)