Enable multi-hop routing for messages

This patch enables the middleman to send messages to nodes it does not have a
direct connection to by maintaining a routing table.