| name | security-baseline |
| description | Audit and implement security best practices for GitHub repositories. USE THIS SKILL when user says "security audit", "check security", "add gitleaks", "secret scanning", "dependency audit", or needs security hardening. |
| allowed-tools | ["Bash","Read","Write","Edit","Glob","Grep"] |
Security Baseline Skill
Purpose
Audit and implement security best practices for GitHub repositories, including secret scanning, dependency audits, and security hardening.
Triggers
- "audit repository security"
- "add secret scanning"
- "check for vulnerabilities"
- "security hardening"
- "add pre-commit hooks"
- "configure dependabot"
Usage
Run a security audit on any repository to identify gaps, then use the provided checklists and commands to implement security controls systematically.
Security Audit Checklist
GitHub Actions Security
Repository Security
Secret Management
Dependency Security
SHA Pinning Validation
grep -rn "uses:.*@v[0-9]" .github/workflows/
grep -rn "uses:.*@main" .github/workflows/
./scripts/validate-sha-pinning.sh .github/workflows/
Safe Permission Patterns
permissions:
contents: read
permissions:
contents: read
pull-requests: write
permissions:
contents: write
packages: write
OIDC Authentication
permissions:
id-token: write
contents: read
steps:
- uses: aws-actions/configure-aws-credentials@e7f100cf4c008499ea8adda475de1042d6975c7b
with:
role-to-assume: arn:aws:iam::123456789:role/github-actions
aws-region: us-east-1
Secret Scanning Setup
Gitleaks Configuration
[allowlist]
paths = [
'''\.example$''',
'''test/fixtures''',
]
Pre-commit Hook
repos:
- repo: https://github.com/gitleaks/gitleaks
rev: v8.18.0
hooks:
- id: gitleaks
Dependency Audit Commands
uv pip audit
pnpm audit
go list -json -m all | nancy sleuth
cargo deny check advisories
Required Security Files
| File | Purpose |
|---|
SECURITY.md | Vulnerability reporting |
dependabot.yml | Automated updates |
.pre-commit-config.yaml | Pre-commit hooks |
gitleaks.toml | Secret patterns |
CODEOWNERS | Review requirements |
Vulnerability Response
| Severity | Response Time |
|---|
| Critical | Immediate |
| High | 24 hours |
| Medium | 1 week |
| Low | Next release |
Quick Security Commands
gitleaks detect --source . --verbose
gitleaks detect --source . --log-opts="--all"
for f in .github/workflows/*.yml; do
grep -q "^permissions:" "$f" || echo "Missing: $f"
done