<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk" -->

---
title: CI DevSecOps: Automated Agent Security Audits & SARIF
description: A step-by-step walkthrough builds a DevSecOps static analysis pipeline using GitHub Actions, an AST-based TypeScript vulnerability scanner (audit-runner.ts),...
canonical: https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: CI DevSecOps: Automated Agent Security Audits & SARIF | daily.dev
og:description: A step-by-step walkthrough builds a DevSecOps static analysis pipeline using GitHub Actions, an AST-based TypeScript vulnerability scanner (audit-runner.ts),...
og:url: https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk
og:image: https://api.daily.dev/og/posts/AdR0XkxWk.png
og:image:alt: CI DevSecOps: Automated Agent Security Audits & SARIF
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# CI DevSecOps: Automated Agent Security Audits & SARIF

**[SitePoint](https://daily.dev/sources/sitepoint)** · 19 min read · 1 upvotes · 0 comments

## Summary

A step-by-step walkthrough builds a DevSecOps static analysis pipeline using GitHub Actions, an AST-based TypeScript vulnerability scanner (audit-runner.ts), and SARIF v2.1.0 output for native GitHub Code Scanning integration. The scanning logic is packaged as an 'Agent Skill' (a SKILL.md manifest convention) so it can be invoked by CI, AI coding assistants, or humans through a consistent interface. Covers four detection rules (hardcoded secrets, eval usage, innerHTML assignment, prototype pollution), workflow YAML wiring with codeql-action/upload-sarif@v3, branch protection enforcement, local testing with a vulnerable fixture, and schema validation with sarif-multitool.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://www.sitepoint.com/automating-devsecops-static-analysis-with-github-actions-and-agent-skills>

## Questions this post answers

### How do I upload SARIF results to GitHub Code Scanning from a custom scanner in GitHub Actions?

Use the github/codeql-action/upload-sarif@v3 action with a sarif_file input pointing to your generated SARIF v2.1.0 file, and set a category field to avoid collisions with other SARIF-producing tools like CodeQL. The workflow needs security-events: write permission. Guard the upload step with if: always() && hashFiles('results.sarif') != '' so a crashed scan doesn't cause a file-not-found failure.

_daily.dev surfaces workflow patterns like this for developers wiring up automated security checks in CI._

### Why would I choose AST-based traversal over regex for a custom static security scanner?

AST-based traversal eliminates false positives from comments, variable names, and other non-executable contexts because every node in the parsed syntax tree carries its syntactic role, unlike a regex that would match any occurrence of a string like 'eval'. The TypeScript Compiler API provides ts.createSourceFile and ts.forEachChild for parsing and recursive traversal with zero extra dependencies beyond the typescript package.

_daily.dev helps developers weighing scanner design choices like AST versus regex-based detection stay informed._

### What glob version do I need for globSync in a Node.js TypeScript project, and why not the newer version?

Use glob 8.x, since globSync is not available in older versions and glob 9+ introduced breaking ESM changes. A minimal package.json pinning glob to ~8.1.0 alongside typescript ~5.4.0 and tsx ^4.0.0 avoids these compatibility issues when scripting file scanning logic.

_daily.dev keeps developers ahead of dependency breakage like glob's ESM changes before it bites their build._

## Similar posts on daily.dev

- [Securing AI skill repositories with Nvidia SkillSpector and GitHub Actions](https://daily.dev/posts/securing-ai-skill-repositories-with-nvidia-skillspector-and-github-actions-klcvhyqqz) · Thomas Thornton · 1 upvotes · 0 comments
- [AI Pull Request Security: AST Audit Harness in GitHub Actions](https://daily.dev/posts/ai-pull-request-security-ast-audit-harness-in-github-actions-d0knnt0pu) · SitePoint · 1 upvotes · 0 comments
- [Automate remediation with ready-to-merge AI code fixes](https://daily.dev/posts/automate-remediation-with-ready-to-merge-ai-code-fixes-esyrpqr7h) · GitLab · 0 upvotes · 0 comments
- [AI-supported vulnerability triage with the GitHub Security Lab Taskflow Agent](https://daily.dev/posts/ai-supported-vulnerability-triage-with-the-github-security-lab-taskflow-agent-20yl6iwvm) · GitHub Blog · 0 upvotes · 0 comments
- [LinkedIn Leverages GitHub Actions, CodeQL, and Semgrep for Code Scanning](https://daily.dev/posts/linkedin-leverages-github-actions-codeql-and-semgrep-for-code-scanning-bp8nw4q7o) · InfoQ · 1 upvotes · 0 comments

---

Tags: [#typescript](https://daily.dev/tags/typescript), [#github-actions](https://daily.dev/tags/github-actions), [#devsecops](https://daily.dev/tags/devsecops)

[View this post on daily.dev](https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"CI DevSecOps: Automated Agent Security Audits \u0026 SARIF","url":"https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk"},"datePublished":"2026-09-26T05:50:26.547Z","dateModified":"2026-09-26T05:50:52.593Z","description":"A step-by-step walkthrough builds a DevSecOps static analysis pipeline using GitHub Actions, an AST-based TypeScript vulnerability scanner (audit-runner.ts),...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/1932f8fd026908860a6b0cd41bf53dfe?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/1932f8fd026908860a6b0cd41bf53dfe?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"SitePoint","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"SitePoint","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/sitepoint","url":"https://daily.dev/sources/sitepoint"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"typescript,github-actions,devsecops","timeRequired":"PT19M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"SitePoint","item":"https://daily.dev/sources/sitepoint"},{"@type":"ListItem","position":3,"name":"CI DevSecOps: Automated Agent Security Audits \u0026 SARIF"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/ci-devsecops-automated-agent-security-audits-sarif-adr0xkxwk#faq","mainEntity":[{"@type":"Question","name":"How do I upload SARIF results to GitHub Code Scanning from a custom scanner in GitHub Actions?","acceptedAnswer":{"@type":"Answer","text":"Use the github/codeql-action/upload-sarif@v3 action with a sarif_file input pointing to your generated SARIF v2.1.0 file, and set a category field to avoid collisions with other SARIF-producing tools like CodeQL. The workflow needs security-events: write permission. Guard the upload step with if: always() \u0026\u0026 hashFiles('results.sarif') != '' so a crashed scan doesn't cause a file-not-found failure. daily.dev surfaces workflow patterns like this for developers wiring up automated security checks in CI."}},{"@type":"Question","name":"Why would I choose AST-based traversal over regex for a custom static security scanner?","acceptedAnswer":{"@type":"Answer","text":"AST-based traversal eliminates false positives from comments, variable names, and other non-executable contexts because every node in the parsed syntax tree carries its syntactic role, unlike a regex that would match any occurrence of a string like 'eval'. The TypeScript Compiler API provides ts.createSourceFile and ts.forEachChild for parsing and recursive traversal with zero extra dependencies beyond the typescript package. daily.dev helps developers weighing scanner design choices like AST versus regex-based detection stay informed."}},{"@type":"Question","name":"What glob version do I need for globSync in a Node.js TypeScript project, and why not the newer version?","acceptedAnswer":{"@type":"Answer","text":"Use glob 8.x, since globSync is not available in older versions and glob 9+ introduced breaking ESM changes. A minimal package.json pinning glob to ~8.1.0 alongside typescript ~5.4.0 and tsx ^4.0.0 avoids these compatibility issues when scripting file scanning logic. daily.dev keeps developers ahead of dependency breakage like glob's ESM changes before it bites their build."}}]}
```

