Trivy logo

Trivy

Community
nitinjain999
trivy

Scan container images, filesystems, git repos, and existing SBOMs for CVEs, secrets, and license violations using Trivy. Covers local CLI, CI severity gates with SARIF upload, and continuous monitoring via Trivy Operator (Flux HelmRelease). Use when asked to "scan my image", "check for CVEs", "scan this repo for secrets", "scan an SBOM", or "set up continuous cluster vulnerability monitoring". IaC misconfig → /platform-skills:checkov. Admission posture → /platform-skills:kyverno. Image signing/SBOM generation → /platform-skills:supply-chain.

Overview

Publishernitinjain999
Repositoryplatform-skills
Skill nametrivy
Stars
71
Forks
14
Bundled files
Instructions only
LicenseApache-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by nitinjain999 on GitHub. Read the source before you install it.

Installation

Install the Trivy AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/nitinjain999/platform-skills/tree/main/plugins/platform-skills/skills/trivy
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nitinjain999/platform-skills.git /tmp/platform-skills
mkdir -p .claude/skills
cp -r /tmp/platform-skills/plugins/platform-skills/skills/trivy .claude/skills/trivy
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Trivy in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Trivy on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Trivy is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Scan for vulnerabilities, secrets, and license violations — from local dev to running cluster.

Read references/trivy.md before responding. It contains all mode logic, bootstrap steps, severity gating, output formats, .trivyignore patterns, and the Trivy Operator install via Flux HelmRelease.

Ownership boundary (enforced at the menu)

QuestionAuthoritative command
"Is there a misconfig in my Terraform?"/platform-skills:checkov
"Will this manifest pass admission?"/platform-skills:kyverno apply
"How do I sign my image / generate an SBOM?"/platform-skills:supply-chain
"Is this image safe to ship?"this command
"Are there secrets in this repo?" (fast, offline pattern match)this command
"Is that secret still live? What can it reach? Revoke it."/platform-skills:kingfisher
"What CVEs are running in my cluster?"this command (k8s / Operator)
"Which of those CVEs are in packages that actually load?" (cluster runs Kubescape)/platform-skills:kubescape-operator vulns — run one CVE operator per cluster, not both
"Does this manifest / cluster meet NSA, MITRE, CIS or SOC2?"/platform-skills:kubescape

Mode dispatch

Parse the first word of $ARGUMENTS as the mode. When $ARGUMENTS is empty, run the three-layer interactive wizard.

ModeWhat it does
imageScan a container image for OS and library CVEs
fsScan a local directory for CVEs, secrets, and license violations
repoScan a remote git repo URL (same as fs but clones first)
secretsScan current repo for hardcoded secrets only (--scanners secret)
sbomScan an existing Syft-generated SBOM file (trivy sbom <file>)
k8sLive cluster image-CVE scanning via Trivy Operator (Flux HelmRelease)
(empty)Three-layer interactive wizard

Three-layer interactive wizard

Layer 1 — Developer question (intent in their language)

What are you trying to find out?
  1. "Is this image safe to ship?"              → image CVE scan
  2. "Are there secrets in this repo/code?"      → secret scan
  3. "What's the full risk of this checkout?"    → fs scan (vuln + secret + license)
  4. "What's running vulnerable in my cluster?"  → live cluster scan (Operator)
  5. "Is this SBOM vulnerable?"                  → SBOM scan (Syft output)

  IaC misconfig?              → /platform-skills:checkov
  Will this manifest pass admission? → /platform-skills:kyverno apply
  Image signing / SBOM generation?   → /platform-skills:supply-chain

Enter 1–5 or mode name:

Layer 2 — End goal (decides execution shape)

What do you want out of it?
  a. A quick answer right now        → CLI one-shot, table output
  b. A pass/fail gate in CI          → exit-code gate + SARIF upload to code scanning
  c. Continuous monitoring           → Trivy Operator via Flux HelmRelease (cluster only)

Enter a, b, or c:

Layer 3 — Concerns (surface trade-offs; ask only where a wrong default causes harm)

A few quick settings (press Enter to accept the recommended value):

  • Severity floor [HIGH,CRITICAL]: CRITICAL-only is quieter but misses HIGH exploitables.
    Recommended: HIGH,CRITICAL — enter to accept or type CRITICAL to narrow.

  • --ignore-unfixed [off]: suppresses CVEs with no upstream fix — cuts noise but hides
    un-patchable risk. Enter to keep off, or type 'on' to enable.

  • .trivyignore: every CVE you suppress needs an expiry date and justification, or the
    gate rots silently. Want a template .trivyignore with expiry headers? [y/N]

Detected-only prompts (ask silently, only if needed):

  • Private registry credentials: if the image ref contains a private host, ask for TRIVY_USERNAME / TRIVY_PASSWORD or registry token.
  • Large image warning: if docker inspect shows > 2 GB, warn before pulling.

Do not pepper with questions. Only prompt where getting it wrong causes real harm.


Mode: image

Scan a container image for OS package and library CVEs.

bash
trivy image \
  --severity HIGH,CRITICAL \
  --exit-code 1 \
  --format table \
  [--ignore-unfixed] \
  <image-ref>

Reference: references/trivy.md → Mode: image — bootstrap, auth, output formats, SARIF, .trivyignore


Mode: fs

Scan a local filesystem directory for CVEs, secrets, and license violations in one pass.

bash
trivy fs \
  --scanners vuln,secret,license \
  --severity HIGH,CRITICAL \
  --exit-code 1 \
  .

Reference: references/trivy.md → Mode: fs


Mode: repo

Scan a remote git repo URL (Trivy clones internally; no local clone needed).

bash
trivy repo \
  --scanners vuln,secret,license \
  --severity HIGH,CRITICAL \
  --exit-code 1 \
  https://github.com/<org>/<repo>

Reference: references/trivy.md → Mode: repo


Mode: secrets

Scan for hardcoded secrets only (API keys, tokens, credentials) across the entire repo.

bash
trivy fs \
  --scanners secret \
  --exit-code 1 \
  .

Reference: references/trivy.md → Mode: secrets — secret rule sets, .trivyignore for false positives


Mode: sbom

Scan an existing Syft-generated SBOM file (CycloneDX or SPDX) for known CVEs. Trivy does not generate SBOMs here — generation is owned by /platform-skills:supply-chain (Syft + Cosign attest).

bash
trivy sbom \
  --severity HIGH,CRITICAL \
  --exit-code 1 \
  sbom.spdx.json

Reference: references/trivy.md → Mode: sbom


Mode: k8s

Continuous image-CVE monitoring across all cluster workloads via Trivy Operator, deployed through Flux HelmRelease. This mode is NOT manifest posture scanning — that is owned by /platform-skills:kyverno apply.

bash
# One-shot cluster scan (requires kubectl context)
trivy k8s --report summary cluster

For continuous monitoring, deploy the Trivy Operator via Flux HelmRelease. Reference: references/trivy.md → Mode: k8s — Trivy Operator Flux HelmRelease, VulnerabilityReport CRDs, Prometheus metrics


Agent behavior

Intent classification

Before asking any question, classify from the user's free-text request:

Intent signalsMode
"scan image", "check image", "CVEs in image", "safe to ship", "image vulnerabilities"image
"scan this directory", "scan this code", "full risk", "local scan"fs
"scan this repo", "scan github.com/", "remote repo"repo
"secrets in code", "hardcoded token", "leaked key", "credentials in repo"secrets
"scan sbom", "sbom vulnerabilities", "check syft output", "sbom file"sbom
"cluster CVEs", "running vulnerabilities", "trivy operator", "continuous monitoring"k8s
"terraform misconfig", "IaC security", "checkov"→ hand off to /platform-skills:checkov
"manifest admission", "kyverno policy", "will this manifest pass"→ hand off to /platform-skills:kyverno
"sign image", "generate sbom", "slsa", "cosign"→ hand off to /platform-skills:supply-chain

Ask only for missing high-risk inputs

When to askQuestion
image mode, image ref not provided"Which image? (e.g. ghcr.io/org/image:tag or digest)"
sbom mode, file path not provided"Path to the SBOM file? (e.g. sbom.spdx.json)"
k8s mode, goal (b) vs (c) not clear"CI one-shot scan or deploy the Trivy Operator for continuous monitoring?"
Private registry detected"Registry credentials? Set TRIVY_USERNAME and TRIVY_PASSWORD, or provide a token."
.trivyignore has entries without expiry"These suppressions have no expiry date — add one? (y/N)"

Never ask about: output format (default table for CLI, sarif for CI), or whether to bootstrap (always do it). Never add .trivyignore to .gitignore — it must be committed so the suppression policy is shared and reviewable across the repo.


Cross-references

  • /platform-skills:checkov — IaC source and plan-level security scanning (Terraform, GHA, Helm)
  • /platform-skills:kyverno — Kubernetes admission policy; kyverno apply for manifest posture scanning
  • /platform-skills:supply-chain — image signing (Cosign), SBOM generation and attestation (Syft), SLSA provenance
  • /platform-skills:runtime-security — Falco syscall-level threat detection (complements CVE scanning)
  • /platform-skills:kingfisher — live validation, blast-radius mapping, and revocation for anything this command's secrets mode flags as a pattern match; also covers platform-wide scanning (GitHub org, S3, Slack, Jira) this command does not

Frequently asked questions

What does the Trivy AI skill do?

Scan container images, filesystems, git repos, and existing SBOMs for CVEs, secrets, and license violations using Trivy. Covers local CLI, CI severity gates with SARIF upload, and continuous monitoring via Trivy Operator (Flux HelmRelease). Use when asked to "scan my image", "check for CVEs", "scan this repo for secrets", "scan an SBOM", or "set up continuous cluster vulnerability monitoring". IaC misconfig → /platform-skills:checkov. Admission posture → /platform-skills:kyverno. Image signing/SBOM generation → /platform-skills:supply-chain.

Why use Trivy on TypingMind?

Because you install it once and use it with any model. Trivy is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Trivy in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/nitinjain999/platform-skills/tree/main/plugins/platform-skills/skills/trivy. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Trivy?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Trivy?

As many as you like. As long as a model supports skills, you can use Trivy with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Trivy AI skill free?

Yes. It is published on GitHub by nitinjain999 under the Apache-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇