added connection request code + corrected byte ordering when resolving server.