extern "C" __declspec(dllexport) void TitanDebuggingCallBack(LPDEBUG_EVENT debugEvent, int CallReason) { switch(CallReason) { case UE_PLUGIN_CALL_REASON_EXCEPTION: { switch(debugEvent->dwDebugEventCode) { case CREATE_PROCESS_DEBUG_EVENT: { ProcessId=debugEvent->dwProcessId; bHooked = false; ZeroMemory(&DllExchangeLoader, sizeof(HOOK_DLL_EXCHANGE)); ReadSettings(); break; } case LOAD_DLL_DEBUG_EVENT: { if (bHooked) { startInjection(ProcessId, ScyllaHideDllPath, false); } break; } case EXCEPTION_DEBUG_EVENT: { switch(debugEvent->u.Exception.ExceptionRecord.ExceptionCode) { case STATUS_BREAKPOINT: { if (!bHooked) { ReadNtApiInformation(); bHooked = true; startInjection(ProcessId, ScyllaHideDllPath, true); } break; } } break; } } } break; } }
/* * Description : Executable entry point. */ int main (int argc, char **argv) { startInjection (); endInjection (); return 0; }