0

The easyhook.h header file has this function declaration.

typedef void __stdcall REMOTE_ENTRY_POINT(REMOTE_ENTRY_INFO* InRemoteInfo);

The easyhook creator stated this:

Your injected native DLL must have a REMOTE_ENTRY_POINT exported as "NativeInjectionEntryPoint". Take a look at easyhook.h for the signature of that export.

Assuming my dll already looks like this:

void __stdcall NativeInjectionEntryPoint(REMOTE_ENTRY_INFO* InRemoteInfo);

INT WINAPI DllMain(HMODULE hDLL, DWORD Reason, LPVOID Reserved){    
    switch(Reason){
    case DLL_PROCESS_ATTACH:
    case DLL_PROCESS_DETACH:
    case DLL_THREAD_ATTACH:
    case DLL_THREAD_DETACH:
        break;
    }
    return TRUE;
}

void _stdcall NativeInjectionEntryPoint(REMOTE_ENTRY_INFO* InRemoteInfo)(){

}

What is my dll supposed to look like?

For feedback, I'd like to know if I've stated the question clearly enough to be answered. My last one was voted down and I don't know why.

Any help will be appreciated.

4

1 回答 1

1

我知道这个问题很老,但是由于我也遇到了这个问题并且花了我一段时间来解决,所以我在这里回答。

首先,正如 Harry Johnston 所说,您应该添加__declspec(dllexport). 其次,如果您的项目是 C++ 项目,您也应该添加extern "C"。因此,您的方法定义应如下所示:

extern "C" __declspec(dllexport) void __stdcall NativeInjectionEntryPoint(REMOTE_ENTRY_INFO* InRemoteInfo)
{
    // ...
}
于 2015-05-29T17:47:17.630 回答