Tried to add inet_addr and port range check