Incomplete branch to implement an RPC session registry and link SOCKS streams to RPC
Please feel free to review what I have here if you like; I am mainly sharing this so I can point at code and say "what do you think I should do here".
Part of #863 (closed).