DLL exported function signature
I know this question is old, but since I also had this problem and took me a while to fix, I'm answering it here.
First, as Harry Johnston said you should add __declspec(dllexport)
.
Second, if your project is a C++ project, you should add extern "C"
too.
So, your method definition should look like this:
extern "C" __declspec(dllexport) void __stdcall NativeInjectionEntryPoint(REMOTE_ENTRY_INFO* InRemoteInfo)
{
// ...
}
Is there any native DLL export functions viewer?
you can use Dependency Walker to view the function name.
you can see the function's parameters only if it's decorated.
read the following from the FAQ:
How do I view the parameter and return types of a function?
For most functions, this information is simply not present in the module. The Windows' module file format only provides a single text string to identify each function. There is no structured way to list the number of parameters, the parameter types, or the return type. However, some languages do something called function "decoration" or "mangling", which is the process of encoding information into the text string. For example, a function like int Foo(int, int) encoded with simple decoration might be exported as _Foo@8. The 8 refers to the number of bytes used by the parameters. If C++ decoration is used, the function would be exported as ?Foo@@YGHHH@Z, which can be directly decoded back to the function's original prototype: int Foo(int, int). Dependency Walker supports C++ undecoration by using the Undecorate C++ Functions Command.
Related Topics
How to Call a Pointer-To-Member-Function
Is It Safe to Reinterpret_Cast an Enum Class Variable to a Reference of the Underlying Type
How to Find the Size of All Files Located Inside a Folder
What Is Aggregate Initialization
Unordered Set of Pairs, Compilation Error
Constraining the Existing Boost.Spirit Real_Parser (With a Policy)
Const Variable Changed with Pointer in C
How Do Stackless Coroutines Differ from Stackful Coroutines
C++ Function for Picking from a List Where Each Element Has a Distinct Probability
Should Std::Common_Type Use Std::Decay
Ramifications of C++20 Requiring Two's Complement
Difference Between Regex_Match and Regex_Search
What Are the Operations Supported by Raw Pointer and Function Pointer in C/C++
Deleted Function in Std::Pair When Using a Unique_Ptr Inside a Map