mirror of
https://github.com/anchore/syft.git
synced 2025-11-18 00:43:20 +01:00
22 lines
405 B
Go
22 lines
405 B
Go
package cpe
|
|
|
|
import "github.com/anchore/syft/syft/pkg"
|
|
|
|
func candidateVendorsForRPM(p pkg.Package) fieldCandidateSet {
|
|
metadata, ok := p.Metadata.(pkg.RpmdbMetadata)
|
|
if !ok {
|
|
return nil
|
|
}
|
|
|
|
vendors := newFieldCandidateSet()
|
|
|
|
if metadata.Vendor != "" {
|
|
vendors.add(fieldCandidate{
|
|
value: normalizeName(metadata.Vendor),
|
|
disallowSubSelections: true,
|
|
})
|
|
}
|
|
|
|
return vendors
|
|
}
|