Research

by Alex Azuero

CSS

https://medium.com/@jasonrigden/using-tor-with-the-python-request-library-79015b2606cb





https://ipinfo.io/73.180.207.159/json?token=f6c82d23c419da

html= 'https://ipinfo.io/73.180.207.159/json?token=f6c82d23c419da'
f = requests.get( html)#,proxies=proxies)
f.json()


https://stackoverflow.com/questions/24678308/how-to-find-location-with-ip-address-in-python
https://dev.maxmind.com/geoip/legacy/geolite/
import pygeoip
GEOIP = pygeoip.GeoIP("/absolute_path/GeoIP.dat", pygeoip.MEMORY_CACHE)
GEOIP.country_name_by_addr(ip)
http://ip-api.com/docs/api:json
http://ip-api.com/json/208.80.152.201




https://lite.ip2location.com/ip-address-ranges-by-country



#-----------------------------------------------------------
import re
import json
import urllib
import requests
import random
# dir(urllib)

url = 'http://ipinfo.io/json'
proxies_list=["104.129.24.39","173.254.236.39", "73.180.207.159", "198.23.79.85"]
proxies = dict(http= random.choice(proxies_list))
# response = urllib.request(url)
response = requests.get(url, proxies=proxies)

# data = response.text#json.load(response)
data = response.json()
IP=data['ip']
org=data['org']
city = data['city']
country=data['country']
region=data['region']

print ('Your IP detail\n ')
print ('IP : {4} \nRegion : {1} \nCountry : {2} \nCity : {3} \nOrg : {0}'.format(org,region,country,city,IP))





#