Hello
In order to better protect the source code of some functions, I moved them from my C# project to a native C++ dll. The concerned functions are now declared as "extern "C" __declspec(dllexport)" and can thus be used by any external program.
Now, I would like to restrict the usage of these functions so that only my C# program can call them (or at least make these functions throw an exception if they are not called by my authenticated program). How can such verification be made in a very safe way? Is it possible to check inside the C++ functions the strong name of the calling assembly?
Thank you in advances for any advices regarding this matter.
max
In order to better protect the source code of some functions, I moved them from my C# project to a native C++ dll. The concerned functions are now declared as "extern "C" __declspec(dllexport)" and can thus be used by any external program.
Now, I would like to restrict the usage of these functions so that only my C# program can call them (or at least make these functions throw an exception if they are not called by my authenticated program). How can such verification be made in a very safe way? Is it possible to check inside the C++ functions the strong name of the calling assembly?
Thank you in advances for any advices regarding this matter.
max