use of sockets in openPort