Initialize the hyper trace module.
22{
24
25
26
27
28
29
30
31
32
37
38
39
40
42
43
44
45
46
48
53
58
61
62
63
64
65
67
72
77
78
79
80
82 {
83 LogDebugInfo(
"HyperDbg's hypertrace loaded successfully");
84
85
86
87
89
90
91
92
94
96 }
97 else
98 {
99
100
101
102 LogDebugInfo(
"Err, HyperDbg's hypertrace was not loaded");
103
104
105
106
108
110 }
111}
IMPORT_EXPORT_HYPERLOG BOOLEAN LogCallbackSendBuffer(_In_ UINT32 OperationCode, _In_reads_bytes_(BufferLength) PVOID Buffer, _In_ UINT32 BufferLength, _In_ BOOLEAN Priority)
routines callback for sending buffer
Definition HyperLogCallback.c:123
IMPORT_EXPORT_HYPERLOG BOOLEAN LogCallbackCheckIfBufferIsFull(BOOLEAN Priority)
Checks whether the priority or regular buffer is full or not.
Definition Logging.c:262
IMPORT_EXPORT_HYPERLOG BOOLEAN LogCallbackSendMessageToQueue(UINT32 OperationCode, BOOLEAN IsImmediateMessage, CHAR *LogMessage, UINT32 BufferLen, BOOLEAN Priority)
Send string messages and tracing for logging and monitoring.
Definition Logging.c:1214
IMPORT_EXPORT_HYPERLOG BOOLEAN LogCallbackPrepareAndSendMessageToQueueWrapper(UINT32 OperationCode, BOOLEAN IsImmediateMessage, BOOLEAN ShowCurrentSystemTime, BOOLEAN Priority, const CHAR *Fmt, va_list ArgList)
Prepare a printf-style message mapping and send string messages and tracing for logging and monitorin...
Definition Logging.c:987
IMPORT_EXPORT_HYPERTRACE BOOLEAN HyperTraceInitCallback(HYPERTRACE_CALLBACKS *HyperTraceCallbacks, BOOLEAN RunningOnHypervisorEnvironment)
Initialize the hypertrace module callbacks.
Definition TraceApi.c:24
IMPORT_EXPORT_VMM VOID VmFuncSetLoadGuestIa32LbrCtl(UINT32 CoreId, BOOLEAN Set)
Set LOAD GUEST IA32_LBR_CTL on Vm-entry controls.
Definition Export.c:151
IMPORT_EXPORT_VMM BOOLEAN VmFuncCheckCpuSupportForSaveAndLoadDebugControls()
Check if CPU support save and load debug controls on exit and load entries.
Definition Export.c:488
IMPORT_EXPORT_VMM VOID VmFuncSetLoadGuestIa32LbrCtlVmcallOnTargetCore(BOOLEAN Set)
Set LOAD GUEST IA32_LBR_CTL on VM-entry controls on the target core from VMCS using VMCALL.
Definition Export.c:599
IMPORT_EXPORT_VMM VOID VmFuncSetLbrSelectVmcallOnTargetCore(UINT64 FilterOptions)
Set the guest state of MSR_LEGACY_LBR_SELECT on the target core from VMCS using VMCALL.
Definition Export.c:573
IMPORT_EXPORT_VMM BOOLEAN VmFuncCheckCpuSupportForLoadAndClearGuestIa32LbrCtlControls()
Check if CPU support load and clear guest IA32_LBR_CTL controls on VM-entry and VM-exit.
Definition Export.c:499
IMPORT_EXPORT_VMM VOID VmFuncSetDebugctl(UINT64 Value)
Set the guest state of IA32_DEBUGCTL.
Definition Export.c:511
IMPORT_EXPORT_VMM UINT64 VmFuncGetDebugctlVmcallOnTargetCore()
Get the guest state of IA32_DEBUGCTL on the target core from VMCS using VMCALL.
Definition Export.c:455
IMPORT_EXPORT_VMM VOID VmFuncSetGuestIa32LbrCtl(UINT64 Value)
Set the guest state of IA32_LBR_CTL.
Definition Export.c:536
IMPORT_EXPORT_VMM VOID VmFuncSetClearGuestIa32LbrCtl(UINT32 CoreId, BOOLEAN Set)
Set CLEAR GUEST IA32_LBR_CTL on Vm-exit controls.
Definition Export.c:179
IMPORT_EXPORT_VMM VOID VmFuncSetDebugctlVmcallOnTargetCore(UINT64 Value)
Set the guest state of IA32_DEBUGCTL on the target core from VMCS using VMCALL.
Definition Export.c:524
IMPORT_EXPORT_VMM UINT64 VmFuncGetGuestIa32LbrCtlVmcallOnTargetCore()
Get the guest state of IA32_LBR_CTL on the target core from VMCS.
Definition Export.c:477
IMPORT_EXPORT_VMM VOID VmFuncSetSaveDebugControls(UINT32 CoreId, BOOLEAN Set)
Set SAVE DEBUG CONTROLS on Vm-exit controls.
Definition Export.c:165
IMPORT_EXPORT_VMM VOID VmFuncSetLoadDebugControls(UINT32 CoreId, BOOLEAN Set)
Set LOAD DEBUG CONTROLS on Vm-entry controls.
Definition Export.c:137
IMPORT_EXPORT_VMM VOID VmFuncSetClearGuestIa32LbrCtlVmcallOnTargetCore(BOOLEAN Set)
Set CLEAR GUEST IA32_LBR_CTL on VM-exit controls on the target core from VMCS using VMCALL.
Definition Export.c:625
IMPORT_EXPORT_VMM VOID VmFuncSetSaveDebugControlsVmcallOnTargetCore(BOOLEAN Set)
Set SAVE DEBUG CONTROLS on VM-exit controls on the target core from VMCS using VMCALL.
Definition Export.c:612
IMPORT_EXPORT_VMM VOID VmFuncSetLbrSelect(UINT64 FilterOptions)
Set the guest state of MSR_LEGACY_LBR_SELECT.
Definition Export.c:561
IMPORT_EXPORT_VMM VOID VmFuncSetLoadDebugControlsVmcallOnTargetCore(BOOLEAN Set)
Set LOAD DEBUG CONTROLS on VM-entry controls on the target core from VMCS using VMCALL.
Definition Export.c:586
IMPORT_EXPORT_VMM UINT64 VmFuncGetGuestIa32LbrCtl()
Get the guest state of IA32_LBR_CTL.
Definition Export.c:466
IMPORT_EXPORT_VMM UINT64 VmFuncGetDebugctl()
Get the guest state of IA32_DEBUGCTL.
Definition Export.c:443
IMPORT_EXPORT_VMM VOID VmFuncSetGuestIa32LbrCtlVmcallOnTargetCore(UINT64 Value)
Set the guest state of IA32_LBR_CTL on the target core from VMCS using VMCALL.
Definition Export.c:549
struct _HYPERTRACE_CALLBACKS HYPERTRACE_CALLBACKS
Prototype of each function needed by hypertrace module.
UINT32 KernelStatus
Definition RequestStructures.h:40
VM_FUNC_SET_LOAD_GUEST_IA32_LBR_CTL VmFuncSetLoadGuestIa32LbrCtl
Definition HyperTrace.h:250
VM_FUNC_SET_DEBUGCTL_VMCALL_ON_TARGET_CORE VmFuncSetDebugctlVmcallOnTargetCore
Definition HyperTrace.h:229
VM_FUNC_SET_GUEST_IA32_LBR_CTL VmFuncSetGuestIa32LbrCtl
Definition HyperTrace.h:247
VM_FUNC_SET_CLEAR_GUEST_IA32_LBR_CTL VmFuncSetClearGuestIa32LbrCtl
Definition HyperTrace.h:252
VM_FUNC_GET_DEBUGCTL_VMCALL_ON_TARGET_CORE VmFuncGetDebugctlVmcallOnTargetCore
Definition HyperTrace.h:227
VM_FUNC_CHECK_CPU_SUPPORT_FOR_SAVE_AND_LOAD_DEBUG_CONTROLS VmFuncCheckCpuSupportForSaveAndLoadDebugControls
Definition HyperTrace.h:224
VM_FUNC_SET_LBR_SELECT_VMCALL_ON_TARGET_CORE VmFuncSetLbrSelectVmcallOnTargetCore
Definition HyperTrace.h:237
VM_FUNC_SET_CLEAR_GUEST_IA32_LBR_CTL_VMCALL_ON_TARGET_CORE VmFuncSetClearGuestIa32LbrCtlVmcallOnTargetCore
Definition HyperTrace.h:253
VM_FUNC_SET_GUEST_IA32_LBR_CTL_VMCALL_ON_TARGET_CORE VmFuncSetGuestIa32LbrCtlVmcallOnTargetCore
Definition HyperTrace.h:248
LOG_CALLBACK_SEND_MESSAGE_TO_QUEUE LogCallbackSendMessageToQueue
Definition HyperTrace.h:211
VM_FUNC_SET_SAVE_DEBUG_CONTROLS_VMCALL_ON_TARGET_CORE VmFuncSetSaveDebugControlsVmcallOnTargetCore
Definition HyperTrace.h:234
LOG_CALLBACK_CHECK_IF_BUFFER_IS_FULL LogCallbackCheckIfBufferIsFull
Definition HyperTrace.h:213
VM_FUNC_GET_DEBUGCTL VmFuncGetDebugctl
Definition HyperTrace.h:226
LOG_CALLBACK_PREPARE_AND_SEND_MESSAGE_TO_QUEUE LogCallbackPrepareAndSendMessageToQueueWrapper
Definition HyperTrace.h:210
VM_FUNC_SET_LBR_SELECT VmFuncSetLbrSelect
Definition HyperTrace.h:236
VM_FUNC_SET_LOAD_DEBUG_CONTROLS_VMCALL_ON_TARGET_CORE VmFuncSetLoadDebugControlsVmcallOnTargetCore
Definition HyperTrace.h:232
VM_FUNC_SET_SAVE_DEBUG_CONTROLS VmFuncSetSaveDebugControls
Definition HyperTrace.h:233
VM_FUNC_SET_LOAD_DEBUG_CONTROLS VmFuncSetLoadDebugControls
Definition HyperTrace.h:231
VM_FUNC_GET_GUEST_IA32_LBR_CTL VmFuncGetGuestIa32LbrCtl
Definition HyperTrace.h:245
VM_FUNC_CHECK_CPU_SUPPORT_FOR_LOAD_AND_CLEAR_GUEST_IA32_LBR_CTL_CONTROLS VmFuncCheckCpuSupportForLoadAndClearGuestIa32LbrCtlControls
Definition HyperTrace.h:243
VM_FUNC_GET_GUEST_IA32_LBR_CTL_VMCALL_ON_TARGET_CORE VmFuncGetGuestIa32LbrCtlVmcallOnTargetCore
Definition HyperTrace.h:246
VM_FUNC_VMX_GET_CURRENT_EXECUTION_MODE VmFuncVmxGetCurrentExecutionMode
Definition HyperTrace.h:218
VM_FUNC_SET_LOAD_GUEST_IA32_LBR_CTL_VMCALL_ON_TARGET_CORE VmFuncSetLoadGuestIa32LbrCtlVmcallOnTargetCore
Definition HyperTrace.h:251
VM_FUNC_SET_DEBUGCTL VmFuncSetDebugctl
Definition HyperTrace.h:228
LOG_CALLBACK_SEND_BUFFER LogCallbackSendBuffer
Definition HyperTrace.h:212