vulnsrc

package
v0.0.0-...-41c8d9c Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package vulnsrc exposes functions to dynamically register vulnerability sources used to update a Clair database.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrFilesystem is returned when a fetcher fails to interact with the local filesystem.
	ErrFilesystem = errors.New("vulnsrc: something went wrong when interacting with the fs")
)

Functions

func CleanAll

func CleanAll()

CleanAll is a utility function that calls Clean() on every registered Updater.

func ListUpdaters

func ListUpdaters() []string

ListUpdaters returns the names of registered vulnerability updaters.

func RegisterUpdater

func RegisterUpdater(name string, u Updater)

RegisterUpdater makes an Updater available by the provided name.

If called twice with the same name, the name is blank, or if the provided Updater is nil, this function panics.

func Updaters

func Updaters() map[string]Updater

Updaters returns the list of the registered Updaters.

Types

type UpdateResponse

type UpdateResponse struct {
	FlagName        string
	FlagValue       string
	Notes           []string
	Vulnerabilities []database.VulnerabilityWithAffected
}

UpdateResponse represents the sum of results of an update.

type Updater

type Updater interface {
	// Update gets vulnerability updates.
	Update(database.Datastore) (UpdateResponse, error)

	// Clean deletes any allocated resources.
	// It is invoked when Clair stops.
	Clean()
}

Updater represents anything that can fetch vulnerabilities.

Directories

Path Synopsis
Package alpine implements a vulnerability source updater using the alpine-secdb git repository.
Package alpine implements a vulnerability source updater using the alpine-secdb git repository.
Package amzn implements a vulnerability source updater using ALAS (Amazon Linux Security Advisories).
Package amzn implements a vulnerability source updater using ALAS (Amazon Linux Security Advisories).
Package debian implements a vulnerability source updater using the Debian Security Tracker.
Package debian implements a vulnerability source updater using the Debian Security Tracker.
Package oracle implements a vulnerability source updater using the Oracle Linux OVAL Database.
Package oracle implements a vulnerability source updater using the Oracle Linux OVAL Database.
Package rhel implements a vulnerability source updater using the Red Hat Linux OVAL Database.
Package rhel implements a vulnerability source updater using the Red Hat Linux OVAL Database.
Package suse implements a vulnerability source updater using the SUSE Linux and openSUSE OVAL Database.
Package suse implements a vulnerability source updater using the SUSE Linux and openSUSE OVAL Database.
Package ubuntu implements a vulnerability source updater using the Ubuntu CVE Tracker.
Package ubuntu implements a vulnerability source updater using the Ubuntu CVE Tracker.

Jump to

Keyboard shortcuts

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