Login to your pi’s terminal, and run the following two commands.
sudo su wpa_passphrase YOUR_SSID
You’ll then be asked to enter the passphrase and confirm the passphrase. If they match; you’ll see a blurb that’s a config file fragment.
Now (still as
su) repeat the last step, but pipe-append the output to the supplicant file.
wpa_passphrase YOUR_SSID >> /etc/wpa_supplicant/wpa_supplicant.conf
You won’t see the instructions this time - but that’s okay. Next, remove the plain text password from the supplicant file.
sudo nano /etc/wpa_supplicant/wpa_supplicant.conf
Finally; reboot and run something like
sudo apt-get update to test it all.
I have no idea why the guides for this take four pages.