A final-year project implementing Multi-Agent Deep Deterministic Policy Gradient (MADDPG)
for simulating red-team penetration testing strategies in a cybersecurity environment.
This project simulates a red-team penetration testing scenario using Multi-Agent Reinforcement Learning (MARL).
Agents represent attackers attempting to discover and exploit vulnerabilities in a simulated computer network,
with the ultimate goal of compromising a designated target node.
- Multi-Agent environment for red-team style attack simulations.
- Cybersecurity network modeled as a graph with nodes and services.
- Implementation of MADDPG (Multi-Agent Deep Deterministic Policy Gradient).
- Training and evaluation scripts with visualization support.
- Custom Replay Buffer for experience replay.
├── training.py # Main training loop
├── evaluate.py # Run trained agents
├── cyber_env.py # Custom cybersecurity environment
├── maddpg.py # MADDPG agent and neural networks
├── requirements.txt # Python dependencies
└── README.yaml # Project documentation
- Clone the repository:
git clone https://github.com/your-username/MARL-RedTeam.git cd MARL-RedTeam - Create a virtual environment:
python3 -m venv venv
source venv/bin/activate # Linux/Mac
venv\Scripts\activate # Windows- Install dependencies:
pip install -r requirements.txtRun the training script:
python training.pyProgress is displayed every 100 episodes with:
- Average reward
- Success rate
- After training, save agent weights
- Evaluate trained agents:
python evaluate.py
During training, results are plotted:
- Episode Rewards
- Success Rate (rolling average)
The environment can also render:
- Node states
- Compromised systems
- Python 3.10+
- PyTorch
- NumPy
- NetworkX
- Matplotlib
- More realistic vulnerability models
- Blue-team (defender) agents -Larger, dynamic network topologies Transfer learning for different environments
This project is licensed under the MIT License.