Skip to content

Commit

Permalink
fix: add deprecation notes
Browse files Browse the repository at this point in the history
Signed-off-by: juan131 <[email protected]>
  • Loading branch information
juan131 committed Nov 21, 2023
1 parent 56d52ff commit a777f50
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
12 changes: 9 additions & 3 deletions pkg/fanal/types/artifact.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,15 @@ type Package struct {

Modularitylabel string `json:",omitempty"` // only for Red Hat based distributions
BuildInfo *BuildInfo `json:",omitempty"` // only for Red Hat

Ref string `json:",omitempty"` // identifier which can be used to reference the component elsewhere
Indirect bool `json:",omitempty"` // this package is direct dependency of the project or not
Indirect bool `json:",omitempty"` // this package is direct dependency of the project or not

// TO BE DEPRECATED - use Identifier instead
// Only used when scanning SBOM and contains the reference ID used in it.
// It could be PURL, UUID, etc.
// e.g.
// - pkg:npm/acme/[email protected]
// - b2a46a4b-8367-4bae-9820-95557cfe03a8
Ref string `json:",omitempty"`

// Dependencies of this package
// Note: it may have interdependencies, which may lead to infinite loops.
Expand Down
4 changes: 2 additions & 2 deletions pkg/types/vulnerability.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ type DetectedVulnerability struct {
SeveritySource types.SourceID `json:",omitempty"`
PrimaryURL string `json:",omitempty"`

// PkgRef is populated only when scanning SBOM and contains the reference ID used in the SBOM.
// TO BE DEPRECATED - use PkgIdentifier instead
// Only used when scanning SBOM and contains the reference ID used in it.
// It could be PURL, UUID, etc.
// e.g.
// - pkg:npm/acme/[email protected]
// - b2a46a4b-8367-4bae-9820-95557cfe03a8
// To be deprecated now we have PkgIdentifier
PkgRef string `json:",omitempty"`

// DataSource holds where the advisory comes from
Expand Down

0 comments on commit a777f50

Please sign in to comment.