CycloneDX/sbom-utility
Explore using custom struct tags for CycloneDX property versioning
Aperta
#24 aperta il 18 mag 2023
enhancementhelp wanted
Metriche repository
- Star
- (155 stelle)
- Metriche merge PR
- (Metriche PR in attesa)
Descrizione
If we want to have special processing for JSON encoding/decoding (e.g., marshal/unmarshal) it would be helpful to enable this via custom struct tags.
For example:
// v1.3 added "compositions"
Compositions []CDXCompositions `json:"compositions,omitempty" cdx:"v1.3"`
// v1.4 added "vulnerabilities", "signature"
Vulnerabilities []CDXVulnerability `json:"vulnerabilities,omitempty" cdx:"v1.4"`