node

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2019 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ScannerTypeNpm  = "npm"
	ScannerTypeYarn = "yarn"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Advisory

type Advisory struct {
	ID                 int
	Title              string
	ModuleName         string `json:"module_name""`
	Cves               []string
	VulnerableVersions string `json:"vulnerable_versions"`
	PatchedVersions    string `json:"patched_versions"`
	Overview           string
	Recommendation     string
	References         []string
	CvssScoreNumber    json.Number `json:"cvss_score"`
	CvssScore          float64
}

type AdvisoryDB

type AdvisoryDB map[string][]Advisory

type Scanner

type Scanner struct {
	// contains filtered or unexported fields
}

func NewScanner

func NewScanner(scannerType string) *Scanner

func (*Scanner) Detect

func (s *Scanner) Detect(pkgName string, pkgVer *version.Version) ([]vulnerability.DetectedVulnerability, error)

func (*Scanner) ParseLockfile

func (s *Scanner) ParseLockfile(f *os.File) ([]ptypes.Library, error)

func (*Scanner) Type

func (s *Scanner) Type() string

func (*Scanner) UpdateDB

func (s *Scanner) UpdateDB() (err error)

Jump to

Keyboard shortcuts

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