codeql-semgrep

codeql-semgrep is a skill for Claude Code from itallstartedwithaidea/agent-skills. It costs 34 tokens per session (1,576 once invoked), scanned A, original, MIT.

A guide for using CodeQL and Semgrep to inspect source code for security and code-quality problems. CodeQL analyzes relationships and data flow in a program, while Semgrep checks code patterns.

In plain words
What is it for?
Use it to write and run custom CodeQL queries and Semgrep rules, review findings, check project-specific practices, and plan fixes.
Why use it?
It helps find issues that simple text searches may miss and lets teams express rules specific to their own codebase.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions Claude Code; built for cline.

Part of the security-skills plugin — 4 skills shipped together , and of all-skills

Good fit Use it to write and run custom CodeQL queries and Semgrep rules, review findings, check project-specific practices, and plan fixes.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/itallstartedwithaidea/agent-skills/codeql-semgrep
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add itallstartedwithaidea/agent-skills --skill codeql-semgrep
Clone the repo
git clone --depth 1 https://github.com/itallstartedwithaidea/agent-skills

Made for: Claude Code.

Or install security-skills, the plugin that ships this one along with the rest of its 4 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for codeql-semgrep

README.md
[![agentmods](https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/codeql-semgrep/github.svg)](https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/codeql-semgrep)
Your own site
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/codeql-semgrep"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/codeql-semgrep/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for codeql-semgrep

Your own site · 80×15
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/codeql-semgrep"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/codeql-semgrep.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 34 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,576 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00034 $0.01576
Opus 5.5 $0.00014 $0.00630
Sonnet 5.5 $0.00007 $0.00315
Haiku 4.5 $0.00003 $0.00158

Measured 1mo ago against content hash a6d9be1f425a, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

codeql-semgrep scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/security/codeql-semgrep/SKILL.md · 191 lines

How it starts

The opening of the file, as written. The whole thing — 191 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CodeQL & Semgrep

Part of Agent Skills™ by googleadsagent.ai™

Description

CodeQL & Semgrep integrates production-grade static analysis into agent workflows for deep vulnerability detection, custom rule authoring, and automated code review enforcement. The agent writes CodeQL queries and Semgrep rules tailored to project-specific patterns, runs them against codebases, and interprets results with actionable remediation guidance.

Pattern-matching security scanners catch surface-level issues. CodeQL and Semgrep operate at a deeper level: CodeQL builds a relational database of the program's structure and evaluates queries that trace data flow from sources (user input) to sinks (dangerous operations). Semgrep matches syntactic patterns with type-aware analysis. Together, they catch vulnerabilities that regex-based scanners miss entirely.

This skill goes beyond running default rulesets. The agent writes custom rules for project-specific patterns: ensuring all database queries use the project's ORM wrapper, verifying that authentication middleware is applied to every route, or confirming that error responses never leak stack traces. Custom rules encode institutional security knowledge that persists beyond any individual reviewer.

Use When

  • Running static analysis on AI-generated or human-written code
  • Writing custom security rules for project-specific patterns
  • Integrating security scanning into CI/CD pipelines
  • Tracing data flow from user input to dangerous operations
  • Enforcing architectural security constraints (auth on all routes, ORM usage)
  • The user requests "static analysis", "CodeQL", or "Semgrep"

How It Works

graph TD
    A[Codebase] --> B{Analysis Engine}
    B -->|Data Flow| C[CodeQL: Build Database]
    B -->|Pattern Match| D[Semgrep: Parse AST]
    C --> E[Run CodeQL Queries]
    D --> F[Run Semgrep Rules]
    E --> G[Taint Tracking: Source → Sink]
    F --> H[Pattern Matches + Metavariables]
    G --> I[Merge Findings]
    H --> I
    I --> J[Deduplicate + Prioritize]
    J --> K[Remediation Report]
    K --> L[CI/CD Gate: Pass/Fail]

Read the full file on GitHub · 191 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 191 lines · 34 tokens per session scan A a6d9be1f425a

Subscribe to this mod's changes

codeql-semgrep is a skill published in the GitHub repository itallstartedwithaidea/agent-skills (44 stars, last pushed 6mo ago), licensed MIT. It adds 34 tokens to every session and 1,576 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

review-stack

Stack review of one or more third-party tools (OXC, TanStack, Vite, cf, Sentry, pnpm, Claude Code...) against current official best practices, or of what a dependency bump brings (bumped): one parallel subagent per tool, verified findings, one consolidated plan in chat. USE WHEN: user runs /review-stack or explicitly…

louisbrulenaudet/monorepo-template · 115 tokens

review

Code and design review of this repo by domain - architecture, ci, code-quality, configuration, performance, security, seo, simplicity, tests, ui: one parallel reviewer subagent per selected domain, verified findings, one consolidated plan in chat with IDs to answer. USE WHEN: user runs /review, optionally with domains…

louisbrulenaudet/monorepo-template · 131 tokens

ad-delivery-review

A Chinese-language quality review and retrospective guide for advertising proposals, presentation outlines, campaign plans, strategy documents, and client pitches.

ilexlyu/ad-proposal-skills · 81 tokens

tool-defs-analysis

Read-only audit of MCP definition language across an existing surface — tools, resources, prompts, server instructions. Walks every definition file and checks 16 categories the LLM reads to decide whether and how to call: voice & tense, internal leaks, audience leaks, defaults, recovery hints, field descriptions…

cyanheads/mcp-ts-core · 177 tokens

release-pr-review

Review pass on an open release PR (release/ → main) — the step between git-wrapup and release-and-publish when a project releases in gated release PR mode. Reads the PR's commit range through the code-simplifier lens plus a correctness review, verifies whatever an automated reviewer left on the PR, lands fixes as…

cyanheads/mcp-ts-core · 136 tokens

code-simplifier

Cleanup pass that edits the working tree — over a session's uncommitted changes, or a named path or whole codebase. Reads git diff (or the named target) and simplifies, consolidates, and aligns code with the existing codebase — modernize syntax, cut unnecessary complexity and slop, consolidate duplicated logic, catch…

cyanheads/mcp-ts-core · 160 tokens