PentestGPT
Automated Penetration Testing Agentic Framework Powered by Large Language Models
What is PentestGPT?
Automated Penetration Testing Agentic Framework Powered by Large Language Models
Overview of PentestGPT
What it is
PentestGPT is an automated penetration testing agentic framework powered by large language models. It was published at USENIX Security 2024. The tool can operate in autonomous mode (driving Claude Code or Codex) or in an interactive legacy mode that supports multiple LLM providers including OpenAI, Anthropic, Google Gemini, DeepSeek, xAI, Qwen, Moonshot, and local Ollama.
Key features
- AI-Powered Challenge Solver – leverages LLM advanced reasoning to perform penetration testing and CTFs
- Multi-Stage Pipeline – works through staged phases (recon → exploit → walkthrough for CTF; asset discovery → vulnerability identification → report for pentests), feeding each stage's findings into the next
- Live Walkthrough – tracks steps in real-time as the agent works through challenges
- Multi-Category Support – Web, Crypto, Reversing, Forensics, PWN, Privilege Escalation
- Real-Time Feedback – watch the AI work with live activity updates
- Extensible Architecture – clean, modular design ready for future enhancements
- Session Persistence – save and resume penetration testing sessions
Use cases
- Solving Capture The Flag (CTF) challenges across multiple categories
- Performing automated penetration tests on targets with asset discovery, vulnerability identification, and report generation
- Interactive human-in-the-loop penetration testing using the legacy multi-LLM mode
Getting started
Prerequisites: Python 3.12+, uv package manager, and either Claude Code CLI or Codex CLI installed and authenticated.
git clone https://github.com/GreyDGL/PentestGPT.git
cd PentestGPT
make install # runs uv sync
Basic usage:
pentestgpt --target 10.10.11.234
For Docker usage, see the repository README.
License and pricing
Licensed under MIT. Open source (no pricing).
Based on the project's public README and repository metadata.