Fixed the handshake and added server -> client frame handling.