I have a C++ DLL I’ve written that sometimes requires another instance of itself to carry out some actions. It would be nice if I didn’t have to split it into 2 different parts, especially because I don’t want any type of confusion that one of them is supposed to be “runnable”.
I’ve been looking at a few system-ey processes on Windows I could start and inject into. svchost and dllhost have both caught my eye; but they weren’t what I thought they were. Surely windows has some kind of generic DLL host I can use?
Looks like rundll32 is designed just for this purpose, and is exactly what I was looking for.
Command Line documentation:
http://support.microsoft.com/kb/164787
Reference on usage (SO):
How to use Rundll32 to execute DLL Function?