securityhub

package
v5.6.0 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client for securityhub API

func (*Client) GetSecuritySummary

func (a *Client) GetSecuritySummary(params *GetSecuritySummaryParams, authInfo runtime.ClientAuthInfoWriter) (*GetSecuritySummaryOK, error)

GetSecuritySummary gets vulnerability system summary

Retrieve the vulnerability summary of the system

func (*Client) ListVulnerabilities

func (a *Client) ListVulnerabilities(params *ListVulnerabilitiesParams, authInfo runtime.ClientAuthInfoWriter) (*ListVulnerabilitiesOK, error)
ListVulnerabilities gets the vulnerability list

Get the vulnerability list. use q to pass the query condition,

supported conditions: cve_id(exact match) cvss_score_v3(range condition) severity(exact match) repository_name(exact match) project_id(exact match) package(exact match) tag(exact match) digest(exact match)

func (*Client) SetTransport

func (a *Client) SetTransport(transport runtime.ClientTransport)

SetTransport changes the transport on the client

type ClientService

type ClientService interface {
	ListVulnerabilities(params *ListVulnerabilitiesParams, authInfo runtime.ClientAuthInfoWriter) (*ListVulnerabilitiesOK, error)

	GetSecuritySummary(params *GetSecuritySummaryParams, authInfo runtime.ClientAuthInfoWriter) (*GetSecuritySummaryOK, error)

	SetTransport(transport runtime.ClientTransport)
}

ClientService is the interface for Client methods

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService

New creates a new securityhub API client.

type GetSecuritySummaryForbidden

type GetSecuritySummaryForbidden struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

GetSecuritySummaryForbidden handles this case with default header values.

Forbidden

func NewGetSecuritySummaryForbidden

func NewGetSecuritySummaryForbidden() *GetSecuritySummaryForbidden

NewGetSecuritySummaryForbidden creates a GetSecuritySummaryForbidden with default headers values

func (*GetSecuritySummaryForbidden) Error

func (*GetSecuritySummaryForbidden) GetPayload

func (o *GetSecuritySummaryForbidden) GetPayload() *model.Errors

type GetSecuritySummaryInternalServerError

type GetSecuritySummaryInternalServerError struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

GetSecuritySummaryInternalServerError handles this case with default header values.

Internal server error

func NewGetSecuritySummaryInternalServerError

func NewGetSecuritySummaryInternalServerError() *GetSecuritySummaryInternalServerError

NewGetSecuritySummaryInternalServerError creates a GetSecuritySummaryInternalServerError with default headers values

func (*GetSecuritySummaryInternalServerError) Error

func (*GetSecuritySummaryInternalServerError) GetPayload

type GetSecuritySummaryNotFound

type GetSecuritySummaryNotFound struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

GetSecuritySummaryNotFound handles this case with default header values.

Not found

func NewGetSecuritySummaryNotFound

func NewGetSecuritySummaryNotFound() *GetSecuritySummaryNotFound

NewGetSecuritySummaryNotFound creates a GetSecuritySummaryNotFound with default headers values

func (*GetSecuritySummaryNotFound) Error

func (*GetSecuritySummaryNotFound) GetPayload

func (o *GetSecuritySummaryNotFound) GetPayload() *model.Errors

type GetSecuritySummaryOK

type GetSecuritySummaryOK struct {
	Payload *model.SecuritySummary
}

GetSecuritySummaryOK handles this case with default header values.

Success

func NewGetSecuritySummaryOK

func NewGetSecuritySummaryOK() *GetSecuritySummaryOK

NewGetSecuritySummaryOK creates a GetSecuritySummaryOK with default headers values

func (*GetSecuritySummaryOK) Error

func (o *GetSecuritySummaryOK) Error() string

func (*GetSecuritySummaryOK) GetPayload

func (o *GetSecuritySummaryOK) GetPayload() *model.SecuritySummary

type GetSecuritySummaryParams

type GetSecuritySummaryParams struct {

	/*XRequestID
	  An unique ID for the request

	*/
	XRequestID *string
	/*WithDangerousArtifact
	  Specify whether the dangerous Artifact are included inside summary information

	*/
	WithDangerousArtifact *bool
	/*WithDangerousCVE
	  Specify whether the dangerous CVEs are included inside summary information

	*/
	WithDangerousCVE *bool

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

GetSecuritySummaryParams contains all the parameters to send to the API endpoint for the get security summary operation typically these are written to a http.Request

func NewGetSecuritySummaryParams

func NewGetSecuritySummaryParams() *GetSecuritySummaryParams

NewGetSecuritySummaryParams creates a new GetSecuritySummaryParams object with the default values initialized.

func NewGetSecuritySummaryParamsWithContext

func NewGetSecuritySummaryParamsWithContext(ctx context.Context) *GetSecuritySummaryParams

NewGetSecuritySummaryParamsWithContext creates a new GetSecuritySummaryParams object with the default values initialized, and the ability to set a context for a request

func NewGetSecuritySummaryParamsWithHTTPClient

func NewGetSecuritySummaryParamsWithHTTPClient(client *http.Client) *GetSecuritySummaryParams

NewGetSecuritySummaryParamsWithHTTPClient creates a new GetSecuritySummaryParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewGetSecuritySummaryParamsWithTimeout

func NewGetSecuritySummaryParamsWithTimeout(timeout time.Duration) *GetSecuritySummaryParams

NewGetSecuritySummaryParamsWithTimeout creates a new GetSecuritySummaryParams object with the default values initialized, and the ability to set a timeout on a request

func (*GetSecuritySummaryParams) SetContext

func (o *GetSecuritySummaryParams) SetContext(ctx context.Context)

SetContext adds the context to the get security summary params

func (*GetSecuritySummaryParams) SetHTTPClient

func (o *GetSecuritySummaryParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the get security summary params

func (*GetSecuritySummaryParams) SetTimeout

func (o *GetSecuritySummaryParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the get security summary params

func (*GetSecuritySummaryParams) SetWithDangerousArtifact

func (o *GetSecuritySummaryParams) SetWithDangerousArtifact(withDangerousArtifact *bool)

SetWithDangerousArtifact adds the withDangerousArtifact to the get security summary params

func (*GetSecuritySummaryParams) SetWithDangerousCVE

func (o *GetSecuritySummaryParams) SetWithDangerousCVE(withDangerousCVE *bool)

SetWithDangerousCVE adds the withDangerousCve to the get security summary params

func (*GetSecuritySummaryParams) SetXRequestID

func (o *GetSecuritySummaryParams) SetXRequestID(xRequestID *string)

SetXRequestID adds the xRequestId to the get security summary params

func (*GetSecuritySummaryParams) WithContext

WithContext adds the context to the get security summary params

func (*GetSecuritySummaryParams) WithHTTPClient

func (o *GetSecuritySummaryParams) WithHTTPClient(client *http.Client) *GetSecuritySummaryParams

WithHTTPClient adds the HTTPClient to the get security summary params

func (*GetSecuritySummaryParams) WithTimeout

WithTimeout adds the timeout to the get security summary params

func (*GetSecuritySummaryParams) WithWithDangerousArtifact

func (o *GetSecuritySummaryParams) WithWithDangerousArtifact(withDangerousArtifact *bool) *GetSecuritySummaryParams

WithWithDangerousArtifact adds the withDangerousArtifact to the get security summary params

func (*GetSecuritySummaryParams) WithWithDangerousCVE

func (o *GetSecuritySummaryParams) WithWithDangerousCVE(withDangerousCVE *bool) *GetSecuritySummaryParams

WithWithDangerousCVE adds the withDangerousCVE to the get security summary params

func (*GetSecuritySummaryParams) WithXRequestID

func (o *GetSecuritySummaryParams) WithXRequestID(xRequestID *string) *GetSecuritySummaryParams

WithXRequestID adds the xRequestID to the get security summary params

func (*GetSecuritySummaryParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type GetSecuritySummaryReader

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

GetSecuritySummaryReader is a Reader for the GetSecuritySummary structure.

func (*GetSecuritySummaryReader) ReadResponse

func (o *GetSecuritySummaryReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type GetSecuritySummaryUnauthorized

type GetSecuritySummaryUnauthorized struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

GetSecuritySummaryUnauthorized handles this case with default header values.

Unauthorized

func NewGetSecuritySummaryUnauthorized

func NewGetSecuritySummaryUnauthorized() *GetSecuritySummaryUnauthorized

NewGetSecuritySummaryUnauthorized creates a GetSecuritySummaryUnauthorized with default headers values

func (*GetSecuritySummaryUnauthorized) Error

func (*GetSecuritySummaryUnauthorized) GetPayload

func (o *GetSecuritySummaryUnauthorized) GetPayload() *model.Errors

type ListVulnerabilitiesBadRequest

type ListVulnerabilitiesBadRequest struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

ListVulnerabilitiesBadRequest handles this case with default header values.

Bad request

func NewListVulnerabilitiesBadRequest

func NewListVulnerabilitiesBadRequest() *ListVulnerabilitiesBadRequest

NewListVulnerabilitiesBadRequest creates a ListVulnerabilitiesBadRequest with default headers values

func (*ListVulnerabilitiesBadRequest) Error

func (*ListVulnerabilitiesBadRequest) GetPayload

func (o *ListVulnerabilitiesBadRequest) GetPayload() *model.Errors

type ListVulnerabilitiesInternalServerError

type ListVulnerabilitiesInternalServerError struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

ListVulnerabilitiesInternalServerError handles this case with default header values.

Internal server error

func NewListVulnerabilitiesInternalServerError

func NewListVulnerabilitiesInternalServerError() *ListVulnerabilitiesInternalServerError

NewListVulnerabilitiesInternalServerError creates a ListVulnerabilitiesInternalServerError with default headers values

func (*ListVulnerabilitiesInternalServerError) Error

func (*ListVulnerabilitiesInternalServerError) GetPayload

type ListVulnerabilitiesOK

type ListVulnerabilitiesOK struct {
	/*Link refers to the previous page and next page
	 */
	Link string
	/*The total count of vulnerabilities
	 */
	XTotalCount int64

	Payload []*model.VulnerabilityItem
}

ListVulnerabilitiesOK handles this case with default header values.

The vulnerability list.

func NewListVulnerabilitiesOK

func NewListVulnerabilitiesOK() *ListVulnerabilitiesOK

NewListVulnerabilitiesOK creates a ListVulnerabilitiesOK with default headers values

func (*ListVulnerabilitiesOK) Error

func (o *ListVulnerabilitiesOK) Error() string

func (*ListVulnerabilitiesOK) GetPayload

func (o *ListVulnerabilitiesOK) GetPayload() []*model.VulnerabilityItem

type ListVulnerabilitiesParams

type ListVulnerabilitiesParams struct {

	/*XRequestID
	  An unique ID for the request

	*/
	XRequestID *string
	/*Page
	  The page number

	*/
	Page *int64
	/*PageSize
	  The size of per page

	*/
	PageSize *int64
	/*Q
	  Query string to query resources. Supported query patterns are "exact match(k=v)", "fuzzy match(k=~v)", "range(k=[min~max])", "list with union releationship(k={v1 v2 v3})" and "list with intersetion relationship(k=(v1 v2 v3))". The value of range and list can be string(enclosed by " or '), integer or time(in format "2020-04-09 02:36:00"). All of these query patterns should be put in the query string "q=xxx" and splitted by ",". e.g. q=k1=v1,k2=~v2,k3=[min~max]

	*/
	Q *string
	/*TuneCount
	  Enable to ignore X-Total-Count when the total count > 1000, if the total count is less than 1000, the real total count is returned, else -1.

	*/
	TuneCount *bool
	/*WithTag
	  Specify whether the tag information is included inside vulnerability information

	*/
	WithTag *bool

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

ListVulnerabilitiesParams contains all the parameters to send to the API endpoint for the list vulnerabilities operation typically these are written to a http.Request

func NewListVulnerabilitiesParams

func NewListVulnerabilitiesParams() *ListVulnerabilitiesParams

NewListVulnerabilitiesParams creates a new ListVulnerabilitiesParams object with the default values initialized.

func NewListVulnerabilitiesParamsWithContext

func NewListVulnerabilitiesParamsWithContext(ctx context.Context) *ListVulnerabilitiesParams

NewListVulnerabilitiesParamsWithContext creates a new ListVulnerabilitiesParams object with the default values initialized, and the ability to set a context for a request

func NewListVulnerabilitiesParamsWithHTTPClient

func NewListVulnerabilitiesParamsWithHTTPClient(client *http.Client) *ListVulnerabilitiesParams

NewListVulnerabilitiesParamsWithHTTPClient creates a new ListVulnerabilitiesParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewListVulnerabilitiesParamsWithTimeout

func NewListVulnerabilitiesParamsWithTimeout(timeout time.Duration) *ListVulnerabilitiesParams

NewListVulnerabilitiesParamsWithTimeout creates a new ListVulnerabilitiesParams object with the default values initialized, and the ability to set a timeout on a request

func (*ListVulnerabilitiesParams) SetContext

func (o *ListVulnerabilitiesParams) SetContext(ctx context.Context)

SetContext adds the context to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetHTTPClient

func (o *ListVulnerabilitiesParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetPage

func (o *ListVulnerabilitiesParams) SetPage(page *int64)

SetPage adds the page to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetPageSize

func (o *ListVulnerabilitiesParams) SetPageSize(pageSize *int64)

SetPageSize adds the pageSize to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetQ

func (o *ListVulnerabilitiesParams) SetQ(q *string)

SetQ adds the q to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetTimeout

func (o *ListVulnerabilitiesParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetTuneCount

func (o *ListVulnerabilitiesParams) SetTuneCount(tuneCount *bool)

SetTuneCount adds the tuneCount to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetWithTag

func (o *ListVulnerabilitiesParams) SetWithTag(withTag *bool)

SetWithTag adds the withTag to the list vulnerabilities params

func (*ListVulnerabilitiesParams) SetXRequestID

func (o *ListVulnerabilitiesParams) SetXRequestID(xRequestID *string)

SetXRequestID adds the xRequestId to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithContext

WithContext adds the context to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithHTTPClient

func (o *ListVulnerabilitiesParams) WithHTTPClient(client *http.Client) *ListVulnerabilitiesParams

WithHTTPClient adds the HTTPClient to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithPage

WithPage adds the page to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithPageSize

func (o *ListVulnerabilitiesParams) WithPageSize(pageSize *int64) *ListVulnerabilitiesParams

WithPageSize adds the pageSize to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithQ

WithQ adds the q to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithTimeout

WithTimeout adds the timeout to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithTuneCount

func (o *ListVulnerabilitiesParams) WithTuneCount(tuneCount *bool) *ListVulnerabilitiesParams

WithTuneCount adds the tuneCount to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithWithTag

func (o *ListVulnerabilitiesParams) WithWithTag(withTag *bool) *ListVulnerabilitiesParams

WithWithTag adds the withTag to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WithXRequestID

func (o *ListVulnerabilitiesParams) WithXRequestID(xRequestID *string) *ListVulnerabilitiesParams

WithXRequestID adds the xRequestID to the list vulnerabilities params

func (*ListVulnerabilitiesParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type ListVulnerabilitiesReader

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

ListVulnerabilitiesReader is a Reader for the ListVulnerabilities structure.

func (*ListVulnerabilitiesReader) ReadResponse

func (o *ListVulnerabilitiesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type ListVulnerabilitiesUnauthorized

type ListVulnerabilitiesUnauthorized struct {
	/*The ID of the corresponding request for the response
	 */
	XRequestID string

	Payload *model.Errors
}

ListVulnerabilitiesUnauthorized handles this case with default header values.

Unauthorized

func NewListVulnerabilitiesUnauthorized

func NewListVulnerabilitiesUnauthorized() *ListVulnerabilitiesUnauthorized

NewListVulnerabilitiesUnauthorized creates a ListVulnerabilitiesUnauthorized with default headers values

func (*ListVulnerabilitiesUnauthorized) Error

func (*ListVulnerabilitiesUnauthorized) GetPayload

func (o *ListVulnerabilitiesUnauthorized) GetPayload() *model.Errors

Jump to

Keyboard shortcuts

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