adding socket and port input conditions through bool functions