Skip to main content
AI Finds What CodeQL Missed: A TeardownIncident
5 min readFor Security Engineers

AI Finds What CodeQL Missed: A Teardown

GitHub's AI-powered scanning feature wasn't launched because their existing tools were flawless. It launched because traditional static analysis has blind spots, and those blind spots cost companies real money.

Let's explore what happened when GitHub ran their hybrid AI model against real codebases, what it revealed about conventional security tooling, and what your team needs to do differently.

What Happened

GitHub deployed an AI-enhanced vulnerability scanner alongside CodeQL, their semantic analysis engine, to test whether machine learning could catch issues that rule-based tools miss. Over 30 days, the system processed more than 170,000 findings across production repositories. Developers accepted the AI's recommendations with 80% positive feedback, which is unusually high for security tools that often struggle with alert fatigue.

The AI model specifically targeted gaps in language and framework coverage where CodeQL's query packs don't exist or lag behind ecosystem changes. When paired with Copilot Autofix for remediation, average resolution time dropped from 1.29 hours to 0.66 hours per finding.

Timeline

Pre-deployment baseline: CodeQL provided strong coverage for mature languages like Java, C#, and Python but struggled with newer frameworks, custom DSLs, and rapidly evolving ecosystems like JavaScript frontend libraries.

30-day pilot period: GitHub's AI scanner ran in parallel with CodeQL. The hybrid approach flagged vulnerabilities in areas where static analysis either lacked rules or couldn't parse the semantic context, such as complex data flows through React hooks or authentication logic in serverless functions.

Post-pilot analysis: The 80% developer acceptance rate indicated the AI wasn't just generating more alerts. It was finding real issues that mattered, in code paths developers recognized as risky once pointed out.

Public preview announcement: An early Q2 2026 rollout is planned, giving teams roughly six months to evaluate whether their current SAST tools leave similar gaps.

Which Controls Failed or Were Missing

The core failure wasn't in any single tool, it was in the assumption that rule-based static analysis provides complete coverage. Here's where the gaps appeared:

Incomplete language support: Your SAST tool might have 400 queries for Java but only 40 for Go. When your team adopts a new framework, security coverage doesn't keep pace with development velocity.

Context-blind pattern matching: Traditional static analysis excels at finding SQL injection in straightforward database calls. It struggles when the vulnerability requires understanding how three different libraries interact across four files. The AI model demonstrated better performance in these multi-hop scenarios because it learned patterns from millions of code samples, not just predefined rules.

Remediation bottleneck: Even when CodeQL found issues, developers spent over an hour per fix on average. That's not a detection problem, it's a workflow problem. The security tool identified the vulnerability but left the developer to figure out the correct fix, research the API, and test the change.

What the Standards Require

Let's map these gaps to specific compliance requirements:

PCI DSS v4.0.1 Requirement 6.3.2 mandates that you identify and address common coding vulnerabilities during development. The standard doesn't prescribe tools, but it does require that your chosen method actually catches vulnerabilities before they reach production. If your SAST tool has blind spots in 30% of your codebase, you're not meeting this requirement for that code.

OWASP ASVS v4.0.3, Section V1 (Architecture, Design and Threat Modeling) requires verification that security is considered at every stage of development. When your security tooling can't analyze the frameworks your developers actually use, you've created an architectural gap between your security controls and your attack surface.

ISO/IEC 27001:2022 Control 8.25 (Secure development lifecycle) requires that security is integrated into development processes. The control specifically mentions that organizations should use tools appropriate to the technology stack. Running a 2019-era SAST engine against 2025 code doesn't satisfy this requirement, even if you can check a compliance box that says "SAST: enabled."

NIST 800-53 Rev 5, SA-11 (Developer Testing and Evaluation) requires security testing throughout the development cycle. The control enhancement SA-11(1) adds static code analysis. But here's the catch: the control assumes your static analysis is effective. If it misses entire categories of vulnerabilities because it can't parse your framework, you're compliant on paper but exposed in practice.

Lessons and Action Items

Audit your SAST coverage by framework, not just by language. Don't ask "Do we scan Python?" Ask "Do we scan FastAPI applications with async database calls?" Run a sample of your actual code through your security tools and measure what percentage of your dependencies and frameworks have meaningful rule coverage.

Test your tools against AI-augmented alternatives before Q2 2026. GitHub's public preview gives you a forcing function. Set up a pilot: run your current SAST tool and an AI-enhanced scanner (GitHub's or a competitor's) against the same codebase. Compare the findings. Calculate the overlap and the gaps. If the AI catches issues your existing tool misses, you've found your business case for change.

Measure time-to-remediation, not just time-to-detection. The drop from 1.29 hours to 0.66 hours matters because it's a workflow metric, not a tool metric. Even if you don't adopt GitHub's stack, ask: how long does it take your developers to go from "alert received" to "fix deployed"? If it's over an hour, your remediation process needs as much attention as your detection capability.

Reassess your compliance evidence. If your auditor asks "How do you ensure secure coding practices?" and you answer "We run SAST scans," that's not enough anymore. The better answer: "We run SAST with documented coverage across our technology stack, we measure detection rates against known vulnerability types, and we track remediation time as a key metric."

Plan for hybrid models. Pure rule-based tools won't disappear, and pure AI tools aren't mature enough to run unsupervised. The future is hybrid: semantic analysis for high-confidence detections, AI for pattern recognition in complex scenarios, and human review for business logic flaws. Build your toolchain accordingly.

The 170,000 findings in 30 days weren't just numbers, they represented real vulnerabilities that traditional tools missed. Your codebase likely has the same gaps. The question isn't whether AI will change security tooling. It's whether you'll wait for an incident to prove it.

Topics:Incident

You Might Also Like