sarif-parsing

Parses, filters, deduplicates, and aggregates SARIF static analysis results from security scanners.

507|40|Updated Apr 26, 2026
One-click install
npx skills add https://github.com/waybarrios/opencode-power-pack --skill sarif-parsing-waybarrios
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: sarif-parsing
Source: https://github.com/waybarrios/opencode-power-pack/tree/main/skills/sarif-parsing
Command: npx skills add https://github.com/waybarrios/opencode-power-pack --skill sarif-parsing-waybarrios

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires jq, pysarif, sarif-tools, ijson.

What problem does it solve? Static analysis tools like CodeQL and Semgrep produce large SARIF result files that are hard to read, deduplicate, and integrate into CI/CD pipelines. This Skill provides proven patterns and ready-to-use utilities for extracting actionable findings from SARIF data. ## Core Features & Use Cases - Query and Filter Findings: Use 40+ ready-made jq queries or Python helpers to filter results by severity, rule ID, or file path. - Deduplicate and Aggregate: Merge SARIF files from multiple scanners and remove duplicate alerts using stable fingerprinting strategies. - CI/CD Integration: Diff baseline against current scans to fail builds on new issues, and convert SARIF to CSV or HTML reports. - Use Case: After running CodeQL and Semgrep in a pipeline, aggregate both SARIF outputs, deduplicate overlapping findings, and fail the build only if new error-level issues appear. ## Quick Start Parse the attached results.sarif file and list all error-level findings with their file paths and line numbers.

Frequently Asked Questions about sarif-parsing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I parse SARIF files from CodeQL or Semgrep?▼

Use jq for quick CLI queries like extracting rule IDs and severity counts, or Python libraries such as pysarif and sarif-tools for programmatic access. The sarif-tools CLI also supports summary, diff, and CSV/HTML conversion commands.

How do I deduplicate findings across multiple SARIF files?▼

Deduplicate using the partialFingerprints or fingerprints fields in each result, falling back to a computed hash of rule ID, filename, line, and message. Merge the runs arrays from each file first, then remove results with duplicate fingerprints.

What is the difference between pysarif and sarif-tools?▼

pysarif provides a typed object model for loading and saving SARIF files in Python. sarif-tools adds higher-level reporting, severity histograms, file diffing, and a CLI for summary, filtering, and format conversion.

How do I handle large SARIF files over 100MB?▼

Stream results with the ijson library instead of loading the entire file into memory. Iterate over the runs.item.results.item path to process findings one at a time with constant memory usage.

Why do fingerprints mismatch between SARIF runs?▼

Fingerprints change when file paths differ between environments, tool versions update their hashing algorithm, or code reformatting shifts line numbers. Compute stable fingerprints from rule ID, filename only, and normalized code snippets.

Can this skill run CodeQL or Semgrep scans?▼

No, it only processes existing SARIF output files. Running scans, writing rules, or analyzing source code directly requires the dedicated CodeQL or Semgrep skills instead.