agentleFS
kaandgnshkaandgnsh/Claude-Blue/skills/supply-chain-security/sbom-generation/SKILL.md

sbom-generation

Skill0 starsChanged 13 days agoMITView on GitHub

Generate accurate SBOMs (CycloneDX, SPDX) for source, containers and binaries with Syft, cdxgen, Trivy or build plugins; meet NTIA minimum elements; attach SBOMs to releases as signed attestations; and manage SBOM quality. Use when producing SBOMs for customers/regulators (EO 14028, EU CRA), building an SBOM pipeline, or checking an SBOM's completeness.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

Files
SKILL.md

SBOM Generation

Generate

syft dir:. -o cyclonedx-json=sbom.cdx.json                 # source tree (lockfiles)
syft registry:ghcr.io/org/app@sha256:<digest> -o spdx-json=sbom.spdx.json   # container image by digest
cdxgen -r -o bom.json .                                     # CycloneDX generator, deep language support (-r recursive)
trivy image --format cyclonedx --output sbom.cdx.json ghcr.io/org/app:1.4.2

Build-time plugins (CycloneDX Maven/Gradle/npm, cyclonedx-py) give more accurate dependency graphs than post-hoc scanning. Generate from the built artifact (image digest), not only the repo.

Quality checklist (NTIA minimum elements + practice)

  • Supplier, component name, version, unique identifier (purl, CPE), dependency relationships, author of SBOM data, timestamp.
  • Transitive dependencies included (lockfiles present at scan time).
  • OS packages included for images.
  • Hashes for components where available.
  • SBOM references the exact artifact (image digest / file hash) it describes.
  • Format validated: cyclonedx validate --input-file sbom.cdx.json (CycloneDX CLI) or SPDX tools.

Distribution

Attach as a signed attestation to the image (cosign attest --predicate sbom.cdx.json --type cyclonedx ghcr.io/org/app@sha256:<digest>) or GitHub attestation (actions/attest-sbom), and store with the release. Keep SBOMs per version to answer "were we affected?" retroactively (emergency-vulnerability-response).

Related skills

sbom-vulnerability-analysis, artifact-signing, slsa-provenance, image-scanning

References

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.