summaryrefslogtreecommitdiffstats
path: root/usr/lib/autowifi/plugins/00profile
diff options
context:
space:
mode:
Diffstat (limited to 'usr/lib/autowifi/plugins/00profile')
-rwxr-xr-xusr/lib/autowifi/plugins/00profile8
1 files changed, 8 insertions, 0 deletions
diff --git a/usr/lib/autowifi/plugins/00profile b/usr/lib/autowifi/plugins/00profile
new file mode 100755
index 00000000..fe42470b
--- /dev/null
+++ b/usr/lib/autowifi/plugins/00profile
@@ -0,0 +1,8 @@
+#!/bin/sh
+#ESSID MAC CHANNEL ENCRYPTION WPA WPA2
+cat /etc/autowifi/wifi_keys | (while IFS='|' read SSID MAC KEY; do
+ if [ "$1" == "$SSID" -a "$2" == "$MAC" ]; then
+ echo $KEY
+ exit 0
+ fi
+done; exit 1)