db

package
v0.90.1 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CreateTablesQuery string

Functions

This section is empty.

Types

type Advisory

type Advisory struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	PackageManager  string
	PackageFilePath string
	DepTypes        string
	Level           string
	AdvisoryType    string
	Description     string
	SupportedUntil  sql.NullString
	EolFrom         sql.NullString
}

type AwsElasticacheDatastore added in v0.28.0

type AwsElasticacheDatastore struct {
	AccountID     string
	Region        string
	Arn           string
	Name          string
	Engine        string
	EngineVersion string
	Tags          string
}

type AwsElasticacheDatastoreEngine added in v0.28.0

type AwsElasticacheDatastoreEngine struct {
	Engine        string
	EngineVersion string
	Deprecation   string
}

type AwsLambdaFunction added in v0.28.0

type AwsLambdaFunction struct {
	AccountID    string
	Region       string
	Arn          string
	Name         string
	Runtime      string
	LastModified sql.NullString
	Tags         string
}

type AwsLambdaFunctionRuntime added in v0.28.0

type AwsLambdaFunctionRuntime struct {
	Runtime     string
	Deprecation sql.NullString
	EndOfLife   sql.NullString
}

type AwsRdsDatabase added in v0.28.0

type AwsRdsDatabase struct {
	AccountID     string
	Region        string
	Arn           string
	Name          string
	Engine        string
	EngineVersion string
	Tags          string
}

type AwsRdsDatabasesEngine added in v0.28.0

type AwsRdsDatabasesEngine struct {
	Engine        string
	EngineVersion string
	Deprecation   string
}

type CountPackageAdvisoriesLikeParams added in v0.51.0

type CountPackageAdvisoriesLikeParams struct {
	Platform     string
	Org          string
	Repo         string
	Owner        interface{}
	AdvisoryType string
}

func NewCountPackageAdvisoriesLikeParams added in v0.51.0

func NewCountPackageAdvisoriesLikeParams(platform, org, repo, owner, advisoryType string) CountPackageAdvisoriesLikeParams

NewCountPackageAdvisoriesLikeParams constructs a CountPackageAdvisoriesLikeParams with the correct defaults, and replaces wildcard characters (`*`) with the appropriate SQL

func (CountPackageAdvisoriesLikeParams) IsWildcard added in v0.51.0

func (p CountPackageAdvisoriesLikeParams) IsWildcard() bool

type CountPackageAdvisoriesLikeRow added in v0.51.0

type CountPackageAdvisoriesLikeRow struct {
	Platform          string
	Organisation      string
	Repo              string
	Owner             sql.NullString
	TotalDeprecated   sql.NullFloat64
	TotalUnmaintained sql.NullFloat64
	TotalSecurity     sql.NullFloat64
	TotalPolicy       sql.NullFloat64
	TotalOther        sql.NullFloat64
}

type CustomAdvisory added in v0.71.0

type CustomAdvisory struct {
	PackagePattern       string
	PackageManager       string
	Version              sql.NullString
	VersionMatchStrategy sql.NullString
	Level                string
	AdvisoryType         string
	Description          string
}

type DBTX

type DBTX interface {
	ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
	PrepareContext(context.Context, string) (*sql.Stmt, error)
	QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
	QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}

type DepsdevCfe added in v0.44.0

type DepsdevCfe struct {
	PackageName string
	Version     string
	CveID       string
	UpdatedAt   string
}

type DepsdevLicense added in v0.44.0

type DepsdevLicense struct {
	PackageName string
	Version     string
	License     string
	UpdatedAt   string
}

type EndoflifedateProduct added in v0.28.0

type EndoflifedateProduct struct {
	ProductName    string
	Cycle          string
	SupportedUntil sql.NullString
	EolFrom        sql.NullString
	InsertedAt     string
}

type InsertAdvisoryParams added in v0.71.0

type InsertAdvisoryParams struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	PackageManager  string
	PackageFilePath string
	DepTypes        string
	Level           string
	AdvisoryType    string
	Description     string
	SupportedUntil  sql.NullString
	EolFrom         sql.NullString
}

type Owner added in v0.42.0

type Owner struct {
	Platform     string
	Organisation string
	Repo         string
	Owner        string
	Notes        sql.NullString
	UpdatedAt    string
}

type Queries

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

func New

func New(db DBTX) *Queries

func (*Queries) CountPackageAdvisoriesLike added in v0.51.0

func (q *Queries) CountPackageAdvisoriesLike(ctx context.Context, arg CountPackageAdvisoriesLikeParams) ([]CountPackageAdvisoriesLikeRow, error)

func (*Queries) InsertAdvisory added in v0.71.0

func (q *Queries) InsertAdvisory(ctx context.Context, arg InsertAdvisoryParams) error

func (*Queries) RetrieveAWSAdvisories added in v0.28.0

func (q *Queries) RetrieveAWSAdvisories(ctx context.Context) ([]RetrieveAWSAdvisoriesRow, error)

func (*Queries) RetrievePackageAdvisories added in v0.39.0

func (q *Queries) RetrievePackageAdvisories(ctx context.Context) ([]RetrievePackageAdvisoriesRow, error)

func (*Queries) RetrievePackageAdvisoriesFromSeparateTables added in v0.71.0

func (q *Queries) RetrievePackageAdvisoriesFromSeparateTables(ctx context.Context) ([]RetrievePackageAdvisoriesFromSeparateTablesRow, error)

func (*Queries) RetrievePackageAdvisoriesLike added in v0.42.0

func (q *Queries) RetrievePackageAdvisoriesLike(ctx context.Context, arg RetrievePackageAdvisoriesLikeParams) ([]RetrievePackageAdvisoriesLikeRow, error)

func (*Queries) WithTx

func (q *Queries) WithTx(tx *sql.Tx) *Queries

type Renovate added in v0.27.0

type Renovate struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	PackageManager  string
	PackageFilePath string
	Datasource      string
	DepTypes        string
}

type RenovateEndoflife added in v0.28.0

type RenovateEndoflife struct {
	PackageName    string
	Version        string
	CurrentVersion sql.NullString
	PackageManager string
	Datasource     string
	ProductName    string
	Cycle          string
}

type RenovateUpdate added in v0.27.0

type RenovateUpdate struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	PackageManager  string
	PackageFilePath string
	Datasource      string
	NewVersion      string
	UpdateType      string
}

type RetrieveAWSAdvisoriesRow added in v0.28.0

type RetrieveAWSAdvisoriesRow struct {
	Arn          string
	Name         string
	Runtime      sql.NullString
	AdvisoryType interface{}
	Description  interface{}
}

type RetrievePackageAdvisoriesFromSeparateTablesRow added in v0.71.0

type RetrievePackageAdvisoriesFromSeparateTablesRow struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         sql.NullString
	CurrentVersion  sql.NullString
	PackageManager  string
	DepTypes        string
	PackageFilePath string
	Owner           sql.NullString
	AdvisoryType    string
	Level           string
	Description     string
	SupportedUntil  interface{}
	EolFrom         interface{}
}

type RetrievePackageAdvisoriesLikeParams added in v0.42.0

type RetrievePackageAdvisoriesLikeParams struct {
	Platform     string
	Org          string
	Repo         string
	Owner        interface{}
	AdvisoryType string
}

func NewRetrievePackageAdvisoriesLikeParams added in v0.42.0

func NewRetrievePackageAdvisoriesLikeParams(platform, org, repo, owner, advisoryType string) RetrievePackageAdvisoriesLikeParams

NewRetrievePackageAdvisoriesLikeParams constructs a RetrievePackageAdvisoriesLikeParams with the correct defaults, and replaces wildcard characters (`*`) with the appropriate SQL

func (RetrievePackageAdvisoriesLikeParams) IsWildcard added in v0.42.0

type RetrievePackageAdvisoriesLikeRow added in v0.42.0

type RetrievePackageAdvisoriesLikeRow struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	DepTypes        string
	PackageFilePath string
	Owner           sql.NullString
	AdvisoryType    string
	Description     string
}

type RetrievePackageAdvisoriesRow added in v0.39.0

type RetrievePackageAdvisoriesRow struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	DepTypes        string
	PackageFilePath string
	Owner           sql.NullString
	AdvisoryType    string
	Description     string
}

type Sbom added in v0.39.0

type Sbom struct {
	Platform       string
	Organisation   string
	Repo           string
	PackageName    string
	Version        sql.NullString
	CurrentVersion sql.NullString
	PackageType    string
}

type SbomsEndoflife added in v0.43.0

type SbomsEndoflife struct {
	PackageName    string
	Version        sql.NullString
	CurrentVersion sql.NullString
	PackageType    string
	ProductName    string
	Cycle          string
}

Jump to

Keyboard shortcuts

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