← Latest papers
💻 computer science

PoCGen: Generating Proof-of-Concept Exploits for Vulnerabilities in Npm Packages

PoCGen is a novel framework that autonomously generates and validates proof-of-concept exploits for npm package vulnerabilities by synergizing large language models, static analysis, and dynamic analysis, achieving a 77% success rate that significantly outperforms existing baselines at a low cost.

Original authors: Deniz Simsek, Aryaz Eghbali, Michael Pradel

Published 2026-06-30
📖 4 min read☕ Coffee break read

Original authors: Deniz Simsek, Aryaz Eghbali, Michael Pradel

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you own a massive library of digital tools (called npm packages) that developers use to build websites and apps. Sometimes, these tools have hidden cracks or broken locks in their design—these are vulnerabilities.

When a security researcher finds a crack, they write a report describing the problem. But often, the report is like a vague warning sign: "Hey, there's a loose board on the third shelf!" It doesn't show how to actually step on that board to prove it's loose. Without a clear demonstration (called a Proof-of-Concept or PoC), the people who fix the library might struggle to understand the danger, and they can't easily test if their repair actually works.

PoCGen is a new automated "detective" designed to solve this problem. It takes that vague warning sign and automatically builds a step-by-step demonstration to prove the crack exists.

Here is how PoCGen works, using a simple analogy:

The Detective's Toolkit

PoCGen isn't just one tool; it's a team of three specialists working together:

  1. The Translator (Large Language Model - LLM): Think of this as a super-smart intern who is great at reading messy, informal notes. When the security report says, "Something weird happens with URLs," the Translator understands the human language and guesses, "Oh, they probably mean this specific function handles URLs."
  2. The Mapmaker (Static Analysis): This is a tool that looks at the blueprints of the code without actually running it. It traces the path a piece of data takes from the front door to the back room. It answers: "If I put a bad input here, does it actually reach the dangerous part of the code?"
  3. The Test Driver (Dynamic Analysis): This is the person who actually drives the car to see if it breaks. They take the instructions from the Translator and the Mapmaker, run the code, and see: "Did the car crash? Did the lock break?"

How PoCGen Solves the Mystery

The process is like a game of "Hot and Cold" where the detective keeps refining their guess until they find the treasure.

  1. The First Guess: The Translator reads the report and the code blueprints. It writes a draft "exploit" (a script to break the code).
  2. The Test Drive: The Test Driver runs this script.
    • Success: If the script breaks the code exactly as the report predicted, PoCGen says, "Got it!" and hands the solution to the user.
    • Failure: If the script fails (e.g., the car didn't crash, or it crashed for the wrong reason), the detective doesn't give up.
  3. The Refinement Loop: This is the magic part. PoCGen looks at why it failed.
    • Did the code throw an error? The Translator gets the error message and tries again.
    • Did the code not reach the dangerous part? The Mapmaker shows the Translator exactly where the path stopped, so the next script can go further.
    • Did the input look wrong? The Test Driver shows the Translator exactly what the code saw, so the next script can be more precise.

The detective keeps refining the script, adding more clues and fixing mistakes, until it successfully demonstrates the vulnerability.

What the Paper Found

The researchers tested PoCGen on 560 real-world vulnerabilities in the npm library.

  • Success Rate: PoCGen successfully created a working demonstration for 71% of the vulnerabilities.
  • Comparison: A previous top-tier tool (called Explode.js) only managed to solve 32% of the same problems. PoCGen was significantly better.
  • Cost: It was very cheap to run, costing an average of only $0.02 per vulnerability.
  • Real-World Impact: The team also tested PoCGen on 126 brand-new vulnerabilities reported recently. It succeeded in 60% of those cases. In fact, they used PoCGen to add working demonstrations to five official security reports that previously had none.

Why This Matters

Before PoCGen, if a security report lacked a demonstration, developers might have to spend hours or days trying to figure out how to break their own code to fix it. PoCGen automates this "breaking" process.

  • For Developers: It gives them a clear "test case" to verify their fix works.
  • For Security Researchers: It helps them prove their findings are real and actionable.
  • For the Ecosystem: It speeds up the time between finding a bug and fixing it, making the software ecosystem safer for everyone.

In short, PoCGen turns vague warnings into clear, actionable evidence, helping the digital world patch its holes faster and more reliably.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →