forked from hook-s3c/blueborne-scanner
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbluebornescan.py
59 lines (49 loc) · 1.98 KB
/
bluebornescan.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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
import time
import bluetooth
from classes.deviceslist import devices
devicelookup = devices.get_devices()
def search():
print "searching for devices"
devices = bluetooth.discover_devices(duration=20, lookup_names = True)
return devices
def is_device_vulnerable(addr):
#print "looking up OUI {0}".format(addr[:8])
manufacturers = devicelookup["ANDROIDS"]
for manufacturer in manufacturers:
#print manufacturer
lookups = manufacturers[manufacturer]
for _ in lookups:
if _ == addr[:8]:
return True
#print "FOUND : " + _
return False
if __name__=="__main__":
print ("\n")
print ("\x1b[1;35mhook's Blueborne Android scanner v0.01\x1b[0m")
print ("\n")
print ("\n")
try:
while True:
results = search()
if (results!=None):
for addr, name in results:
vulnerable = is_device_vulnerable(addr)
print "{0} - {1} - {isVulnerable}Vulnerable".format(addr, name, isVulnerable="!!! IS " if vulnerable else "NOT ")
#endfor
#endif
time.sleep(60)
#endwhile
except KeyboardInterrupt:
print ("\n\x1b[1;35m ")
print (" _ (^) ")
print (" (_\ |_| ")
print (" \_\ |_| ")
print (" _\_\,/_| ap0r ")
print (" (`\(_|`\| ")
print (" (`\,) \ \' ")
print (" \,) | | ")
print (" \__(__|\x1b[0m ")
print (" ")
print ("Shoutz to sh3llg0d, an0n, daemochi, akatz")
print ("Peace! ")
print ("\n ")