Hostname detection now includes protocol