Skip to main content

A vulnerability scan diffing command-line tool for container images and SBOMs

Project description

Diffused CLI

Command-line interface for the Diffused vulnerability scanning and diffing library. This tool provides an easy-to-use interface for comparing container images and SBOMs (Software Bill of Materials) to track security improvements and regressions.

Features

  • 🔍 Container Image Comparison: Compare vulnerabilities between different container image versions
  • 📊 SBOM Diffing: Direct comparison of SPDX-JSON formatted SBOMs (Trivy only)
  • 📄 Multiple Output Formats: Support for both rich text and JSON output
  • 🎨 Rich Terminal Output: Beautiful, colored output for better readability

Installation

Prerequisites

  1. Install the scanner:
    1. Trivy: Follow the official Trivy installation guide
    2. RHACS: Follow the official roxctl installation guide
  2. Python Environment: Ensure Python 3.9+ is installed

From Source

# Install the library
pip install -e ./diffused

# Install the CLI
pip install -e ./diffusedcli

From PyPI

pip install diffusedcli

Usage

Compare Container Images

# Basic vulnerability diff between two container images
diffused image-diff -p ubuntu:20.04 -n ubuntu:22.04

# Use ACS scanner
diffused --scanner acs image-diff -p nginx:1.20 -n nginx:1.21

# Save output to JSON file
diffused image-diff -p app:v1.0 -n app:v2.0 --output json --file report.json

Compare SBOMs

# Compare two SBOM files
diffused sbom-diff -p previous.json -n current.json

# Get detailed vulnerability information
diffused sbom-diff -p old-sbom.json -n new-sbom.json --all-info

# Export to file with rich formatting
diffused sbom-diff -p v1-sbom.json -n v2-sbom.json --file vulnerability-report.txt

CLI Commands and Options

For more information on commands and options, use the --help option.

Commands

Command Description
image-diff Show the vulnerability diff between two container images
sbom-diff Show the vulnerability diff between two SBOMs

Global Options

Option Short Description Default
--scanner -s Scanner to use (acs, trivy) trivy
--output -o Output format (rich, json) rich
--file -f Output file (use - for stdout) -
--help -h Show help message -

image-diff Options

Option Short Description Required
--previous-image -p Previous container image URL Yes
--next-image -n Next container image URL Yes
--output -o Output format (rich, json) rich
--file -f Output file (use - for stdout) -

sbom-diff Options

Option Short Description Required
--previous-sbom -p Previous SBOM file path Yes
--next-sbom -n Next SBOM file path Yes
--all-info -a Show detailed vulnerability information (SBOM only) False
--output -o Output format (rich, json) rich
--file -f Output file (use - for stdout) -

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

diffused_cli-0.2.0.tar.gz (7.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

diffused_cli-0.2.0-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file diffused_cli-0.2.0.tar.gz.

File metadata

  • Download URL: diffused_cli-0.2.0.tar.gz
  • Upload date:
  • Size: 7.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for diffused_cli-0.2.0.tar.gz
Algorithm Hash digest
SHA256 3c9988e8c01c499d5d024528e9b326d269e64bcdde0dc39fad872bd3e16f02bb
MD5 7a7cfc3576553831f4c46bcfb9781ce1
BLAKE2b-256 311d8b60aabff2bb1918a7db9059f6240dbf78bdb993b5f30f069e4a2085195e

See more details on using hashes here.

Provenance

The following attestation bundles were made for diffused_cli-0.2.0.tar.gz:

Publisher: release.yml on konflux-ci/diffused

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file diffused_cli-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: diffused_cli-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 4.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for diffused_cli-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b2c0b5892e9acdd539a3bc945cea7025638d4b4c1f6f559e88feed54765dea1f
MD5 1fb9dee786a38b014eb01e9001cf6885
BLAKE2b-256 6544740264a304375d538195b3f881af05c41bcdca514873469bae630f1c8862

See more details on using hashes here.

Provenance

The following attestation bundles were made for diffused_cli-0.2.0-py3-none-any.whl:

Publisher: release.yml on konflux-ci/diffused

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page