HyperDbg Debugger
Loading...
Searching...
No Matches
Layout.h File Reference

Header files for working with memory layouts. More...

Go to the source code of this file.

Functions

CR3_TYPE LayoutGetCr3ByProcessId (_In_ UINT32 ProcessId)
 
UINT64 LayoutGetSystemDirectoryTableBase ()
 Find cr3 of system process.
 

Detailed Description

Header files for working with memory layouts.

Author
Sina Karvandi (sina@.nosp@m.hype.nosp@m.rdbg..nosp@m.org)
Version
0.2
Date
2023-04-27

Function Documentation

◆ LayoutGetCr3ByProcessId()

CR3_TYPE LayoutGetCr3ByProcessId ( _In_ UINT32 ProcessId)

◆ LayoutGetSystemDirectoryTableBase()

UINT64 LayoutGetSystemDirectoryTableBase ( )

Find cr3 of system process.

Returns
UINT64 Returns cr3 of System process (pid=4)
91{
92 //
93 // Return CR3 of the system process.
94 //
95 NT_KPROCESS * SystemProcess = (NT_KPROCESS *)(PsInitialSystemProcess);
96 return SystemProcess->DirectoryTableBase;
97}
KPROCESS Brief structure.
Definition Common.h:265
ULONG_PTR DirectoryTableBase
Definition Common.h:268