Skip to content

Instantly share code, notes, and snippets.

@DNA64
Last active January 15, 2023 00:15
Show Gist options
  • Save DNA64/59e280dbbd3dd90b33dc6f1fae60b99d to your computer and use it in GitHub Desktop.
Save DNA64/59e280dbbd3dd90b33dc6f1fae60b99d to your computer and use it in GitHub Desktop.
This will patch the wifi-wpa-setup file of the wpa_supplicant module to allow spaces in SSID's and Passwords. Credit viral_dna if used.
#!/bin/sh
# October 3rd, 2019
# This will patch the wifi-wpa-setup file of the wpa_supplicant module to allow spaces in SSID's and Passwords.
# While I don't think spaces in passwords will be an issue, I figured it couldn't hurt to add that in as well.
#
# The wpa_supplicant module KMFD's Mod Hub has now been updated with this fix.
# - viral_dna (aka DNA64)
sed -i '5,5d' /bin/wifi-wpa-setup
sed -i '5s/.*/ IFS= read -r -p "Enter your SSID (Spaces are allowed!): " SSID/' /bin/wifi-wpa-setup
sed -i '11,11d' /bin/wifi-wpa-setup
sed -i '11s/.*/ IFS= read -r -p "Enter your Wi-Fi password: " PASS/' /bin/wifi-wpa-setup
rm -f wpa_patch #cleanup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment