safety checks on address/socket string