AIALIB: A Threat Library for AI-Generated Code
Abstract
Large language models (LLMs) are increasingly integrated into software development workflows, yet a growing body of evidence shows that the code they generate often contains security vulnerabilities. Prior work has primarily focused on measuring the prevalence of such issues, providing useful evidence of risk but limited support for understanding their causes, tracking how they propagate through development workflows, or integrating this knowledge into practical security processes. To address these gaps, we present aialib, an annotated threat library for AI-generated code. aialib systematically generates, analyzes, and structures potential vulnerabilities from LLM-produced code, enriching each finding with conventional security taxonomies (CWE and OWASP) together with AI-specific information describing why the vulnerability was generated, how it propagates through code reuse and refactoring, and how it relates to AI-system threat models.