Hello
Well, I'm not going to commit that part since it doesn't actually do anything with the remote operation, and it's not clear at all that the requests you added will be appropriate to whatever mechanism we use to do the remote operation.
Ok, here is a draft working implementation of NtAllocateVirtualMemory. There are four mechanisms at all: signals, ptrace, service thread and wait. This implementation uses so-called wait approach: request is passed via wait_fd. The drawback is that request may not always be handled but most sane applications sooner or later fall into wait state. Also i'm going to try other mechanisms but their implementations seem will be very similar.
I hope that people will give suggestions.