-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
25 changed files
with
371 additions
and
289 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,69 @@ | ||
# project94 ver.1.0 | ||
|
||
:trollface: Project94 is a fun software for trolling people. | ||
|
||
<div id="badges"> | ||
<img src="https://img.shields.io/pypi/v/project94" alt="Package version"/> | ||
<img src="https://img.shields.io/pypi/pyversions/project94" alt="Python version"/> | ||
<img src="https://img.shields.io/github/license/d35ync/project94" alt="License"/> | ||
</div> | ||
|
||
### Features | ||
- [X] Multiplying sessions using `select` | ||
- [X] SSL support + client certificate verify | ||
- [ ] TODO Support custom modules (idk why) | ||
- [ ] TODO Support both reverse and bind shells | ||
- [X] SSL support + client certificate verify | ||
- [X] Support both reverse and bind shells | ||
- [X] Cli interface commands autocompletion | ||
|
||
### Requirements | ||
- python3.10 | ||
- requests (not necessary) | ||
|
||
### TROLL TUTORIAL "HOW TO USE" | ||
**STEP 1** Installation | ||
Use one of these methods: | ||
- ~~`sudo pip3 install project94`~~ (TODO) | ||
- `sudo pip3 install project94` | ||
- ```bash | ||
git clone https://github.com/d35ync/project94.git | ||
cd project94 | ||
### Stable | ||
git checkout v1.1 | ||
### Unstable | ||
git checkout dev | ||
### Or keep on master for 'pre-release' | ||
|
||
sudo pip3 install . | ||
``` | ||
- `git clone https://github.com/d35ync/project94.git` (yeahs is would works without installing requirements) | ||
|
||
**STEP 2** | ||
BEGIN TROLLING :trollface: | ||
|
||
**STEP 2** Run | ||
- pip installation: `project94 --help` | ||
- git installation: `python3 -m project94 -V` or `python3 project94.py -V` | ||
|
||
**STEP 3** | ||
EZ | ||
|
||
|
||
### CLI interface info | ||
Default command set: | ||
``` | ||
/show displays information of specified type | ||
/interact start interactive shell | ||
/exit shutdown project94 | ||
/help display help message | ||
/bindshell connects to bind shell | ||
/encoding changes active session encoding | ||
/kill kill active or specified session | ||
/goto switch to another session | ||
/cmd executes the command in the current or each session | ||
``` | ||
|
||
U can get extended help for every command: | ||
``` | ||
[NO_SESSION]>> /help /show | ||
[*] Help: /show | ||
Description: displays information of specified type | ||
sessions - shows list of sessions and information about them | ||
info - shows information about active session | ||
Usage: /show {sessions, info} | ||
``` | ||
|
||
### Demo | ||
|
||
https://user-images.githubusercontent.com/52525711/232234241-8eec8eb5-3c6b-4032-9991-d606d3af05b3.mp4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,3 @@ | |
|
||
if __name__ == '__main__': | ||
project94.entry() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
# from project94.project94 import entry, __version__ | ||
from .__main__ import entry, __version__, Project94 | ||
from .project94 import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +0,0 @@ | ||
from .base_command import BaseCommand | ||
from .command import Command | ||
from .encoding import Encoding | ||
from .goto import Goto | ||
from .help import Help | ||
from .info import Info | ||
from .interact import Interact | ||
from .kill import Kill | ||
from .multiply_command import MultiCommand | ||
from .sessions import Sessions | ||
from .exit import Exit | ||
|
||
__all__ = ["BaseCommand", "Command", "Encoding", "Goto", | ||
"Help", "Exit", "Info", "Interact", | ||
"Kill", "MultiCommand", "Sessions"] | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import socket | ||
|
||
from .base_command import BaseCommand | ||
|
||
|
||
class BindShell(BaseCommand): | ||
@property | ||
def description(self) -> str: | ||
return "connects to bind shell" | ||
|
||
@property | ||
def usage(self) -> str: | ||
return f"Usage: {self.name} IP PORT" | ||
|
||
def __call__(self, *args, **kwargs): | ||
ip = args[1] | ||
try: | ||
port = int(args[2]) | ||
except ValueError: | ||
kwargs.get("print_error_callback", lambda x: print(f"[!!!] {x}"))(f"Cant convert {args[1]} to int") | ||
return | ||
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) | ||
try: | ||
sock.connect((ip, port)) | ||
except socket.error: | ||
kwargs.get("print_error_callback", lambda x: print(f"[!!!] {x}"))(f"Cant connect to {ip}:{port}") | ||
else: | ||
self._app.handle_connection(sock, sock.getpeername()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
from .base_command import BaseCommand | ||
|
||
|
||
class Cmd(BaseCommand): | ||
@property | ||
def description(self) -> str: | ||
return "executes the command in the current or each session" | ||
|
||
@property | ||
def usage(self) -> str: | ||
return f"Usage: {self.name} {{current, each}} CMDLINE" | ||
|
||
@property | ||
def subcommands(self) -> list[str]: | ||
return ["current", "each"] | ||
|
||
def __call__(self, *args, **kwargs): | ||
match args: | ||
case ("/cmd", "current", *cmdline): | ||
if 0 == len(cmdline): | ||
kwargs.get("print_error_callback", lambda x: print(f"[!!!] {x}"))(self.usage) | ||
return | ||
if self._app.active_session: | ||
if cmdline: | ||
self._app.active_session.send_command(" ".join(cmdline)) | ||
else: | ||
kwargs.get("print_error_callback", lambda x: print(f"[!!!] {x}"))(self.usage) | ||
else: | ||
kwargs.get("print_warning_callback", lambda x: print(f"[!] {x}"))("Current session is FUCKING DEAD") | ||
|
||
case ("/cmd", "each", *cmdline): | ||
if 0 == len(cmdline): | ||
kwargs.get("print_error_callback", lambda x: print(f"[!!!] {x}"))(self.usage) | ||
return | ||
for id_ in self._app.sessions: | ||
self._app.sessions[id_].send_command(" ".join(cmdline)) | ||
case _: | ||
kwargs.get("print_error_callback", lambda x: print(f"[!!!] {x}"))(self.usage) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.