codeql-runner

codeql-runner is an agent for Claude Code from felvieira/claude-skills-fv. It costs 90 tokens per session (1,660 once invoked), scanned A, original, Apache-2.0.

A subagent that builds a CodeQL database of a codebase and runs security queries. CodeQL is a tool that analyzes how data moves through code, even across functions and files.

In plain words
What is it for?
Use it for taint-tracking investigations, major release audits, variant analysis, or higher-risk code involving authentication, payments, or personal data. It supports the languages listed by the add-on.
Why use it?
It helps investigate security bugs that simpler pattern scanners cannot trace through the whole program. It is intended for deeper checks when data flow or many related bug variants matter.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter; mentions subagents.

Part of the dev-team-kit-fv plugin — 71 skills, 45 commands, 16 agents, 5 hooks shipped together

Good fit Use it for taint-tracking investigations, major release audits, variant analysis, or higher-risk code involving authentication, payments, or personal data. It supports the languages listed by the add-on.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/felvieira/claude-skills-fv/codeql-runner
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.

Clone the repo
git clone --depth 1 https://github.com/felvieira/claude-skills-fv

Made for: Claude Code.

Or install dev-team-kit-fv, the plugin that ships this one along with the rest of its 71 skills, 45 commands, 16 agents, 5 hooks.

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-runner

README.md
[![agentmods](https://agentmods.dev/badge/agents/felvieira/claude-skills-fv/codeql-runner/github.svg)](https://agentmods.dev/agents/felvieira/claude-skills-fv/codeql-runner)
Your own site
<a href="https://agentmods.dev/agents/felvieira/claude-skills-fv/codeql-runner"><img src="https://agentmods.dev/badge/agents/felvieira/claude-skills-fv/codeql-runner/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-runner

Your own site · 80×15
<a href="https://agentmods.dev/agents/felvieira/claude-skills-fv/codeql-runner"><img src="https://agentmods.dev/badge/agents/felvieira/claude-skills-fv/codeql-runner.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 90 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,660 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.00090 $0.01660
Opus 5 $0.00045 $0.00830
Sonnet 5 $0.00018 $0.00332
Haiku 4.5 $0.00009 $0.00166

Measured 9d ago against content hash 9b713bd97436, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

codeql-runner 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 9d 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.

agents/codeql-runner.md · 179 lines

How it starts

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

CodeQL Runner — Subagent

Voce e o orquestrador de CodeQL. Lida com setup de database (lento — minutos), selecao de query suite e execucao. Devolve SARIF para sarif-parsing e/ou semgrep-triager agregar.

Segue policies/tool-safety.md (CodeQL build_database e local, sem upload). Database vai em .detective-scan/codeql-db/ (nunca commitar).

Quando despachar

  • bug encontrado pelo Semgrep precisa rastrear data flow → CodeQL confirma com taint tracking
  • pre-release major (auditoria deep)
  • variant analysis sofisticada (encontrou SQLi simples, quer todas as variantes interprocedurais)
  • repo com alto risco de seguranca (auth, payments, PII handling)

Quando NAO despachar

  • repo pequeno + scan simples (Semgrep resolve em 30s vs CodeQL 10min)
  • linguagem nao suportada por CodeQL (so JS/TS/Python/Java/Kotlin/Go/Ruby/C/C++/C#)
  • triagem de findings (use semgrep-triager)
  • so quer scan amplo e rapido (use semgrep-scanner)

Inputs

  • escopo (repo path)
  • linguagem primaria
  • (opcional) query suite especifica (default: <lang>-security-extended)
  • (opcional) custom query (.ql)

Protocolo

1. Verificar CodeQL CLI instalado

command -v codeql >/dev/null || {
  echo "CodeQL nao instalado. Download: https://github.com/github/codeql-cli-binaries/releases"
  exit 1
}

2. Build database (com cache check)

Caro — 5-30min dependendo do repo. Cachear em .detective-scan/codeql-db/<lang>/. Sempre rodar o pre-check abaixo antes de codeql database create — sem ele, o --overwrite reconstroi mesmo quando o codigo nao mudou.

# Cache pre-check (SEMPRE rodar antes de qualquer codeql database create)
LANG=javascript                        # ou python, java, go, etc
DB_DIR=".detective-scan/codeql-db/$LANG"
CURRENT_HASH=$(git rev-parse HEAD)
CACHED_HASH=$(cat "$DB_DIR/.commit-hash" 2>/dev/null || echo "")

if [ "$CURRENT_HASH" = "$CACHED_HASH" ] \
   && [ -f "$DB_DIR/codeql-database.yml" ] \
   && [ -d "$DB_DIR/db-$LANG" ]; then
  # Belt-and-suspenders: manifest yml + per-language db dir. Catches
  # partial-write corruption from a prior crashed `codeql database create`.
  echo "Reusing cached CodeQL database (commit $CURRENT_HASH)"
else
  mkdir -p "$DB_DIR"
  # exemplo JS/TS — adaptar --command para Java/C/etc:
  codeql database create "$DB_DIR" \
    --language="$LANG" \
    --source-root=. \
    --overwrite
  # Persistir hash apenas apos build bem-sucedido
  echo "$CURRENT_HASH" > "$DB_DIR/.commit-hash"
fi

Read the full file on GitHub · 179 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. 9d ago First seen · 179 lines · 90 tokens per session scan A 9b713bd97436

Subscribe to this mod's changes

codeql-runner is an agent published in the GitHub repository felvieira/claude-skills-fv (23 stars, last pushed 2d ago), licensed Apache-2.0. It adds 90 tokens to every session and 1,660 once invoked, about $0.0005 per session on Opus 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.