websecurityscanner
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Overview¶
Package websecurityscanner provides access to the Web Security Scanner API.
For product documentation, see:https://cloud.google.com/security-command-center/docs/concepts-web-security-scanner-overview/
Library status¶
These client libraries are officially supported by Google. However, thislibrary is considered complete and is in maintenance mode. This meansthat we will address critical bugs and security issues but will not addany new features.
When possible, we recommend using our newer[Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)that are still actively being worked and iterated on.
Creating a client¶
Usage example:
import "google.golang.org/api/websecurityscanner/v1"...ctx := context.Background()websecurityscannerService, err := websecurityscanner.NewService(ctx)
In this example, Google Application Default Credentials are used forauthentication. For information on how to create and obtain ApplicationDefault Credentials, seehttps://developers.google.com/identity/protocols/application-default-credentials.
Other authentication options¶
To use an API key for authentication (note: some APIs do not support APIkeys), usegoogle.golang.org/api/option.WithAPIKey:
websecurityscannerService, err := websecurityscanner.NewService(ctx, option.WithAPIKey("AIza..."))To use an OAuth token (e.g., a user token obtained via a three-legged OAuthflow, usegoogle.golang.org/api/option.WithTokenSource:
config := &oauth2.Config{...}// ...token, err := config.Exchange(ctx, ...)websecurityscannerService, err := websecurityscanner.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))Seegoogle.golang.org/api/option.ClientOption for details on options.
Index¶
- Constants
- type Authentication
- type CrawledUrl
- type CustomAccount
- type Empty
- type Finding
- type FindingTypeStats
- type Form
- type GoogleAccount
- type Header
- type IapCredential
- type IapTestServiceAccountInfo
- type ListCrawledUrlsResponse
- type ListFindingTypeStatsResponse
- type ListFindingsResponse
- type ListScanConfigsResponse
- type ListScanRunsResponse
- type OutdatedLibrary
- type ProjectsScanConfigsCreateCall
- func (c *ProjectsScanConfigsCreateCall) Context(ctx context.Context) *ProjectsScanConfigsCreateCall
- func (c *ProjectsScanConfigsCreateCall) Do(opts ...googleapi.CallOption) (*ScanConfig, error)
- func (c *ProjectsScanConfigsCreateCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsCreateCall
- func (c *ProjectsScanConfigsCreateCall) Header() http.Header
- type ProjectsScanConfigsDeleteCall
- func (c *ProjectsScanConfigsDeleteCall) Context(ctx context.Context) *ProjectsScanConfigsDeleteCall
- func (c *ProjectsScanConfigsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error)
- func (c *ProjectsScanConfigsDeleteCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsDeleteCall
- func (c *ProjectsScanConfigsDeleteCall) Header() http.Header
- type ProjectsScanConfigsGetCall
- func (c *ProjectsScanConfigsGetCall) Context(ctx context.Context) *ProjectsScanConfigsGetCall
- func (c *ProjectsScanConfigsGetCall) Do(opts ...googleapi.CallOption) (*ScanConfig, error)
- func (c *ProjectsScanConfigsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsGetCall
- func (c *ProjectsScanConfigsGetCall) Header() http.Header
- func (c *ProjectsScanConfigsGetCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsGetCall
- type ProjectsScanConfigsListCall
- func (c *ProjectsScanConfigsListCall) Context(ctx context.Context) *ProjectsScanConfigsListCall
- func (c *ProjectsScanConfigsListCall) Do(opts ...googleapi.CallOption) (*ListScanConfigsResponse, error)
- func (c *ProjectsScanConfigsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsListCall
- func (c *ProjectsScanConfigsListCall) Header() http.Header
- func (c *ProjectsScanConfigsListCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsListCall
- func (c *ProjectsScanConfigsListCall) PageSize(pageSize int64) *ProjectsScanConfigsListCall
- func (c *ProjectsScanConfigsListCall) PageToken(pageToken string) *ProjectsScanConfigsListCall
- func (c *ProjectsScanConfigsListCall) Pages(ctx context.Context, f func(*ListScanConfigsResponse) error) error
- type ProjectsScanConfigsPatchCall
- func (c *ProjectsScanConfigsPatchCall) Context(ctx context.Context) *ProjectsScanConfigsPatchCall
- func (c *ProjectsScanConfigsPatchCall) Do(opts ...googleapi.CallOption) (*ScanConfig, error)
- func (c *ProjectsScanConfigsPatchCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsPatchCall
- func (c *ProjectsScanConfigsPatchCall) Header() http.Header
- func (c *ProjectsScanConfigsPatchCall) UpdateMask(updateMask string) *ProjectsScanConfigsPatchCall
- type ProjectsScanConfigsScanRunsCrawledUrlsListCall
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Do(opts ...googleapi.CallOption) (*ListCrawledUrlsResponse, error)
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Header() http.Header
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) PageSize(pageSize int64) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) PageToken(pageToken string) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
- func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Pages(ctx context.Context, f func(*ListCrawledUrlsResponse) error) error
- type ProjectsScanConfigsScanRunsCrawledUrlsService
- type ProjectsScanConfigsScanRunsFindingTypeStatsListCall
- func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
- func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Do(opts ...googleapi.CallOption) (*ListFindingTypeStatsResponse, error)
- func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
- func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Header() http.Header
- func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
- type ProjectsScanConfigsScanRunsFindingTypeStatsService
- type ProjectsScanConfigsScanRunsFindingsGetCall
- func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsFindingsGetCall
- func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Do(opts ...googleapi.CallOption) (*Finding, error)
- func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsFindingsGetCall
- func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Header() http.Header
- func (c *ProjectsScanConfigsScanRunsFindingsGetCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsScanRunsFindingsGetCall
- type ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) Do(opts ...googleapi.CallOption) (*ListFindingsResponse, error)
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) Filter(filter string) *ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) Header() http.Header
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) PageSize(pageSize int64) *ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) PageToken(pageToken string) *ProjectsScanConfigsScanRunsFindingsListCall
- func (c *ProjectsScanConfigsScanRunsFindingsListCall) Pages(ctx context.Context, f func(*ListFindingsResponse) error) error
- type ProjectsScanConfigsScanRunsFindingsService
- type ProjectsScanConfigsScanRunsGetCall
- func (c *ProjectsScanConfigsScanRunsGetCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsGetCall
- func (c *ProjectsScanConfigsScanRunsGetCall) Do(opts ...googleapi.CallOption) (*ScanRun, error)
- func (c *ProjectsScanConfigsScanRunsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsGetCall
- func (c *ProjectsScanConfigsScanRunsGetCall) Header() http.Header
- func (c *ProjectsScanConfigsScanRunsGetCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsScanRunsGetCall
- type ProjectsScanConfigsScanRunsListCall
- func (c *ProjectsScanConfigsScanRunsListCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsListCall
- func (c *ProjectsScanConfigsScanRunsListCall) Do(opts ...googleapi.CallOption) (*ListScanRunsResponse, error)
- func (c *ProjectsScanConfigsScanRunsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsListCall
- func (c *ProjectsScanConfigsScanRunsListCall) Header() http.Header
- func (c *ProjectsScanConfigsScanRunsListCall) IfNoneMatch(entityTag string) *ProjectsScanConfigsScanRunsListCall
- func (c *ProjectsScanConfigsScanRunsListCall) PageSize(pageSize int64) *ProjectsScanConfigsScanRunsListCall
- func (c *ProjectsScanConfigsScanRunsListCall) PageToken(pageToken string) *ProjectsScanConfigsScanRunsListCall
- func (c *ProjectsScanConfigsScanRunsListCall) Pages(ctx context.Context, f func(*ListScanRunsResponse) error) error
- type ProjectsScanConfigsScanRunsService
- func (r *ProjectsScanConfigsScanRunsService) Get(name string) *ProjectsScanConfigsScanRunsGetCall
- func (r *ProjectsScanConfigsScanRunsService) List(parent string) *ProjectsScanConfigsScanRunsListCall
- func (r *ProjectsScanConfigsScanRunsService) Stop(name string, stopscanrunrequest *StopScanRunRequest) *ProjectsScanConfigsScanRunsStopCall
- type ProjectsScanConfigsScanRunsStopCall
- func (c *ProjectsScanConfigsScanRunsStopCall) Context(ctx context.Context) *ProjectsScanConfigsScanRunsStopCall
- func (c *ProjectsScanConfigsScanRunsStopCall) Do(opts ...googleapi.CallOption) (*ScanRun, error)
- func (c *ProjectsScanConfigsScanRunsStopCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsStopCall
- func (c *ProjectsScanConfigsScanRunsStopCall) Header() http.Header
- type ProjectsScanConfigsService
- func (r *ProjectsScanConfigsService) Create(parent string, scanconfig *ScanConfig) *ProjectsScanConfigsCreateCall
- func (r *ProjectsScanConfigsService) Delete(name string) *ProjectsScanConfigsDeleteCall
- func (r *ProjectsScanConfigsService) Get(name string) *ProjectsScanConfigsGetCall
- func (r *ProjectsScanConfigsService) List(parent string) *ProjectsScanConfigsListCall
- func (r *ProjectsScanConfigsService) Patch(name string, scanconfig *ScanConfig) *ProjectsScanConfigsPatchCall
- func (r *ProjectsScanConfigsService) Start(name string, startscanrunrequest *StartScanRunRequest) *ProjectsScanConfigsStartCall
- type ProjectsScanConfigsStartCall
- func (c *ProjectsScanConfigsStartCall) Context(ctx context.Context) *ProjectsScanConfigsStartCall
- func (c *ProjectsScanConfigsStartCall) Do(opts ...googleapi.CallOption) (*ScanRun, error)
- func (c *ProjectsScanConfigsStartCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsStartCall
- func (c *ProjectsScanConfigsStartCall) Header() http.Header
- type ProjectsService
- type ScanConfig
- type ScanConfigError
- type ScanRun
- type ScanRunErrorTrace
- type ScanRunWarningTrace
- type Schedule
- type Service
- type StartScanRunRequest
- type StopScanRunRequest
- type ViolatingResource
- type VulnerableHeaders
- type VulnerableParameters
- type Xss
- type Xxe
Constants¶
const (// See, edit, configure, and delete your Google Cloud data and see the email// address for your Google Account.CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform")
OAuth2 scopes used by this API.
Variables¶
This section is empty.
Functions¶
This section is empty.
Types¶
typeAuthentication¶
type Authentication struct {// CustomAccount: Authentication using a custom account.CustomAccount *CustomAccount `json:"customAccount,omitempty"`// GoogleAccount: Authentication using a Google account.GoogleAccount *GoogleAccount `json:"googleAccount,omitempty"`// IapCredential: Authentication using Identity-Aware-Proxy (IAP).IapCredential *IapCredential `json:"iapCredential,omitempty"`// ForceSendFields is a list of field names (e.g. "CustomAccount") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CustomAccount") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Authentication: Scan authentication configuration.
func (Authentication)MarshalJSON¶
func (sAuthentication) MarshalJSON() ([]byte,error)
typeCrawledUrl¶
type CrawledUrl struct {// Body: Output only. The body of the request that was used to visit the URL.Bodystring `json:"body,omitempty"`// HttpMethod: Output only. The http method of the request that was used to// visit the URL, in uppercase.HttpMethodstring `json:"httpMethod,omitempty"`// Url: Output only. The URL that was crawled.Urlstring `json:"url,omitempty"`// ForceSendFields is a list of field names (e.g. "Body") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Body") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}CrawledUrl: A CrawledUrl resource represents a URL that was crawled during aScanRun. Web Security Scanner Service crawls the web applications, followingall links within the scope of sites, to find the URLs to test against.
func (CrawledUrl)MarshalJSON¶
func (sCrawledUrl) MarshalJSON() ([]byte,error)
typeCustomAccount¶
type CustomAccount struct {// LoginUrl: Required. The login form URL of the website.LoginUrlstring `json:"loginUrl,omitempty"`// Password: Required. Input only. The password of the custom account. The// credential is stored encrypted and not returned in any response nor included// in audit logs.Passwordstring `json:"password,omitempty"`// Username: Required. The user name of the custom account.Usernamestring `json:"username,omitempty"`// ForceSendFields is a list of field names (e.g. "LoginUrl") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "LoginUrl") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}CustomAccount: Describes authentication configuration that uses a customaccount.
func (CustomAccount)MarshalJSON¶
func (sCustomAccount) MarshalJSON() ([]byte,error)
typeEmpty¶
type Empty struct {// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`}Empty: A generic empty message that you can re-use to avoid definingduplicated empty messages in your APIs. A typical example is to use it asthe request or the response type of an API method. For instance: service Foo{ rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
typeFinding¶
type Finding struct {// Body: Output only. The body of the request that triggered the vulnerability.Bodystring `json:"body,omitempty"`// Description: Output only. The description of the vulnerability.Descriptionstring `json:"description,omitempty"`// FinalUrl: Output only. The URL where the browser lands when the// vulnerability is detected.FinalUrlstring `json:"finalUrl,omitempty"`// FindingType: Output only. The type of the Finding. Detailed and up-to-date// information on findings can be found here://https://cloud.google.com/security-command-center/docs/how-to-remediate-web-security-scanner-findingsFindingTypestring `json:"findingType,omitempty"`// Form: Output only. An addon containing information reported for a// vulnerability with an HTML form, if any.Form *Form `json:"form,omitempty"`// FrameUrl: Output only. If the vulnerability was originated from nested// IFrame, the immediate parent IFrame is reported.FrameUrlstring `json:"frameUrl,omitempty"`// FuzzedUrl: Output only. The URL produced by the server-side fuzzer and used// in the request that triggered the vulnerability.FuzzedUrlstring `json:"fuzzedUrl,omitempty"`// HttpMethod: Output only. The http method of the request that triggered the// vulnerability, in uppercase.HttpMethodstring `json:"httpMethod,omitempty"`// Name: Output only. The resource name of the Finding. The name follows the// format of// 'projects/{projectId}/scanConfigs/{scanConfigId}/scanruns/{scanRunId}/finding// s/{findingId}'. The finding IDs are generated by the system.Namestring `json:"name,omitempty"`// OutdatedLibrary: Output only. An addon containing information about outdated// libraries.OutdatedLibrary *OutdatedLibrary `json:"outdatedLibrary,omitempty"`// ReproductionUrl: Output only. The URL containing human-readable payload that// user can leverage to reproduce the vulnerability.ReproductionUrlstring `json:"reproductionUrl,omitempty"`// Severity: Output only. The severity level of the reported vulnerability.//// Possible values:// "SEVERITY_UNSPECIFIED" - No severity specified. The default value.// "CRITICAL" - Critical severity.// "HIGH" - High severity.// "MEDIUM" - Medium severity.// "LOW" - Low severity.Severitystring `json:"severity,omitempty"`// TrackingId: Output only. The tracking ID uniquely identifies a vulnerability// instance across multiple ScanRuns.TrackingIdstring `json:"trackingId,omitempty"`// ViolatingResource: Output only. An addon containing detailed information// regarding any resource causing the vulnerability such as JavaScript sources,// image, audio files, etc.ViolatingResource *ViolatingResource `json:"violatingResource,omitempty"`// VulnerableHeaders: Output only. An addon containing information about// vulnerable or missing HTTP headers.VulnerableHeaders *VulnerableHeaders `json:"vulnerableHeaders,omitempty"`// VulnerableParameters: Output only. An addon containing information about// request parameters which were found to be vulnerable.VulnerableParameters *VulnerableParameters `json:"vulnerableParameters,omitempty"`// Xss: Output only. An addon containing information reported for an XSS, if// any.Xss *Xss `json:"xss,omitempty"`// Xxe: Output only. An addon containing information reported for an XXE, if// any.Xxe *Xxe `json:"xxe,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Body") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Body") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Finding: A Finding resource represents a vulnerability instance identifiedduring a ScanRun.
func (Finding)MarshalJSON¶
typeFindingTypeStats¶
type FindingTypeStats struct {// FindingCount: Output only. The count of findings belonging to this finding// type.FindingCountint64 `json:"findingCount,omitempty"`// FindingType: Output only. The finding type associated with the stats.FindingTypestring `json:"findingType,omitempty"`// ForceSendFields is a list of field names (e.g. "FindingCount") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "FindingCount") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}FindingTypeStats: A FindingTypeStats resource represents stats regarding aspecific FindingType of Findings under a given ScanRun.
func (FindingTypeStats)MarshalJSON¶
func (sFindingTypeStats) MarshalJSON() ([]byte,error)
typeForm¶
type Form struct {// ActionUri: ! The URI where to send the form when it's submitted.ActionUristring `json:"actionUri,omitempty"`// Fields: ! The names of form fields related to the vulnerability.Fields []string `json:"fields,omitempty"`// ForceSendFields is a list of field names (e.g. "ActionUri") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActionUri") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Form: ! Information about a vulnerability with an HTML.
func (Form)MarshalJSON¶
typeGoogleAccount¶
type GoogleAccount struct {// Password: Required. Input only. The password of the Google account. The// credential is stored encrypted and not returned in any response nor included// in audit logs.Passwordstring `json:"password,omitempty"`// Username: Required. The user name of the Google account.Usernamestring `json:"username,omitempty"`// ForceSendFields is a list of field names (e.g. "Password") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Password") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GoogleAccount: Describes authentication configuration that uses a Googleaccount.
func (GoogleAccount)MarshalJSON¶
func (sGoogleAccount) MarshalJSON() ([]byte,error)
typeHeader¶
type Header struct {// Name: Header name.Namestring `json:"name,omitempty"`// Value: Header value.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "Name") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Name") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Header: Describes a HTTP Header.
func (Header)MarshalJSON¶
typeIapCredential¶added inv0.16.0
type IapCredential struct {// IapTestServiceAccountInfo: Authentication configuration when// Web-Security-Scanner service account is added in Identity-Aware-Proxy (IAP)// access policies.IapTestServiceAccountInfo *IapTestServiceAccountInfo `json:"iapTestServiceAccountInfo,omitempty"`// ForceSendFields is a list of field names (e.g. "IapTestServiceAccountInfo")// to unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "IapTestServiceAccountInfo") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}IapCredential: Describes authentication configuration forIdentity-Aware-Proxy (IAP).
func (IapCredential)MarshalJSON¶added inv0.16.0
func (sIapCredential) MarshalJSON() ([]byte,error)
typeIapTestServiceAccountInfo¶added inv0.16.0
type IapTestServiceAccountInfo struct {// TargetAudienceClientId: Required. Describes OAuth2 client id of resources// protected by Identity-Aware-Proxy (IAP).TargetAudienceClientIdstring `json:"targetAudienceClientId,omitempty"`// ForceSendFields is a list of field names (e.g. "TargetAudienceClientId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "TargetAudienceClientId") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}IapTestServiceAccountInfo: Describes authentication configuration whenWeb-Security-Scanner service account is added in Identity-Aware-Proxy (IAP)access policies.
func (IapTestServiceAccountInfo)MarshalJSON¶added inv0.16.0
func (sIapTestServiceAccountInfo) MarshalJSON() ([]byte,error)
typeListCrawledUrlsResponse¶
type ListCrawledUrlsResponse struct {// CrawledUrls: The list of CrawledUrls returned.CrawledUrls []*CrawledUrl `json:"crawledUrls,omitempty"`// NextPageToken: Token to retrieve the next page of results, or empty if there// are no more results in the list.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "CrawledUrls") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CrawledUrls") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListCrawledUrlsResponse: Response for the `ListCrawledUrls` method.
func (ListCrawledUrlsResponse)MarshalJSON¶
func (sListCrawledUrlsResponse) MarshalJSON() ([]byte,error)
typeListFindingTypeStatsResponse¶
type ListFindingTypeStatsResponse struct {// FindingTypeStats: The list of FindingTypeStats returned.FindingTypeStats []*FindingTypeStats `json:"findingTypeStats,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "FindingTypeStats") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "FindingTypeStats") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListFindingTypeStatsResponse: Response for the `ListFindingTypeStats`method.
func (ListFindingTypeStatsResponse)MarshalJSON¶
func (sListFindingTypeStatsResponse) MarshalJSON() ([]byte,error)
typeListFindingsResponse¶
type ListFindingsResponse struct {// Findings: The list of Findings returned.Findings []*Finding `json:"findings,omitempty"`// NextPageToken: Token to retrieve the next page of results, or empty if there// are no more results in the list.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Findings") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Findings") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListFindingsResponse: Response for the `ListFindings` method.
func (ListFindingsResponse)MarshalJSON¶
func (sListFindingsResponse) MarshalJSON() ([]byte,error)
typeListScanConfigsResponse¶
type ListScanConfigsResponse struct {// NextPageToken: Token to retrieve the next page of results, or empty if there// are no more results in the list.NextPageTokenstring `json:"nextPageToken,omitempty"`// ScanConfigs: The list of ScanConfigs returned.ScanConfigs []*ScanConfig `json:"scanConfigs,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "NextPageToken") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "NextPageToken") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListScanConfigsResponse: Response for the `ListScanConfigs` method.
func (ListScanConfigsResponse)MarshalJSON¶
func (sListScanConfigsResponse) MarshalJSON() ([]byte,error)
typeListScanRunsResponse¶
type ListScanRunsResponse struct {// NextPageToken: Token to retrieve the next page of results, or empty if there// are no more results in the list.NextPageTokenstring `json:"nextPageToken,omitempty"`// ScanRuns: The list of ScanRuns returned.ScanRuns []*ScanRun `json:"scanRuns,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "NextPageToken") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "NextPageToken") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListScanRunsResponse: Response for the `ListScanRuns` method.
func (ListScanRunsResponse)MarshalJSON¶
func (sListScanRunsResponse) MarshalJSON() ([]byte,error)
typeOutdatedLibrary¶
type OutdatedLibrary struct {// LearnMoreUrls: URLs to learn more information about the vulnerabilities in// the library.LearnMoreUrls []string `json:"learnMoreUrls,omitempty"`// LibraryName: The name of the outdated library.LibraryNamestring `json:"libraryName,omitempty"`// Version: The version number.Versionstring `json:"version,omitempty"`// ForceSendFields is a list of field names (e.g. "LearnMoreUrls") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "LearnMoreUrls") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}OutdatedLibrary: Information reported for an outdated library.
func (OutdatedLibrary)MarshalJSON¶
func (sOutdatedLibrary) MarshalJSON() ([]byte,error)
typeProjectsScanConfigsCreateCall¶
type ProjectsScanConfigsCreateCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsCreateCall)Context¶
func (c *ProjectsScanConfigsCreateCall) Context(ctxcontext.Context) *ProjectsScanConfigsCreateCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsCreateCall)Do¶
func (c *ProjectsScanConfigsCreateCall) Do(opts ...googleapi.CallOption) (*ScanConfig,error)
Do executes the "websecurityscanner.projects.scanConfigs.create" call.Any non-2xx status code is an error. Response headers are in either*ScanConfig.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsCreateCall)Fields¶
func (c *ProjectsScanConfigsCreateCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsCreateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsCreateCall)Header¶
func (c *ProjectsScanConfigsCreateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsScanConfigsDeleteCall¶
type ProjectsScanConfigsDeleteCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsDeleteCall)Context¶
func (c *ProjectsScanConfigsDeleteCall) Context(ctxcontext.Context) *ProjectsScanConfigsDeleteCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsDeleteCall)Do¶
func (c *ProjectsScanConfigsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty,error)
Do executes the "websecurityscanner.projects.scanConfigs.delete" call.Any non-2xx status code is an error. Response headers are in either*Empty.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsDeleteCall)Fields¶
func (c *ProjectsScanConfigsDeleteCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsDeleteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsDeleteCall)Header¶
func (c *ProjectsScanConfigsDeleteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsScanConfigsGetCall¶
type ProjectsScanConfigsGetCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsGetCall)Context¶
func (c *ProjectsScanConfigsGetCall) Context(ctxcontext.Context) *ProjectsScanConfigsGetCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsGetCall)Do¶
func (c *ProjectsScanConfigsGetCall) Do(opts ...googleapi.CallOption) (*ScanConfig,error)
Do executes the "websecurityscanner.projects.scanConfigs.get" call.Any non-2xx status code is an error. Response headers are in either*ScanConfig.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsGetCall)Fields¶
func (c *ProjectsScanConfigsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsGetCall)Header¶
func (c *ProjectsScanConfigsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsGetCall)IfNoneMatch¶
func (c *ProjectsScanConfigsGetCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeProjectsScanConfigsListCall¶
type ProjectsScanConfigsListCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsListCall)Context¶
func (c *ProjectsScanConfigsListCall) Context(ctxcontext.Context) *ProjectsScanConfigsListCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsListCall)Do¶
func (c *ProjectsScanConfigsListCall) Do(opts ...googleapi.CallOption) (*ListScanConfigsResponse,error)
Do executes the "websecurityscanner.projects.scanConfigs.list" call.Any non-2xx status code is an error. Response headers are in either*ListScanConfigsResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ProjectsScanConfigsListCall)Fields¶
func (c *ProjectsScanConfigsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsListCall)Header¶
func (c *ProjectsScanConfigsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsListCall)IfNoneMatch¶
func (c *ProjectsScanConfigsListCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*ProjectsScanConfigsListCall)PageSize¶
func (c *ProjectsScanConfigsListCall) PageSize(pageSizeint64) *ProjectsScanConfigsListCall
PageSize sets the optional parameter "pageSize": The maximum number ofScanConfigs to return, can be limited by server. If not specified or notpositive, the implementation will select a reasonable value.
func (*ProjectsScanConfigsListCall)PageToken¶
func (c *ProjectsScanConfigsListCall) PageToken(pageTokenstring) *ProjectsScanConfigsListCall
PageToken sets the optional parameter "pageToken": A token identifying apage of results to be returned. This should be a `next_page_token` valuereturned from a previous List request. If unspecified, the first page ofresults is returned.
func (*ProjectsScanConfigsListCall)Pages¶
func (c *ProjectsScanConfigsListCall) Pages(ctxcontext.Context, f func(*ListScanConfigsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeProjectsScanConfigsPatchCall¶
type ProjectsScanConfigsPatchCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsPatchCall)Context¶
func (c *ProjectsScanConfigsPatchCall) Context(ctxcontext.Context) *ProjectsScanConfigsPatchCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsPatchCall)Do¶
func (c *ProjectsScanConfigsPatchCall) Do(opts ...googleapi.CallOption) (*ScanConfig,error)
Do executes the "websecurityscanner.projects.scanConfigs.patch" call.Any non-2xx status code is an error. Response headers are in either*ScanConfig.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsPatchCall)Fields¶
func (c *ProjectsScanConfigsPatchCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsPatchCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsPatchCall)Header¶
func (c *ProjectsScanConfigsPatchCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsPatchCall)UpdateMask¶
func (c *ProjectsScanConfigsPatchCall) UpdateMask(updateMaskstring) *ProjectsScanConfigsPatchCall
UpdateMask sets the optional parameter "updateMask": Required. The updatemask applies to the resource. For the `FieldMask` definition, seehttps://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask
typeProjectsScanConfigsScanRunsCrawledUrlsListCall¶
type ProjectsScanConfigsScanRunsCrawledUrlsListCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)Context¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)Do¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Do(opts ...googleapi.CallOption) (*ListCrawledUrlsResponse,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.crawledUrls.list" call.Any non-2xx status code is an error. Response headers are in either*ListCrawledUrlsResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)Fields¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)Header¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)IfNoneMatch¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)PageSize¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) PageSize(pageSizeint64) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
PageSize sets the optional parameter "pageSize": The maximum number ofCrawledUrls to return, can be limited by server. If not specified or notpositive, the implementation will select a reasonable value.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)PageToken¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) PageToken(pageTokenstring) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
PageToken sets the optional parameter "pageToken": A token identifying apage of results to be returned. This should be a `next_page_token` valuereturned from a previous List request. If unspecified, the first page ofresults is returned.
func (*ProjectsScanConfigsScanRunsCrawledUrlsListCall)Pages¶
func (c *ProjectsScanConfigsScanRunsCrawledUrlsListCall) Pages(ctxcontext.Context, f func(*ListCrawledUrlsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeProjectsScanConfigsScanRunsCrawledUrlsService¶
type ProjectsScanConfigsScanRunsCrawledUrlsService struct {// contains filtered or unexported fields}funcNewProjectsScanConfigsScanRunsCrawledUrlsService¶
func NewProjectsScanConfigsScanRunsCrawledUrlsService(s *Service) *ProjectsScanConfigsScanRunsCrawledUrlsService
func (*ProjectsScanConfigsScanRunsCrawledUrlsService)List¶
func (r *ProjectsScanConfigsScanRunsCrawledUrlsService) List(parentstring) *ProjectsScanConfigsScanRunsCrawledUrlsListCall
List: List CrawledUrls under a given ScanRun.
- parent: The parent resource name, which should be a scan run resource namein the format'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'.
typeProjectsScanConfigsScanRunsFindingTypeStatsListCall¶
type ProjectsScanConfigsScanRunsFindingTypeStatsListCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsFindingTypeStatsListCall)Context¶
func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsFindingTypeStatsListCall)Do¶
func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Do(opts ...googleapi.CallOption) (*ListFindingTypeStatsResponse,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.findingTypeStats.list" call.Any non-2xx status code is an error. Response headers are in either*ListFindingTypeStatsResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ProjectsScanConfigsScanRunsFindingTypeStatsListCall)Fields¶
func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsFindingTypeStatsListCall)Header¶
func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsScanRunsFindingTypeStatsListCall)IfNoneMatch¶
func (c *ProjectsScanConfigsScanRunsFindingTypeStatsListCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeProjectsScanConfigsScanRunsFindingTypeStatsService¶
type ProjectsScanConfigsScanRunsFindingTypeStatsService struct {// contains filtered or unexported fields}funcNewProjectsScanConfigsScanRunsFindingTypeStatsService¶
func NewProjectsScanConfigsScanRunsFindingTypeStatsService(s *Service) *ProjectsScanConfigsScanRunsFindingTypeStatsService
func (*ProjectsScanConfigsScanRunsFindingTypeStatsService)List¶
func (r *ProjectsScanConfigsScanRunsFindingTypeStatsService) List(parentstring) *ProjectsScanConfigsScanRunsFindingTypeStatsListCall
List: List all FindingTypeStats under a given ScanRun.
- parent: The parent resource name, which should be a scan run resource namein the format'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'.
typeProjectsScanConfigsScanRunsFindingsGetCall¶
type ProjectsScanConfigsScanRunsFindingsGetCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsFindingsGetCall)Context¶
func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsFindingsGetCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsFindingsGetCall)Do¶
func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Do(opts ...googleapi.CallOption) (*Finding,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.findings.get" call.Any non-2xx status code is an error. Response headers are in either*Finding.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsScanRunsFindingsGetCall)Fields¶
func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsFindingsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsFindingsGetCall)Header¶
func (c *ProjectsScanConfigsScanRunsFindingsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsScanRunsFindingsGetCall)IfNoneMatch¶
func (c *ProjectsScanConfigsScanRunsFindingsGetCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsScanRunsFindingsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeProjectsScanConfigsScanRunsFindingsListCall¶
type ProjectsScanConfigsScanRunsFindingsListCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsFindingsListCall)Context¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsFindingsListCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsFindingsListCall)Do¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) Do(opts ...googleapi.CallOption) (*ListFindingsResponse,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.findings.list" call.Any non-2xx status code is an error. Response headers are in either*ListFindingsResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*ProjectsScanConfigsScanRunsFindingsListCall)Fields¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsFindingsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsFindingsListCall)Filter¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) Filter(filterstring) *ProjectsScanConfigsScanRunsFindingsListCall
Filter sets the optional parameter "filter": The filter expression. Theexpression must be in the format: . Supported field: 'finding_type'.Supported operator: '='.
func (*ProjectsScanConfigsScanRunsFindingsListCall)Header¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsScanRunsFindingsListCall)IfNoneMatch¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsScanRunsFindingsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*ProjectsScanConfigsScanRunsFindingsListCall)PageSize¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) PageSize(pageSizeint64) *ProjectsScanConfigsScanRunsFindingsListCall
PageSize sets the optional parameter "pageSize": The maximum number ofFindings to return, can be limited by server. If not specified or notpositive, the implementation will select a reasonable value.
func (*ProjectsScanConfigsScanRunsFindingsListCall)PageToken¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) PageToken(pageTokenstring) *ProjectsScanConfigsScanRunsFindingsListCall
PageToken sets the optional parameter "pageToken": A token identifying apage of results to be returned. This should be a `next_page_token` valuereturned from a previous List request. If unspecified, the first page ofresults is returned.
func (*ProjectsScanConfigsScanRunsFindingsListCall)Pages¶
func (c *ProjectsScanConfigsScanRunsFindingsListCall) Pages(ctxcontext.Context, f func(*ListFindingsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeProjectsScanConfigsScanRunsFindingsService¶
type ProjectsScanConfigsScanRunsFindingsService struct {// contains filtered or unexported fields}funcNewProjectsScanConfigsScanRunsFindingsService¶
func NewProjectsScanConfigsScanRunsFindingsService(s *Service) *ProjectsScanConfigsScanRunsFindingsService
func (*ProjectsScanConfigsScanRunsFindingsService)Get¶
func (r *ProjectsScanConfigsScanRunsFindingsService) Get(namestring) *ProjectsScanConfigsScanRunsFindingsGetCall
Get: Gets a Finding.
- name: The resource name of the Finding to be returned. The name followsthe format of'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}/findings/{findingId}'.
func (*ProjectsScanConfigsScanRunsFindingsService)List¶
func (r *ProjectsScanConfigsScanRunsFindingsService) List(parentstring) *ProjectsScanConfigsScanRunsFindingsListCall
List: List Findings under a given ScanRun.
- parent: The parent resource name, which should be a scan run resource namein the format'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'.
typeProjectsScanConfigsScanRunsGetCall¶
type ProjectsScanConfigsScanRunsGetCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsGetCall)Context¶
func (c *ProjectsScanConfigsScanRunsGetCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsGetCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsGetCall)Do¶
func (c *ProjectsScanConfigsScanRunsGetCall) Do(opts ...googleapi.CallOption) (*ScanRun,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.get" call.Any non-2xx status code is an error. Response headers are in either*ScanRun.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsScanRunsGetCall)Fields¶
func (c *ProjectsScanConfigsScanRunsGetCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsGetCall)Header¶
func (c *ProjectsScanConfigsScanRunsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsScanRunsGetCall)IfNoneMatch¶
func (c *ProjectsScanConfigsScanRunsGetCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsScanRunsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeProjectsScanConfigsScanRunsListCall¶
type ProjectsScanConfigsScanRunsListCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsListCall)Context¶
func (c *ProjectsScanConfigsScanRunsListCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsListCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsListCall)Do¶
func (c *ProjectsScanConfigsScanRunsListCall) Do(opts ...googleapi.CallOption) (*ListScanRunsResponse,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.list" call.Any non-2xx status code is an error. Response headers are in either*ListScanRunsResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*ProjectsScanConfigsScanRunsListCall)Fields¶
func (c *ProjectsScanConfigsScanRunsListCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsListCall)Header¶
func (c *ProjectsScanConfigsScanRunsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsScanConfigsScanRunsListCall)IfNoneMatch¶
func (c *ProjectsScanConfigsScanRunsListCall) IfNoneMatch(entityTagstring) *ProjectsScanConfigsScanRunsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*ProjectsScanConfigsScanRunsListCall)PageSize¶
func (c *ProjectsScanConfigsScanRunsListCall) PageSize(pageSizeint64) *ProjectsScanConfigsScanRunsListCall
PageSize sets the optional parameter "pageSize": The maximum number ofScanRuns to return, can be limited by server. If not specified or notpositive, the implementation will select a reasonable value.
func (*ProjectsScanConfigsScanRunsListCall)PageToken¶
func (c *ProjectsScanConfigsScanRunsListCall) PageToken(pageTokenstring) *ProjectsScanConfigsScanRunsListCall
PageToken sets the optional parameter "pageToken": A token identifying apage of results to be returned. This should be a `next_page_token` valuereturned from a previous List request. If unspecified, the first page ofresults is returned.
func (*ProjectsScanConfigsScanRunsListCall)Pages¶
func (c *ProjectsScanConfigsScanRunsListCall) Pages(ctxcontext.Context, f func(*ListScanRunsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeProjectsScanConfigsScanRunsService¶
type ProjectsScanConfigsScanRunsService struct {CrawledUrls *ProjectsScanConfigsScanRunsCrawledUrlsServiceFindingTypeStats *ProjectsScanConfigsScanRunsFindingTypeStatsServiceFindings *ProjectsScanConfigsScanRunsFindingsService// contains filtered or unexported fields}funcNewProjectsScanConfigsScanRunsService¶
func NewProjectsScanConfigsScanRunsService(s *Service) *ProjectsScanConfigsScanRunsService
func (*ProjectsScanConfigsScanRunsService)Get¶
func (r *ProjectsScanConfigsScanRunsService) Get(namestring) *ProjectsScanConfigsScanRunsGetCall
Get: Gets a ScanRun.
- name: The resource name of the ScanRun to be returned. The name followsthe format of'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'.
func (*ProjectsScanConfigsScanRunsService)List¶
func (r *ProjectsScanConfigsScanRunsService) List(parentstring) *ProjectsScanConfigsScanRunsListCall
List: Lists ScanRuns under a given ScanConfig, in descending order ofScanRun stop time.
- parent: The parent resource name, which should be a scan resource name inthe format 'projects/{projectId}/scanConfigs/{scanConfigId}'.
func (*ProjectsScanConfigsScanRunsService)Stop¶
func (r *ProjectsScanConfigsScanRunsService) Stop(namestring, stopscanrunrequest *StopScanRunRequest) *ProjectsScanConfigsScanRunsStopCall
Stop: Stops a ScanRun. The stopped ScanRun is returned.
- name: The resource name of the ScanRun to be stopped. The name follows theformat of'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'.
typeProjectsScanConfigsScanRunsStopCall¶
type ProjectsScanConfigsScanRunsStopCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsScanRunsStopCall)Context¶
func (c *ProjectsScanConfigsScanRunsStopCall) Context(ctxcontext.Context) *ProjectsScanConfigsScanRunsStopCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsScanRunsStopCall)Do¶
func (c *ProjectsScanConfigsScanRunsStopCall) Do(opts ...googleapi.CallOption) (*ScanRun,error)
Do executes the "websecurityscanner.projects.scanConfigs.scanRuns.stop" call.Any non-2xx status code is an error. Response headers are in either*ScanRun.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsScanRunsStopCall)Fields¶
func (c *ProjectsScanConfigsScanRunsStopCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsScanRunsStopCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsScanRunsStopCall)Header¶
func (c *ProjectsScanConfigsScanRunsStopCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsScanConfigsService¶
type ProjectsScanConfigsService struct {ScanRuns *ProjectsScanConfigsScanRunsService// contains filtered or unexported fields}funcNewProjectsScanConfigsService¶
func NewProjectsScanConfigsService(s *Service) *ProjectsScanConfigsService
func (*ProjectsScanConfigsService)Create¶
func (r *ProjectsScanConfigsService) Create(parentstring, scanconfig *ScanConfig) *ProjectsScanConfigsCreateCall
Create: Creates a new ScanConfig.
- parent: The parent resource name where the scan is created, which shouldbe a project resource name in the format 'projects/{projectId}'.
func (*ProjectsScanConfigsService)Delete¶
func (r *ProjectsScanConfigsService) Delete(namestring) *ProjectsScanConfigsDeleteCall
Delete: Deletes an existing ScanConfig and its child resources.
- name: The resource name of the ScanConfig to be deleted. The name followsthe format of 'projects/{projectId}/scanConfigs/{scanConfigId}'.
func (*ProjectsScanConfigsService)Get¶
func (r *ProjectsScanConfigsService) Get(namestring) *ProjectsScanConfigsGetCall
Get: Gets a ScanConfig.
- name: The resource name of the ScanConfig to be returned. The name followsthe format of 'projects/{projectId}/scanConfigs/{scanConfigId}'.
func (*ProjectsScanConfigsService)List¶
func (r *ProjectsScanConfigsService) List(parentstring) *ProjectsScanConfigsListCall
List: Lists ScanConfigs under a given project.
- parent: The parent resource name, which should be a project resource namein the format 'projects/{projectId}'.
func (*ProjectsScanConfigsService)Patch¶
func (r *ProjectsScanConfigsService) Patch(namestring, scanconfig *ScanConfig) *ProjectsScanConfigsPatchCall
Patch: Updates a ScanConfig. This method support partial update of aScanConfig.
- name: Identifier. The resource name of the ScanConfig. The name followsthe format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. TheScanConfig IDs are generated by the system.
func (*ProjectsScanConfigsService)Start¶
func (r *ProjectsScanConfigsService) Start(namestring, startscanrunrequest *StartScanRunRequest) *ProjectsScanConfigsStartCall
Start: Start a ScanRun according to the given ScanConfig.
- name: The resource name of the ScanConfig to be used. The name follows theformat of 'projects/{projectId}/scanConfigs/{scanConfigId}'.
typeProjectsScanConfigsStartCall¶
type ProjectsScanConfigsStartCall struct {// contains filtered or unexported fields}func (*ProjectsScanConfigsStartCall)Context¶
func (c *ProjectsScanConfigsStartCall) Context(ctxcontext.Context) *ProjectsScanConfigsStartCall
Context sets the context to be used in this call's Do method.
func (*ProjectsScanConfigsStartCall)Do¶
func (c *ProjectsScanConfigsStartCall) Do(opts ...googleapi.CallOption) (*ScanRun,error)
Do executes the "websecurityscanner.projects.scanConfigs.start" call.Any non-2xx status code is an error. Response headers are in either*ScanRun.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsScanConfigsStartCall)Fields¶
func (c *ProjectsScanConfigsStartCall) Fields(s ...googleapi.Field) *ProjectsScanConfigsStartCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsScanConfigsStartCall)Header¶
func (c *ProjectsScanConfigsStartCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsService¶
type ProjectsService struct {ScanConfigs *ProjectsScanConfigsService// contains filtered or unexported fields}funcNewProjectsService¶
func NewProjectsService(s *Service) *ProjectsService
typeScanConfig¶
type ScanConfig struct {// Authentication: The authentication configuration. If specified, service will// use the authentication configuration during scanning.Authentication *Authentication `json:"authentication,omitempty"`// BlacklistPatterns: The excluded URL patterns as described in//https://cloud.google.com/security-command-center/docs/how-to-use-web-security-scanner#excluding_urlsBlacklistPatterns []string `json:"blacklistPatterns,omitempty"`// DisplayName: Required. The user provided display name of the ScanConfig.DisplayNamestring `json:"displayName,omitempty"`// ExportToSecurityCommandCenter: Controls export of scan configurations and// results to Security Command Center.//// Possible values:// "EXPORT_TO_SECURITY_COMMAND_CENTER_UNSPECIFIED" - Use default, which is// ENABLED.// "ENABLED" - Export results of this scan to Security Command Center.// "DISABLED" - Do not export results of this scan to Security Command// Center.ExportToSecurityCommandCenterstring `json:"exportToSecurityCommandCenter,omitempty"`// IgnoreHttpStatusErrors: Whether to keep scanning even if most requests// return HTTP error codes.IgnoreHttpStatusErrorsbool `json:"ignoreHttpStatusErrors,omitempty"`LatestRun *ScanRun `json:"latestRun,omitempty"`// ManagedScan: Whether the scan config is managed by Web Security Scanner,// output only.ManagedScanbool `json:"managedScan,omitempty"`// MaxQps: The maximum QPS during scanning. A valid value ranges from 5 to 20// inclusively. If the field is unspecified or its value is set 0, server will// default to 15. Other values outside of [5, 20] range will be rejected with// INVALID_ARGUMENT error.MaxQpsint64 `json:"maxQps,omitempty"`// Name: Identifier. The resource name of the ScanConfig. The name follows the// format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. The ScanConfig// IDs are generated by the system.Namestring `json:"name,omitempty"`// RiskLevel: The risk level selected for the scan//// Possible values:// "RISK_LEVEL_UNSPECIFIED" - Use default, which is NORMAL.// "NORMAL" - Normal scanning (Recommended)// "LOW" - Lower impact scanningRiskLevelstring `json:"riskLevel,omitempty"`// Schedule: The schedule of the ScanConfig.Schedule *Schedule `json:"schedule,omitempty"`// StartingUrls: Required. The starting URLs from which the scanner finds site// pages.StartingUrls []string `json:"startingUrls,omitempty"`// StaticIpScan: Whether the scan configuration has enabled static IP address// scan feature. If enabled, the scanner will access applications from static// IP addresses.StaticIpScanbool `json:"staticIpScan,omitempty"`// TargetPlatforms: Set of Google Cloud platforms targeted by the scan. If// empty, APP_ENGINE will be used as a default.//// Possible values:// "TARGET_PLATFORM_UNSPECIFIED" - The target platform is unknown. Requests// with this enum value will be rejected with INVALID_ARGUMENT error.// "APP_ENGINE" - Google App Engine service.// "COMPUTE" - Google Compute Engine service.// "CLOUD_RUN" - Google Cloud Run service.// "CLOUD_FUNCTIONS" - Google Cloud Function service.TargetPlatforms []string `json:"targetPlatforms,omitempty"`// UserAgent: The user agent used during scanning.//// Possible values:// "USER_AGENT_UNSPECIFIED" - The user agent is unknown. Service will default// to CHROME_LINUX.// "CHROME_LINUX" - Chrome on Linux. This is the service default if// unspecified.// "CHROME_ANDROID" - Chrome on Android.// "SAFARI_IPHONE" - Safari on IPhone.UserAgentstring `json:"userAgent,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Authentication") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Authentication") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ScanConfig: A ScanConfig resource contains the configurations to launch ascan.
func (ScanConfig)MarshalJSON¶
func (sScanConfig) MarshalJSON() ([]byte,error)
typeScanConfigError¶
type ScanConfigError struct {// Code: Output only. Indicates the reason code for a configuration failure.//// Possible values:// "CODE_UNSPECIFIED" - There is no error.// "OK" - There is no error.// "INTERNAL_ERROR" - Indicates an internal server error. Please DO NOT USE// THIS ERROR CODE unless the root cause is truly unknown.// "APPENGINE_API_BACKEND_ERROR" - One of the seed URLs is an App Engine URL// but we cannot validate the scan settings due to an App Engine API backend// error.// "APPENGINE_API_NOT_ACCESSIBLE" - One of the seed URLs is an App Engine URL// but we cannot access the App Engine API to validate scan settings.// "APPENGINE_DEFAULT_HOST_MISSING" - One of the seed URLs is an App Engine// URL but the Default Host of the App Engine is not set.// "CANNOT_USE_GOOGLE_COM_ACCOUNT" - Google corporate accounts can not be// used for scanning.// "CANNOT_USE_OWNER_ACCOUNT" - The account of the scan creator can not be// used for scanning.// "COMPUTE_API_BACKEND_ERROR" - This scan targets Compute Engine, but we// cannot validate scan settings due to a Compute Engine API backend error.// "COMPUTE_API_NOT_ACCESSIBLE" - This scan targets Compute Engine, but we// cannot access the Compute Engine API to validate the scan settings.// "CUSTOM_LOGIN_URL_DOES_NOT_BELONG_TO_CURRENT_PROJECT" - The Custom Login// URL does not belong to the current project.// "CUSTOM_LOGIN_URL_MALFORMED" - The Custom Login URL is malformed (can not// be parsed).// "CUSTOM_LOGIN_URL_MAPPED_TO_NON_ROUTABLE_ADDRESS" - The Custom Login URL// is mapped to a non-routable IP address in DNS.// "CUSTOM_LOGIN_URL_MAPPED_TO_UNRESERVED_ADDRESS" - The Custom Login URL is// mapped to an IP address which is not reserved for the current project.// "CUSTOM_LOGIN_URL_HAS_NON_ROUTABLE_IP_ADDRESS" - The Custom Login URL has// a non-routable IP address.// "CUSTOM_LOGIN_URL_HAS_UNRESERVED_IP_ADDRESS" - The Custom Login URL has an// IP address which is not reserved for the current project.// "DUPLICATE_SCAN_NAME" - Another scan with the same name (case-sensitive)// already exists.// "INVALID_FIELD_VALUE" - A field is set to an invalid value.// "FAILED_TO_AUTHENTICATE_TO_TARGET" - There was an error trying to// authenticate to the scan target.// "FINDING_TYPE_UNSPECIFIED" - Finding type value is not specified in the// list findings request.// "FORBIDDEN_TO_SCAN_COMPUTE" - Scan targets Compute Engine, yet current// project was not whitelisted for Google Compute Engine Scanning Alpha access.// "FORBIDDEN_UPDATE_TO_MANAGED_SCAN" - User tries to update managed scan// "MALFORMED_FILTER" - The supplied filter is malformed. For example, it can// not be parsed, does not have a filter type in expression, or the same filter// type appears more than once.// "MALFORMED_RESOURCE_NAME" - The supplied resource name is malformed (can// not be parsed).// "PROJECT_INACTIVE" - The current project is not in an active state.// "REQUIRED_FIELD" - A required field is not set.// "RESOURCE_NAME_INCONSISTENT" - Project id, scanconfig id, scanrun id, or// finding id are not consistent with each other in resource name.// "SCAN_ALREADY_RUNNING" - The scan being requested to start is already// running.// "SCAN_NOT_RUNNING" - The scan that was requested to be stopped is not// running.// "SEED_URL_DOES_NOT_BELONG_TO_CURRENT_PROJECT" - One of the seed URLs does// not belong to the current project.// "SEED_URL_MALFORMED" - One of the seed URLs is malformed (can not be// parsed).// "SEED_URL_MAPPED_TO_NON_ROUTABLE_ADDRESS" - One of the seed URLs is mapped// to a non-routable IP address in DNS.// "SEED_URL_MAPPED_TO_UNRESERVED_ADDRESS" - One of the seed URLs is mapped// to an IP address which is not reserved for the current project.// "SEED_URL_HAS_NON_ROUTABLE_IP_ADDRESS" - One of the seed URLs has// on-routable IP address.// "SEED_URL_HAS_UNRESERVED_IP_ADDRESS" - One of the seed URLs has an IP// address that is not reserved for the current project.// "SERVICE_ACCOUNT_NOT_CONFIGURED" - The Web Security Scanner service// account is not configured under the project.// "TOO_MANY_SCANS" - A project has reached the maximum number of scans.// "UNABLE_TO_RESOLVE_PROJECT_INFO" - Resolving the details of the current// project fails.// "UNSUPPORTED_BLACKLIST_PATTERN_FORMAT" - One or more blacklist patterns// were in the wrong format.// "UNSUPPORTED_FILTER" - The supplied filter is not supported.// "UNSUPPORTED_FINDING_TYPE" - The supplied finding type is not supported.// For example, we do not provide findings of the given finding type.// "UNSUPPORTED_URL_SCHEME" - The URL scheme of one or more of the supplied// URLs is not supported.// "CLOUD_ASSET_INVENTORY_ASSET_NOT_FOUND" - CAI is not able to list assets.Codestring `json:"code,omitempty"`// FieldName: Output only. Indicates the full name of the ScanConfig field that// triggers this error, for example "scan_config.max_qps". This field is// provided for troubleshooting purposes only and its actual value can change// in the future.FieldNamestring `json:"fieldName,omitempty"`// ForceSendFields is a list of field names (e.g. "Code") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Code") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ScanConfigError: Defines a custom error message used by CreateScanConfig andUpdateScanConfig APIs when scan configuration validation fails. It is alsoreported as part of a ScanRunErrorTrace message if scan validation fails dueto a scan configuration error.
func (ScanConfigError)MarshalJSON¶
func (sScanConfigError) MarshalJSON() ([]byte,error)
typeScanRun¶
type ScanRun struct {// EndTime: Output only. The time at which the ScanRun reached termination// state - that the ScanRun is either finished or stopped by user.EndTimestring `json:"endTime,omitempty"`// ErrorTrace: Output only. If result_state is an ERROR, this field provides// the primary reason for scan's termination and more details, if such are// available.ErrorTrace *ScanRunErrorTrace `json:"errorTrace,omitempty"`// ExecutionState: Output only. The execution state of the ScanRun.//// Possible values:// "EXECUTION_STATE_UNSPECIFIED" - Represents an invalid state caused by// internal server error. This value should never be returned.// "QUEUED" - The scan is waiting in the queue.// "SCANNING" - The scan is in progress.// "FINISHED" - The scan is either finished or stopped by user.ExecutionStatestring `json:"executionState,omitempty"`// HasVulnerabilities: Output only. Whether the scan run has found any// vulnerabilities.HasVulnerabilitiesbool `json:"hasVulnerabilities,omitempty"`// Name: Output only. The resource name of the ScanRun. The name follows the// format of// 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. The// ScanRun IDs are generated by the system.Namestring `json:"name,omitempty"`// ProgressPercent: Output only. The percentage of total completion ranging// from 0 to 100. If the scan is in queue, the value is 0. If the scan is// running, the value ranges from 0 to 100. If the scan is finished, the value// is 100.ProgressPercentint64 `json:"progressPercent,omitempty"`// ResultState: Output only. The result state of the ScanRun. This field is// only available after the execution state reaches "FINISHED".//// Possible values:// "RESULT_STATE_UNSPECIFIED" - Default value. This value is returned when// the ScanRun is not yet finished.// "SUCCESS" - The scan finished without errors.// "ERROR" - The scan finished with errors.// "KILLED" - The scan was terminated by user.ResultStatestring `json:"resultState,omitempty"`// StartTime: Output only. The time at which the ScanRun started.StartTimestring `json:"startTime,omitempty"`// UrlsCrawledCount: Output only. The number of URLs crawled during this// ScanRun. If the scan is in progress, the value represents the number of URLs// crawled up to now.UrlsCrawledCountint64 `json:"urlsCrawledCount,omitempty,string"`// UrlsTestedCount: Output only. The number of URLs tested during this ScanRun.// If the scan is in progress, the value represents the number of URLs tested// up to now. The number of URLs tested is usually larger than the number URLS// crawled because typically a crawled URL is tested with multiple test// payloads.UrlsTestedCountint64 `json:"urlsTestedCount,omitempty,string"`// WarningTraces: Output only. A list of warnings, if such are encountered// during this scan run.WarningTraces []*ScanRunWarningTrace `json:"warningTraces,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EndTime") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ScanRun: A ScanRun is a output-only resource representing an actual run ofthe scan. Next id: 12
func (ScanRun)MarshalJSON¶
typeScanRunErrorTrace¶
type ScanRunErrorTrace struct {// Code: Output only. Indicates the error reason code.//// Possible values:// "CODE_UNSPECIFIED" - Default value is never used.// "INTERNAL_ERROR" - Indicates that the scan run failed due to an internal// server error.// "SCAN_CONFIG_ISSUE" - Indicates a scan configuration error, usually due to// outdated ScanConfig settings, such as starting_urls or the DNS// configuration.// "AUTHENTICATION_CONFIG_ISSUE" - Indicates an authentication error, usually// due to outdated ScanConfig authentication settings.// "TIMED_OUT_WHILE_SCANNING" - Indicates a scan operation timeout, usually// caused by a very large site.// "TOO_MANY_REDIRECTS" - Indicates that a scan encountered excessive// redirects, either to authentication or some other page outside of the scan// scope.// "TOO_MANY_HTTP_ERRORS" - Indicates that a scan encountered numerous errors// from the web site pages. When available, most_common_http_error_code field// indicates the most common HTTP error code encountered during the scan.// "STARTING_URLS_CRAWL_HTTP_ERRORS" - Indicates that some of the starting// web urls returned HTTP errors during the scan.Codestring `json:"code,omitempty"`// MostCommonHttpErrorCode: Output only. If the scan encounters// TOO_MANY_HTTP_ERRORS, this field indicates the most common HTTP error code,// if such is available. For example, if this code is 404, the scan has// encountered too many NOT_FOUND responses.MostCommonHttpErrorCodeint64 `json:"mostCommonHttpErrorCode,omitempty"`// ScanConfigError: Output only. If the scan encounters SCAN_CONFIG_ISSUE// error, this field has the error message encountered during scan// configuration validation that is performed before each scan run.ScanConfigError *ScanConfigError `json:"scanConfigError,omitempty"`// ForceSendFields is a list of field names (e.g. "Code") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Code") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ScanRunErrorTrace: Output only. Defines an error trace message for aScanRun.
func (ScanRunErrorTrace)MarshalJSON¶
func (sScanRunErrorTrace) MarshalJSON() ([]byte,error)
typeScanRunWarningTrace¶
type ScanRunWarningTrace struct {// Code: Output only. Indicates the warning code.//// Possible values:// "CODE_UNSPECIFIED" - Default value is never used.// "INSUFFICIENT_CRAWL_RESULTS" - Indicates that a scan discovered an// unexpectedly low number of URLs. This is sometimes caused by complex// navigation features or by using a single URL for numerous pages.// "TOO_MANY_CRAWL_RESULTS" - Indicates that a scan discovered too many URLs// to test, or excessive redundant URLs.// "TOO_MANY_FUZZ_TASKS" - Indicates that too many tests have been generated// for the scan. Customer should try reducing the number of starting URLs,// increasing the QPS rate, or narrowing down the scope of the scan using the// excluded patterns.// "BLOCKED_BY_IAP" - Indicates that a scan is blocked by IAP.// "NO_STARTING_URL_FOUND_FOR_MANAGED_SCAN" - Indicates that no seeds is// found for a scanCodestring `json:"code,omitempty"`// ForceSendFields is a list of field names (e.g. "Code") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Code") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ScanRunWarningTrace: Output only. Defines a warning trace message forScanRun. Warning traces provide customers with useful information that helpsmake the scanning process more effective.
func (ScanRunWarningTrace)MarshalJSON¶
func (sScanRunWarningTrace) MarshalJSON() ([]byte,error)
typeSchedule¶
type Schedule struct {// IntervalDurationDays: Required. The duration of time between executions in// days.IntervalDurationDaysint64 `json:"intervalDurationDays,omitempty"`// ScheduleTime: A timestamp indicates when the next run will be scheduled. The// value is refreshed by the server after each run. If unspecified, it will// default to current server time, which means the scan will be scheduled to// start immediately.ScheduleTimestring `json:"scheduleTime,omitempty"`// ForceSendFields is a list of field names (e.g. "IntervalDurationDays") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "IntervalDurationDays") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Schedule: Scan schedule configuration.
func (Schedule)MarshalJSON¶
typeService¶
type Service struct {BasePathstring// API endpoint base URLUserAgentstring// optional additional User-Agent fragmentProjects *ProjectsService// contains filtered or unexported fields} funcNewdeprecated
New creates a new Service. It uses the provided http.Client for requests.
Deprecated: please use NewService instead.To provide a custom HTTP client, use option.WithHTTPClient.If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
funcNewService¶
NewService creates a new Service.
typeStartScanRunRequest¶
type StartScanRunRequest struct {}StartScanRunRequest: Request for the `StartScanRun` method.
typeStopScanRunRequest¶
type StopScanRunRequest struct {}StopScanRunRequest: Request for the `StopScanRun` method.
typeViolatingResource¶
type ViolatingResource struct {// ContentType: The MIME type of this resource.ContentTypestring `json:"contentType,omitempty"`// ResourceUrl: URL of this violating resource.ResourceUrlstring `json:"resourceUrl,omitempty"`// ForceSendFields is a list of field names (e.g. "ContentType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ContentType") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ViolatingResource: Information regarding any resource causing thevulnerability such as JavaScript sources, image, audio files, etc.
func (ViolatingResource)MarshalJSON¶
func (sViolatingResource) MarshalJSON() ([]byte,error)
typeVulnerableHeaders¶
type VulnerableHeaders struct {// Headers: List of vulnerable headers.Headers []*Header `json:"headers,omitempty"`// MissingHeaders: List of missing headers.MissingHeaders []*Header `json:"missingHeaders,omitempty"`// ForceSendFields is a list of field names (e.g. "Headers") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Headers") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}VulnerableHeaders: Information about vulnerable or missing HTTP Headers.
func (VulnerableHeaders)MarshalJSON¶
func (sVulnerableHeaders) MarshalJSON() ([]byte,error)
typeVulnerableParameters¶
type VulnerableParameters struct {// ParameterNames: The vulnerable parameter names.ParameterNames []string `json:"parameterNames,omitempty"`// ForceSendFields is a list of field names (e.g. "ParameterNames") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ParameterNames") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}VulnerableParameters: Information about vulnerable request parameters.
func (VulnerableParameters)MarshalJSON¶
func (sVulnerableParameters) MarshalJSON() ([]byte,error)
typeXss¶
type Xss struct {// AttackVector: The attack vector of the payload triggering this XSS.//// Possible values:// "ATTACK_VECTOR_UNSPECIFIED" - Unknown attack vector.// "LOCAL_STORAGE" - The attack comes from fuzzing the browser's// localStorage.// "SESSION_STORAGE" - The attack comes from fuzzing the browser's// sessionStorage.// "WINDOW_NAME" - The attack comes from fuzzing the window's name property.// "REFERRER" - The attack comes from fuzzing the referrer property.// "FORM_INPUT" - The attack comes from fuzzing an input element.// "COOKIE" - The attack comes from fuzzing the browser's cookies.// "POST_MESSAGE" - The attack comes from hijacking the post messaging// mechanism.// "GET_PARAMETERS" - The attack comes from fuzzing parameters in the url.// "URL_FRAGMENT" - The attack comes from fuzzing the fragment in the url.// "HTML_COMMENT" - The attack comes from fuzzing the HTML comments.// "POST_PARAMETERS" - The attack comes from fuzzing the POST parameters.// "PROTOCOL" - The attack comes from fuzzing the protocol.// "STORED_XSS" - The attack comes from the server side and is stored.// "SAME_ORIGIN" - The attack is a Same-Origin Method Execution attack via a// GET parameter.// "USER_CONTROLLABLE_URL" - The attack payload is received from a// third-party host via a URL that is user-controllableAttackVectorstring `json:"attackVector,omitempty"`// ErrorMessage: An error message generated by a javascript breakage.ErrorMessagestring `json:"errorMessage,omitempty"`// StackTraces: Stack traces leading to the point where the XSS occurred.StackTraces []string `json:"stackTraces,omitempty"`// StoredXssSeedingUrl: The reproduction url for the seeding POST request of a// Stored XSS.StoredXssSeedingUrlstring `json:"storedXssSeedingUrl,omitempty"`// ForceSendFields is a list of field names (e.g. "AttackVector") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AttackVector") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Xss: Information reported for an XSS.
func (Xss)MarshalJSON¶
typeXxe¶added inv0.63.0
type Xxe struct {// PayloadLocation: Location within the request where the payload was placed.//// Possible values:// "LOCATION_UNSPECIFIED" - Unknown Location.// "COMPLETE_REQUEST_BODY" - The XML payload replaced the complete request// body.PayloadLocationstring `json:"payloadLocation,omitempty"`// PayloadValue: The XML string that triggered the XXE vulnerability.// Non-payload values might be redacted.PayloadValuestring `json:"payloadValue,omitempty"`// ForceSendFields is a list of field names (e.g. "PayloadLocation") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "PayloadLocation") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Xxe: Information reported for an XXE.