What happened
Veracode's latest GenAI Code Security Report reveals that the security of code produced by large language models (LLMs) has improved, with the overall security score rising from 56 percent to 62 percent. This shift corresponds to a reduction in identified vulnerabilities from 44 percent to 38 percent. The report, which has tracked LLM code output since July 2025, highlights that 10 models now exceed a 60 percent security threshold, compared to only four in the previous assessment. Anthropic's Claude Opus 5.5 and OpenAI's GPT-6-Sol currently share the top ranking with a 73 percent security score, surpassing the previous high of 68 percent held by GPT-5.5.
Veracode tested 18 distinct LLMs across four programming languages: Python, C#, JavaScript, and Java. The evaluation focused on four specific Common Weakness Enumeration (CWE) categories: CWE-89 (SQL injection), CWE-327 (broken cryptographic algorithms), CWE-80 (cross-site scripting), and CWE-117 (improper output neutralization for logs).
The primary driver for the observed security gains was identified as improved pattern recognition, particularly regarding cross-site scripting (XSS) vulnerabilities. Veracode characterized XSS as the most straightforward vulnerability for current models to address through existing training patterns.
Despite the overall improvement, the report highlights a persistent limitation in complex security reasoning. LLMs continue to struggle with data-flow reasoning that requires understanding how information moves across multiple functions, such as in cases of log injection.
Why it matters
The improvement in AI-generated code security is significant for enterprise software development, as it suggests that LLMs are becoming more reliable at avoiding common coding flaws. By reducing the frequency of vulnerabilities like cross-site scripting (XSS), these models can potentially lower the burden on human developers to manually audit AI-assisted code. However, the persistence of failures in complex security reasoning—such as data-flow analysis across multiple functions—underscores that AI remains an imperfect tool. The findings emphasize that while AI security is trending upward, it is not yet a replacement for rigorous, independent security verification processes in production environments.
The data provides a for the efficacy of LLMs in secure coding practices. With top models now achieving a 73 percent security score, the industry is seeing a measurable, albeit incomplete, maturation of AI-assisted development tools.
Chris Wysopal, co-founder and chief security evangelist at Veracode, emphasized that while the progress is encouraging, the cost-to-performance ratio remains a hurdle. Top-performing models are more expensive to deploy, yet they still fail to identify or prevent vulnerabilities in more than one out of every four security tasks.
The report serves as a reminder that AI-generated code is not inherently secure. Veracode explicitly recommends that organizations integrate AI-assisted coding with continuous, independent security verification to catch vulnerabilities that models fail to detect.
Interactive Mechanism: How It Actually Works
Explore the underlying technology behind this development interactively.
Which component of an AI application is the machine-learning model itself?
What to watch next
Industry observers should monitor whether the performance gap between top-tier models and smaller, more cost-effective models continues to widen. As Veracode noted, the most secure models currently command higher costs, which may influence adoption strategies for organizations balancing security requirements against budget constraints. Additionally, the ongoing struggle of LLMs with complex, multi-functional security reasoning suggests that future model updates will need to prioritize architectural improvements in logic and data-flow analysis rather than just pattern recognition. Continued reliance on independent security testing remains the recommended standard for mitigating the remaining 27 percent failure rate observed in top-performing models.
Future reports will likely focus on whether models can bridge the gap in complex reasoning tasks. The current plateau in logic-heavy security tasks suggests that simple pattern matching has reached a point of diminishing returns.
The cost of high-security AI models will be a critical factor for enterprise adoption. If the most secure models remain significantly more expensive, organizations may face a trade-off between security and operational efficiency.
The reliance on independent security verification is expected to remain a standard industry practice. As AI models evolve, the integration of these tools into automated CI/CD pipelines will be the next phase of development for secure software engineering.