Use HTTP server and client instead of plain TCP sockets.