feat: add comprehensive audit trail for SBOM modifications#130
Merged
vpetersson merged 1 commit intomasterfrom Jan 19, 2026
Merged
feat: add comprehensive audit trail for SBOM modifications#130vpetersson merged 1 commit intomasterfrom
vpetersson merged 1 commit intomasterfrom
Conversation
Implement structured tracking of all SBOM changes for attestation and compliance purposes. Every modification is now recorded with UTC timestamps and categorized by type. Changes: - Add AuditTrail and AuditEntry classes with categorized tracking (AUGMENTATION, ENRICHMENT, SANITIZATION, OVERRIDE) - Write detailed audit_trail.txt file alongside SBOM output - Display summary table in stdout showing modification counts - Output full audit trail in GitHub Actions collapsible group - Record augmentation: supplier, manufacturer, authors, licenses, VCS, lifecycle - Record enrichment: per-component metadata from external sources - Record sanitization: URL/PURL normalizations, rejections, stubs - Record overrides: CLI/env component name, version, PURL changes - Maintain backward compatibility via TransformationTracker alias - Add 28 new tests for audit trail functionality - Document feature in README with example outputs
Contributor
There was a problem hiding this comment.
Pull request overview
This PR implements a comprehensive audit trail system for tracking all SBOM modifications during processing. The audit trail captures every change made to the SBOM, categorized by type (augmentation, enrichment, sanitization, override), with UTC timestamps for compliance and attestation purposes.
Changes:
- Added
AuditEntryandAuditTrailclasses to replace and extend the legacyTransformationTracker - Integrated audit trail recording throughout SBOM processing pipeline (augmentation, enrichment, overrides)
- Output includes summary table, detailed
audit_trail.txtfile, and collapsible attestation group in GitHub Actions - Maintained backward compatibility through
TransformationTrackeralias
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| tests/test_console.py | Added 28 comprehensive tests for AuditEntry and AuditTrail functionality |
| sbomify_action/console.py | Implemented AuditEntry and AuditTrail classes with recording methods and output formatting |
| sbomify_action/enrichment.py | Integrated audit trail recording for component enrichment operations |
| sbomify_action/cli/main.py | Added audit trail initialization, finalization, and file output in main pipeline |
| sbomify_action/augmentation.py | Integrated audit trail recording for SBOM augmentation operations |
| README.md | Documented the audit trail feature with example outputs |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implement structured tracking of all SBOM changes for attestation and compliance purposes. Every modification is now recorded with UTC timestamps and categorized by type.
Changes: