There are several main mobile providers in Spain: Movistar, Vodafone, Orange, T-Mobile. But there are small sub companies like pepephone, simyo or Yoigo.
It is not possible to get a contract with a mobile provider in Spain without the Número de Identidad de Extranjero (NIE) and a Spanish bank account. Therefore, unless you have the NIE and the an open bank account already, you will have to get a “pay as you go” sim card, which is less convenient yet easily accessible. You can buy one of those in every mobile store with only your passport/ID. Unfortunately, to get a DSL/Fiber optics connection, a NIE and a Spanish bank account are needed.
Harbour.Space provides free Wi-Fi for their students on the campus.