Yet another bastard child for remote process manipulation.
Uses C# AssemblyLoadContext (.NET 5+ I think) to dynamically load, execute, unload C# DLLs into a remote process, without having to restart the process. The intended usecase is to quickly iterate on C# code that is supposed to run in and interact with native code.
See RemoteHands for alternative approach.
I suck as C++, so want to do stuff in C#, and without having to restart the native process all the time.
The project is composed out of 4 parts:
- Runtime - C++ library that gets injected into a remote process and starts up a C# runtime
- Host - The bootstrap library the "Runtime" component starts. Responsible for loading and unloading DLLs. Listens on a named pipe for instructions.
- Base - Base class for a plugin that you'd like the "Host" to run. Provides the basic expected interface.
- Common - Common shared utilities. Contains the code required to talk between the plugin and the host. Also contains the code for injecting "Runtime" into remote processes (but that's accessible from Base).
See DemoPlugin - An example tying it all together and showing how it works. It will start Notepad with a C# runtime embedded, executing your C# code.
Assumes you have .NET 5+ installed on your machine.