openclaw-skills/grype-syft-sbom-scanner/SKILL.md
用于通过 Syft 生成 SBOM,并用 Grype 扫描容器镜像、文件系统、软件包、归档和 SBOM 漏洞。
npx skillsauth add seaworld008/commonly-used-high-value-skills grype-syft-sbom-scannerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Use this skill when the user wants SBOM-first vulnerability management, container image scanning, package inventory, or repeatable vulnerability scans using Anchore open-source tools Syft and Grype.
Good trigger phrases:
Use one of these modes:
Prefer SBOM-first when the result will be attached to a release, shared with customers, or compared later.
syft version
grype version
If missing, install from official Anchore channels. Pin versions in CI when release evidence matters.
For a container image:
syft registry.example.com/app:1.2.3 -o cyclonedx-json=sbom.cdx.json
For a local source or filesystem directory:
syft dir:. -o spdx-json=sbom.spdx.json
For Syft JSON:
syft packages . -o syft-json=sbom.syft.json
Scan an image directly:
grype registry.example.com/app:1.2.3
Scan a directory:
grype dir:.
Scan an SBOM:
grype sbom:sbom.cdx.json
Fail on high-severity findings in CI:
grype registry.example.com/app:1.2.3 --fail-on high
grype sbom:sbom.cdx.json -o json > grype-results.json
grype sbom:sbom.cdx.json -o sarif > grype-results.sarif
grype sbom:sbom.cdx.json -o table
Retain:
For each finding, capture:
Prioritize runtime packages over build-only layers unless the build system is also in scope.
release-security/
image-digest.txt
sbom.cdx.json
grype-results.json
grype-results.sarif
scanner-versions.txt
accepted-risk.md
name: sbom-vuln-scan
on: [pull_request]
jobs:
scan:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Generate SBOM
run: syft dir:. -o cyclonedx-json=sbom.cdx.json
- name: Scan SBOM
run: grype sbom:sbom.cdx.json --fail-on high
syft old-image:tag -o syft-json=old.sbom.json
syft new-image:tag -o syft-json=new.sbom.json
grype sbom:old.sbom.json -o json > old.vulns.json
grype sbom:new.sbom.json -o json > new.vulns.json
Summarize deltas by new, fixed, unchanged, and severity-changed vulnerabilities.
development
Enumerating failure modes via pre-mortem analysis. Systematically identifies failure scenarios for plans, designs, and features, scoring them with RPN/AP. Does not write code.
testing
Orchestrating specialist AI agent teams as a meta-coordinator. Decomposes requests into minimum viable chains, spawns each as an independent session in AUTORUN modes, and drives to final output. Use when a task spans multiple specialist domains, requires parallel agent execution, or needs hub-and-spoke routing across the skill ecosystem.
development
Converting document formats (Markdown/Word/Excel/PDF/HTML). Converts specs from Scribe and reports from Harvest into distributable formats; generates reusable conversion scripts. Use when converting documents, building accessibility-compliant PDFs, or creating Pandoc/LibreOffice pipelines.
testing
Curating cross-agent knowledge and guarding institutional memory. Extracts patterns from agent journals into METAPATTERNS.md, detects knowledge decay, propagates best practices, prevents organizational forgetting. Use when consolidating cross-agent insights, curating memory, or auditing knowledge decay.