Last active
December 21, 2015 16:49
-
-
Save Marko-M/6335764 to your computer and use it in GitHub Desktop.
Debian based wireless with WPA/WPA2 from CLI
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# One time only, to create wpa.conf: | |
# wpa_passphrase ESSID secret > wpa.conf | |
# su to root, or use sudo for following commands | |
su | |
# Bring the wlan interface up | |
ifconfig wlan0 up | |
# Start wpa_supplicant. If n180211 driver doesn't | |
# work for you try the other ones (man wpa_supplicant) | |
sudo wpa_supplicant -B -Dnl80211 -iwlan0 -c./wpa.conf | |
# Release old lease just in case (restart dhclient) | |
dhclient -r | |
# Obtain new lease | |
dhclient wlan0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment