diff options
Diffstat (limited to 'wifi')
-rwxr-xr-x | wifi | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -0,0 +1,16 @@ +#!/bin/bash +# +# Wifi initializer +# + +#DEVICE="ath0" +DEVICE="wlan0" + +if [ ! -z "$1" ]; then + read -sp "Enter the WPA passphrase: " PASS + echo "" + wpa_passphrase $1 $PASS +elif [ -f "wpa_supplicant.conf" ]; then + sudo wpa_supplicant -B -Dwext -i$DEVICE -cwpa_supplicant.conf + sudo dhclient $DEVICE +fi |