Sec-Context is a curated security research project that distills common code anti-patterns and vulnerabilities that generative AI tends to produce, presenting them as a comprehensive set of examples and secure alternatives that can be used to train or guide AI assistants and reviewers toward safer code generation. It compiles insights from over 150 industry and academic sources into structured reference documents that outline real-world security problems such as hardcoded secrets, SQL injection, cross-site scripting, command injection, weak password storage, and other frequent issues that occur when code is auto-generated without context of best practices. Each anti-pattern is paired with a secure coding alternative and explanation, offering educational value for both humans and automated review agents designed to flag or correct unsafe patterns.
Features
- Curated AI code security anti-patterns
- Secure alternatives for common vulnerabilities
- Examples and mitigation guidance
- Designed for AI code reviewers or assistants
- Synthesized from 150+ sources
- Useful for training security-aware models