Presented at
DEF CON 31 (2023),
Aug. 13, 2023, noon
(45 minutes).
Large Language Models are already revolutionizing the software development landscape. As hackers we can only do what we've always done, embrace the machine and use it to do our bidding.
There are many valid criticisms of GPT models for writing code like the tendency to hallucinate functions, not being able to reason about architecture, training done on amateur code, limited context due to token length, and more. None of which are particularly important when writing fuzz tests. This presentation will delve into the integration of LLMs into fuzz testing, providing attendees with the insights and tools necessary to transform and automate their security assessment strategies.
The presentation will kick off with an introduction to LLMs; how they work, the potential use cases and challenges for hackers, prompt writing tips, and the deficiencies of current models. We will then provide a high level overview explaining the purpose, goals, and obstacles of fuzzing, why this research was undertaken, and why we chose to start with 'memory safe' Python. We will then explore efficient usage of LLMs for coding, and the primary benefits LLMs offer for security work, paving the way for a comprehensive understanding of how LLMs can automate tasks traditionally performed by humans in fuzz testing engagements.
We will then introduce FuzzForest, an open source tool that harnesses the power of LLMs to automatically write, fix, and triage fuzz tests on Python code. A thorough discussion on the workings of FuzzForest will follow, with a focus on the challenges faced during development and our solutions. The highlight of the talk will showcase the results of running the tool on the 20 most popular open-source Python libraries which resulted in identifying dozens of bugs.
We will end the talk with an analysis of efficacy and question if we'll all be replaced with a SecurityGPT model soon.
To maximize the benefits of this talk, attendees should possess a fundamental understanding of fuzz testing, programming languages, and basic AI concepts. However, a high-level refresher will be provided to ensure a smooth experience for all participants.
REFERENCES:
My original blog post that sparked the idea:
https://infiniteforest.org/LLMs+to+Write+Fuzzers
Blogs:
https://comby.dev/blog/2022/04/11/comby-decomposer-compiler-fuzzing
https://martinfowler.com/articles/2023-chatgpt-xu-hao.html
Research Papers:
https://arxiv.org/abs/2212.14834
https://embed.cs.utah.edu/csmith/
https://www.usenix.org/system/files/sec23fall-prepub-446-fu.pdf
Tools:
https://github.com/google/atheris
https://github.com/mpaepper/llm_agents
Prompt Course:
https://www.deeplearning.ai/short-courses/chatgpt-prompt-engineering-for-developers/
Presenters:
-
X
- Hacker
X is a seasoned security researcher and programming language enthusiast with an impressive track record in research, vulnerability discovery, and fuzz testing. From the moment he laid hands on a Blueberry-colored Apple iBook G3 provided by his elementary school, X developed a slight obsession with technology.
He is a urban cycling enthusiast that needs to wear his helmet more often, a techno and bass aficionado, and tree wizard.
Before finding vulnerabilities for a living he developed scientific computing software. See his Clojure-based Sequoia database fuzzer for an ideal representation of X's skill set and interests.
Links:
Similar Presentations: