Textractor/host/host.h

30 lines
865 B
C
Raw Normal View History

#pragma once
// host.h
// 8/23/2013 jichi
// Branch: ITH/IHF.h, rev 105
2018-08-22 12:24:55 -04:00
#include "common.h"
2018-07-23 12:25:02 -07:00
#include "textthread.h"
typedef std::function<void(DWORD)> ProcessEventCallback;
typedef std::function<void(TextThread*)> ThreadEventCallback;
2018-07-23 12:25:02 -07:00
namespace Host
{
2018-08-24 12:50:20 -04:00
void Start(ProcessEventCallback onAttach, ProcessEventCallback onDetach, ThreadEventCallback onCreate, ThreadEventCallback onRemove);
void Close();
bool InjectProcess(DWORD pid, DWORD timeout = 5000);
bool DetachProcess(DWORD pid);
bool InsertHook(DWORD pid, HookParam hp, std::string name = "");
bool RemoveHook(DWORD pid, unsigned __int64 addr);
HookParam GetHookParam(DWORD pid, unsigned __int64 addr);
HookParam GetHookParam(ThreadParam tp);
std::wstring GetHookName(DWORD pid, unsigned __int64 addr);
TextThread* GetThread(ThreadParam tp);
void AddConsoleOutput(std::wstring text);
2018-07-23 12:25:02 -07:00
}
// EOF