News

GitHub Copilot AI Boosts App Security with Autofix: 'Found Means Fixed'

Now in beta for top-tier GitHub customers is "code scanning autofix" used to mitigate security vulnerabilities in code. The feature is powered by GitHub Copilot AI, which has advanced from its "AI pair programmer" days to help out with all manner of development-related tasks, including security.

Announced in beta last week, the new functionality is available only to GitHub Enterprise customers who use the Microsoft-owned company's Advanced Security offering that "helps developers fix potential issues before production" with the help of AI.

Basically, code scanning autofix flags pull request vulnerability alerts in certain codebases and then proposes and explains new code that can quickly be inserted by a developer, speeding up the tedious and time-consuming bug-fixing process.

Right now, the beta works only with JavaScript, Typescript, Java and Python, with support planned for C# and Go this week.

When a vulnerability is flagged in one of those languages, the proposed fixes are accompanied by natural language explanations of the suggested fix, along with a preview of the code suggestion that can quickly be accepted, edited or dismissed.

Code Scanning Autofix in Action
[Click on image for larger, animated GIF view.] Code Scanning Autofix in Action (circa November 2023) (source: GitHub).

"Our vision for application security is an environment where found means fixed," GitHub said in a March 20 announcement. "By prioritizing the developer experience in GitHub Advanced Security, we already help teams remediate 7x faster than traditional security tools. Code scanning autofix is the next leap forward, helping developers dramatically reduce time and effort spent on remediation."

Along with Copilot AI, code scanning autofix is powered by CodeQL, a semantic code analysis engine developed by GitHub to automate security checks by enabling developers to analyze their code and display the results as code scanning alerts.

GitHub Copilot APIs, CodeQL and combined heuristics are all used together to generate code suggestions, explained in last month's engineering blog post, "Fixing security vulnerabilities with AI," which provides "a peek under the hood of GitHub Advanced Security code scanning autofix."

It explains the background technical nuts-and-bolts: "The basic idea behind autofix is simple: when a code analysis tool such as CodeQL detects a problem, we send the affected code and a description of the problem to a large language model (LLM), asking it to suggest code edits that will fix the problem without changing the functionality of the code."

Code scanning autofix is available on private repositories with a working code scanning configuration.

More information can be found in a video, "GitHub code scanning autofix demo," and in "About autofix for CodeQL code scanning" documentation.

About the Author

David Ramel is an editor and writer at Converge 360.

comments powered by Disqus

Featured

  • VS Code 1.123 Adds Agent Session Sync, 1M Context Windows

    Microsoft released Visual Studio Code 1.123 on June 3, adding agent-focused features, larger model context support, integrated browser updates and a new delay for some automatic extension updates.

  • Copilot Billing Shock Hits Developers

    Developer complaints about GitHub Copilot's new usage-based billing model have centered on unexpectedly rapid AI credit consumption, and neither GitHub nor Microsoft has responded directly to the backlash, though they have previously published guidance to lessen model usage costs.

  • Hands On with GitHub Copilot App Technical Preview: Turning a Blazor Issue into a PR

    GitHub's brand-new Copilot desktop app, in technical preview, handled a small Blazor issue from planning through pull request creation, but the hands-on test also showed why developers still need to verify agent work in the running app before merging.

  • At Build 2026, Microsoft Sets Up Windows as an OS for AI Agents

    Microsoft's Build 2026 Windows developer announcements point to a broader platform strategy for agentic AI, spanning terminal workflows, local models, app-building skills, Cloud PCs and operating system-level containment.

Subscribe on YouTube