google-apis-websecurityscanner_v1alpha 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.yardopts +13 -0
- data/CHANGELOG.md +7 -0
- data/LICENSE.md +202 -0
- data/OVERVIEW.md +96 -0
- data/lib/google-apis-websecurityscanner_v1alpha.rb +15 -0
- data/lib/google/apis/websecurityscanner_v1alpha.rb +36 -0
- data/lib/google/apis/websecurityscanner_v1alpha/classes.rb +784 -0
- data/lib/google/apis/websecurityscanner_v1alpha/gem_version.rb +28 -0
- data/lib/google/apis/websecurityscanner_v1alpha/representations.rb +388 -0
- data/lib/google/apis/websecurityscanner_v1alpha/service.rb +529 -0
- metadata +76 -0
@@ -0,0 +1,28 @@
|
|
1
|
+
# Copyright 2020 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
module Google
|
16
|
+
module Apis
|
17
|
+
module WebsecurityscannerV1alpha
|
18
|
+
# Version of the google-apis-websecurityscanner_v1alpha gem
|
19
|
+
GEM_VERSION = "0.1.0"
|
20
|
+
|
21
|
+
# Version of the code generator used to generate this client
|
22
|
+
GENERATOR_VERSION = "0.1.1"
|
23
|
+
|
24
|
+
# Revision of the discovery document this client was generated from
|
25
|
+
REVISION = "20200826"
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,388 @@
|
|
1
|
+
# Copyright 2020 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'date'
|
16
|
+
require 'google/apis/core/base_service'
|
17
|
+
require 'google/apis/core/json_representation'
|
18
|
+
require 'google/apis/core/hashable'
|
19
|
+
require 'google/apis/errors'
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Apis
|
23
|
+
module WebsecurityscannerV1alpha
|
24
|
+
|
25
|
+
class Authentication
|
26
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
27
|
+
|
28
|
+
include Google::Apis::Core::JsonObjectSupport
|
29
|
+
end
|
30
|
+
|
31
|
+
class CrawledUrl
|
32
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
33
|
+
|
34
|
+
include Google::Apis::Core::JsonObjectSupport
|
35
|
+
end
|
36
|
+
|
37
|
+
class CustomAccount
|
38
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
39
|
+
|
40
|
+
include Google::Apis::Core::JsonObjectSupport
|
41
|
+
end
|
42
|
+
|
43
|
+
class Empty
|
44
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
45
|
+
|
46
|
+
include Google::Apis::Core::JsonObjectSupport
|
47
|
+
end
|
48
|
+
|
49
|
+
class Finding
|
50
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
51
|
+
|
52
|
+
include Google::Apis::Core::JsonObjectSupport
|
53
|
+
end
|
54
|
+
|
55
|
+
class FindingTypeStats
|
56
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
57
|
+
|
58
|
+
include Google::Apis::Core::JsonObjectSupport
|
59
|
+
end
|
60
|
+
|
61
|
+
class GoogleAccount
|
62
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
63
|
+
|
64
|
+
include Google::Apis::Core::JsonObjectSupport
|
65
|
+
end
|
66
|
+
|
67
|
+
class Header
|
68
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
69
|
+
|
70
|
+
include Google::Apis::Core::JsonObjectSupport
|
71
|
+
end
|
72
|
+
|
73
|
+
class ListCrawledUrlsResponse
|
74
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
75
|
+
|
76
|
+
include Google::Apis::Core::JsonObjectSupport
|
77
|
+
end
|
78
|
+
|
79
|
+
class ListFindingTypeStatsResponse
|
80
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
81
|
+
|
82
|
+
include Google::Apis::Core::JsonObjectSupport
|
83
|
+
end
|
84
|
+
|
85
|
+
class ListFindingsResponse
|
86
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
87
|
+
|
88
|
+
include Google::Apis::Core::JsonObjectSupport
|
89
|
+
end
|
90
|
+
|
91
|
+
class ListScanConfigsResponse
|
92
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
93
|
+
|
94
|
+
include Google::Apis::Core::JsonObjectSupport
|
95
|
+
end
|
96
|
+
|
97
|
+
class ListScanRunsResponse
|
98
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
99
|
+
|
100
|
+
include Google::Apis::Core::JsonObjectSupport
|
101
|
+
end
|
102
|
+
|
103
|
+
class OutdatedLibrary
|
104
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
105
|
+
|
106
|
+
include Google::Apis::Core::JsonObjectSupport
|
107
|
+
end
|
108
|
+
|
109
|
+
class ScanConfig
|
110
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
111
|
+
|
112
|
+
include Google::Apis::Core::JsonObjectSupport
|
113
|
+
end
|
114
|
+
|
115
|
+
class ScanRun
|
116
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
117
|
+
|
118
|
+
include Google::Apis::Core::JsonObjectSupport
|
119
|
+
end
|
120
|
+
|
121
|
+
class Schedule
|
122
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
123
|
+
|
124
|
+
include Google::Apis::Core::JsonObjectSupport
|
125
|
+
end
|
126
|
+
|
127
|
+
class StartScanRunRequest
|
128
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
129
|
+
|
130
|
+
include Google::Apis::Core::JsonObjectSupport
|
131
|
+
end
|
132
|
+
|
133
|
+
class StopScanRunRequest
|
134
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
135
|
+
|
136
|
+
include Google::Apis::Core::JsonObjectSupport
|
137
|
+
end
|
138
|
+
|
139
|
+
class ViolatingResource
|
140
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
141
|
+
|
142
|
+
include Google::Apis::Core::JsonObjectSupport
|
143
|
+
end
|
144
|
+
|
145
|
+
class VulnerableHeaders
|
146
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
147
|
+
|
148
|
+
include Google::Apis::Core::JsonObjectSupport
|
149
|
+
end
|
150
|
+
|
151
|
+
class VulnerableParameters
|
152
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
153
|
+
|
154
|
+
include Google::Apis::Core::JsonObjectSupport
|
155
|
+
end
|
156
|
+
|
157
|
+
class Xss
|
158
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
159
|
+
|
160
|
+
include Google::Apis::Core::JsonObjectSupport
|
161
|
+
end
|
162
|
+
|
163
|
+
class Authentication
|
164
|
+
# @private
|
165
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
166
|
+
property :custom_account, as: 'customAccount', class: Google::Apis::WebsecurityscannerV1alpha::CustomAccount, decorator: Google::Apis::WebsecurityscannerV1alpha::CustomAccount::Representation
|
167
|
+
|
168
|
+
property :google_account, as: 'googleAccount', class: Google::Apis::WebsecurityscannerV1alpha::GoogleAccount, decorator: Google::Apis::WebsecurityscannerV1alpha::GoogleAccount::Representation
|
169
|
+
|
170
|
+
end
|
171
|
+
end
|
172
|
+
|
173
|
+
class CrawledUrl
|
174
|
+
# @private
|
175
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
176
|
+
property :body, as: 'body'
|
177
|
+
property :http_method, as: 'httpMethod'
|
178
|
+
property :url, as: 'url'
|
179
|
+
end
|
180
|
+
end
|
181
|
+
|
182
|
+
class CustomAccount
|
183
|
+
# @private
|
184
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
185
|
+
property :login_url, as: 'loginUrl'
|
186
|
+
property :password, as: 'password'
|
187
|
+
property :username, as: 'username'
|
188
|
+
end
|
189
|
+
end
|
190
|
+
|
191
|
+
class Empty
|
192
|
+
# @private
|
193
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
194
|
+
end
|
195
|
+
end
|
196
|
+
|
197
|
+
class Finding
|
198
|
+
# @private
|
199
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
200
|
+
property :body, as: 'body'
|
201
|
+
property :description, as: 'description'
|
202
|
+
property :final_url, as: 'finalUrl'
|
203
|
+
property :finding_type, as: 'findingType'
|
204
|
+
property :frame_url, as: 'frameUrl'
|
205
|
+
property :fuzzed_url, as: 'fuzzedUrl'
|
206
|
+
property :http_method, as: 'httpMethod'
|
207
|
+
property :name, as: 'name'
|
208
|
+
property :outdated_library, as: 'outdatedLibrary', class: Google::Apis::WebsecurityscannerV1alpha::OutdatedLibrary, decorator: Google::Apis::WebsecurityscannerV1alpha::OutdatedLibrary::Representation
|
209
|
+
|
210
|
+
property :reproduction_url, as: 'reproductionUrl'
|
211
|
+
property :tracking_id, as: 'trackingId'
|
212
|
+
property :violating_resource, as: 'violatingResource', class: Google::Apis::WebsecurityscannerV1alpha::ViolatingResource, decorator: Google::Apis::WebsecurityscannerV1alpha::ViolatingResource::Representation
|
213
|
+
|
214
|
+
property :vulnerable_headers, as: 'vulnerableHeaders', class: Google::Apis::WebsecurityscannerV1alpha::VulnerableHeaders, decorator: Google::Apis::WebsecurityscannerV1alpha::VulnerableHeaders::Representation
|
215
|
+
|
216
|
+
property :vulnerable_parameters, as: 'vulnerableParameters', class: Google::Apis::WebsecurityscannerV1alpha::VulnerableParameters, decorator: Google::Apis::WebsecurityscannerV1alpha::VulnerableParameters::Representation
|
217
|
+
|
218
|
+
property :xss, as: 'xss', class: Google::Apis::WebsecurityscannerV1alpha::Xss, decorator: Google::Apis::WebsecurityscannerV1alpha::Xss::Representation
|
219
|
+
|
220
|
+
end
|
221
|
+
end
|
222
|
+
|
223
|
+
class FindingTypeStats
|
224
|
+
# @private
|
225
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
226
|
+
property :finding_count, as: 'findingCount'
|
227
|
+
property :finding_type, as: 'findingType'
|
228
|
+
end
|
229
|
+
end
|
230
|
+
|
231
|
+
class GoogleAccount
|
232
|
+
# @private
|
233
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
234
|
+
property :password, as: 'password'
|
235
|
+
property :username, as: 'username'
|
236
|
+
end
|
237
|
+
end
|
238
|
+
|
239
|
+
class Header
|
240
|
+
# @private
|
241
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
242
|
+
property :name, as: 'name'
|
243
|
+
property :value, as: 'value'
|
244
|
+
end
|
245
|
+
end
|
246
|
+
|
247
|
+
class ListCrawledUrlsResponse
|
248
|
+
# @private
|
249
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
250
|
+
collection :crawled_urls, as: 'crawledUrls', class: Google::Apis::WebsecurityscannerV1alpha::CrawledUrl, decorator: Google::Apis::WebsecurityscannerV1alpha::CrawledUrl::Representation
|
251
|
+
|
252
|
+
property :next_page_token, as: 'nextPageToken'
|
253
|
+
end
|
254
|
+
end
|
255
|
+
|
256
|
+
class ListFindingTypeStatsResponse
|
257
|
+
# @private
|
258
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
259
|
+
collection :finding_type_stats, as: 'findingTypeStats', class: Google::Apis::WebsecurityscannerV1alpha::FindingTypeStats, decorator: Google::Apis::WebsecurityscannerV1alpha::FindingTypeStats::Representation
|
260
|
+
|
261
|
+
end
|
262
|
+
end
|
263
|
+
|
264
|
+
class ListFindingsResponse
|
265
|
+
# @private
|
266
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
267
|
+
collection :findings, as: 'findings', class: Google::Apis::WebsecurityscannerV1alpha::Finding, decorator: Google::Apis::WebsecurityscannerV1alpha::Finding::Representation
|
268
|
+
|
269
|
+
property :next_page_token, as: 'nextPageToken'
|
270
|
+
end
|
271
|
+
end
|
272
|
+
|
273
|
+
class ListScanConfigsResponse
|
274
|
+
# @private
|
275
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
276
|
+
property :next_page_token, as: 'nextPageToken'
|
277
|
+
collection :scan_configs, as: 'scanConfigs', class: Google::Apis::WebsecurityscannerV1alpha::ScanConfig, decorator: Google::Apis::WebsecurityscannerV1alpha::ScanConfig::Representation
|
278
|
+
|
279
|
+
end
|
280
|
+
end
|
281
|
+
|
282
|
+
class ListScanRunsResponse
|
283
|
+
# @private
|
284
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
285
|
+
property :next_page_token, as: 'nextPageToken'
|
286
|
+
collection :scan_runs, as: 'scanRuns', class: Google::Apis::WebsecurityscannerV1alpha::ScanRun, decorator: Google::Apis::WebsecurityscannerV1alpha::ScanRun::Representation
|
287
|
+
|
288
|
+
end
|
289
|
+
end
|
290
|
+
|
291
|
+
class OutdatedLibrary
|
292
|
+
# @private
|
293
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
294
|
+
collection :learn_more_urls, as: 'learnMoreUrls'
|
295
|
+
property :library_name, as: 'libraryName'
|
296
|
+
property :version, as: 'version'
|
297
|
+
end
|
298
|
+
end
|
299
|
+
|
300
|
+
class ScanConfig
|
301
|
+
# @private
|
302
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
303
|
+
property :authentication, as: 'authentication', class: Google::Apis::WebsecurityscannerV1alpha::Authentication, decorator: Google::Apis::WebsecurityscannerV1alpha::Authentication::Representation
|
304
|
+
|
305
|
+
collection :blacklist_patterns, as: 'blacklistPatterns'
|
306
|
+
property :display_name, as: 'displayName'
|
307
|
+
property :latest_run, as: 'latestRun', class: Google::Apis::WebsecurityscannerV1alpha::ScanRun, decorator: Google::Apis::WebsecurityscannerV1alpha::ScanRun::Representation
|
308
|
+
|
309
|
+
property :max_qps, as: 'maxQps'
|
310
|
+
property :name, as: 'name'
|
311
|
+
property :schedule, as: 'schedule', class: Google::Apis::WebsecurityscannerV1alpha::Schedule, decorator: Google::Apis::WebsecurityscannerV1alpha::Schedule::Representation
|
312
|
+
|
313
|
+
collection :starting_urls, as: 'startingUrls'
|
314
|
+
collection :target_platforms, as: 'targetPlatforms'
|
315
|
+
property :user_agent, as: 'userAgent'
|
316
|
+
end
|
317
|
+
end
|
318
|
+
|
319
|
+
class ScanRun
|
320
|
+
# @private
|
321
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
322
|
+
property :end_time, as: 'endTime'
|
323
|
+
property :execution_state, as: 'executionState'
|
324
|
+
property :has_vulnerabilities, as: 'hasVulnerabilities'
|
325
|
+
property :name, as: 'name'
|
326
|
+
property :progress_percent, as: 'progressPercent'
|
327
|
+
property :result_state, as: 'resultState'
|
328
|
+
property :start_time, as: 'startTime'
|
329
|
+
property :urls_crawled_count, :numeric_string => true, as: 'urlsCrawledCount'
|
330
|
+
property :urls_tested_count, :numeric_string => true, as: 'urlsTestedCount'
|
331
|
+
end
|
332
|
+
end
|
333
|
+
|
334
|
+
class Schedule
|
335
|
+
# @private
|
336
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
337
|
+
property :interval_duration_days, as: 'intervalDurationDays'
|
338
|
+
property :schedule_time, as: 'scheduleTime'
|
339
|
+
end
|
340
|
+
end
|
341
|
+
|
342
|
+
class StartScanRunRequest
|
343
|
+
# @private
|
344
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
345
|
+
end
|
346
|
+
end
|
347
|
+
|
348
|
+
class StopScanRunRequest
|
349
|
+
# @private
|
350
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
351
|
+
end
|
352
|
+
end
|
353
|
+
|
354
|
+
class ViolatingResource
|
355
|
+
# @private
|
356
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
357
|
+
property :content_type, as: 'contentType'
|
358
|
+
property :resource_url, as: 'resourceUrl'
|
359
|
+
end
|
360
|
+
end
|
361
|
+
|
362
|
+
class VulnerableHeaders
|
363
|
+
# @private
|
364
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
365
|
+
collection :headers, as: 'headers', class: Google::Apis::WebsecurityscannerV1alpha::Header, decorator: Google::Apis::WebsecurityscannerV1alpha::Header::Representation
|
366
|
+
|
367
|
+
collection :missing_headers, as: 'missingHeaders', class: Google::Apis::WebsecurityscannerV1alpha::Header, decorator: Google::Apis::WebsecurityscannerV1alpha::Header::Representation
|
368
|
+
|
369
|
+
end
|
370
|
+
end
|
371
|
+
|
372
|
+
class VulnerableParameters
|
373
|
+
# @private
|
374
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
375
|
+
collection :parameter_names, as: 'parameterNames'
|
376
|
+
end
|
377
|
+
end
|
378
|
+
|
379
|
+
class Xss
|
380
|
+
# @private
|
381
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
382
|
+
property :error_message, as: 'errorMessage'
|
383
|
+
collection :stack_traces, as: 'stackTraces'
|
384
|
+
end
|
385
|
+
end
|
386
|
+
end
|
387
|
+
end
|
388
|
+
end
|
@@ -0,0 +1,529 @@
|
|
1
|
+
# Copyright 2020 Google LLC
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'google/apis/core/base_service'
|
16
|
+
require 'google/apis/core/json_representation'
|
17
|
+
require 'google/apis/core/hashable'
|
18
|
+
require 'google/apis/errors'
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Apis
|
22
|
+
module WebsecurityscannerV1alpha
|
23
|
+
# Web Security Scanner API
|
24
|
+
#
|
25
|
+
# Scans your Compute and App Engine apps for common web vulnerabilities.
|
26
|
+
#
|
27
|
+
# @example
|
28
|
+
# require 'google/apis/websecurityscanner_v1alpha'
|
29
|
+
#
|
30
|
+
# Websecurityscanner = Google::Apis::WebsecurityscannerV1alpha # Alias the module
|
31
|
+
# service = Websecurityscanner::WebSecurityScannerService.new
|
32
|
+
#
|
33
|
+
# @see https://cloud.google.com/security-command-center/docs/concepts-web-security-scanner-overview/
|
34
|
+
class WebSecurityScannerService < Google::Apis::Core::BaseService
|
35
|
+
# @return [String]
|
36
|
+
# API key. Your API key identifies your project and provides you with API access,
|
37
|
+
# quota, and reports. Required unless you provide an OAuth 2.0 token.
|
38
|
+
attr_accessor :key
|
39
|
+
|
40
|
+
# @return [String]
|
41
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
42
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
43
|
+
attr_accessor :quota_user
|
44
|
+
|
45
|
+
def initialize
|
46
|
+
super('https://websecurityscanner.googleapis.com/', '',
|
47
|
+
client_name: 'google-apis-websecurityscanner_v1alpha',
|
48
|
+
client_version: Google::Apis::WebsecurityscannerV1alpha::GEM_VERSION)
|
49
|
+
@batch_path = 'batch'
|
50
|
+
end
|
51
|
+
|
52
|
+
# Creates a new ScanConfig.
|
53
|
+
# @param [String] parent
|
54
|
+
# Required. The parent resource name where the scan is created, which should be
|
55
|
+
# a project resource name in the format 'projects/`projectId`'.
|
56
|
+
# @param [Google::Apis::WebsecurityscannerV1alpha::ScanConfig] scan_config_object
|
57
|
+
# @param [String] fields
|
58
|
+
# Selector specifying which fields to include in a partial response.
|
59
|
+
# @param [String] quota_user
|
60
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
61
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
62
|
+
# @param [Google::Apis::RequestOptions] options
|
63
|
+
# Request-specific options
|
64
|
+
#
|
65
|
+
# @yield [result, err] Result & error if block supplied
|
66
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ScanConfig] parsed result object
|
67
|
+
# @yieldparam err [StandardError] error object if request failed
|
68
|
+
#
|
69
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ScanConfig]
|
70
|
+
#
|
71
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
72
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
73
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
74
|
+
def create_project_scan_config(parent, scan_config_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
75
|
+
command = make_simple_command(:post, 'v1alpha/{+parent}/scanConfigs', options)
|
76
|
+
command.request_representation = Google::Apis::WebsecurityscannerV1alpha::ScanConfig::Representation
|
77
|
+
command.request_object = scan_config_object
|
78
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ScanConfig::Representation
|
79
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ScanConfig
|
80
|
+
command.params['parent'] = parent unless parent.nil?
|
81
|
+
command.query['fields'] = fields unless fields.nil?
|
82
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
83
|
+
execute_or_queue_command(command, &block)
|
84
|
+
end
|
85
|
+
|
86
|
+
# Deletes an existing ScanConfig and its child resources.
|
87
|
+
# @param [String] name
|
88
|
+
# Required. The resource name of the ScanConfig to be deleted. The name follows
|
89
|
+
# the format of 'projects/`projectId`/scanConfigs/`scanConfigId`'.
|
90
|
+
# @param [String] fields
|
91
|
+
# Selector specifying which fields to include in a partial response.
|
92
|
+
# @param [String] quota_user
|
93
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
94
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
95
|
+
# @param [Google::Apis::RequestOptions] options
|
96
|
+
# Request-specific options
|
97
|
+
#
|
98
|
+
# @yield [result, err] Result & error if block supplied
|
99
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::Empty] parsed result object
|
100
|
+
# @yieldparam err [StandardError] error object if request failed
|
101
|
+
#
|
102
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::Empty]
|
103
|
+
#
|
104
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
105
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
106
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
107
|
+
def delete_project_scan_config(name, fields: nil, quota_user: nil, options: nil, &block)
|
108
|
+
command = make_simple_command(:delete, 'v1alpha/{+name}', options)
|
109
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::Empty::Representation
|
110
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::Empty
|
111
|
+
command.params['name'] = name unless name.nil?
|
112
|
+
command.query['fields'] = fields unless fields.nil?
|
113
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
114
|
+
execute_or_queue_command(command, &block)
|
115
|
+
end
|
116
|
+
|
117
|
+
# Gets a ScanConfig.
|
118
|
+
# @param [String] name
|
119
|
+
# Required. The resource name of the ScanConfig to be returned. The name follows
|
120
|
+
# the format of 'projects/`projectId`/scanConfigs/`scanConfigId`'.
|
121
|
+
# @param [String] fields
|
122
|
+
# Selector specifying which fields to include in a partial response.
|
123
|
+
# @param [String] quota_user
|
124
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
125
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
126
|
+
# @param [Google::Apis::RequestOptions] options
|
127
|
+
# Request-specific options
|
128
|
+
#
|
129
|
+
# @yield [result, err] Result & error if block supplied
|
130
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ScanConfig] parsed result object
|
131
|
+
# @yieldparam err [StandardError] error object if request failed
|
132
|
+
#
|
133
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ScanConfig]
|
134
|
+
#
|
135
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
136
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
137
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
138
|
+
def get_project_scan_config(name, fields: nil, quota_user: nil, options: nil, &block)
|
139
|
+
command = make_simple_command(:get, 'v1alpha/{+name}', options)
|
140
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ScanConfig::Representation
|
141
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ScanConfig
|
142
|
+
command.params['name'] = name unless name.nil?
|
143
|
+
command.query['fields'] = fields unless fields.nil?
|
144
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
145
|
+
execute_or_queue_command(command, &block)
|
146
|
+
end
|
147
|
+
|
148
|
+
# Lists ScanConfigs under a given project.
|
149
|
+
# @param [String] parent
|
150
|
+
# Required. The parent resource name, which should be a project resource name in
|
151
|
+
# the format 'projects/`projectId`'.
|
152
|
+
# @param [Fixnum] page_size
|
153
|
+
# The maximum number of ScanConfigs to return, can be limited by server. If not
|
154
|
+
# specified or not positive, the implementation will select a reasonable value.
|
155
|
+
# @param [String] page_token
|
156
|
+
# A token identifying a page of results to be returned. This should be a `
|
157
|
+
# next_page_token` value returned from a previous List request. If unspecified,
|
158
|
+
# the first page of results is returned.
|
159
|
+
# @param [String] fields
|
160
|
+
# Selector specifying which fields to include in a partial response.
|
161
|
+
# @param [String] quota_user
|
162
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
163
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
164
|
+
# @param [Google::Apis::RequestOptions] options
|
165
|
+
# Request-specific options
|
166
|
+
#
|
167
|
+
# @yield [result, err] Result & error if block supplied
|
168
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ListScanConfigsResponse] parsed result object
|
169
|
+
# @yieldparam err [StandardError] error object if request failed
|
170
|
+
#
|
171
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ListScanConfigsResponse]
|
172
|
+
#
|
173
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
174
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
175
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
176
|
+
def list_project_scan_configs(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
177
|
+
command = make_simple_command(:get, 'v1alpha/{+parent}/scanConfigs', options)
|
178
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ListScanConfigsResponse::Representation
|
179
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ListScanConfigsResponse
|
180
|
+
command.params['parent'] = parent unless parent.nil?
|
181
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
182
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
183
|
+
command.query['fields'] = fields unless fields.nil?
|
184
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
185
|
+
execute_or_queue_command(command, &block)
|
186
|
+
end
|
187
|
+
|
188
|
+
# Updates a ScanConfig. This method support partial update of a ScanConfig.
|
189
|
+
# @param [String] name
|
190
|
+
# The resource name of the ScanConfig. The name follows the format of 'projects/`
|
191
|
+
# projectId`/scanConfigs/`scanConfigId`'. The ScanConfig IDs are generated by
|
192
|
+
# the system.
|
193
|
+
# @param [Google::Apis::WebsecurityscannerV1alpha::ScanConfig] scan_config_object
|
194
|
+
# @param [String] update_mask
|
195
|
+
# Required. The update mask applies to the resource. For the `FieldMask`
|
196
|
+
# definition, see https://developers.google.com/protocol-buffers/docs/reference/
|
197
|
+
# google.protobuf#fieldmask
|
198
|
+
# @param [String] fields
|
199
|
+
# Selector specifying which fields to include in a partial response.
|
200
|
+
# @param [String] quota_user
|
201
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
202
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
203
|
+
# @param [Google::Apis::RequestOptions] options
|
204
|
+
# Request-specific options
|
205
|
+
#
|
206
|
+
# @yield [result, err] Result & error if block supplied
|
207
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ScanConfig] parsed result object
|
208
|
+
# @yieldparam err [StandardError] error object if request failed
|
209
|
+
#
|
210
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ScanConfig]
|
211
|
+
#
|
212
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
213
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
214
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
215
|
+
def patch_project_scan_config(name, scan_config_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
|
216
|
+
command = make_simple_command(:patch, 'v1alpha/{+name}', options)
|
217
|
+
command.request_representation = Google::Apis::WebsecurityscannerV1alpha::ScanConfig::Representation
|
218
|
+
command.request_object = scan_config_object
|
219
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ScanConfig::Representation
|
220
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ScanConfig
|
221
|
+
command.params['name'] = name unless name.nil?
|
222
|
+
command.query['updateMask'] = update_mask unless update_mask.nil?
|
223
|
+
command.query['fields'] = fields unless fields.nil?
|
224
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
225
|
+
execute_or_queue_command(command, &block)
|
226
|
+
end
|
227
|
+
|
228
|
+
# Start a ScanRun according to the given ScanConfig.
|
229
|
+
# @param [String] name
|
230
|
+
# Required. The resource name of the ScanConfig to be used. The name follows the
|
231
|
+
# format of 'projects/`projectId`/scanConfigs/`scanConfigId`'.
|
232
|
+
# @param [Google::Apis::WebsecurityscannerV1alpha::StartScanRunRequest] start_scan_run_request_object
|
233
|
+
# @param [String] fields
|
234
|
+
# Selector specifying which fields to include in a partial response.
|
235
|
+
# @param [String] quota_user
|
236
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
237
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
238
|
+
# @param [Google::Apis::RequestOptions] options
|
239
|
+
# Request-specific options
|
240
|
+
#
|
241
|
+
# @yield [result, err] Result & error if block supplied
|
242
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ScanRun] parsed result object
|
243
|
+
# @yieldparam err [StandardError] error object if request failed
|
244
|
+
#
|
245
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ScanRun]
|
246
|
+
#
|
247
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
248
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
249
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
250
|
+
def start_scan_config_scan_run(name, start_scan_run_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
251
|
+
command = make_simple_command(:post, 'v1alpha/{+name}:start', options)
|
252
|
+
command.request_representation = Google::Apis::WebsecurityscannerV1alpha::StartScanRunRequest::Representation
|
253
|
+
command.request_object = start_scan_run_request_object
|
254
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ScanRun::Representation
|
255
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ScanRun
|
256
|
+
command.params['name'] = name unless name.nil?
|
257
|
+
command.query['fields'] = fields unless fields.nil?
|
258
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
259
|
+
execute_or_queue_command(command, &block)
|
260
|
+
end
|
261
|
+
|
262
|
+
# Gets a ScanRun.
|
263
|
+
# @param [String] name
|
264
|
+
# Required. The resource name of the ScanRun to be returned. The name follows
|
265
|
+
# the format of 'projects/`projectId`/scanConfigs/`scanConfigId`/scanRuns/`
|
266
|
+
# scanRunId`'.
|
267
|
+
# @param [String] fields
|
268
|
+
# Selector specifying which fields to include in a partial response.
|
269
|
+
# @param [String] quota_user
|
270
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
271
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
272
|
+
# @param [Google::Apis::RequestOptions] options
|
273
|
+
# Request-specific options
|
274
|
+
#
|
275
|
+
# @yield [result, err] Result & error if block supplied
|
276
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ScanRun] parsed result object
|
277
|
+
# @yieldparam err [StandardError] error object if request failed
|
278
|
+
#
|
279
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ScanRun]
|
280
|
+
#
|
281
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
282
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
283
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
284
|
+
def get_project_scan_config_scan_run(name, fields: nil, quota_user: nil, options: nil, &block)
|
285
|
+
command = make_simple_command(:get, 'v1alpha/{+name}', options)
|
286
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ScanRun::Representation
|
287
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ScanRun
|
288
|
+
command.params['name'] = name unless name.nil?
|
289
|
+
command.query['fields'] = fields unless fields.nil?
|
290
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
291
|
+
execute_or_queue_command(command, &block)
|
292
|
+
end
|
293
|
+
|
294
|
+
# Lists ScanRuns under a given ScanConfig, in descending order of ScanRun stop
|
295
|
+
# time.
|
296
|
+
# @param [String] parent
|
297
|
+
# Required. The parent resource name, which should be a scan resource name in
|
298
|
+
# the format 'projects/`projectId`/scanConfigs/`scanConfigId`'.
|
299
|
+
# @param [Fixnum] page_size
|
300
|
+
# The maximum number of ScanRuns to return, can be limited by server. If not
|
301
|
+
# specified or not positive, the implementation will select a reasonable value.
|
302
|
+
# @param [String] page_token
|
303
|
+
# A token identifying a page of results to be returned. This should be a `
|
304
|
+
# next_page_token` value returned from a previous List request. If unspecified,
|
305
|
+
# the first page of results is returned.
|
306
|
+
# @param [String] fields
|
307
|
+
# Selector specifying which fields to include in a partial response.
|
308
|
+
# @param [String] quota_user
|
309
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
310
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
311
|
+
# @param [Google::Apis::RequestOptions] options
|
312
|
+
# Request-specific options
|
313
|
+
#
|
314
|
+
# @yield [result, err] Result & error if block supplied
|
315
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ListScanRunsResponse] parsed result object
|
316
|
+
# @yieldparam err [StandardError] error object if request failed
|
317
|
+
#
|
318
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ListScanRunsResponse]
|
319
|
+
#
|
320
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
321
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
322
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
323
|
+
def list_project_scan_config_scan_runs(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
324
|
+
command = make_simple_command(:get, 'v1alpha/{+parent}/scanRuns', options)
|
325
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ListScanRunsResponse::Representation
|
326
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ListScanRunsResponse
|
327
|
+
command.params['parent'] = parent unless parent.nil?
|
328
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
329
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
330
|
+
command.query['fields'] = fields unless fields.nil?
|
331
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
332
|
+
execute_or_queue_command(command, &block)
|
333
|
+
end
|
334
|
+
|
335
|
+
# Stops a ScanRun. The stopped ScanRun is returned.
|
336
|
+
# @param [String] name
|
337
|
+
# Required. The resource name of the ScanRun to be stopped. The name follows the
|
338
|
+
# format of 'projects/`projectId`/scanConfigs/`scanConfigId`/scanRuns/`scanRunId`
|
339
|
+
# '.
|
340
|
+
# @param [Google::Apis::WebsecurityscannerV1alpha::StopScanRunRequest] stop_scan_run_request_object
|
341
|
+
# @param [String] fields
|
342
|
+
# Selector specifying which fields to include in a partial response.
|
343
|
+
# @param [String] quota_user
|
344
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
345
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
346
|
+
# @param [Google::Apis::RequestOptions] options
|
347
|
+
# Request-specific options
|
348
|
+
#
|
349
|
+
# @yield [result, err] Result & error if block supplied
|
350
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ScanRun] parsed result object
|
351
|
+
# @yieldparam err [StandardError] error object if request failed
|
352
|
+
#
|
353
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ScanRun]
|
354
|
+
#
|
355
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
356
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
357
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
358
|
+
def stop_scan_run(name, stop_scan_run_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
359
|
+
command = make_simple_command(:post, 'v1alpha/{+name}:stop', options)
|
360
|
+
command.request_representation = Google::Apis::WebsecurityscannerV1alpha::StopScanRunRequest::Representation
|
361
|
+
command.request_object = stop_scan_run_request_object
|
362
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ScanRun::Representation
|
363
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ScanRun
|
364
|
+
command.params['name'] = name unless name.nil?
|
365
|
+
command.query['fields'] = fields unless fields.nil?
|
366
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
367
|
+
execute_or_queue_command(command, &block)
|
368
|
+
end
|
369
|
+
|
370
|
+
# List CrawledUrls under a given ScanRun.
|
371
|
+
# @param [String] parent
|
372
|
+
# Required. The parent resource name, which should be a scan run resource name
|
373
|
+
# in the format 'projects/`projectId`/scanConfigs/`scanConfigId`/scanRuns/`
|
374
|
+
# scanRunId`'.
|
375
|
+
# @param [Fixnum] page_size
|
376
|
+
# The maximum number of CrawledUrls to return, can be limited by server. If not
|
377
|
+
# specified or not positive, the implementation will select a reasonable value.
|
378
|
+
# @param [String] page_token
|
379
|
+
# A token identifying a page of results to be returned. This should be a `
|
380
|
+
# next_page_token` value returned from a previous List request. If unspecified,
|
381
|
+
# the first page of results is returned.
|
382
|
+
# @param [String] fields
|
383
|
+
# Selector specifying which fields to include in a partial response.
|
384
|
+
# @param [String] quota_user
|
385
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
386
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
387
|
+
# @param [Google::Apis::RequestOptions] options
|
388
|
+
# Request-specific options
|
389
|
+
#
|
390
|
+
# @yield [result, err] Result & error if block supplied
|
391
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ListCrawledUrlsResponse] parsed result object
|
392
|
+
# @yieldparam err [StandardError] error object if request failed
|
393
|
+
#
|
394
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ListCrawledUrlsResponse]
|
395
|
+
#
|
396
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
397
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
398
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
399
|
+
def list_project_scan_config_scan_run_crawled_urls(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
400
|
+
command = make_simple_command(:get, 'v1alpha/{+parent}/crawledUrls', options)
|
401
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ListCrawledUrlsResponse::Representation
|
402
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ListCrawledUrlsResponse
|
403
|
+
command.params['parent'] = parent unless parent.nil?
|
404
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
405
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
406
|
+
command.query['fields'] = fields unless fields.nil?
|
407
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
408
|
+
execute_or_queue_command(command, &block)
|
409
|
+
end
|
410
|
+
|
411
|
+
# List all FindingTypeStats under a given ScanRun.
|
412
|
+
# @param [String] parent
|
413
|
+
# Required. The parent resource name, which should be a scan run resource name
|
414
|
+
# in the format 'projects/`projectId`/scanConfigs/`scanConfigId`/scanRuns/`
|
415
|
+
# scanRunId`'.
|
416
|
+
# @param [String] fields
|
417
|
+
# Selector specifying which fields to include in a partial response.
|
418
|
+
# @param [String] quota_user
|
419
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
420
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
421
|
+
# @param [Google::Apis::RequestOptions] options
|
422
|
+
# Request-specific options
|
423
|
+
#
|
424
|
+
# @yield [result, err] Result & error if block supplied
|
425
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ListFindingTypeStatsResponse] parsed result object
|
426
|
+
# @yieldparam err [StandardError] error object if request failed
|
427
|
+
#
|
428
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ListFindingTypeStatsResponse]
|
429
|
+
#
|
430
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
431
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
432
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
433
|
+
def list_project_scan_config_scan_run_finding_type_stats(parent, fields: nil, quota_user: nil, options: nil, &block)
|
434
|
+
command = make_simple_command(:get, 'v1alpha/{+parent}/findingTypeStats', options)
|
435
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ListFindingTypeStatsResponse::Representation
|
436
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ListFindingTypeStatsResponse
|
437
|
+
command.params['parent'] = parent unless parent.nil?
|
438
|
+
command.query['fields'] = fields unless fields.nil?
|
439
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
440
|
+
execute_or_queue_command(command, &block)
|
441
|
+
end
|
442
|
+
|
443
|
+
# Gets a Finding.
|
444
|
+
# @param [String] name
|
445
|
+
# Required. The resource name of the Finding to be returned. The name follows
|
446
|
+
# the format of 'projects/`projectId`/scanConfigs/`scanConfigId`/scanRuns/`
|
447
|
+
# scanRunId`/findings/`findingId`'.
|
448
|
+
# @param [String] fields
|
449
|
+
# Selector specifying which fields to include in a partial response.
|
450
|
+
# @param [String] quota_user
|
451
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
452
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
453
|
+
# @param [Google::Apis::RequestOptions] options
|
454
|
+
# Request-specific options
|
455
|
+
#
|
456
|
+
# @yield [result, err] Result & error if block supplied
|
457
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::Finding] parsed result object
|
458
|
+
# @yieldparam err [StandardError] error object if request failed
|
459
|
+
#
|
460
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::Finding]
|
461
|
+
#
|
462
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
463
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
464
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
465
|
+
def get_project_scan_config_scan_run_finding(name, fields: nil, quota_user: nil, options: nil, &block)
|
466
|
+
command = make_simple_command(:get, 'v1alpha/{+name}', options)
|
467
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::Finding::Representation
|
468
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::Finding
|
469
|
+
command.params['name'] = name unless name.nil?
|
470
|
+
command.query['fields'] = fields unless fields.nil?
|
471
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
472
|
+
execute_or_queue_command(command, &block)
|
473
|
+
end
|
474
|
+
|
475
|
+
# List Findings under a given ScanRun.
|
476
|
+
# @param [String] parent
|
477
|
+
# Required. The parent resource name, which should be a scan run resource name
|
478
|
+
# in the format 'projects/`projectId`/scanConfigs/`scanConfigId`/scanRuns/`
|
479
|
+
# scanRunId`'.
|
480
|
+
# @param [String] filter
|
481
|
+
# Required. The filter expression. The expression must be in the format: .
|
482
|
+
# Supported field: 'finding_type'. Supported operator: '='.
|
483
|
+
# @param [Fixnum] page_size
|
484
|
+
# The maximum number of Findings to return, can be limited by server. If not
|
485
|
+
# specified or not positive, the implementation will select a reasonable value.
|
486
|
+
# @param [String] page_token
|
487
|
+
# A token identifying a page of results to be returned. This should be a `
|
488
|
+
# next_page_token` value returned from a previous List request. If unspecified,
|
489
|
+
# the first page of results is returned.
|
490
|
+
# @param [String] fields
|
491
|
+
# Selector specifying which fields to include in a partial response.
|
492
|
+
# @param [String] quota_user
|
493
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
494
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
495
|
+
# @param [Google::Apis::RequestOptions] options
|
496
|
+
# Request-specific options
|
497
|
+
#
|
498
|
+
# @yield [result, err] Result & error if block supplied
|
499
|
+
# @yieldparam result [Google::Apis::WebsecurityscannerV1alpha::ListFindingsResponse] parsed result object
|
500
|
+
# @yieldparam err [StandardError] error object if request failed
|
501
|
+
#
|
502
|
+
# @return [Google::Apis::WebsecurityscannerV1alpha::ListFindingsResponse]
|
503
|
+
#
|
504
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
505
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
506
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
507
|
+
def list_project_scan_config_scan_run_findings(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
508
|
+
command = make_simple_command(:get, 'v1alpha/{+parent}/findings', options)
|
509
|
+
command.response_representation = Google::Apis::WebsecurityscannerV1alpha::ListFindingsResponse::Representation
|
510
|
+
command.response_class = Google::Apis::WebsecurityscannerV1alpha::ListFindingsResponse
|
511
|
+
command.params['parent'] = parent unless parent.nil?
|
512
|
+
command.query['filter'] = filter unless filter.nil?
|
513
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
514
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
515
|
+
command.query['fields'] = fields unless fields.nil?
|
516
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
517
|
+
execute_or_queue_command(command, &block)
|
518
|
+
end
|
519
|
+
|
520
|
+
protected
|
521
|
+
|
522
|
+
def apply_command_defaults(command)
|
523
|
+
command.query['key'] = key unless key.nil?
|
524
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
525
|
+
end
|
526
|
+
end
|
527
|
+
end
|
528
|
+
end
|
529
|
+
end
|