Handling CONNECT message and sending CONACK