Connecting Linux To Cavalier
Connecting Linux (and Raspbian) to UVA’s “cavalier” Network:
The following are instructions for connecting your Linux computer to the “cavalier” WiFi network at UVA. The steps are to be used at your own risk, and are offered without any guarantee of working or not totally destroying your computer and turning you into a goon (but we’re pretty sure that won’t happen).
The steps were put together by Jasper Braun, a first-year Arts & Sciences student. He deserves all the praise and credit for this article. He is willing to help troubleshoot, but be kind, he’s just a student, not a full-time support staff.
For Raspbian (regular Linux below):
There is no gui network manager, so all entries must be done manually.
- On initial start-up (with the latest version of Raspbian), make sure you have set your Wifi country code if prompted.
- Get your personal .p12 certificate from https://standard.pki.virginia.edu/pkcs12/ and move it to the Pi with a Flash Drive.
cd
into the directory of that .p12 file in terminal.- Convert it into a .pem file using
openssl pkcs12 -in yourNetBadgeID.p12 -out yourNetBadgeID.pem
- Enter your netbadge password for all three prompts. No symbols will show as you type.
- Your .pem file may now be located at /home/pi/Desktop/yourNetBadgeID.pem. Make sure to note the location of your .pem file.
- Open terminal and type
sudo nano /etc/network/interfaces
-
Add the following text to this file
iface wlan0 inet manual
next line,wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
It should look like this:iface wlan0 inet manual wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
- To save the file and quit nano, press ‘Control X’, Y, Enter
- In terminal again, type
sudo nano /etc/wpa_supplicant/wpa_supplicant.conf
-
Add the following to this file:
network={ ssid="cavalier" eap=TLS auth_alg=OPEN ket_mgmt=WPA-EAP identity="yourNetBadgeID@Virginia.EDU" ca_cert="/home/pi/Desktop/yourNetBadgeID.pem" client_cert="/home/pi/Desktop/yourNetBadgeID.pem" private_key="/home/pi/Desktop/yourNetBadgeID.pem" private_key_passwd="yourNetbadgePass" }
- Now, Control X, Y, Enter
- Find the wlan0 MAC address of your Pi from typing
iwconfig wlan0
and getting the “ether” value. Register this at http://netreg.virginia.edu with your UVA account. - Reboot the Pi and it should automatically connect to the ‘cavalier’ network. If an error shows in the Pi’s network monitor, type
wpa_cli status
in terminal to see if it is really connected or searching.
For standard Linux distros with a gui network manager program:
- Follow all prompts and download your personal certificate as above.
- Convert it to a .pem as above.
- Open your network manager and connect to ‘cavalier’. The parameters are as follows:
- Network type is ‘WPA Enterprise’
- Authentication is ‘TLS’
- Identity is ‘yourNetBadgeID@Virgnia.EDU’ (note the caps)
- CA Cert and Client Cert and Private Key should be ‘yourNetBadgeID.pem’
- Private Key Password is ‘yourNetBadgePassword’
- Finally, find your wlan0 MAC address (Google for how, as dependent on version of Linux), login to netbage here http://netreg.virginia.edu , and register your device’s MAC address for the wlan0 interface.
Final Remarks
If you find any errors in this post, or would like to comment, please send an email to scholarslab@vriginia.edu.