summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2013-07-29 09:45:21 +0200
committermakefu <github@syntax-fehler.de>2013-07-29 09:45:21 +0200
commitc0ed79350e3202fce841cb2cda337b8ecdf52b1c (patch)
treeb3b39e071527277395368509918b4ad349a29db5
parent7356d022cab45297c2aadeaa02834a354daf1c66 (diff)
add tp-link default wpa key implementation
-rwxr-xr-xusr/lib/autowifi/plugins/02tplink17
1 files changed, 17 insertions, 0 deletions
diff --git a/usr/lib/autowifi/plugins/02tplink b/usr/lib/autowifi/plugins/02tplink
new file mode 100755
index 00000000..b2b96f95
--- /dev/null
+++ b/usr/lib/autowifi/plugins/02tplink
@@ -0,0 +1,17 @@
+#!/bin/sh
+# Implementation of TP-Link default WPA Key
+# Based on
+# http://www.wardriving-forum.de/forum/f321/ezwlan-android-2-1-a-70045-4.html#post342481
+
+cd $(dirname $(readlink -f $0))
+. ../lib/plugin_core
+
+parse_plugin_args "$@"
+
+! check_vendor_mac $VENDOR_MAC "F8D111" && echo "$VENDOR_MAC not affected" && exit 1
+! echo $ESSID | egrep -q '^tp' && echo "$ESSID not affected" && exit 1
+
+
+# printf always makes string to lower, need that for correct md5sum
+printf ${MAC:4:12}
+exit 0