-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathip.py
29 lines (26 loc) · 1.06 KB
/
ip.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
#!usr/bin/python
# author by angga kurniawan
import os, json, requests
def __main__():
os.system("clear")
with requests.Session() as ses:
try:
j = ses.get("https://ipapi.co/json/").json()
print(" [+] IP Anda : %s"%(j["ip"]))
print(" +--------------------------------------+")
print(" [+] Negara : %s"%(j["country_name"]))
print(" [+] Kota : %s"%(j["city"]))
print(" [+] Provinsi : %s"%(j["region"]))
print(" +--------------------------------------+")
print(" [+] Kode Negara : %s"%(j["country_calling_code"]))
print(" [+] Mata Uang : %s"%(j["currency_name"]))
print(" [+] Bahasa : %s"%(j["languages"]))
print(" +--------------------------------------+")
print(" [+] Populasi : %s"%(j["country_population"]))
print(" [+] Organisasi : %s"%(j["org"]))
print(" [+] Time Zone : %s"%(j["timezone"]))
print(" +--------------------------------------+")
exit(" [*] Website : https://ipapi.co")
except Exception as e:
exit("\n [!] Error : "+str(e))
__main__()