-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathHwBpEngine.h
57 lines (45 loc) · 1.06 KB
/
HwBpEngine.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
//
// Created by kali on 19/09/23.
//
#ifndef PSINLINE_HWBPENGINE_H
#define PSINLINE_HWBPENGINE_H
#include <windows.h>
#include <ntstatus.h>
typedef struct _BP_LIST
{
DWORD Tid;
PVOID Address;
PVOID Function;
BYTE Position;
/* next in the list */
struct _BP_LIST* Next;
} BP_LIST, *PBP_LIST;
typedef struct _HWBP_ENGINE
{
/* Veh (Vectored Exception Handling) handle */
HANDLE Veh;
/* first time adding hw bp. need to prepare register */
BYTE First;
/* list of breakpoints */
PBP_LIST Breakpoints;
} HWBP_ENGINE, *PHWBP_ENGINE;
NTSTATUS HwBpEngineInit(
OUT PHWBP_ENGINE Engine,
IN PVOID Exception
);
NTSTATUS HwBpEngineAdd(
IN PHWBP_ENGINE Engine,
IN DWORD Tid,
IN PVOID Address,
IN PVOID Function,
IN BYTE Position
);
NTSTATUS HwBpEngineRemove(
IN PHWBP_ENGINE Engine,
IN DWORD Tid,
IN PVOID Address
);
NTSTATUS HwBpEngineDestroy(
IN PHWBP_ENGINE Engine
);
#endif //PSINLINE_HWBPENGINE_H