Initial handling of handshake

This patch enables acceptor-style handshaking. All header encoding/decoding is done by the multiplexer, and the "business logic" is handled by the socket.

Limitations:
* The various examples works, but the socket_suite tests hangs.
* Packet loss is not handled.
* Data packets are not acknowledged.
* Existing acknowledgement is a hack to get handshake working.