Published on
A developer who once wrote every line of a feature might now spend their time reviewing a function an AI assistant drafted in seconds. To approve it safely, the developer has to identify the same flaws in the AI assistant's code they once avoided in their own code.
Secure coding training for developers should teach those fundamentals with the expectation that developers will rely on AI assistants more and more. And as those same developers add AI to their own products, they'll also need to recognize the new ways attackers can target those AI features.
Why Does AI Change What Secure Coding Training Needs to Cover?
Secure coding training has more to cover now that AI coding assistants write the first draft for many developers. Those developers then spend their time reviewing the code before it merges instead of writing it themselves, so they need deeper secure coding knowledge to identify flaws in code they didn't write themselves.
Researchers estimated that by the end of 2024, 29% of new Python functions from US developers on GitHub were written with substantial AI support, up from about 5% in 2022.1 On a team with that mix, the reviewer may be the first human to read more than a quarter of new functions.
When Veracode tested more than 100 models on 80 coding tasks in 2025, its static analysis flagged the targeted weakness in 45% of the tasks.2 The models struggled with cross-site scripting in particular, with flagged code in 86% of relevant cases. Developers need training on weakness types like these to recognize them in a pull request.
Developers still need that training as models improve. Veracode's October 2026 update, which tested 18 models, found the average pass rate had risen to 62%. That means newer models still produced flagged code in 38% of tasks.3 Java code passed only about 31% of the time, which left Java teams with insecure suggestions in roughly two of every three tasks.
Each team's risk depends partly on the language it works in, so training has to cover the stack each developer uses. When a reviewer approves an AI suggestion, they're making the security decision. That's why developers still need secure code training even when an assistant writes the first draft.
What Core Secure Coding Skills Should Every Developer Training Program Include?
Every developer training program should still teach the secure coding fundamentals that reviewers use to judge an AI suggestion:
- Validate input at every trust boundary: Attackers could inject code any time an application accepts outside data, including a model's reply.
- Expire sessions and protect tokens: An attacker can reuse a stolen session token if the code keeps it valid after logout.
- Check permissions on every request: An assistant may write a working endpoint that skips the ownership check.
- Keep secrets out of code and logs: Developers who track where data flows can stop a password from ending up in a repository.
- Treat every dependency as code you ship: One untrustworthy library can expose every application that imports it.
Secure code training should teach these skills in the languages and frameworks each developer ships. An injectable database query in Java looks different from one in Python. Veracode saw the same effect in its results, which varied widely by language.
Do Developers Still Need to Learn the OWASP Top 10 and CWE Top 25?
Developers need to learn both lists because AI assistants still write the classic weaknesses they describe. The Open Worldwide Application Security Project (OWASP) groups the cross-site scripting flaws Veracode found under injection on its OWASP Top 10 list.
MITRE also includes cross-site scripting in its Common Weakness Enumeration (CWE) list of the most dangerous software weaknesses, called the CWE Top 25. The AI models Veracode tested had similar issues with log injection and other long-documented weaknesses that a trained reviewer would recognize.
Reviewers can use both lists as a guide to the flaws they should look for in an AI suggestion. Training should then have developers find those weaknesses in pull requests written in their own languages and frameworks.
How Should Training Prepare Developers to Review AI-Generated Code?
Train your developers to read an AI suggestion as critically as a pull request from a new contributor. In a 2026 study of 100 developers who got AI suggestions for C programming tasks, participants looked at each suggestion for about 21 seconds.4
Only 22% of the solutions they submitted were free of vulnerabilities. Developers who glance that quickly can easily miss a flaw, which is why secure code review needs time and practice. Training should teach developers to take these steps any time they work with an AI assistant:
- Look for insecure defaults: An assistant may disable a certificate check to make a feature work.
- Check every dependency version: In a 2026 measurement study, 37% to 56% of tasks across 10 models pinned at least one vulnerable library version.5 A reviewer who checks those versions against a vulnerability database can catch flaws that were mostly rated critical or high.
- Don't count on the prompt to make code secure: A 2026 evaluation of five models found no statistically significant drop in vulnerabilities across prompting methods.⁶ Stating security requirements still helps make your intent clear, but the reviewer still has to do the security check..
Developers need those steps even more when they try vibe coding, which is a style where they describe a feature in plain language and let an AI assistant write it. Scanners can back up their review and flag some flaws automatically, which helps with vibe coding security. Those developers still have to decide which findings matter and how to fix them.
What AI and LLM Risks Should Developers Learn to Recognize?
Developers who add large language model (LLM) features to a product should learn to recognize prompt injection, sensitive information disclosure, excessive agency, and improper output handling from the OWASP Top 10 for LLM Applications. In prompt injection, text from an email or file overrides the app's instructions.
Once an attacker controls the model's instructions, they can push it to show private data to the wrong user. The attacker can do even more damage if the app gives the model excessive agency, or more permissions than its task needs. If the app also passes the model's reply straight into other code, the attacker can use that reply to attack those systems through improper output handling.
Why Does Hands-On, Role-Based Practice Matter More Than Video Training?
Developers get better at reviewing AI-generated code through practice with real vulnerabilities in real source code. Hands-on secure coding training gives them that practice in full, live applications with complete source code, just like in real life.
They can watch an attack succeed in a break/fix lab, then trace it to the faulty code and write their own fix. To write that fix, the developer has to use the same judgment a reviewer applies to an AI suggestion. Developers in copy-paste exercises paste in a fix someone else wrote and don't have to make that judgment call.
Role-based secure coding training also matches that practice to each person's work. A front-end developer needs labs on cross-site scripting, a DevOps engineer needs labs on pipelines and secrets, and a team adding LLM features needs labs on prompt injection. Learning paths at foundational, intermediate, and advanced levels let each person start at their current skill level.
How Can You Measure Whether Secure Coding Training Is Working?
To see whether secure coding training works, measure what developers know and how they code before and after it. The National Institute of Standards and Technology (NIST) says learning program metrics should track changes in workforce capability and behavior, such as test scores before and after training and behavior over time.7
Those metrics show you whether developers changed how they code, whereas a completion report only tells you who attended. Track these measures in your developer security training program:
- Baseline and follow-up assessments: Test each developer's knowledge before training and again a few months later.
- Weak spots by team or role: Compare results across teams to see where a group needs more practice.
- Recurring weakness types in your own scans: Check whether the flaws your scanners keep flagging show up less frequently after training. Teams that use adaptive training can also assign each developer lessons based on those same scan findings.
What Does PCI DSS 4.0 Require for Developer Training?
Requirement 6.2.2 of the Payment Card Industry Data Security Standard (PCI DSS) v4.0.1 requires annual training for developers who work on custom software.8 Each developer's training has to address software security for their job function and development languages, with secure design, secure coding techniques, and any security testing tools the team uses. Providing role-based training in each developer's own languages is one way teams can support those PCI DSS 4.0 secure coding training requirements.
The NIST Secure Software Development Framework (SSDF) adds role-based training requirements for anyone whose responsibilities affect secure development.9 ISO/IEC 27001:2022 clause 7.2 asks organizations to give people the security skills their work requires and then check whether those efforts worked.10 Teams can use before-and-after assessments and scan tracking as evidence for that.
How Do You Choose Secure Code Training That Keeps Pace With AI?
Choose a program that teaches the skills AI-assisted development demands and updates as AI tools change. Ask each vendor you're considering these questions:
- Does it teach fundamentals in our languages?
- Does it train developers to review AI-generated code?
- Does it cover LLM risks like prompt injection?
- Do developers fix flaws in live applications?
- Can each role start at its own skill level?
- How does it measure changes in behavior?
- What records can it provide for audits?
- How often does new content come out?
Security Journey's secure code training pairs hands-on break/fix labs in full, live applications with coding and capture-the-flag challenges. Its role-based learning paths cover foundational, intermediate, and advanced levels, with new content each month that includes AI and LLM security lessons.
As AI assistants write more first drafts, the developers who review that code will need training that changes as fast as their tools do.
References
-
- Daniotti, Wachs, Feng, and Neffke. “Who is using AI to code? Global diffusion and impact of generative AI.” Science. January 2026. https://doi.org/10.1126/science.adz9311
- Veracode. “AI-Generated Code Poses Major Security Risks in Nearly Half of All Development Tasks, Veracode Research Reveals.” July 2025. https://www.veracode.com/press-release/ai-generated-code-poses-major-security-risks-in-nearly-half-of-all-development-tasks-veracode-research-reveals/
- Veracode. “Veracode Finds First Meaningful Gain in AI Code Security Since 2025 as Average Pass Rate Hits 62%.” October 2026. https://www.veracode.com/?p=33104
- Khalid, Sabater, Mussiba, Votipka, Thompson, and Fulton. “(Don’t) Trust, but (Don’t) Verify: Developers’ Attention to Security in AI-Generated Code.” September 2026. https://arxiv.org/html/2609.21020v1
- Wang, Wu, Ling, Luo, and Zhao. “Correct Code, Vulnerable Dependencies: A Large Scale Measurement Study of LLM-Specified Library Versions.” May 2026. https://arxiv.org/html/2605.06279
- Kharma, Sabbah, Alkhanafseh, Hammoudeh, and Mohaisen. “An Empirical Evaluation of LLM-Generated Code Security Across Prompting Methods.” May 2026. https://arxiv.org/html/2605.24298
- National Institute of Standards and Technology. “Building a Cybersecurity and Privacy Learning Program” (SP 800-50 Rev. 1). September 2024. https://csrc.nist.gov/pubs/sp/800/50/r1/final
- PCI Security Standards Council. “Payment Card Industry Data Security Standard: Requirements and Testing Procedures, v4.0.1.” June 2024. https://www.pcisecuritystandards.org/document_library/
- National Institute of Standards and Technology. “Secure Software Development Framework (SSDF) Version 1.1” (SP 800-218). February 2022. https://csrc.nist.gov/projects/ssdf/publications
- ISO/IEC. “ISO/IEC 27001:2022 Information security, cybersecurity and privacy protection: Information security management systems: Requirements.” October 2022. https://www.iso.org/standard/27001