Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问clear审计通过

trivytrivy 搜索

Agent Skill

trivy 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

539

周安装

22

GitHub Stars

公开资料未说明

下载量

174
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:trivy(trivy 搜索)
来源仓库:https://github.com/lorenzogirardi/ai-ecom-demo
仓库路径:skills/trivy
安装命令:
npx skills add https://github.com/lorenzogirardi/ai-ecom-demo --skill trivy
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/lorenzogirardi/ai-ecom-demo --skill trivy

简介

trivy 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。

  • 适用于研究检索类任务,如信息搜集、资料筛选和线索整理,尤其适合需要自动化处理重复性搜索的场景。
  • 通过 npx skills add 命令从指定 GitHub 仓库安装,需确认权限范围和实际维护状态后再使用。
  • 使用前应检查是否会触发联网、命令执行或文件读写操作,避免在不安全环境中运行。
  • 建议结合原始 README 和仓库内容进一步核验具体用法和功能边界。

SKILL.md

ABOUTME: Security vulnerability scanning skill using Trivy

ABOUTME: Enforces CRITICAL/HIGH blocking before commits

Trivy Security Scanning Skill

Quick Reference

Scan TypeCommandWhen
Dependenciestrivy fs.package.json changes
Containertrivy image <name>Dockerfile changes
IaCtrivy config.Terraform changes

When to Scan

TriggerAction
package.json changedScan filesystem
package-lock.json changedScan filesystem
Dockerfile modifiedScan config + image
*.tf files changedScan IaC config
Before commit with depsMANDATORY scan

Scan Commands

Filesystem Scan (Dependencies)

# Most common - scan Node.js dependencies
trivy fs \
    --severity CRITICAL,HIGH \
    --exit-code 1 \
    --ignore-unfixed \
    --format table \
    .

Container Image Scan

# Build image first
docker build -t local-scan:latest .

# Scan the image
trivy image \
    --severity CRITICAL,HIGH \
    --exit-code 1 \
    --ignore-unfixed \
    local-scan:latest

IaC Configuration Scan

# Scan Terraform files
trivy config \
    --severity CRITICAL,HIGH \
    --exit-code 1 \
    infra/terraform/

Severity Policy

SeverityActionCommit Allowed
CRITICALBLOCK - Fix immediatelyNO
HIGHBLOCK - Fix or upgradeNO
MEDIUMWARN - Plan remediationYES
LOWINFO - DocumentYES

Remediation Strategies

Strategy 1: Upgrade Package

# Check which version fixes the CVE
npm audit

# Upgrade specific package
npm install package@latest

# Or use npm audit fix
npm audit fix

Strategy 2: Find Fixed Version

# Show fixed versions in JSON
trivy fs --severity CRITICAL,HIGH --format json . | \
  jq '.Results[].Vulnerabilities[] | {pkg: .PkgName, installed: .InstalledVersion, fixed: .FixedVersion}'

Strategy 3: Override Transitive Dependency

// package.json
{
  "overrides": {
    "vulnerable-package": "^X.Y.Z"
  }
}

Strategy 4: Exclude False Positive

Create .trivyignore:

# CVE-2023-XXXXX: Not exploitable - we don't use affected feature
CVE-2023-XXXXX

WARNING: Every exclusion MUST have documented justification.


Ecommerce-Specific Patterns

Backend Scan

cd apps/backend
trivy fs --severity CRITICAL,HIGH --exit-code 1 .

Frontend Scan

cd apps/frontend
trivy fs --severity CRITICAL,HIGH --exit-code 1 .

Docker Compose Scan

# Build all images
docker-compose -f docker-compose.full.yml build

# Scan each
trivy image ecommerce-demo-backend:latest
trivy image ecommerce-demo-frontend:latest

Terraform Scan

trivy config --severity CRITICAL,HIGH infra/terraform/

CI Integration

The project has Trivy in CI (.github/workflows/backend-ci.yml):

- name: Run Trivy vulnerability scanner
  uses: aquasecurity/trivy-action@master
  with:
    scan-type: 'fs'
    scan-ref: 'apps/backend'
    format: 'json'
    output: 'security/reports/trivy-backend-${{ github.sha }}.json'

Reports saved to security/reports/ for Claude CVE analysis.


CVE Analysis Workflow

When Trivy finds vulnerabilities:

  1. Get the report trivy fs --format json --output report.json.
  2. Ask Claude to analyze Analyze report.json for contextual CVE prioritization. For each CVE: - Search codebase for usage of affected library - Evaluate if attack vector is exposed - Provide remediation priority
  3. Follow remediation plan

Checklist

Before committing with dependency changes:

  • Trivy installed (brew install trivy)
  • Ran trivy fs --severity CRITICAL,HIGH --exit-code 1.
  • No CRITICAL vulnerabilities
  • No HIGH vulnerabilities (or documented exception)
  • Any .trivyignore entries justified
  • Container images scanned (if Dockerfile changed)
  • IaC scanned (if Terraform changed)

Troubleshooting

IssueSolution
trivy: command not foundbrew install trivy
Slow scanUse --skip-update after first run
False positiveAdd to .trivyignore with justification
Transitive dependencyUse overrides in package.json
Old DBRun trivy --download-db-only

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Gemini CLI

27.29%
按下载量换算47

Antigravity

25.22%
按下载量换算44

Claude Code

18.82%
按下载量换算33

Codex

13.19%
按下载量换算23

windsurf

7.51%
按下载量换算13

trae

3.09%
按下载量换算5

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills