Documentation
¶
Overview ¶
Package imodels defines internal models for osv-scanner.
Index ¶
- type PackageInfo
- func (pkg *PackageInfo) Commit() string
- func (pkg *PackageInfo) DepGroups() []string
- func (pkg *PackageInfo) Ecosystem() ecosystem.Parsed
- func (pkg *PackageInfo) Location() string
- func (pkg *PackageInfo) Name() string
- func (pkg *PackageInfo) OSPackageName() string
- func (pkg *PackageInfo) SourceType() models.SourceType
- func (pkg *PackageInfo) Version() string
- type PackageScanResult
- type ScanResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PackageInfo ¶
PackageInfo provides getter functions for commonly used fields of inventory and applies transformations when required for use in osv-scanner
func FromInventory ¶
func FromInventory(inv *extractor.Package) PackageInfo
FromInventory converts an extractor.Package into a PackageInfo.
func (*PackageInfo) Commit ¶
func (pkg *PackageInfo) Commit() string
func (*PackageInfo) DepGroups ¶
func (pkg *PackageInfo) DepGroups() []string
func (*PackageInfo) Ecosystem ¶
func (pkg *PackageInfo) Ecosystem() ecosystem.Parsed
func (*PackageInfo) Location ¶
func (pkg *PackageInfo) Location() string
func (*PackageInfo) Name ¶
func (pkg *PackageInfo) Name() string
func (*PackageInfo) OSPackageName ¶
func (pkg *PackageInfo) OSPackageName() string
func (*PackageInfo) SourceType ¶
func (pkg *PackageInfo) SourceType() models.SourceType
func (*PackageInfo) Version ¶
func (pkg *PackageInfo) Version() string
type PackageScanResult ¶
type PackageScanResult struct {
PackageInfo PackageInfo
// TODO: Use osvschema.Vulnerability instead
Vulnerabilities []*osvschema.Vulnerability
Licenses []models.License
LayerDetails *extractor.LayerDetails
}
PackageScanResult represents a package and its associated vulnerabilities and licenses. This struct is used to store the results of a scan at a per package level.
type ScanResult ¶ added in v2.2.0
type ScanResult struct {
PackageResults []PackageScanResult
GenericFindings []*inventory.GenericFinding
}
ScanResult represents the result of a scan, which will generally have packages but can also have more generic findings that are not related to packages
Directories
¶
| Path | Synopsis |
|---|---|
|
Package ecosystem provides a parser and mappings for ecosystem strings.
|
Package ecosystem provides a parser and mappings for ecosystem strings. |
|
Package results defines the data structures for scan results.
|
Package results defines the data structures for scan results. |
Click to show internal directories.
Click to hide internal directories.