Here is the server - part of socket connection using GCDAsyncSocket library