Process Hacker
phplug.h File Reference
#include <extmgr.h>
#include <sysinfo.h>
#include <miniinfo.h>

Go to the source code of this file.

Data Structures

struct  _PH_PLUGIN_GET_HIGHLIGHTING_COLOR
 
struct  _PH_PLUGIN_GET_TOOLTIP_TEXT
 
struct  _PH_PLUGIN_PROCESS_PROPCONTEXT
 
struct  _PH_PLUGIN_NOTIFY_EVENT
 
struct  _PH_PLUGIN_OBJECT_PROPERTIES
 
struct  _PH_PLUGIN_HANDLE_PROPERTIES_CONTEXT
 
struct  _PH_PLUGIN_MENU_INFORMATION
 
struct  _PH_PLUGIN_MENU_HOOK_INFORMATION
 
struct  _PH_PLUGIN_TREENEW_INFORMATION
 
struct  _PH_PLUGIN_THREAD_STACK_CONTROL
 
struct  _PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL
 
struct  _PH_PLUGIN_SYSINFO_POINTERS
 
struct  _PH_PLUGIN_MINIINFO_POINTERS
 
struct  _PH_PLUGIN_TREENEW_MESSAGE
 
struct  _PH_PLUGIN_PHSVC_REQUEST
 
struct  _PH_PLUGIN_PHSVC_CLIENT
 
struct  _PH_PLUGIN_INFORMATION
 
struct  _PH_PLUGIN
 
struct  _PH_PLUGIN_MENU_ITEM
 
struct  _PH_PLUGIN_SYSTEM_STATISTICS
 

Macros

#define PH_PLUGIN_MENU_DISALLOW_HOOKS   0x1
 
#define PH_PLUGIN_FLAG_RESERVED   0x1
 
#define PH_MENU_ITEM_LOCATION_VIEW   1
 
#define PH_MENU_ITEM_LOCATION_TOOLS   2
 
#define PH_MENU_ITEM_SUB_MENU   0x80000000
 
#define PH_MENU_ITEM_RETURN_MENU   0x40000000
 
#define PH_MENU_ITEM_VALID_FLAGS   0xc0000000
 

Typedefs

typedef enum _PH_GENERAL_CALLBACK PH_GENERAL_CALLBACK
 
typedef enum _PH_GENERAL_CALLBACKPPH_GENERAL_CALLBACK
 
typedef enum _PH_PLUGIN_CALLBACK PH_PLUGIN_CALLBACK
 
typedef enum _PH_PLUGIN_CALLBACKPPH_PLUGIN_CALLBACK
 
typedef struct
_PH_PLUGIN_GET_HIGHLIGHTING_COLOR 
PH_PLUGIN_GET_HIGHLIGHTING_COLOR
 
typedef struct
_PH_PLUGIN_GET_HIGHLIGHTING_COLOR
PPH_PLUGIN_GET_HIGHLIGHTING_COLOR
 
typedef struct
_PH_PLUGIN_GET_TOOLTIP_TEXT 
PH_PLUGIN_GET_TOOLTIP_TEXT
 
typedef struct
_PH_PLUGIN_GET_TOOLTIP_TEXT
PPH_PLUGIN_GET_TOOLTIP_TEXT
 
typedef struct
_PH_PLUGIN_PROCESS_PROPCONTEXT 
PH_PLUGIN_PROCESS_PROPCONTEXT
 
typedef struct
_PH_PLUGIN_PROCESS_PROPCONTEXT
PPH_PLUGIN_PROCESS_PROPCONTEXT
 
typedef struct
_PH_PLUGIN_NOTIFY_EVENT 
PH_PLUGIN_NOTIFY_EVENT
 
typedef struct
_PH_PLUGIN_NOTIFY_EVENT
PPH_PLUGIN_NOTIFY_EVENT
 
typedef struct
_PH_PLUGIN_OBJECT_PROPERTIES 
PH_PLUGIN_OBJECT_PROPERTIES
 
typedef struct
_PH_PLUGIN_OBJECT_PROPERTIES
PPH_PLUGIN_OBJECT_PROPERTIES
 
typedef struct
_PH_PLUGIN_HANDLE_PROPERTIES_CONTEXT 
PH_PLUGIN_HANDLE_PROPERTIES_CONTEXT
 
typedef struct
_PH_PLUGIN_HANDLE_PROPERTIES_CONTEXT
PPH_PLUGIN_HANDLE_PROPERTIES_CONTEXT
 
typedef struct _PH_EMENU_ITEMPPH_EMENU_ITEM
 
typedef struct _PH_EMENU_ITEMPPH_EMENU
 
typedef struct
_PH_PLUGIN_MENU_INFORMATION 
PH_PLUGIN_MENU_INFORMATION
 
typedef struct
_PH_PLUGIN_MENU_INFORMATION
PPH_PLUGIN_MENU_INFORMATION
 
typedef struct
_PH_PLUGIN_MENU_HOOK_INFORMATION 
PH_PLUGIN_MENU_HOOK_INFORMATION
 
typedef struct
_PH_PLUGIN_MENU_HOOK_INFORMATION
PPH_PLUGIN_MENU_HOOK_INFORMATION
 
typedef struct
_PH_PLUGIN_TREENEW_INFORMATION 
PH_PLUGIN_TREENEW_INFORMATION
 
typedef struct
_PH_PLUGIN_TREENEW_INFORMATION
PPH_PLUGIN_TREENEW_INFORMATION
 
typedef enum
_PH_PLUGIN_THREAD_STACK_CONTROL_TYPE 
PH_PLUGIN_THREAD_STACK_CONTROL_TYPE
 
typedef struct
_PH_SYMBOL_PROVIDER
PPH_SYMBOL_PROVIDER
 
typedef struct
_PH_THREAD_STACK_FRAME
PPH_THREAD_STACK_FRAME
 
typedef BOOLEAN(NTAPI * PPH_PLUGIN_WALK_THREAD_STACK_CALLBACK )(_In_ PPH_THREAD_STACK_FRAME StackFrame, _In_opt_ PVOID Context)
 
typedef struct
_PH_PLUGIN_THREAD_STACK_CONTROL 
PH_PLUGIN_THREAD_STACK_CONTROL
 
typedef struct
_PH_PLUGIN_THREAD_STACK_CONTROL
PPH_PLUGIN_THREAD_STACK_CONTROL
 
typedef enum
_PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL_TYPE 
PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL_TYPE
 
typedef struct
_PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL 
PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL
 
typedef struct
_PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL
PPH_PLUGIN_MEMORY_ITEM_LIST_CONTROL
 
typedef PPH_SYSINFO_SECTION(NTAPI * PPH_SYSINFO_CREATE_SECTION )(_In_ PPH_SYSINFO_SECTION Template)
 
typedef PPH_SYSINFO_SECTION(NTAPI * PPH_SYSINFO_FIND_SECTION )(_In_ PPH_STRINGREF Name)
 
typedef VOID(NTAPI * PPH_SYSINFO_ENTER_SECTION_VIEW )(_In_ PPH_SYSINFO_SECTION NewSection)
 
typedef VOID(NTAPI * PPH_SYSINFO_RESTORE_SUMMARY_VIEW )(VOID)
 
typedef struct
_PH_PLUGIN_SYSINFO_POINTERS 
PH_PLUGIN_SYSINFO_POINTERS
 
typedef struct
_PH_PLUGIN_SYSINFO_POINTERS
PPH_PLUGIN_SYSINFO_POINTERS
 
typedef PPH_MINIINFO_SECTION(NTAPI * PPH_MINIINFO_CREATE_SECTION )(_In_ PPH_MINIINFO_SECTION Template)
 
typedef PPH_MINIINFO_SECTION(NTAPI * PPH_MINIINFO_FIND_SECTION )(_In_ PPH_STRINGREF Name)
 
typedef
PPH_MINIINFO_LIST_SECTION(NTAPI * 
PPH_MINIINFO_CREATE_LIST_SECTION )(_In_ PWSTR Name, _In_ ULONG Flags, _In_ PPH_MINIINFO_LIST_SECTION Template)
 
typedef struct
_PH_PLUGIN_MINIINFO_POINTERS 
PH_PLUGIN_MINIINFO_POINTERS
 
typedef struct
_PH_PLUGIN_MINIINFO_POINTERS
PPH_PLUGIN_MINIINFO_POINTERS
 
typedef struct
_PH_PLUGIN_TREENEW_MESSAGE 
PH_PLUGIN_TREENEW_MESSAGE
 
typedef struct
_PH_PLUGIN_TREENEW_MESSAGE
PPH_PLUGIN_TREENEW_MESSAGE
 
typedef LONG(NTAPI * PPH_PLUGIN_TREENEW_SORT_FUNCTION )(_In_ PVOID Node1, _In_ PVOID Node2, _In_ ULONG SubId, _In_ PVOID Context)
 
typedef NTSTATUS(NTAPI * PPHSVC_SERVER_PROBE_BUFFER )(_In_ PPH_RELATIVE_STRINGREF String, _In_ ULONG Alignment, _In_ BOOLEAN AllowNull, _Out_ PVOID *Pointer)
 
typedef NTSTATUS(NTAPI * PPHSVC_SERVER_CAPTURE_BUFFER )(_In_ PPH_RELATIVE_STRINGREF String, _In_ BOOLEAN AllowNull, _Out_ PVOID *CapturedBuffer)
 
typedef NTSTATUS(NTAPI * PPHSVC_SERVER_CAPTURE_STRING )(_In_ PPH_RELATIVE_STRINGREF String, _In_ BOOLEAN AllowNull, _Out_ PPH_STRING *CapturedString)
 
typedef struct
_PH_PLUGIN_PHSVC_REQUEST 
PH_PLUGIN_PHSVC_REQUEST
 
typedef struct
_PH_PLUGIN_PHSVC_REQUEST
PPH_PLUGIN_PHSVC_REQUEST
 
typedef VOID(NTAPI * PPHSVC_CLIENT_FREE_HEAP )(_In_ PVOID Memory)
 
typedef PVOID(NTAPI * PPHSVC_CLIENT_CREATE_STRING )(_In_opt_ PVOID String, _In_ SIZE_T Length, _Out_ PPH_RELATIVE_STRINGREF StringRef)
 
typedef struct
_PH_PLUGIN_PHSVC_CLIENT 
PH_PLUGIN_PHSVC_CLIENT
 
typedef struct
_PH_PLUGIN_PHSVC_CLIENT
PPH_PLUGIN_PHSVC_CLIENT
 
typedef struct
_PH_PLUGIN_INFORMATION 
PH_PLUGIN_INFORMATION
 
typedef struct
_PH_PLUGIN_INFORMATION
PPH_PLUGIN_INFORMATION
 
typedef struct _PH_PLUGIN PH_PLUGIN
 
typedef struct _PH_PLUGINPPH_PLUGIN
 
typedef VOID(NTAPI * PPH_PLUGIN_MENU_ITEM_DELETE_FUNCTION )(_In_ struct _PH_PLUGIN_MENU_ITEM *MenuItem)
 
typedef struct _PH_PLUGIN_MENU_ITEM PH_PLUGIN_MENU_ITEM
 
typedef struct
_PH_PLUGIN_MENU_ITEM
PPH_PLUGIN_MENU_ITEM
 
typedef struct
_PH_PLUGIN_SYSTEM_STATISTICS 
PH_PLUGIN_SYSTEM_STATISTICS
 
typedef struct
_PH_PLUGIN_SYSTEM_STATISTICS
PPH_PLUGIN_SYSTEM_STATISTICS
 

Enumerations

enum  _PH_GENERAL_CALLBACK {
  GeneralCallbackMainWindowShowing = 0, GeneralCallbackProcessesUpdated = 1, GeneralCallbackGetProcessHighlightingColor = 2, GeneralCallbackGetProcessTooltipText = 3,
  GeneralCallbackProcessPropertiesInitializing = 4, GeneralCallbackMainMenuInitializing = 5, GeneralCallbackNotifyEvent = 6, GeneralCallbackServicePropertiesInitializing = 7,
  GeneralCallbackHandlePropertiesInitializing = 8, GeneralCallbackProcessMenuInitializing = 9, GeneralCallbackServiceMenuInitializing = 10, GeneralCallbackNetworkMenuInitializing = 11,
  GeneralCallbackIconMenuInitializing = 12, GeneralCallbackThreadMenuInitializing = 13, GeneralCallbackModuleMenuInitializing = 14, GeneralCallbackMemoryMenuInitializing = 15,
  GeneralCallbackHandleMenuInitializing = 16, GeneralCallbackProcessTreeNewInitializing = 17, GeneralCallbackServiceTreeNewInitializing = 18, GeneralCallbackNetworkTreeNewInitializing = 19,
  GeneralCallbackModuleTreeNewInitializing = 20, GeneralCallbackModuleTreeNewUninitializing = 21, GeneralCallbackThreadTreeNewInitializing = 22, GeneralCallbackThreadTreeNewUninitializing = 23,
  GeneralCallbackHandleTreeNewInitializing = 24, GeneralCallbackHandleTreeNewUninitializing = 25, GeneralCallbackThreadStackControl = 26, GeneralCallbackSystemInformationInitializing = 27,
  GeneralCallbackMainWindowTabChanged = 28, GeneralCallbackMemoryTreeNewInitializing = 29, GeneralCallbackMemoryTreeNewUninitializing = 30, GeneralCallbackMemoryItemListControl = 31,
  GeneralCallbackMiniInformationInitializing = 32, GeneralCallbackMiListSectionMenuInitializing = 33, GeneralCallbackMaximum, GeneralCallbackMainWindowShowing = 0,
  GeneralCallbackProcessesUpdated = 1, GeneralCallbackGetProcessHighlightingColor = 2, GeneralCallbackGetProcessTooltipText = 3, GeneralCallbackProcessPropertiesInitializing = 4,
  GeneralCallbackMainMenuInitializing = 5, GeneralCallbackNotifyEvent = 6, GeneralCallbackServicePropertiesInitializing = 7, GeneralCallbackHandlePropertiesInitializing = 8,
  GeneralCallbackProcessMenuInitializing = 9, GeneralCallbackServiceMenuInitializing = 10, GeneralCallbackNetworkMenuInitializing = 11, GeneralCallbackIconMenuInitializing = 12,
  GeneralCallbackThreadMenuInitializing = 13, GeneralCallbackModuleMenuInitializing = 14, GeneralCallbackMemoryMenuInitializing = 15, GeneralCallbackHandleMenuInitializing = 16,
  GeneralCallbackProcessTreeNewInitializing = 17, GeneralCallbackServiceTreeNewInitializing = 18, GeneralCallbackNetworkTreeNewInitializing = 19, GeneralCallbackModuleTreeNewInitializing = 20,
  GeneralCallbackModuleTreeNewUninitializing = 21, GeneralCallbackThreadTreeNewInitializing = 22, GeneralCallbackThreadTreeNewUninitializing = 23, GeneralCallbackHandleTreeNewInitializing = 24,
  GeneralCallbackHandleTreeNewUninitializing = 25, GeneralCallbackThreadStackControl = 26, GeneralCallbackSystemInformationInitializing = 27, GeneralCallbackMainWindowTabChanged = 28,
  GeneralCallbackMemoryTreeNewInitializing = 29, GeneralCallbackMemoryTreeNewUninitializing = 30, GeneralCallbackMemoryItemListControl = 31, GeneralCallbackMiniInformationInitializing = 32,
  GeneralCallbackMiListSectionMenuInitializing = 33, GeneralCallbackMaximum
}
 
enum  _PH_PLUGIN_CALLBACK {
  PluginCallbackLoad = 0, PluginCallbackUnload = 1, PluginCallbackShowOptions = 2, PluginCallbackMenuItem = 3,
  PluginCallbackTreeNewMessage = 4, PluginCallbackPhSvcRequest = 5, PluginCallbackMenuHook = 6, PluginCallbackMaximum,
  PluginCallbackLoad = 0, PluginCallbackUnload = 1, PluginCallbackShowOptions = 2, PluginCallbackMenuItem = 3,
  PluginCallbackTreeNewMessage = 4, PluginCallbackPhSvcRequest = 5, PluginCallbackMenuHook = 6, PluginCallbackMaximum
}
 
enum  _PH_PLUGIN_THREAD_STACK_CONTROL_TYPE {
  PluginThreadStackInitializing, PluginThreadStackUninitializing, PluginThreadStackResolveSymbol, PluginThreadStackGetTooltip,
  PluginThreadStackWalkStack, PluginThreadStackBeginDefaultWalkStack, PluginThreadStackEndDefaultWalkStack, PluginThreadStackMaximum,
  PluginThreadStackInitializing, PluginThreadStackUninitializing, PluginThreadStackResolveSymbol, PluginThreadStackGetTooltip,
  PluginThreadStackWalkStack, PluginThreadStackBeginDefaultWalkStack, PluginThreadStackEndDefaultWalkStack, PluginThreadStackMaximum
}
 
enum  _PH_PLUGIN_MEMORY_ITEM_LIST_CONTROL_TYPE { PluginMemoryItemListInitialized, PluginMemoryItemListMaximum, PluginMemoryItemListInitialized, PluginMemoryItemListMaximum }
 

Functions

 C_ASSERT (RTL_FIELD_SIZE(PH_PLUGIN_MENU_INFORMATION, u)==RTL_FIELD_SIZE(PH_PLUGIN_MENU_INFORMATION, u.DoNotUse))
 
PHAPPAPI PPH_PLUGIN NTAPI PhRegisterPlugin (_In_ PWSTR Name, _In_ PVOID DllBase, _Out_opt_ PPH_PLUGIN_INFORMATION *Information)
 Registers a plugin with the host.
 
PHAPPAPI PPH_PLUGIN NTAPI PhFindPlugin (_In_ PWSTR Name)
 Locates a plugin instance structure.
 
PHAPPAPI
PPH_PLUGIN_INFORMATION NTAPI 
PhGetPluginInformation (_In_ PPH_PLUGIN Plugin)
 Gets a pointer to a plugin's additional information block.
 
PHAPPAPI PPH_CALLBACK NTAPI PhGetPluginCallback (_In_ PPH_PLUGIN Plugin, _In_ PH_PLUGIN_CALLBACK Callback)
 Retrieves a pointer to a plugin callback.
 
PHAPPAPI PPH_CALLBACK NTAPI PhGetGeneralCallback (_In_ PH_GENERAL_CALLBACK Callback)
 Retrieves a pointer to a general callback.
 
PHAPPAPI ULONG NTAPI PhPluginReserveIds (_In_ ULONG Count)
 Reserves unique GUI identifiers.
 
PHAPPAPI ULONG_PTR NTAPI PhPluginAddMenuItem (_In_ PPH_PLUGIN Plugin, _In_ ULONG_PTR Location, _In_opt_ PWSTR InsertAfter, _In_ ULONG Id, _In_ PWSTR Text, _In_opt_ PVOID Context)
 Adds a menu item to the program's main menu.
 
PHAPPAPI VOID NTAPI PhPluginGetSystemStatistics (_Out_ PPH_PLUGIN_SYSTEM_STATISTICS Statistics)
 Retrieves current system statistics.
 
PHAPPAPI PPH_EMENU_ITEM NTAPI PhPluginCreateEMenuItem (_In_ PPH_PLUGIN Plugin, _In_ ULONG Flags, _In_ ULONG Id, _In_ PWSTR Text, _In_opt_ PVOID Context)
 Creates a menu item.
 
PHAPPAPI BOOLEAN NTAPI PhPluginAddMenuHook (_Inout_ PPH_PLUGIN_MENU_INFORMATION MenuInfo, _In_ PPH_PLUGIN Plugin, _In_opt_ PVOID Context)
 Adds a menu hook.
 
VOID NTAPI PhPluginInitializeMenuInfo (_Out_ PPH_PLUGIN_MENU_INFORMATION MenuInfo, _In_opt_ PPH_EMENU Menu, _In_ HWND OwnerWindow, _In_ ULONG Flags)
 Initializes a plugin menu information structure.
 
BOOLEAN NTAPI PhPluginTriggerEMenuItem (_In_ PPH_PLUGIN_MENU_INFORMATION MenuInfo, _In_ PPH_EMENU_ITEM Item)
 Triggers a plugin menu item.
 
PHAPPAPI BOOLEAN NTAPI PhPluginAddTreeNewColumn (_In_ PPH_PLUGIN Plugin, _In_ PVOID CmData, _In_ PPH_TREENEW_COLUMN Column, _In_ ULONG SubId, _In_opt_ PVOID Context, _In_opt_ PPH_PLUGIN_TREENEW_SORT_FUNCTION SortFunction)
 Adds a column to a tree new control.
 
PHAPPAPI VOID NTAPI PhPluginSetObjectExtension (_In_ PPH_PLUGIN Plugin, _In_ PH_EM_OBJECT_TYPE ObjectType, _In_ ULONG ExtensionSize, _In_opt_ PPH_EM_OBJECT_CALLBACK CreateCallback, _In_opt_ PPH_EM_OBJECT_CALLBACK DeleteCallback)
 Sets the object extension size and callbacks for an object type.
 
PHAPPAPI PVOID NTAPI PhPluginGetObjectExtension (_In_ PPH_PLUGIN Plugin, _In_ PVOID Object, _In_ PH_EM_OBJECT_TYPE ObjectType)
 Gets the object extension for an object.
 
PHAPPAPI struct _PH_NF_ICON *NTAPI PhPluginRegisterIcon (_In_ PPH_PLUGIN Plugin, _In_ ULONG SubId, _In_opt_ PVOID Context, _In_ PWSTR Text, _In_ ULONG Flags, _In_ struct _PH_NF_ICON_REGISTRATION_DATA *RegistrationData)
 Creates a notification icon.
 
PHAPPAPI VOID NTAPI PhPluginEnableTreeNewNotify (_In_ PPH_PLUGIN Plugin, _In_ PVOID CmData)
 Allows a plugin to receive all treenew messages, not just column-related ones.
 
PHAPPAPI BOOLEAN NTAPI PhPluginQueryPhSvc (_Out_ PPH_PLUGIN_PHSVC_CLIENT Client)
 
PHAPPAPI NTSTATUS NTAPI PhPluginCallPhSvc (_In_ PPH_PLUGIN Plugin, _In_ ULONG SubId, _In_reads_bytes_opt_(InLength) PVOID InBuffer, _In_ ULONG InLength, _Out_writes_bytes_opt_(OutLength) PVOID OutBuffer, _In_ ULONG OutLength)
 

Macro Definition Documentation

#define PH_MENU_ITEM_LOCATION_TOOLS   2

Definition at line 502 of file phplug.h.

#define PH_MENU_ITEM_LOCATION_VIEW   1

Definition at line 501 of file phplug.h.

#define PH_MENU_ITEM_RETURN_MENU   0x40000000

Definition at line 506 of file phplug.h.

#define PH_MENU_ITEM_SUB_MENU   0x80000000

Definition at line 505 of file phplug.h.

#define PH_MENU_ITEM_VALID_FLAGS   0xc0000000

Definition at line 507 of file phplug.h.

#define PH_PLUGIN_FLAG_RESERVED   0x1

Definition at line 408 of file phplug.h.

#define PH_PLUGIN_MENU_DISALLOW_HOOKS   0x1

Definition at line 120 of file phplug.h.

Typedef Documentation

typedef struct _PH_PLUGIN PH_PLUGIN
typedef struct _PH_EMENU_ITEM * PPH_EMENU

Definition at line 118 of file phplug.h.

typedef struct _PH_EMENU_ITEM* PPH_EMENU_ITEM

Definition at line 118 of file phplug.h.

typedef PPH_MINIINFO_LIST_SECTION(NTAPI * PPH_MINIINFO_CREATE_LIST_SECTION)(_In_ PWSTR Name, _In_ ULONG Flags, _In_ PPH_MINIINFO_LIST_SECTION Template)

Definition at line 314 of file phplug.h.

typedef PPH_MINIINFO_SECTION(NTAPI * PPH_MINIINFO_CREATE_SECTION)(_In_ PPH_MINIINFO_SECTION Template)

Definition at line 306 of file phplug.h.

typedef PPH_MINIINFO_SECTION(NTAPI * PPH_MINIINFO_FIND_SECTION)(_In_ PPH_STRINGREF Name)

Definition at line 310 of file phplug.h.

typedef struct _PH_PLUGIN * PPH_PLUGIN
typedef VOID(NTAPI * PPH_PLUGIN_MENU_ITEM_DELETE_FUNCTION)(_In_ struct _PH_PLUGIN_MENU_ITEM *MenuItem)

Definition at line 483 of file phplug.h.

typedef LONG(NTAPI * PPH_PLUGIN_TREENEW_SORT_FUNCTION)(_In_ PVOID Node1, _In_ PVOID Node2, _In_ ULONG SubId, _In_ PVOID Context)

Definition at line 338 of file phplug.h.

typedef BOOLEAN(NTAPI * PPH_PLUGIN_WALK_THREAD_STACK_CALLBACK)(_In_ PPH_THREAD_STACK_FRAME StackFrame, _In_opt_ PVOID Context)

Definition at line 219 of file phplug.h.

Definition at line 216 of file phplug.h.

typedef PPH_SYSINFO_SECTION(NTAPI * PPH_SYSINFO_CREATE_SECTION)(_In_ PPH_SYSINFO_SECTION Template)

Definition at line 281 of file phplug.h.

typedef VOID(NTAPI * PPH_SYSINFO_ENTER_SECTION_VIEW)(_In_ PPH_SYSINFO_SECTION NewSection)

Definition at line 289 of file phplug.h.

typedef PPH_SYSINFO_SECTION(NTAPI * PPH_SYSINFO_FIND_SECTION)(_In_ PPH_STRINGREF Name)

Definition at line 285 of file phplug.h.

typedef VOID(NTAPI * PPH_SYSINFO_RESTORE_SUMMARY_VIEW)(VOID)

Definition at line 293 of file phplug.h.

Definition at line 217 of file phplug.h.

typedef PVOID(NTAPI * PPHSVC_CLIENT_CREATE_STRING)(_In_opt_ PVOID String, _In_ SIZE_T Length, _Out_ PPH_RELATIVE_STRINGREF StringRef)

Definition at line 382 of file phplug.h.

typedef VOID(NTAPI * PPHSVC_CLIENT_FREE_HEAP)(_In_ PVOID Memory)

Definition at line 378 of file phplug.h.

typedef NTSTATUS(NTAPI * PPHSVC_SERVER_CAPTURE_BUFFER)(_In_ PPH_RELATIVE_STRINGREF String, _In_ BOOLEAN AllowNull, _Out_ PVOID *CapturedBuffer)

Definition at line 352 of file phplug.h.

typedef NTSTATUS(NTAPI * PPHSVC_SERVER_CAPTURE_STRING)(_In_ PPH_RELATIVE_STRINGREF String, _In_ BOOLEAN AllowNull, _Out_ PPH_STRING *CapturedString)

Definition at line 358 of file phplug.h.

typedef NTSTATUS(NTAPI * PPHSVC_SERVER_PROBE_BUFFER)(_In_ PPH_RELATIVE_STRINGREF String, _In_ ULONG Alignment, _In_ BOOLEAN AllowNull, _Out_ PVOID *Pointer)

Definition at line 345 of file phplug.h.

Enumeration Type Documentation

Enumerator:
GeneralCallbackMainWindowShowing 
GeneralCallbackProcessesUpdated 
GeneralCallbackGetProcessHighlightingColor 
GeneralCallbackGetProcessTooltipText 
GeneralCallbackProcessPropertiesInitializing 
GeneralCallbackMainMenuInitializing 
GeneralCallbackNotifyEvent 
GeneralCallbackServicePropertiesInitializing 
GeneralCallbackHandlePropertiesInitializing 
GeneralCallbackProcessMenuInitializing 
GeneralCallbackServiceMenuInitializing 
GeneralCallbackNetworkMenuInitializing 
GeneralCallbackIconMenuInitializing 
GeneralCallbackThreadMenuInitializing 
GeneralCallbackModuleMenuInitializing 
GeneralCallbackMemoryMenuInitializing 
GeneralCallbackHandleMenuInitializing 
GeneralCallbackProcessTreeNewInitializing 
GeneralCallbackServiceTreeNewInitializing 
GeneralCallbackNetworkTreeNewInitializing 
GeneralCallbackModuleTreeNewInitializing 
GeneralCallbackModuleTreeNewUninitializing 
GeneralCallbackThreadTreeNewInitializing 
GeneralCallbackThreadTreeNewUninitializing 
GeneralCallbackHandleTreeNewInitializing 
GeneralCallbackHandleTreeNewUninitializing 
GeneralCallbackThreadStackControl 
GeneralCallbackSystemInformationInitializing 
GeneralCallbackMainWindowTabChanged 
GeneralCallbackMemoryTreeNewInitializing 
GeneralCallbackMemoryTreeNewUninitializing 
GeneralCallbackMemoryItemListControl 
GeneralCallbackMiniInformationInitializing 
GeneralCallbackMiListSectionMenuInitializing 
GeneralCallbackMaximum 
GeneralCallbackMainWindowShowing 
GeneralCallbackProcessesUpdated 
GeneralCallbackGetProcessHighlightingColor 
GeneralCallbackGetProcessTooltipText 
GeneralCallbackProcessPropertiesInitializing 
GeneralCallbackMainMenuInitializing 
GeneralCallbackNotifyEvent 
GeneralCallbackServicePropertiesInitializing 
GeneralCallbackHandlePropertiesInitializing 
GeneralCallbackProcessMenuInitializing 
GeneralCallbackServiceMenuInitializing 
GeneralCallbackNetworkMenuInitializing 
GeneralCallbackIconMenuInitializing 
GeneralCallbackThreadMenuInitializing 
GeneralCallbackModuleMenuInitializing 
GeneralCallbackMemoryMenuInitializing 
GeneralCallbackHandleMenuInitializing 
GeneralCallbackProcessTreeNewInitializing 
GeneralCallbackServiceTreeNewInitializing 
GeneralCallbackNetworkTreeNewInitializing 
GeneralCallbackModuleTreeNewInitializing 
GeneralCallbackModuleTreeNewUninitializing 
GeneralCallbackThreadTreeNewInitializing 
GeneralCallbackThreadTreeNewUninitializing 
GeneralCallbackHandleTreeNewInitializing 
GeneralCallbackHandleTreeNewUninitializing 
GeneralCallbackThreadStackControl 
GeneralCallbackSystemInformationInitializing 
GeneralCallbackMainWindowTabChanged 
GeneralCallbackMemoryTreeNewInitializing 
GeneralCallbackMemoryTreeNewUninitializing 
GeneralCallbackMemoryItemListControl 
GeneralCallbackMiniInformationInitializing 
GeneralCallbackMiListSectionMenuInitializing 
GeneralCallbackMaximum 

Definition at line 11 of file phplug.h.

Enumerator:
PluginCallbackLoad 
PluginCallbackUnload 
PluginCallbackShowOptions 
PluginCallbackMenuItem 
PluginCallbackTreeNewMessage 
PluginCallbackPhSvcRequest 
PluginCallbackMenuHook 
PluginCallbackMaximum 
PluginCallbackLoad 
PluginCallbackUnload 
PluginCallbackShowOptions 
PluginCallbackMenuItem 
PluginCallbackTreeNewMessage 
PluginCallbackPhSvcRequest 
PluginCallbackMenuHook 
PluginCallbackMaximum 

Definition at line 50 of file phplug.h.

Enumerator:
PluginMemoryItemListInitialized 
PluginMemoryItemListMaximum 
PluginMemoryItemListInitialized 
PluginMemoryItemListMaximum 

Definition at line 262 of file phplug.h.

Enumerator:
PluginThreadStackInitializing 
PluginThreadStackUninitializing 
PluginThreadStackResolveSymbol 
PluginThreadStackGetTooltip 
PluginThreadStackWalkStack 
PluginThreadStackBeginDefaultWalkStack 
PluginThreadStackEndDefaultWalkStack 
PluginThreadStackMaximum 
PluginThreadStackInitializing 
PluginThreadStackUninitializing 
PluginThreadStackResolveSymbol 
PluginThreadStackGetTooltip 
PluginThreadStackWalkStack 
PluginThreadStackBeginDefaultWalkStack 
PluginThreadStackEndDefaultWalkStack 
PluginThreadStackMaximum 

Definition at line 204 of file phplug.h.

Function Documentation

C_ASSERT ( RTL_FIELD_SIZE(PH_PLUGIN_MENU_INFORMATION, u)  = =RTL_FIELD_SIZE(PH_PLUGIN_MENU_INFORMATION, u.DoNotUse))
PHAPPAPI PPH_PLUGIN NTAPI PhFindPlugin ( _In_ PWSTR  Name)

Locates a plugin instance structure.

Parameters
NameThe name of the plugin.
Returns
A plugin instance structure, or NULL if the plugin was not found.

Definition at line 526 of file plugin.c.

PHAPPAPI PPH_CALLBACK NTAPI PhGetGeneralCallback ( _In_ PH_GENERAL_CALLBACK  Callback)

Retrieves a pointer to a general callback.

Parameters
CallbackThe type of callback.
Remarks
The program invokes general callbacks for system-wide notifications.

Definition at line 602 of file plugin.c.

PHAPPAPI PPH_CALLBACK NTAPI PhGetPluginCallback ( _In_ PPH_PLUGIN  Plugin,
_In_ PH_PLUGIN_CALLBACK  Callback 
)

Retrieves a pointer to a plugin callback.

Parameters
PluginA plugin instance structure.
CallbackThe type of callback.
Remarks
The program invokes plugin callbacks for notifications specific to a plugin.

Definition at line 583 of file plugin.c.

PHAPPAPI PPH_PLUGIN_INFORMATION NTAPI PhGetPluginInformation ( _In_ PPH_PLUGIN  Plugin)

Gets a pointer to a plugin's additional information block.

Parameters
PluginThe plugin instance structure.
Returns
The plugin's additional information block.

Definition at line 567 of file plugin.c.

PHAPPAPI BOOLEAN NTAPI PhPluginAddMenuHook ( _Inout_ PPH_PLUGIN_MENU_INFORMATION  MenuInfo,
_In_ PPH_PLUGIN  Plugin,
_In_opt_ PVOID  Context 
)

Adds a menu hook.

Parameters
MenuInfoThe plugin menu information structure.
PluginA plugin instance structure.
ContextA user-defined value that is later accessible from the callback.
Remarks
The PluginCallbackMenuHook callback is invoked when any menu item from the menu is chosen.

Definition at line 802 of file plugin.c.

PHAPPAPI ULONG_PTR NTAPI PhPluginAddMenuItem ( _In_ PPH_PLUGIN  Plugin,
_In_ ULONG_PTR  Location,
_In_opt_ PWSTR  InsertAfter,
_In_ ULONG  Id,
_In_ PWSTR  Text,
_In_opt_ PVOID  Context 
)

Adds a menu item to the program's main menu.

This function is deprecated. Use GeneralCallbackMainMenuInitializing instead.

Parameters
PluginA plugin instance structure.
LocationA handle to the parent menu, or one of the following:
  • PH_MENU_ITEM_LOCATION_VIEW The "View" menu.
  • PH_MENU_ITEM_LOCATION_TOOLS The "Tools" menu.
InsertAfterThe text of the menu item to insert the new menu item after. The search is a case-insensitive prefix search that ignores prefix characters (ampersands).
IdAn identifier for the menu item. This should be unique within the plugin.
TextThe text of the menu item.
ContextA user-defined value for the menu item.
Returns
TRUE if the function succeeded, otherwise FALSE.
Remarks
The PluginCallbackMenuItem callback is invoked when the menu item is chosen, and the PH_PLUGIN_MENU_ITEM structure will contain the Id and Context values passed to this function.

Definition at line 656 of file plugin.c.

PHAPPAPI BOOLEAN NTAPI PhPluginAddTreeNewColumn ( _In_ PPH_PLUGIN  Plugin,
_In_ PVOID  CmData,
_In_ PPH_TREENEW_COLUMN  Column,
_In_ ULONG  SubId,
_In_opt_ PVOID  Context,
_In_opt_ PPH_PLUGIN_TREENEW_SORT_FUNCTION  SortFunction 
)

Adds a column to a tree new control.

Parameters
PluginA plugin instance structure.
CmDataThe CmData value from the PH_PLUGIN_TREENEW_INFORMATION structure.
ColumnThe column properties.
SubIdAn identifier for the column. This should be unique within the plugin.
ContextA user-defined value.
SortFunctionThe sort function for the column.

Definition at line 905 of file plugin.c.

PHAPPAPI NTSTATUS NTAPI PhPluginCallPhSvc ( _In_ PPH_PLUGIN  Plugin,
_In_ ULONG  SubId,
_In_reads_bytes_opt_(InLength) PVOID  InBuffer,
_In_ ULONG  InLength,
_Out_writes_bytes_opt_(OutLength) PVOID  OutBuffer,
_In_ ULONG  OutLength 
)

Definition at line 1032 of file plugin.c.

PHAPPAPI PPH_EMENU_ITEM NTAPI PhPluginCreateEMenuItem ( _In_ PPH_PLUGIN  Plugin,
_In_ ULONG  Flags,
_In_ ULONG  Id,
_In_ PWSTR  Text,
_In_opt_ PVOID  Context 
)

Creates a menu item.

Parameters
PluginA plugin instance structure.
FlagsA combination of flags.
IdAn identifier for the menu item. This should be unique within the plugin.
TextThe text of the menu item.
ContextA user-defined value for the menu item.
Returns
A menu item object. This can then be inserted into another menu using PhInsertEMenuItem().
Remarks
The PluginCallbackMenuItem callback is invoked when the menu item is chosen, and the PH_PLUGIN_MENU_ITEM structure will contain the Id and Context values passed to this function.

Definition at line 767 of file plugin.c.

PHAPPAPI VOID NTAPI PhPluginEnableTreeNewNotify ( _In_ PPH_PLUGIN  Plugin,
_In_ PVOID  CmData 
)

Allows a plugin to receive all treenew messages, not just column-related ones.

Parameters
PluginA plugin instance structure.
CmDataThe CmData value from the PH_PLUGIN_TREENEW_INFORMATION structure.

Definition at line 1010 of file plugin.c.

PHAPPAPI PVOID NTAPI PhPluginGetObjectExtension ( _In_ PPH_PLUGIN  Plugin,
_In_ PVOID  Object,
_In_ PH_EM_OBJECT_TYPE  ObjectType 
)

Gets the object extension for an object.

Parameters
PluginA plugin instance structure.
ObjectThe object.
ObjectTypeThe type of object for which an extension has been registered.

Definition at line 957 of file plugin.c.

PHAPPAPI VOID NTAPI PhPluginGetSystemStatistics ( _Out_ PPH_PLUGIN_SYSTEM_STATISTICS  Statistics)

Retrieves current system statistics.

Definition at line 691 of file plugin.c.

VOID NTAPI PhPluginInitializeMenuInfo ( _Out_ PPH_PLUGIN_MENU_INFORMATION  MenuInfo,
_In_opt_ PPH_EMENU  Menu,
_In_ HWND  OwnerWindow,
_In_ ULONG  Flags 
)

Initializes a plugin menu information structure.

Parameters
MenuInfoThe structure to initialize.
MenuThe menu being shown.
OwnerWindowThe window that owns the menu.
FlagsAdditional flags.
Remarks
This function is reserved for internal use.

Definition at line 834 of file plugin.c.

PHAPPAPI BOOLEAN NTAPI PhPluginQueryPhSvc ( _Out_ PPH_PLUGIN_PHSVC_CLIENT  Client)

Definition at line 1018 of file plugin.c.

PHAPPAPI struct _PH_NF_ICON* NTAPI PhPluginRegisterIcon ( _In_ PPH_PLUGIN  Plugin,
_In_ ULONG  SubId,
_In_opt_ PVOID  Context,
_In_ PWSTR  Text,
_In_ ULONG  Flags,
_In_ struct _PH_NF_ICON_REGISTRATION_DATA RegistrationData 
)
read

Creates a notification icon.

Parameters
PluginA plugin instance structure.
SubIdAn identifier for the column. This should be unique within the plugin.
ContextA user-defined value.
TextA string describing the notification icon.
FlagsA combination of flags.
  • PH_NF_ICON_UNAVAILABLE The notification icon is currently unavailable.
RegistrationDataA PH_NF_ICON_REGISTRATION_DATA structure that contains registration information.

Definition at line 983 of file plugin.c.

PHAPPAPI ULONG NTAPI PhPluginReserveIds ( _In_ ULONG  Count)

Reserves unique GUI identifiers.

Parameters
CountThe number of identifiers to reserve.
Returns
The start of the reserved range.
Remarks
The identifiers reserved by this function are guaranteed to be unique throughout the program.

Definition at line 622 of file plugin.c.

PHAPPAPI VOID NTAPI PhPluginSetObjectExtension ( _In_ PPH_PLUGIN  Plugin,
_In_ PH_EM_OBJECT_TYPE  ObjectType,
_In_ ULONG  ExtensionSize,
_In_opt_ PPH_EM_OBJECT_CALLBACK  CreateCallback,
_In_opt_ PPH_EM_OBJECT_CALLBACK  DeleteCallback 
)

Sets the object extension size and callbacks for an object type.

Parameters
PluginA plugin instance structure.
ObjectTypeThe type of object for which the extension is being registered.
ExtensionSizeThe size of the extension, in bytes.
CreateCallbackThe object creation callback.
DeleteCallbackThe object deletion callback.

Definition at line 933 of file plugin.c.

BOOLEAN NTAPI PhPluginTriggerEMenuItem ( _In_ PPH_PLUGIN_MENU_INFORMATION  MenuInfo,
_In_ PPH_EMENU_ITEM  Item 
)

Triggers a plugin menu item.

Parameters
MenuInfoThe plugin menu information structure.
ItemThe menu item chosen by the user.
Remarks
This function is reserved for internal use.

Definition at line 855 of file plugin.c.

PHAPPAPI PPH_PLUGIN NTAPI PhRegisterPlugin ( _In_ PWSTR  Name,
_In_ PVOID  DllBase,
_Out_opt_ PPH_PLUGIN_INFORMATION Information 
)

Registers a plugin with the host.

Parameters
NameA unique identifier for the plugin. The function fails if another plugin has already been registered with the same name. The name must only contain alphanumeric characters, spaces, dots and underscores.
DllBaseThe base address of the plugin DLL. This is passed to the DllMain function.
InformationA variable which receives a pointer to the plugin's additional information block. This should be filled in after the function returns.
Returns
A pointer to the plugin instance structure, or NULL if the function failed.

Definition at line 469 of file plugin.c.