I made this a year ago and just didn't finish it, I decided to release it incase somebody wants to use it for their own Injector or wants to learn about some of the methods that can be used to inject into Roblox. This includes the following:
- threadpool capabilities with codestorage (didn't finish it, was supposed to be made so you could inject specific functions from the code storage that you can then execute using threadpool)
- two specific roblox methods (adding your thread to the whitelisted threads and adding your memory to the whitelisted modules, both of them allow for execution and rwx pages, just remember that your module has to be mapped with seh in order for the thread to execute, i never added manual mapping with seh so its not finished here)
- wrappers around process, thread, section and memory
- hooking capabilities so you can execute code inside roblox (incase threadpool was not optimal)
I might release a injector that actually uses threadpool and asmjit to inject any asm code and execute it, this can be used in order for execution, so you would need to find a way to map your dll and run it yourself.
Also another hint for threadpool, you don't need to actually allocate a entire module to run a simple function, you can just use asm to make a good threadpool that returns and then have that execute your function, if you did it properly it should work. Here is an example using asmjit:
a.sub(rsp, 40);
a.and_(rsp, -16);
payloadGenerator(ctx); // payload you want to run using the asmjit context, this can be your function, remember that it has to be made using asm to work
a.mov(rax, pCompletionFlag);
a.mov(dword_ptr(rax), 1);
a.add(rsp, 40);
a.xor_(eax, eax);
a.ret();