implement CONNECT command