Getting pwn'd by AI: Penetration Testing with Large Language Models

Andreas Happe, Jürgen Cito
7/24/2023
213 citations
cs.CLcs.AIcs.CR

Official code: ipa-lab/hackingBuddyGPT (1,341 stars, Python, MIT, last commit 2026-03-26).

Abstract

The field of software security testing, more specifically penetration testing, is an activity that requires high levels of expertise and involves many manual testing and analysis steps. This paper explores the potential usage of large-language models, such as GPT3.5, to augment penetration testers with AI sparring partners.

Show full abstract

We explore the feasibility of supplementing penetration testers with AI models for two distinct use cases: high-level task planning for security testing assignments and low-level vulnerability hunting within a vulnerable virtual machine. For the latter, we implemented a closed-feedback loop between LLM-generated low-level actions with a vulnerable virtual machine (connected through SSH) and allowed the LLM to analyze the machine state for vulnerabilities and suggest concrete attack vectors which were automatically executed within the virtual machine. We discuss promising initial results, detail avenues for improvement, and close deliberating on the ethics of providing AI-based sparring partners.

View on arXivView PDF

Code Implementations(1)

MIT

Helping Ethical Hackers use LLMs in 50 Lines of Code or less..

1,341235Python, ShellAug 2, 20238 months agoMIT
large-language-modelsllmpenetration-testingpentesting

Similar Papers

Cite this paper

@article{happe2023getting,
  title  = {Getting pwn'd by AI: Penetration Testing with Large Language Models},
  author = {Andreas Happe and Jürgen Cito},
  year   = {2023},
  eprint = {2308.00121},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2308.00121v3}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2308.00121.svg)](https://codeofpaper.com/paper/2308.00121)

Discussion