https://github.com/luffy0xcyber/trojans-c2c-in-python
I'm learning how Trojans and C2C (Command & Control) systems work using Python. This project helps me understand remote access, command execution, and how client-server communication happens in real-world scenarios — all in a safe and ethical context.
https://github.com/luffy0xcyber/trojans-c2c-in-python
c2c ethical-hacking python python3 trojan trojans
Last synced: 9 months ago
JSON representation
I'm learning how Trojans and C2C (Command & Control) systems work using Python. This project helps me understand remote access, command execution, and how client-server communication happens in real-world scenarios — all in a safe and ethical context.
- Host: GitHub
- URL: https://github.com/luffy0xcyber/trojans-c2c-in-python
- Owner: Luffy0xCyber
- License: mit
- Created: 2025-03-23T15:42:03.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-23T15:55:01.000Z (about 1 year ago)
- Last Synced: 2025-03-23T16:36:01.339Z (about 1 year ago)
- Topics: c2c, ethical-hacking, python, python3, trojan, trojans
- Language: Python
- Homepage:
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Python Trojan (C2 Client-Server)
**Disclaimer**: For ethical hacking and educational use only.
## Description
I've decided to create a simple Python Trojan as a learning exercise.
It's a basic Command & Control (C2) system with a client-server architecture.
*I will improve it over time*.
A lightweight Command & Control system in Python featuring:
- Remote shell execution
- Directory navigation with persistent working directory
- Output logging with encoding-safe handling
## Structure
- `client.py`: Connects to the server and executes commands
- `server.py`: Sends commands and logs responses
- `session_log.txt`: Stores session outputs
## Usage
1. Run `server.py`
2. Run `client.py`
3. Execute commands like `whoami`, `cd`, `dir`, `ipconfig`...
## TODO (coming soon)
- Add file transfer
- Encrypt client-server communication
- Auto system info on connection
- Multi-client support