vulnlib

package
v1.0.10 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2024 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OSCSUrl     = "https://www.oscs1024.com/oscs/v1/intelligence/list"
	OSCSVulnUrl = "https://www.oscs1024.com/oscs/v1/vdb/info"
)

Variables

This section is empty.

Functions

func Fetch

func Fetch(ctx context.Context) error

Fetch get cvss data from Internet

Types

type Client

type Client struct {
	Cli *http.Client
	DB  *sql.DB

	Store string
}

func (*Client) GetCvss

func (c *Client) GetCvss(ctx context.Context) error

func (*Client) GetOSCS added in v1.0.7

func (c *Client) GetOSCS(ctx context.Context) error

func (*Client) Init

func (cli *Client) Init() error

func (*Client) QueryVulnByCVEID

func (cli *Client) QueryVulnByCVEID(cveid string) ([]*DBRow, error)

func (*Client) QueryVulnByName

func (cli *Client) QueryVulnByName(name string) ([]*DBRow, error)

type DBRow

type DBRow struct {
	Id          int
	Hash        string
	VulnName    string
	MaxVersion  string
	MinVersion  string
	Description string
	Level       string
	CVEID       string
	Source      string
	PublishDate string
	Component   string
	Score       float64
}

Jump to

Keyboard shortcuts

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