ReactOS 0.4.15-dev-8102-g108db8f
hook.h
Go to the documentation of this file.
1#pragma once
2
3#define HOOK_THREAD_REFERENCED (0x1)
4#define HOOKID_TO_INDEX(HookId) (HookId - WH_MINHOOK)
5#define HOOKID_TO_FLAG(HookId) (1 << ((HookId) + 1))
6#define ISITHOOKED(HookId) (((PTHREADINFO)PsGetCurrentThreadWin32Thread())->fsHooks & HOOKID_TO_FLAG(HookId))
7
8/* NOTE: The following definition is not a real hook but
9 a pseudo-id that will be used only for
10 injecting user api hook module to all processes.
11 It is used internally in win32k */
12#define WH_APIHOOK WH_MAX + 1
13
14
15typedef struct tagEVENTHOOK
16{
18 LIST_ENTRY Chain; /* Event chain entry */
23 WINEVENTPROC Proc; /* Event function */
24 ULONG Flags; /* Some internal flags */
28
29typedef struct tagEVENTTABLE
30{
34
35typedef struct _NOTIFYEVENT
36{
42
52
54BOOL IntLoadHookModule(int iHookID, HHOOK hHook, BOOL Unload);
56
58
59/* EOF */
unsigned char BOOLEAN
WPARAM wParam
Definition: combotst.c:138
LPARAM lParam
Definition: combotst.c:139
#define APIENTRY
Definition: api.h:79
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
static VOID NTAPI Unload(PDRIVER_OBJECT DriverObject)
Definition: floppy.c:377
LRESULT APIENTRY co_EVENT_CallEvents(DWORD, HWND, UINT_PTR, LONG_PTR)
Definition: event.c:150
struct tagEVENTTABLE EVENTTABLE
LRESULT APIENTRY UserCallNextHookEx(PHOOK pHook, int Code, WPARAM wParam, LPARAM lParam, BOOL Ansi)
LRESULT APIENTRY co_CallHook(INT HookId, INT Code, WPARAM wParam, LPARAM lParam)
Definition: hook.c:321
BOOL FASTCALL UserUnregisterUserApiHook(VOID)
Definition: hook.c:206
BOOLEAN IntRemoveEvent(PVOID Object)
Definition: event.c:126
PHOOK FASTCALL IntGetNextHook(PHOOK Hook)
Definition: hook.c:995
struct _NOTIFYEVENT NOTIFYEVENT
LRESULT APIENTRY co_HOOK_CallHooks(INT HookId, INT Code, WPARAM wParam, LPARAM lParam)
Definition: hook.c:1102
struct tagEVENTTABLE * PEVENTTABLE
BOOL FASTCALL UserLoadApiHook(VOID)
Definition: hook.c:131
struct tagEVENTHOOK * PEVENTHOOK
PHOOK FASTCALL IntGetHookObject(HHOOK)
Definition: hook.c:937
PPROCESSINFO ppiUahServer
Definition: hook.c:24
struct _NOTIFYEVENT * PNOTIFYEVENT
BOOL FASTCALL IntUnhookWindowsHook(int, HOOKPROC)
Definition: hook.c:1319
BOOLEAN IntRemoveHook(PVOID Object)
Definition: hook.c:1036
BOOL IntLoadHookModule(int iHookID, HHOOK hHook, BOOL Unload)
Definition: hook.c:30
struct tagEVENTHOOK EVENTHOOK
__int3264 LONG_PTR
Definition: mstsclib_h.h:276
unsigned __int3264 UINT_PTR
Definition: mstsclib_h.h:274
unsigned int UINT
Definition: ndis.h:50
#define FASTCALL
Definition: nt_native.h:50
long LONG
Definition: pedump.c:60
Definition: typedefs.h:120
LONG idChild
Definition: hook.h:39
DWORD flags
Definition: hook.h:40
LONG idObject
Definition: hook.h:38
DWORD event
Definition: hook.h:37
UINT eventMax
Definition: hook.h:20
DWORD idThread
Definition: hook.h:22
WINEVENTPROC Proc
Definition: hook.h:23
ULONG_PTR offPfn
Definition: hook.h:25
INT_PTR ihmod
Definition: hook.h:26
LIST_ENTRY Chain
Definition: hook.h:18
UINT eventMin
Definition: hook.h:19
THROBJHEAD head
Definition: hook.h:17
ULONG Flags
Definition: hook.h:24
DWORD idProcess
Definition: hook.h:21
UINT Counts
Definition: hook.h:32
LIST_ENTRY Events
Definition: hook.h:31
int32_t INT_PTR
Definition: typedefs.h:64
int32_t INT
Definition: typedefs.h:58
uint32_t ULONG_PTR
Definition: typedefs.h:65
uint32_t ULONG
Definition: typedefs.h:59
_Must_inspect_result_ _In_ WDFCOLLECTION _In_ WDFOBJECT Object
_In_ UCHAR _In_ UCHAR _In_ ULONG Code
Definition: wdfdevice.h:1701
VOID(CALLBACK * WINEVENTPROC)(HWINEVENTHOOK, DWORD, HWND, LONG, LONG, DWORD, DWORD)
Definition: winable.h:68
LONG_PTR LPARAM
Definition: windef.h:208
LONG_PTR LRESULT
Definition: windef.h:209
UINT_PTR WPARAM
Definition: windef.h:207
LRESULT(CALLBACK * HOOKPROC)(int, WPARAM, LPARAM)
Definition: winuser.h:2899