security-secrets

Scan code repositories for hardcoded secrets using ripgrep, gitleaks, semgrep, and trufflehog.

124|12|Updated Nov 17, 2025
One-click install
npx skills add https://github.com/IgorWarzocha/Opencode-Workflows --skill security-secrets-igorwarzocha
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: security-secrets
Source: https://github.com/IgorWarzocha/Opencode-Workflows/tree/main/agents/security-reviewer/.opencode/skill/security-secrets
Command: npx skills add https://github.com/IgorWarzocha/Opencode-Workflows --skill security-secrets-igorwarzocha

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill helps identify and prevent the accidental exposure of sensitive information like API keys, passwords, and private keys within code repositories, mitigating security risks.

Core Features & Use Cases

  • High-Signal Secret Detection: Utilizes specific regex patterns to find common high-risk secrets (AWS keys, GitHub tokens, etc.).
  • Automated Scanning: Executes rg, gitleaks, semgrep, and trufflehog for comprehensive code and history scanning.
  • Prioritized File Checking: Identifies critical files like .env and private key files that commonly store secrets.
  • Use Case: Before committing code, run this skill to automatically scan for any accidentally included API keys or database credentials, preventing a potential data breach.

Quick Start

Run the security secrets scan on the current directory.

Frequently Asked Questions about security-secrets

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

FAQPage Schema
How do I scan my code repository for hardcoded API keys and credentials?

To scan a code repository for hardcoded secrets, this Skill executes ripgrep, gitleaks, semgrep, and trufflehog. It identifies high-signal patterns and prioritizes common secret-containing files like .env and private keys to detect potential data exfiltration vectors.

What is the best way to automatically detect sensitive secrets in .env files?

The best way to detect sensitive secrets in .env files is using automated scanning tools that prioritize these specific files. This Skill checks .env and private key files using regex patterns to find high-risk AWS keys and GitHub tokens.

Can I use gitleaks and trufflehog together for comprehensive secret detection?

Yes, you can use gitleaks and trufflehog together for comprehensive secret detection. This Skill runs both tools alongside ripgrep and semgrep to scan code and history, ensuring proactive security auditing and mitigating data breach risks.

Does this secret scanning approach work without installing external dependencies?

No, this secret scanning approach requires external dependencies to function. The Skill executes scanning scripts that rely on having ripgrep, gitleaks, semgrep, and trufflehog installed in the environment to detect hardcoded credentials.

When should I run a secrets scan to prevent accidental credential exposure?

You should run a secrets scan before committing code to prevent accidental credential exposure. Executing this Skill identifies accidentally included API keys or database credentials, mitigating security risks and preventing a potential data breach.