oracleoval

package
v0.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 2, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AffectedPackage

type AffectedPackage struct {
	Package Package
	OSVer   string
}

func (*AffectedPackage) PlatformName

func (p *AffectedPackage) PlatformName() string

type Criteria

type Criteria struct {
	Operator   string
	Criterias  []Criteria
	Criterions []Criterion
}

type Criterion

type Criterion struct {
	Comment string
}

type Cve

type Cve struct {
	Impact string
	Href   string
	ID     string
}

type DB

type DB interface {
	db.Operation
	Put(*bolt.Tx, PutInput) error
	Get(release, pkgName string) ([]types.Advisory, error)
}

type Date

type Date struct {
	Date string `json:"date"`
}

type Oracle

type Oracle struct {
	db.Operation
}

func (*Oracle) Get

func (o *Oracle) Get(release string, pkgName string) ([]types.Advisory, error)

func (*Oracle) Put

func (o *Oracle) Put(tx *bolt.Tx, input PutInput) error

type OracleOVAL

type OracleOVAL struct {
	Title       string
	Description string
	Platform    []string
	References  []Reference
	Criteria    Criteria
	Severity    string
	Cves        []Cve
	IssuedDate  Date `json:"issued,omitempty"`
}

type Package

type Package struct {
	Name         string
	FixedVersion string
}

type PutInput

type PutInput struct {
	VulnID     string                             // CVE-ID or ELSA-ID
	Vuln       types.VulnerabilityDetail          // vulnerability detail such as CVSS and description
	Advisories map[AffectedPackage]types.Advisory // pkg => advisory
	OVAL       OracleOVAL                         // for extensibility, not used in trivy-db
}

type Reference

type Reference struct {
	Source string
	URI    string
	ID     string
}

type VulnSrc

type VulnSrc struct {
	DB // Those who want to customize Trivy DB can override put/get methods.
}

func NewVulnSrc

func NewVulnSrc() *VulnSrc

func (*VulnSrc) Name

func (vs *VulnSrc) Name() types.SourceID

func (*VulnSrc) Update

func (vs *VulnSrc) Update(dir string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL