Co-Pilot
Updated 3 months ago

static-analysis

Ttrailofbits
1.8k
trailofbits/skills/plugins/static-analysis
82
Agent Score

💡 Summary

A static analysis toolkit for detecting security vulnerabilities using CodeQL, Semgrep, and SARIF parsing.

🎯 Target Audience

Security analystsSoftware developersDevOps engineersQuality assurance teamsOpen source maintainers

🤖 AI Roast:Powerful, but the setup might scare off the impatient.

Security AnalysisMedium Risk

The toolkit may execute external commands and access the filesystem, posing risks of command injection and data leakage. Ensure proper input validation and limit permissions.

Static Analysis

A comprehensive static analysis toolkit with CodeQL, Semgrep, and SARIF parsing for security vulnerability detection.

CodeQL and Semgrep skills are based on the Trail of Bits Testing Handbook:

Author: Axel Mierczuk

Skills Included

| Skill | Purpose | |-----------------|----------------------------------------------------------| | codeql | Deep security analysis with taint tracking and data flow | | semgrep | Fast pattern-based security scanning | | sarif-parsing | Parse and process results from static analysis tools |

When to Use

Use this plugin when you need to:

  • Perform security vulnerability detection on codebases
  • Run CodeQL for interprocedural taint tracking and data flow analysis
  • Use Semgrep for fast pattern-based bug detection
  • Parse SARIF output from security scanners
  • Set up static analysis in CI/CD pipelines
  • Aggregate and deduplicate findings from multiple tools

What It Does

CodeQL

  • Create databases for Python, JavaScript, Go, Java, C/C++, and more
  • Run security queries with SARIF/CSV output
  • Write custom QL queries with taint tracking
  • Integrate with GitHub Actions

Semgrep

  • Quick security scans using built-in rulesets (OWASP, CWE, Trail of Bits)
  • Write custom YAML rules with pattern matching
  • Taint mode for tracking data flow from sources to sinks
  • CI/CD integration with baseline scanning

SARIF Parsing

  • Understand SARIF 2.1.0 structure
  • Quick analysis using jq for CLI queries
  • Python scripting with pysarif and sarif-tools
  • Aggregate and deduplicate results from multiple files
  • CI/CD integration patterns

Installation

/plugin install trailofbits/skills/plugins/static-analysis

Related Skills

  • variant-analysis - Use CodeQL/Semgrep patterns to find bug variants
5-Dim Analysis
Clarity9/10
Novelty7/10
Utility9/10
Completeness8/10
Maintainability8/10
Pros & Cons

Pros

  • Comprehensive vulnerability detection
  • Supports multiple programming languages
  • Integrates well with CI/CD pipelines
  • Fast pattern-based scanning with Semgrep

Cons

  • May require configuration for optimal use
  • Learning curve for custom queries
  • Dependency on external tools
  • Potentially complex setup

Related Skills

mcpspy

A
toolCo-Pilot
86/ 100

“MCPSpy: because who doesn't want to spy on their AI's secrets?”

ffuf-skill

A
toolCo-Pilot
84/ 100

“This skill is essentially a glorified man page for ffuf, offering expert guidance but no actual automation or integration.”

burpsuite-project-parser

A
toolCo-Pilot
82/ 100

“Powerful, but the setup might scare off the impatient.”

Disclaimer: This content is sourced from GitHub open source projects for display and rating purposes only.

Copyright belongs to the original author trailofbits.