Adds more futures to the common library.
Minor fixes.
Adds port and socket handlers for the communication to the server.