-
Notifications
You must be signed in to change notification settings - Fork 45
/
print-final-results.py
37 lines (30 loc) · 1.95 KB
/
print-final-results.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import os
from tabulate import tabulate
networksCracked = []
def hasNetworkalreadyBeenCracked(resultHash):
cracked = False
for network in networksCracked:
if network[2].split(":")[0] == resultHash.split(":")[0]:
cracked = True
break
return cracked
def detectCrackedNetworks():
with open("./hashcat/hashcat-output.txt") as hashcatOutput:
results = hashcatOutput.readlines()
for result in results:
resultHash = result.split(":")[-4] + ":" + result.split(":")[-3]
if(not hasNetworkalreadyBeenCracked(resultHash)):
ssid = result.split(":")[-2]
password = result.split(":")[-1].strip()
networksCracked.append([ssid, password, resultHash])
def printCrackedNetworks():
print('''
▄▄· ▄▄▄ ▄▄▄· ▄▄· ▄ •▄ ▄▄▄ .·▄▄▄▄ ▐ ▄ ▄▄▄ .▄▄▄▄▄▄▄▌ ▐ ▄▌ ▄▄▄ ▄ •▄ .▄▄ ·
▐█ ▌▪▀▄ █·▐█ ▀█ ▐█ ▌▪█▌▄▌▪▀▄.▀·██▪ ██ •█▌▐█▀▄.▀·•██ ██· █▌▐█▪ ▀▄ █·█▌▄▌▪▐█ ▀.
██ ▄▄▐▀▀▄ ▄█▀▀█ ██ ▄▄▐▀▀▄·▐▀▀▪▄▐█· ▐█▌ ▐█▐▐▌▐▀▀▪▄ ▐█.▪██▪▐█▐▐▌ ▄█▀▄ ▐▀▀▄ ▐▀▀▄·▄▀▀▀█▄
▐███▌▐█•█▌▐█ ▪▐▌▐███▌▐█.█▌▐█▄▄▌██. ██ ██▐█▌▐█▄▄▌ ▐█▌·▐█▌██▐█▌▐█▌.▐▌▐█•█▌▐█.█▌▐█▄▪▐█
·▀▀▀ .▀ ▀ ▀ ▀ ·▀▀▀ ·▀ ▀ ▀▀▀ ▀▀▀▀▀• ▀▀ █▪ ▀▀▀ ▀▀▀ ▀▀▀▀ ▀▪ ▀█▄▀▪.▀ ▀·▀ ▀ ▀▀▀▀
''')
print(tabulate(networksCracked, headers=['SSID', 'Password', "Hash"]))
detectCrackedNetworks()
printCrackedNetworks()