HyperDbg Debugger
Loading...
Searching...
No Matches
ud.h
Go to the documentation of this file.
1
12#pragma once
13
15// Structures //
17
37
39// Functions //
41
42VOID
44
45VOID
47
48VOID
50
51VOID
53
54VOID
55UdSetActiveDebuggingProcess(UINT64 DebuggingId,
56 UINT64 Rip,
57 UINT32 ProcessId,
58 UINT32 ThreadId,
59 BOOLEAN Is32Bit,
60 BOOLEAN IsPaused,
61 BYTE InstructionBytesOnRip[]);
62
64UdSendStepPacketToDebuggee(UINT64 ThreadDetailToken,
65 UINT32 TargetThreadId,
67
70
73
76
79
82
85 const WCHAR * TargetFileAddress,
86 const WCHAR * CommandLine,
87 BOOLEAN RunCallbackAtTheFirstInstruction);
88
90UdKillProcess(UINT32 TargetPid);
91
93UdDetachProcess(UINT32 TargetPid, UINT64 ProcessDetailToken);
94
96UdContinueProcess(UINT64 ProcessDebuggingToken);
97
99UdPauseProcess(UINT64 ProcessDebuggingToken);
100
102UdSendCommand(UINT64 ProcessDetailToken,
103 UINT32 ThreadId,
105 PVOID OptionalBuffer,
106 UINT32 OptionalBufferSize,
107 BOOLEAN ApplyToAllPausedThreads,
108 BOOLEAN WaitForEventCompletion,
109 UINT64 OptionalParam1,
110 UINT64 OptionalParam2,
111 UINT64 OptionalParam3,
112 UINT64 OptionalParam4);
113
115UdSendScriptBufferToProcess(UINT64 ProcessDetailToken,
116 UINT32 TargetThreadId,
117 UINT64 BufferAddress,
118 UINT32 BufferLength,
119 UINT32 Pointer,
120 BOOLEAN IsFormat);
121
123UdSendReadRegisterToUserDebugger(UINT64 ProcessDetailToken,
124 UINT32 TargetThreadId,
126 UINT32 RegBuffSize);
UCHAR BOOLEAN
Definition BasicTypes.h:35
void * PVOID
Definition BasicTypes.h:56
unsigned char BYTE
Definition BasicTypes.h:40
unsigned long DWORD
Definition BasicTypes.h:38
unsigned int UINT32
Definition BasicTypes.h:54
#define MAXIMUM_INSTR_SIZE
maximum instruction size in Intel
Definition Constants.h:470
struct _DEBUGGEE_UD_PAUSED_PACKET * PDEBUGGEE_UD_PAUSED_PACKET
enum _DEBUGGER_UD_COMMAND_ACTION_TYPE DEBUGGER_UD_COMMAND_ACTION_TYPE
User-mode debugging actions.
struct _DEBUGGEE_REGISTER_READ_DESCRIPTION * PDEBUGGEE_REGISTER_READ_DESCRIPTION
enum _DEBUGGER_REMOTE_STEPPING_REQUEST DEBUGGER_REMOTE_STEPPING_REQUEST
stepping and tracking types
BOOLEAN UdListProcessThreads(DWORD OwnerPID)
List of threads by owner process id.
Definition ud.cpp:206
BOOLEAN UdSetActiveDebuggingThreadByPidOrTid(UINT32 TargetPidOrTid, BOOLEAN IsTid)
Set the active debugging thread by process id or thread id.
Definition ud.cpp:1314
BOOLEAN UdPauseProcess(UINT64 ProcessDebuggingToken)
Pause the target process.
Definition ud.cpp:865
BOOLEAN UdSendScriptBufferToProcess(UINT64 ProcessDetailToken, UINT32 TargetThreadId, UINT64 BufferAddress, UINT32 BufferLength, UINT32 Pointer, BOOLEAN IsFormat)
Send script buffer to the user debugger.
Definition ud.cpp:1176
VOID UdSetActiveDebuggingProcess(UINT64 DebuggingId, UINT64 Rip, UINT32 ProcessId, UINT32 ThreadId, BOOLEAN Is32Bit, BOOLEAN IsPaused, BYTE InstructionBytesOnRip[])
set the current active debugging process (thread)
Definition ud.cpp:112
BOOLEAN UdSendCommand(UINT64 ProcessDetailToken, UINT32 ThreadId, DEBUGGER_UD_COMMAND_ACTION_TYPE ActionType, PVOID OptionalBuffer, UINT32 OptionalBufferSize, BOOLEAN ApplyToAllPausedThreads, BOOLEAN WaitForEventCompletion, UINT64 OptionalParam1, UINT64 OptionalParam2, UINT64 OptionalParam3, UINT64 OptionalParam4)
Send the command to the user debugger.
Definition ud.cpp:1010
VOID UdInitializeUserDebugger()
initialize user debugger
Definition Ud.c:21
struct _ACTIVE_DEBUGGING_PROCESS * PACTIVE_DEBUGGING_PROCESS
BOOLEAN UdSendReadRegisterToUserDebugger(UINT64 ProcessDetailToken, UINT32 TargetThreadId, PDEBUGGEE_REGISTER_READ_DESCRIPTION RegDes, UINT32 RegBuffSize)
Send the command to the user debugger.
Definition ud.cpp:1142
VOID UdRemoveActiveDebuggingProcess()
Remove the current active debugging process (thread).
Definition ud.cpp:152
BOOLEAN UdDetachProcess(UINT32 TargetPid, UINT64 ProcessDetailToken)
Detach the target process.
Definition ud.cpp:786
struct _ACTIVE_DEBUGGING_PROCESS ACTIVE_DEBUGGING_PROCESS
structures related to current thread debugging state
BOOLEAN UdSendStepPacketToDebuggee(UINT64 ThreadDetailToken, UINT32 TargetThreadId, DEBUGGER_REMOTE_STEPPING_REQUEST StepType)
Send stepping instructions packet to user debugger.
Definition ud.cpp:1246
BOOLEAN UdShowListActiveDebuggingProcessesAndThreads()
Show list of active debugging processes and threads.
Definition ud.cpp:1397
BOOLEAN UdCheckThreadByProcessId(DWORD Pid, DWORD Tid)
Check if a thread belongs to special process.
Definition ud.cpp:266
VOID UdUninitializeUserDebugger()
uninitialize user debugger
Definition Ud.c:90
BOOLEAN UdContinueProcess(UINT64 ProcessDebuggingToken)
Continue the target process.
Definition ud.cpp:933
BOOLEAN UdKillProcess(UINT32 TargetPid)
Kill the target process from kernel.
Definition ud.cpp:688
VOID UdHandleUserDebuggerPausing(PDEBUGGEE_UD_PAUSED_PACKET PausePacket)
Handle pause packets from user debugger.
Definition user-listening.cpp:29
BOOLEAN UdAttachToProcess(UINT32 TargetPid, const WCHAR *TargetFileAddress, const WCHAR *CommandLine, BOOLEAN RunCallbackAtTheFirstInstruction)
Attach to target process.
Definition ud.cpp:372
structures related to current thread debugging state
Definition ud.h:24
UINT32 ProcessId
Definition ud.h:27
UINT64 Context
Definition ud.h:31
UINT64 Rip
Definition ud.h:32
GUEST_REGS Registers
Definition ud.h:30
BOOLEAN IsActive
Definition ud.h:25
UINT32 ThreadId
Definition ud.h:28
UINT64 ProcessDebuggingToken
Definition ud.h:26
BYTE InstructionBytesOnRip[MAXIMUM_INSTR_SIZE]
Definition ud.h:34
BOOLEAN Is32Bit
Definition ud.h:33
BOOLEAN IsPaused
Definition ud.h:29
Definition BasicTypes.h:136