← Latest papers
💻 computer science

Insights into Security-Related AI-Generated Pull Requests

This paper analyzes over 33,000 AI-generated pull requests to reveal that while security-related submissions by agentic AIs often introduce recurring weaknesses like injection flaws, many flawed contributions are merged due to social or process factors rather than technical review, offering new insights into the strengths and limitations of autonomous coding systems in secure software development.

Original authors: Md Fazle Rabbi, Asif K. Turzo, Arifa I. Champa, Minhaz F. Zibran

Published 2026-04-23
📖 5 min read🧠 Deep dive

Original authors: Md Fazle Rabbi, Asif K. Turzo, Arifa I. Champa, Minhaz F. Zibran

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 a bustling construction site where a team of human architects and builders is constantly fixing leaks, reinforcing walls, and upgrading the plumbing of a massive, open-source city. For years, this work has been done entirely by humans. But recently, a new crew has arrived: AI robots (like Copilot, Devin, and Claude) that can write code, fix bugs, and submit their work automatically.

This paper is like a safety inspector's report on what happens when these AI robots try to fix security holes in the city's buildings. The researchers looked at over 33,000 AI submissions (called "Pull Requests" or PRs) and zoomed in on the 675 of them that were supposed to be about security.

Here is the breakdown of their findings, translated into everyday language:

1. The "Robot Mistakes" (What went wrong?)

When humans fix a security hole, they are usually careful. But the AI robots? They tend to make the same few mistakes over and over again.

  • The Analogy: Imagine a robot trying to fix a lock. Instead of making a stronger lock, it accidentally leaves the door slightly ajar, or it uses a key that fits too many doors (making it easy for thieves).
  • The Reality: The most common errors were:
    • Regex Inefficiency (CWE-1333): The AI wrote a "search pattern" that was so complicated it made the computer freeze (like a security guard checking every single grain of sand on a beach instead of just looking for a specific rock).
    • Injection Flaws: The AI let "bad guys" sneak commands into the system (like a delivery person slipping a note into a secure package that tells the guard to open the door).
    • Path Traversal: The AI let people walk into rooms they weren't supposed to enter (like a guest in a hotel finding a back door to the manager's office).

The Scary Part: Even though these robots introduced new security holes, many of their fixes were still approved and merged by human managers. It's like letting a robot fix a fire alarm, and even though it accidentally wired the alarm to the sprinkler system, the building manager still signed off on it.

2. The "Speed and Acceptance" Game (Why did some get in and others get kicked out?)

The researchers asked: What makes a human manager say "Yes, merge this" or "No, go home"?

  • The "Reputation" Factor: If the AI (or the human who prompted it) had a history of good work, it got in faster. It's like a trusted contractor getting their permit approved in an hour, while a stranger waits weeks.
  • The "Busy City" Factor: If the project was already swamped with other work, the AI's request got stuck in traffic.
  • The "Test" Surprise: Usually, adding tests (proof that the fix works) helps you get approved. But for AI? Adding tests actually made it harder to get approved.
    • Why? The researchers think the AI's tests were often "noisy" or fake—like a student trying to cheat on a test by writing the answers in invisible ink. The human reviewers saw the messy tests and got suspicious, so they rejected the whole thing.

3. The "Note on the Door" (Commit Messages)

When a human submits a fix, they write a note explaining what they changed and why.

  • The Finding: For humans, a bad note usually means a slow review or rejection. For AI? It didn't matter much.
  • The Analogy: Imagine a human brings a broken chair and writes a note saying, "I fixed the leg." If they wrote, "I fixed the leg because it was wobbly," the manager is happy. If the AI brings a chair and writes a gibberish note, the manager still looks at the chair. If the chair looks fixed, they accept it. If it looks broken, they reject it. The note didn't change the outcome.

4. The "Rejection Reasons" (Why were they kicked out?)

About 32% of the AI security fixes were rejected. But here is the twist: Most rejections weren't because the code was dangerous.

  • The "Ghost" Rejections: The biggest reason for rejection (38%) was "Unknown." The manager just closed the request without saying why. It's like a hiring manager rejecting a resume with a "No" stamp and no explanation.
  • The "Lazy" Rejections: Another big chunk (12%) was because the AI (or the human) stopped talking to the project for a few days. The system automatically closed the ticket because of "inactivity."
  • The "Real" Rejections: When humans did give a reason, it was usually because the AI introduced a new bug, broke an existing feature, or didn't write enough tests.

The Big Takeaway

The paper concludes that we are currently trusting AI too much in some areas and too little in others.

  • The Problem: Human reviewers are sometimes missing the dangerous security holes the AI creates (like the regex inefficiencies) because they are focused on other things.
  • The Mismatch: At the same time, they are rejecting good AI work just because of minor formatting issues or because the AI didn't "talk" enough to the project.
  • The Solution: We need better "security guards" (tools) to catch the AI's specific types of mistakes before a human ever sees them. We also need to teach the AI to explain its work better and to stop submitting fixes to projects that are already dead or inactive.

In short: AI is a powerful new apprentice, but right now, it's a bit clumsy with security. It needs better supervision, and we need to stop judging it by the same rules we use for humans, because it plays by a different set of rules.

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 →