summaryrefslogtreecommitdiffstats
path: root/usr/lib/autowifi/plugins/02tplink
blob: b2b96f959b3fe02465a4c4cd3a93b8eea1f7a0ff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
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