summaryrefslogtreecommitdiffstats
path: root/usr/bin/autowifi
diff options
context:
space:
mode:
authorlassulus <lassulus@googlemail.com>2013-05-24 13:38:51 +0200
committerlassulus <lassulus@googlemail.com>2013-05-24 13:38:51 +0200
commit6ede8f54181fa1adaf403f66f9779bce7b721af5 (patch)
treebdb54368649c873070c98cb9eeb37c0610874ebb /usr/bin/autowifi
parent631986deaf81a4641578d1d878f66d2e1a622396 (diff)
now with old key deletion
Diffstat (limited to 'usr/bin/autowifi')
-rwxr-xr-xusr/bin/autowifi2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/bin/autowifi b/usr/bin/autowifi
index 3c3444df..a133b3c3 100755
--- a/usr/bin/autowifi
+++ b/usr/bin/autowifi
@@ -68,7 +68,7 @@ crack_wifi(){
connect_wifi $3 $1 $encr $key
sleep 20
if check_gateway; then
- (cat /etc/autowifi/wifi_keys; echo "$1|$2|$key" ) | sort | uniq >> /etc/autowifi/wifi_keys
+ (cat /etc/autowifi/wifi_keys | grep -v "$1|$2|" ; echo "$1|$2|$key" ) | sort | uniq >> /etc/autowifi/wifi_keys
echo "yay internet"
return 0
fi