US phone giant T-Mobile was hacked as part of a broad cyberattack on domestic and international phone and internet companies.