xray

package
v1.35.3 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2023 License: Apache-2.0 Imports: 4 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type XrayServicesManager

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

XrayServicesManager defines the http client and general configuration

func New

func New(config config.Config) (*XrayServicesManager, error)

New creates a service manager to interact with Xray

func (*XrayServicesManager) AddBuildsToIndexing added in v0.20.1

func (sm *XrayServicesManager) AddBuildsToIndexing(buildNames []string) error

AddBuildsToIndexing will add builds to Xray indexing configuration

func (*XrayServicesManager) ArtifactSummary added in v1.12.0

ArtifactSummary returns Xray artifact summaries for the requested checksums and/or paths

func (*XrayServicesManager) BuildScan added in v1.6.4

func (sm *XrayServicesManager) BuildScan(params services.XrayBuildParams, includeVulnerabilities bool) (scanResponse *services.BuildScanResponse, noFailBuildPolicy bool, err error)

BuildScan scans a published build-info with Xray. 'scanResponse' - Xray scan output of the requested build scan. 'noFailBuildPolicy' - Indicates that the Xray API returned a "No Xray Fail build...." error

func (*XrayServicesManager) Client

Client will return the http client

func (*XrayServicesManager) Config added in v0.25.0

func (sm *XrayServicesManager) Config() config.Config

func (*XrayServicesManager) CreatePolicy added in v0.20.1

func (sm *XrayServicesManager) CreatePolicy(params utils.PolicyParams) error

CreatePolicy will create a new Xray policy

func (*XrayServicesManager) CreateWatch

func (sm *XrayServicesManager) CreateWatch(params utils.WatchParams) error

CreateWatch will create a new Xray watch

func (*XrayServicesManager) DeletePolicy added in v0.20.1

func (sm *XrayServicesManager) DeletePolicy(policyName string) error

DeletePolicy will delete an existing policy by name It will error if no policy can be found by that name.

func (*XrayServicesManager) DeleteReport added in v1.6.0

func (sm *XrayServicesManager) DeleteReport(reportId string) error

DeleteReport deletes a Xray report

func (*XrayServicesManager) DeleteWatch

func (sm *XrayServicesManager) DeleteWatch(watchName string) error

DeleteWatch will delete an existing watch by name It will error if no watch can be found by that name.

func (*XrayServicesManager) GenerateLicensesReport added in v1.32.0

func (sm *XrayServicesManager) GenerateLicensesReport(params services.LicensesReportRequestParams) (resp *services.ReportResponse, err error)

GenerateLicensesReport returns a Xray report response of the requested report

func (*XrayServicesManager) GenerateViolationsReport added in v1.32.0

func (sm *XrayServicesManager) GenerateViolationsReport(params services.ViolationsReportRequestParams) (resp *services.ReportResponse, err error)

GenerateVoilationsReport returns a Xray report response of the requested report

func (*XrayServicesManager) GenerateVulnerabilitiesReport added in v1.6.0

func (sm *XrayServicesManager) GenerateVulnerabilitiesReport(params services.VulnerabilitiesReportRequestParams) (resp *services.ReportResponse, err error)

GenerateVulnerabilitiesReport returns a Xray report response of the requested report

func (*XrayServicesManager) GetPolicy added in v0.20.1

func (sm *XrayServicesManager) GetPolicy(policyName string) (*utils.PolicyParams, error)

GetPolicy retrieves the details about an Xray policy by name It will error if no policy can be found by that name.

func (*XrayServicesManager) GetScanGraphResults added in v0.25.0

func (sm *XrayServicesManager) GetScanGraphResults(scanID string, includeVulnerabilities, includeLicenses, xscEnabled bool) (*services.ScanResponse, error)

GetScanGraphResults returns an Xray scan output of the requested graph scan. The scanId input should be received from ScanGraph request.

func (*XrayServicesManager) GetVersion

func (sm *XrayServicesManager) GetVersion() (string, error)

GetVersion will return the Xray version

func (*XrayServicesManager) GetWatch

func (sm *XrayServicesManager) GetWatch(watchName string) (*utils.WatchParams, error)

GetWatch retrieves the details about an Xray watch by name It will error if no watch can be found by that name.

func (*XrayServicesManager) IsEntitled added in v1.29.0

func (sm *XrayServicesManager) IsEntitled(featureId string) (bool, error)

IsEntitled returns true if the user is entitled for the requested feature ID

func (*XrayServicesManager) ReportContent added in v1.6.0

func (sm *XrayServicesManager) ReportContent(params services.ReportContentRequestParams) (content *services.ReportContent, err error)

ReportContent returns a Xray report content response for the requested report

func (*XrayServicesManager) ReportDetails added in v1.6.0

func (sm *XrayServicesManager) ReportDetails(reportId string) (details *services.ReportDetails, err error)

ReportDetails returns a Xray details response for the requested report

func (*XrayServicesManager) ScanGraph added in v0.25.0

func (sm *XrayServicesManager) ScanGraph(params services.XrayGraphScanParams) (scanId string, err error)

ScanGraph will send Xray the given graph for scan Returns a string represents the scan ID.

func (*XrayServicesManager) UpdatePolicy added in v0.20.1

func (sm *XrayServicesManager) UpdatePolicy(params utils.PolicyParams) error

UpdatePolicy will update an existing Xray policy by name It will error if no policy can be found by that name.

func (*XrayServicesManager) UpdateWatch

func (sm *XrayServicesManager) UpdateWatch(params utils.WatchParams) error

UpdateWatch will update an existing Xray watch by name It will error if no watch can be found by that name.

func (*XrayServicesManager) XscEnabled added in v1.32.0

func (sm *XrayServicesManager) XscEnabled() (string, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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