a lot of work on tcp client/server