Autogenerated update (2020-03-10)

Update:
- accesscontextmanager_v1beta
- cloudbuild_v1
- cloudbuild_v1alpha1
- cloudbuild_v1alpha2
- manufacturers_v1
- pagespeedonline_v5
- securitycenter_v1
- securitycenter_v1beta1
- securitycenter_v1p1alpha1
- securitycenter_v1p1beta1
- translate_v3
This commit is contained in:
Google APIs 2020-03-10 00:38:14 +00:00
parent 5680a8e605
commit 7793aeefc5
32 changed files with 1131 additions and 25 deletions

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/access-context-manager/docs/reference/rest/
module AccesscontextmanagerV1beta
VERSION = 'V1beta'
REVISION = '20200224'
REVISION = '20200229'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -52,7 +52,8 @@ module Google
# Required. Resource name for the Access Level. The `short_name` component
# must begin with a letter and only include alphanumeric and '_'. Format:
# `accessPolicies/`policy_id`/accessLevels/`short_name``
# `accessPolicies/`policy_id`/accessLevels/`short_name``. The maximum length
# // of the `short_name` component is 50 characters.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name

View File

@ -398,7 +398,8 @@ module Google
# @param [String] name
# Required. Resource name for the Access Level. The `short_name` component
# must begin with a letter and only include alphanumeric and '_'. Format:
# `accessPolicies/`policy_id`/accessLevels/`short_name``
# `accessPolicies/`policy_id`/accessLevels/`short_name``. The maximum length
# // of the `short_name` component is 50 characters.
# @param [Google::Apis::AccesscontextmanagerV1beta::AccessLevel] access_level_object
# @param [String] update_mask
# Required. Mask to control which fields get updated. Must be non-empty.
@ -432,7 +433,7 @@ module Google
execute_or_queue_command(command, &block)
end
# Create an Service Perimeter. The
# Create a Service Perimeter. The
# longrunning operation from this RPC will have a successful status once the
# Service Perimeter has
# propagated to long-lasting storage. Service Perimeters containing
@ -471,7 +472,7 @@ module Google
execute_or_queue_command(command, &block)
end
# Delete an Service Perimeter by resource
# Delete a Service Perimeter by resource
# name. The longrunning operation from this RPC will have a successful status
# once the Service Perimeter has been
# removed from long-lasting storage.
@ -506,7 +507,7 @@ module Google
execute_or_queue_command(command, &block)
end
# Get an Service Perimeter by resource
# Get a Service Perimeter by resource
# name.
# @param [String] name
# Required. Resource name for the Service Perimeter.
@ -580,7 +581,7 @@ module Google
execute_or_queue_command(command, &block)
end
# Update an Service Perimeter. The
# Update a Service Perimeter. The
# longrunning operation from this RPC will have a successful status once the
# changes to the Service Perimeter have
# propagated to long-lasting storage. Service Perimeter containing

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/cloud-build/docs/
module CloudbuildV1
VERSION = 'V1'
REVISION = '20200229'
REVISION = '20200308'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -1024,6 +1024,12 @@ module Google
# @return [String]
attr_accessor :comment_control
# If true, branches that do NOT match the git_ref will trigger a build.
# Corresponds to the JSON property `invertRegex`
# @return [Boolean]
attr_accessor :invert_regex
alias_method :invert_regex?, :invert_regex
def initialize(**args)
update!(**args)
end
@ -1032,6 +1038,7 @@ module Google
def update!(**args)
@branch = args[:branch] if args.key?(:branch)
@comment_control = args[:comment_control] if args.key?(:comment_control)
@invert_regex = args[:invert_regex] if args.key?(:invert_regex)
end
end
@ -1046,6 +1053,13 @@ module Google
# @return [String]
attr_accessor :branch
# When true, only trigger a build if the revision regex does NOT match the
# git_ref regex.
# Corresponds to the JSON property `invertRegex`
# @return [Boolean]
attr_accessor :invert_regex
alias_method :invert_regex?, :invert_regex
# Regexes matching tags to build.
# The syntax of the regular expressions accepted is the syntax accepted by
# RE2 and described at https://github.com/google/re2/wiki/Syntax
@ -1060,6 +1074,7 @@ module Google
# Update properties of this object
def update!(**args)
@branch = args[:branch] if args.key?(:branch)
@invert_regex = args[:invert_regex] if args.key?(:invert_regex)
@tag = args[:tag] if args.key?(:tag)
end
end
@ -1087,6 +1102,13 @@ module Google
# @return [String]
attr_accessor :dir
# Only trigger a build if the revision regex does NOT match the revision
# regex.
# Corresponds to the JSON property `invertRegex`
# @return [Boolean]
attr_accessor :invert_regex
alias_method :invert_regex?, :invert_regex
# ID of the project that owns the Cloud Source Repository. If omitted, the
# project ID requesting the build is assumed.
# Corresponds to the JSON property `projectId`
@ -1120,6 +1142,7 @@ module Google
@branch_name = args[:branch_name] if args.key?(:branch_name)
@commit_sha = args[:commit_sha] if args.key?(:commit_sha)
@dir = args[:dir] if args.key?(:dir)
@invert_regex = args[:invert_regex] if args.key?(:invert_regex)
@project_id = args[:project_id] if args.key?(:project_id)
@repo_name = args[:repo_name] if args.key?(:repo_name)
@substitutions = args[:substitutions] if args.key?(:substitutions)

View File

@ -443,6 +443,7 @@ module Google
class Representation < Google::Apis::Core::JsonRepresentation
property :branch, as: 'branch'
property :comment_control, as: 'commentControl'
property :invert_regex, as: 'invertRegex'
end
end
@ -450,6 +451,7 @@ module Google
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :branch, as: 'branch'
property :invert_regex, as: 'invertRegex'
property :tag, as: 'tag'
end
end
@ -460,6 +462,7 @@ module Google
property :branch_name, as: 'branchName'
property :commit_sha, as: 'commitSha'
property :dir, as: 'dir'
property :invert_regex, as: 'invertRegex'
property :project_id, as: 'projectId'
property :repo_name, as: 'repoName'
hash :substitutions, as: 'substitutions'

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/cloud-build/docs/
module CloudbuildV1alpha1
VERSION = 'V1alpha1'
REVISION = '20200229'
REVISION = '20200308'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -746,6 +746,13 @@ module Google
# @return [String]
attr_accessor :dir
# Only trigger a build if the revision regex does NOT match the revision
# regex.
# Corresponds to the JSON property `invertRegex`
# @return [Boolean]
attr_accessor :invert_regex
alias_method :invert_regex?, :invert_regex
# ID of the project that owns the Cloud Source Repository. If omitted, the
# project ID requesting the build is assumed.
# Corresponds to the JSON property `projectId`
@ -779,6 +786,7 @@ module Google
@branch_name = args[:branch_name] if args.key?(:branch_name)
@commit_sha = args[:commit_sha] if args.key?(:commit_sha)
@dir = args[:dir] if args.key?(:dir)
@invert_regex = args[:invert_regex] if args.key?(:invert_regex)
@project_id = args[:project_id] if args.key?(:project_id)
@repo_name = args[:repo_name] if args.key?(:repo_name)
@substitutions = args[:substitutions] if args.key?(:substitutions)

View File

@ -327,6 +327,7 @@ module Google
property :branch_name, as: 'branchName'
property :commit_sha, as: 'commitSha'
property :dir, as: 'dir'
property :invert_regex, as: 'invertRegex'
property :project_id, as: 'projectId'
property :repo_name, as: 'repoName'
hash :substitutions, as: 'substitutions'

View File

@ -48,7 +48,6 @@ module Google
end
# Creates a `WorkerPool` to run the builds, and returns the new worker pool.
# This API is experimental.
# @param [String] parent
# ID of the parent project.
# @param [Google::Apis::CloudbuildV1alpha1::WorkerPool] worker_pool_object
@ -82,7 +81,6 @@ module Google
end
# Deletes a `WorkerPool` by its project ID and WorkerPool name.
# This API is experimental.
# @param [String] name
# The field will contain name of the resource requested, for example:
# "projects/project-1/workerPools/workerpool-name"
@ -114,7 +112,6 @@ module Google
end
# Returns information about a `WorkerPool`.
# This API is experimental.
# @param [String] name
# The field will contain name of the resource requested, for example:
# "projects/project-1/workerPools/workerpool-name"
@ -146,7 +143,6 @@ module Google
end
# List project's `WorkerPool`s.
# This API is experimental.
# @param [String] parent
# ID of the parent project.
# @param [String] fields
@ -177,7 +173,6 @@ module Google
end
# Update a `WorkerPool`.
# This API is experimental.
# @param [String] name
# The field will contain name of the resource requested, for example:
# "projects/project-1/workerPools/workerpool-name"

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/cloud-build/docs/
module CloudbuildV1alpha2
VERSION = 'V1alpha2'
REVISION = '20200229'
REVISION = '20200308'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -733,6 +733,13 @@ module Google
# @return [String]
attr_accessor :dir
# Only trigger a build if the revision regex does NOT match the revision
# regex.
# Corresponds to the JSON property `invertRegex`
# @return [Boolean]
attr_accessor :invert_regex
alias_method :invert_regex?, :invert_regex
# ID of the project that owns the Cloud Source Repository. If omitted, the
# project ID requesting the build is assumed.
# Corresponds to the JSON property `projectId`
@ -766,6 +773,7 @@ module Google
@branch_name = args[:branch_name] if args.key?(:branch_name)
@commit_sha = args[:commit_sha] if args.key?(:commit_sha)
@dir = args[:dir] if args.key?(:dir)
@invert_regex = args[:invert_regex] if args.key?(:invert_regex)
@project_id = args[:project_id] if args.key?(:project_id)
@repo_name = args[:repo_name] if args.key?(:repo_name)
@substitutions = args[:substitutions] if args.key?(:substitutions)

View File

@ -325,6 +325,7 @@ module Google
property :branch_name, as: 'branchName'
property :commit_sha, as: 'commitSha'
property :dir, as: 'dir'
property :invert_regex, as: 'invertRegex'
property :project_id, as: 'projectId'
property :repo_name, as: 'repoName'
hash :substitutions, as: 'substitutions'

View File

@ -25,7 +25,7 @@ module Google
# @see https://developers.google.com/manufacturers/
module ManufacturersV1
VERSION = 'V1'
REVISION = '20200213'
REVISION = '20200303'
# Manage your product listings for Google Manufacturer Center
AUTH_MANUFACTURERCENTER = 'https://www.googleapis.com/auth/manufacturercenter'

View File

@ -181,6 +181,12 @@ module Google
# @return [String]
attr_accessor :release_date
# Rich product content. For more information, see
# https://support.google.com/manufacturers/answer/9389865
# Corresponds to the JSON property `richContent`
# @return [Array<String>]
attr_accessor :rich_content
# The scent of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#scent.
# Corresponds to the JSON property `scent`
@ -266,6 +272,7 @@ module Google
@product_page_url = args[:product_page_url] if args.key?(:product_page_url)
@product_type = args[:product_type] if args.key?(:product_type)
@release_date = args[:release_date] if args.key?(:release_date)
@rich_content = args[:rich_content] if args.key?(:rich_content)
@scent = args[:scent] if args.key?(:scent)
@size = args[:size] if args.key?(:size)
@size_system = args[:size_system] if args.key?(:size_system)

View File

@ -129,6 +129,7 @@ module Google
property :product_page_url, as: 'productPageUrl'
collection :product_type, as: 'productType'
property :release_date, as: 'releaseDate'
collection :rich_content, as: 'richContent'
property :scent, as: 'scent'
property :size, as: 'size'
property :size_system, as: 'sizeSystem'

View File

@ -28,7 +28,7 @@ module Google
# @see https://developers.google.com/speed/docs/insights/v5/about
module PagespeedonlineV5
VERSION = 'V5'
REVISION = '20200303'
REVISION = '20200305'
# Associate you with your personal info on Google
PENID = 'openid'

View File

@ -26,7 +26,7 @@ module Google
# @see https://console.cloud.google.com/apis/api/securitycenter.googleapis.com/overview
module SecuritycenterV1
VERSION = 'V1'
REVISION = '20200228'
REVISION = '20200306'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -543,6 +543,36 @@ module Google
end
end
# Cloud SCC's Notification
class GoogleCloudSecuritycenterV1NotificationMessage
include Google::Apis::Core::Hashable
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
# Corresponds to the JSON property `finding`
# @return [Google::Apis::SecuritycenterV1::Finding]
attr_accessor :finding
# Name of the notification config that generated current notification.
# Corresponds to the JSON property `notificationConfigName`
# @return [String]
attr_accessor :notification_config_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@finding = args[:finding] if args.key?(:finding)
@notification_config_name = args[:notification_config_name] if args.key?(:notification_config_name)
end
end
# Response of asset discovery run
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
include Google::Apis::Core::Hashable
@ -1511,6 +1541,32 @@ module Google
end
end
# Response message for listing notification configs.
class ListNotificationConfigsResponse
include Google::Apis::Core::Hashable
# Token to retrieve the next page of results, or empty if there are no more
# results.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# Notification configs belonging to the requested parent.
# Corresponds to the JSON property `notificationConfigs`
# @return [Array<Google::Apis::SecuritycenterV1::NotificationConfig>]
attr_accessor :notification_configs
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@notification_configs = args[:notification_configs] if args.key?(:notification_configs)
end
end
# The response message for Operations.ListOperations.
class ListOperationsResponse
include Google::Apis::Core::Hashable
@ -1562,6 +1618,57 @@ module Google
end
end
# Cloud Security Command Center (Cloud SCC) notification configs.
# A notification config is a Cloud SCC resource that contains the configuration
# to send notifications for create/update events of findings, assets and etc.
class NotificationConfig
include Google::Apis::Core::Hashable
# The description of the notification config (max of 1024 characters).
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# The relative resource name of this notification config. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Example:
# "organizations/`organization_id`/notificationConfigs/notify_public_bucket".
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The PubSub topic to send notifications to. Its format is
# "projects/[project_id]/topics/[topic]".
# Corresponds to the JSON property `pubsubTopic`
# @return [String]
attr_accessor :pubsub_topic
# Output only. The service account that needs "pubsub.topics.publish"
# permission to publish to the PubSub topic.
# Corresponds to the JSON property `serviceAccount`
# @return [String]
attr_accessor :service_account
# The config for streaming-based notifications, which send each event as soon
# as it is detected.
# Corresponds to the JSON property `streamingConfig`
# @return [Google::Apis::SecuritycenterV1::StreamingConfig]
attr_accessor :streaming_config
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@description = args[:description] if args.key?(:description)
@name = args[:name] if args.key?(:name)
@pubsub_topic = args[:pubsub_topic] if args.key?(:pubsub_topic)
@service_account = args[:service_account] if args.key?(:service_account)
@streaming_config = args[:streaming_config] if args.key?(:streaming_config)
end
end
# This resource represents a long-running operation that is the result of a
# network API call.
class Operation
@ -2146,6 +2253,41 @@ module Google
end
end
# The config for streaming-based notifications, which send each event as soon
# as it is detected.
class StreamingConfig
include Google::Apis::Core::Hashable
# Expression that defines the filter to apply across create/update events
# of assets or findings as specified by the event type. The expression is a
# list of zero or more restrictions combined via logical operators `AND`
# and `OR`. Parentheses are supported, and `OR` has higher precedence than
# `AND`.
# Restrictions have the form `<field> <operator> <value>` and may have a
# `-` character in front of them to indicate negation. The fields map to
# those defined in the corresponding resource.
# The supported operators are:
# * `=` for all value types.
# * `>`, `<`, `>=`, `<=` for integer values.
# * `:`, meaning substring matching, for strings.
# The supported value types are:
# * string literals in quotes.
# * integer literals without quotes.
# * boolean literals `true` and `false` without quotes.
# Corresponds to the JSON property `filter`
# @return [String]
attr_accessor :filter
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@filter = args[:filter] if args.key?(:filter)
end
end
# Request message for `TestIamPermissions` method.
class TestIamPermissionsRequest
include Google::Apis::Core::Hashable

View File

@ -82,6 +82,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1NotificationMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -202,6 +208,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class ListNotificationConfigsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListOperationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -214,6 +226,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class NotificationConfig
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -280,6 +298,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class StreamingConfig
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TestIamPermissionsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -391,6 +415,15 @@ module Google
end
end
class GoogleCloudSecuritycenterV1NotificationMessage
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :finding, as: 'finding', class: Google::Apis::SecuritycenterV1::Finding, decorator: Google::Apis::SecuritycenterV1::Finding::Representation
property :notification_config_name, as: 'notificationConfigName'
end
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -600,6 +633,15 @@ module Google
end
end
class ListNotificationConfigsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :notification_configs, as: 'notificationConfigs', class: Google::Apis::SecuritycenterV1::NotificationConfig, decorator: Google::Apis::SecuritycenterV1::NotificationConfig::Representation
end
end
class ListOperationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -618,6 +660,18 @@ module Google
end
end
class NotificationConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :description, as: 'description'
property :name, as: 'name'
property :pubsub_topic, as: 'pubsubTopic'
property :service_account, as: 'serviceAccount'
property :streaming_config, as: 'streamingConfig', class: Google::Apis::SecuritycenterV1::StreamingConfig, decorator: Google::Apis::SecuritycenterV1::StreamingConfig::Representation
end
end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -726,6 +780,13 @@ module Google
end
end
class StreamingConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :filter, as: 'filter'
end
end
class TestIamPermissionsRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation

View File

@ -383,6 +383,188 @@ module Google
execute_or_queue_command(command, &block)
end
# Creates a notification config.
# @param [String] parent
# Required. Resource name of the new notification config's parent. Its format is
# "organizations/[organization_id]".
# @param [Google::Apis::SecuritycenterV1::NotificationConfig] notification_config_object
# @param [String] config_id
# Required.
# Unique identifier provided by the client within the parent scope.
# It must be between 1 and 128 characters, and contains alphanumeric
# characters, underscores or hyphens only.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::SecuritycenterV1::NotificationConfig] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::SecuritycenterV1::NotificationConfig]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def create_organization_notification_config(parent, notification_config_object = nil, config_id: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+parent}/notificationConfigs', options)
command.request_representation = Google::Apis::SecuritycenterV1::NotificationConfig::Representation
command.request_object = notification_config_object
command.response_representation = Google::Apis::SecuritycenterV1::NotificationConfig::Representation
command.response_class = Google::Apis::SecuritycenterV1::NotificationConfig
command.params['parent'] = parent unless parent.nil?
command.query['configId'] = config_id unless config_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Deletes a notification config.
# @param [String] name
# Required. Name of the notification config to delete. Its format is
# "organizations/[organization_id]/notificationConfigs/[config_id]".
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::SecuritycenterV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::SecuritycenterV1::Empty]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_organization_notification_config(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/{+name}', options)
command.response_representation = Google::Apis::SecuritycenterV1::Empty::Representation
command.response_class = Google::Apis::SecuritycenterV1::Empty
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Gets a notification config.
# @param [String] name
# Required. Name of the notification config to get. Its format is
# "organizations/[organization_id]/notificationConfigs/[config_id]".
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::SecuritycenterV1::NotificationConfig] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::SecuritycenterV1::NotificationConfig]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def get_organization_notification_config(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::SecuritycenterV1::NotificationConfig::Representation
command.response_class = Google::Apis::SecuritycenterV1::NotificationConfig
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists notification configs.
# @param [String] parent
# Required. Name of the organization to list notification configs.
# Its format is "organizations/[organization_id]".
# @param [Fixnum] page_size
# The maximum number of results to return in a single response. Default is
# 10, minimum is 1, maximum is 1000.
# @param [String] page_token
# The value returned by the last `ListNotificationConfigsResponse`; indicates
# that this is a continuation of a prior `ListNotificationConfigs` call, and
# that the system should return the next page of data.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::SecuritycenterV1::ListNotificationConfigsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::SecuritycenterV1::ListNotificationConfigsResponse]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def list_organization_notification_configs(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+parent}/notificationConfigs', options)
command.response_representation = Google::Apis::SecuritycenterV1::ListNotificationConfigsResponse::Representation
command.response_class = Google::Apis::SecuritycenterV1::ListNotificationConfigsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Updates a notification config.
# @param [String] name
# The relative resource name of this notification config. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Example:
# "organizations/`organization_id`/notificationConfigs/notify_public_bucket".
# @param [Google::Apis::SecuritycenterV1::NotificationConfig] notification_config_object
# @param [String] update_mask
# The FieldMask to use when updating the notification config.
# If empty all mutable fields will be updated.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::SecuritycenterV1::NotificationConfig] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::SecuritycenterV1::NotificationConfig]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def patch_organization_notification_config(name, notification_config_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:patch, 'v1/{+name}', options)
command.request_representation = Google::Apis::SecuritycenterV1::NotificationConfig::Representation
command.request_object = notification_config_object
command.response_representation = Google::Apis::SecuritycenterV1::NotificationConfig::Representation
command.response_class = Google::Apis::SecuritycenterV1::NotificationConfig
command.params['name'] = name unless name.nil?
command.query['updateMask'] = update_mask unless update_mask.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Starts asynchronous cancellation on a long-running operation. The server
# makes a best effort to cancel the operation, but success is not
# guaranteed. If the server doesn't support this method, it returns

View File

@ -26,7 +26,7 @@ module Google
# @see https://console.cloud.google.com/apis/api/securitycenter.googleapis.com/overview
module SecuritycenterV1beta1
VERSION = 'V1beta1'
REVISION = '20200224'
REVISION = '20200306'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -403,6 +403,108 @@ module Google
end
end
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
class Finding
include Google::Apis::Core::Hashable
# The additional taxonomy group within findings from a given source.
# This field is immutable after creation time.
# Example: "XSS_FLASH_INJECTION"
# Corresponds to the JSON property `category`
# @return [String]
attr_accessor :category
# The time at which the finding was created in Cloud SCC.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# The time at which the event took place. For example, if the finding
# represents an open firewall it would capture the time the detector believes
# the firewall became open. The accuracy is determined by the detector.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
# The URI that, if available, points to a web page outside of Cloud SCC
# where additional information about the finding can be found. This field is
# guaranteed to be either empty or a well formed URL.
# Corresponds to the JSON property `externalUri`
# @return [String]
attr_accessor :external_uri
# The relative resource name of this finding. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Example:
# "organizations/`organization_id`/sources/`source_id`/findings/`finding_id`"
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The relative resource name of the source the finding belongs to. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# This field is immutable after creation time.
# For example:
# "organizations/`organization_id`/sources/`source_id`"
# Corresponds to the JSON property `parent`
# @return [String]
attr_accessor :parent
# For findings on Google Cloud Platform (GCP) resources, the full resource
# name of the GCP resource this finding is for. See:
# https://cloud.google.com/apis/design/resource_names#full_resource_name
# When the finding is for a non-GCP resource, the resourceName can be a
# customer or partner defined string.
# This field is immutable after creation time.
# Corresponds to the JSON property `resourceName`
# @return [String]
attr_accessor :resource_name
# User specified security marks that are attached to the parent Cloud Security
# Command Center (Cloud SCC) resource. Security marks are scoped within a Cloud
# SCC organization -- they can be modified and viewed by all users who have
# proper permissions on the organization.
# Corresponds to the JSON property `securityMarks`
# @return [Google::Apis::SecuritycenterV1beta1::SecurityMarks]
attr_accessor :security_marks
# Source specific properties. These properties are managed by the source
# that writes the finding. The key names in the source_properties map must be
# between 1 and 255 characters, and must start with a letter and contain
# alphanumeric characters or underscores only.
# Corresponds to the JSON property `sourceProperties`
# @return [Hash<String,Object>]
attr_accessor :source_properties
# The state of the finding.
# Corresponds to the JSON property `state`
# @return [String]
attr_accessor :state
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@category = args[:category] if args.key?(:category)
@create_time = args[:create_time] if args.key?(:create_time)
@event_time = args[:event_time] if args.key?(:event_time)
@external_uri = args[:external_uri] if args.key?(:external_uri)
@name = args[:name] if args.key?(:name)
@parent = args[:parent] if args.key?(:parent)
@resource_name = args[:resource_name] if args.key?(:resource_name)
@security_marks = args[:security_marks] if args.key?(:security_marks)
@source_properties = args[:source_properties] if args.key?(:source_properties)
@state = args[:state] if args.key?(:state)
end
end
# Request message for `GetIamPolicy` method.
class GetIamPolicyRequest
include Google::Apis::Core::Hashable
@ -446,6 +548,36 @@ module Google
end
end
# Cloud SCC's Notification
class GoogleCloudSecuritycenterV1NotificationMessage
include Google::Apis::Core::Hashable
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
# Corresponds to the JSON property `finding`
# @return [Google::Apis::SecuritycenterV1beta1::Finding]
attr_accessor :finding
# Name of the notification config that generated current notification.
# Corresponds to the JSON property `notificationConfigName`
# @return [String]
attr_accessor :notification_config_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@finding = args[:finding] if args.key?(:finding)
@notification_config_name = args[:notification_config_name] if args.key?(:notification_config_name)
end
end
# Response of asset discovery run
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
include Google::Apis::Core::Hashable
@ -1742,6 +1874,45 @@ module Google
end
end
# User specified security marks that are attached to the parent Cloud Security
# Command Center (Cloud SCC) resource. Security marks are scoped within a Cloud
# SCC organization -- they can be modified and viewed by all users who have
# proper permissions on the organization.
class SecurityMarks
include Google::Apis::Core::Hashable
# Mutable user specified security marks belonging to the parent resource.
# Constraints are as follows:
# * Keys and values are treated as case insensitive
# * Keys must be between 1 - 256 characters (inclusive)
# * Keys must be letters, numbers, underscores, or dashes
# * Values have leading and trailing whitespace trimmed, remaining
# characters must be between 1 - 4096 characters (inclusive)
# Corresponds to the JSON property `marks`
# @return [Hash<String,String>]
attr_accessor :marks
# The relative resource name of the SecurityMarks. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Examples:
# "organizations/`organization_id`/assets/`asset_id`/securityMarks"
# "organizations/`organization_id`/sources/`source_id`/findings/`finding_id`/
# securityMarks".
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@marks = args[:marks] if args.key?(:marks)
@name = args[:name] if args.key?(:name)
end
end
# Request message for updating a finding's state.
class SetFindingStateRequest
include Google::Apis::Core::Hashable

View File

@ -70,6 +70,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class Finding
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -82,6 +88,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1NotificationMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -244,6 +256,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class SecurityMarks
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SetFindingStateRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -351,6 +369,23 @@ module Google
end
end
class Finding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :category, as: 'category'
property :create_time, as: 'createTime'
property :event_time, as: 'eventTime'
property :external_uri, as: 'externalUri'
property :name, as: 'name'
property :parent, as: 'parent'
property :resource_name, as: 'resourceName'
property :security_marks, as: 'securityMarks', class: Google::Apis::SecuritycenterV1beta1::SecurityMarks, decorator: Google::Apis::SecuritycenterV1beta1::SecurityMarks::Representation
hash :source_properties, as: 'sourceProperties'
property :state, as: 'state'
end
end
class GetIamPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -366,6 +401,15 @@ module Google
end
end
class GoogleCloudSecuritycenterV1NotificationMessage
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :finding, as: 'finding', class: Google::Apis::SecuritycenterV1beta1::Finding, decorator: Google::Apis::SecuritycenterV1beta1::Finding::Representation
property :notification_config_name, as: 'notificationConfigName'
end
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -648,6 +692,14 @@ module Google
end
end
class SecurityMarks
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :marks, as: 'marks'
property :name, as: 'name'
end
end
class SetFindingStateRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation

View File

@ -26,7 +26,7 @@ module Google
# @see https://console.cloud.google.com/apis/api/securitycenter.googleapis.com/overview
module SecuritycenterV1p1alpha1
VERSION = 'V1p1alpha1'
REVISION = '20200224'
REVISION = '20200306'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -41,6 +41,138 @@ module Google
end
end
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
class Finding
include Google::Apis::Core::Hashable
# The additional taxonomy group within findings from a given source.
# This field is immutable after creation time.
# Example: "XSS_FLASH_INJECTION"
# Corresponds to the JSON property `category`
# @return [String]
attr_accessor :category
# The time at which the finding was created in Cloud SCC.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# The time at which the event took place. For example, if the finding
# represents an open firewall it would capture the time the detector believes
# the firewall became open. The accuracy is determined by the detector.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
# The URI that, if available, points to a web page outside of Cloud SCC
# where additional information about the finding can be found. This field is
# guaranteed to be either empty or a well formed URL.
# Corresponds to the JSON property `externalUri`
# @return [String]
attr_accessor :external_uri
# The relative resource name of this finding. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Example:
# "organizations/`organization_id`/sources/`source_id`/findings/`finding_id`"
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The relative resource name of the source the finding belongs to. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# This field is immutable after creation time.
# For example:
# "organizations/`organization_id`/sources/`source_id`"
# Corresponds to the JSON property `parent`
# @return [String]
attr_accessor :parent
# For findings on Google Cloud Platform (GCP) resources, the full resource
# name of the GCP resource this finding is for. See:
# https://cloud.google.com/apis/design/resource_names#full_resource_name
# When the finding is for a non-GCP resource, the resourceName can be a
# customer or partner defined string.
# This field is immutable after creation time.
# Corresponds to the JSON property `resourceName`
# @return [String]
attr_accessor :resource_name
# User specified security marks that are attached to the parent Cloud Security
# Command Center (Cloud SCC) resource. Security marks are scoped within a Cloud
# SCC organization -- they can be modified and viewed by all users who have
# proper permissions on the organization.
# Corresponds to the JSON property `securityMarks`
# @return [Google::Apis::SecuritycenterV1p1alpha1::SecurityMarks]
attr_accessor :security_marks
# Source specific properties. These properties are managed by the source
# that writes the finding. The key names in the source_properties map must be
# between 1 and 255 characters, and must start with a letter and contain
# alphanumeric characters or underscores only.
# Corresponds to the JSON property `sourceProperties`
# @return [Hash<String,Object>]
attr_accessor :source_properties
# The state of the finding.
# Corresponds to the JSON property `state`
# @return [String]
attr_accessor :state
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@category = args[:category] if args.key?(:category)
@create_time = args[:create_time] if args.key?(:create_time)
@event_time = args[:event_time] if args.key?(:event_time)
@external_uri = args[:external_uri] if args.key?(:external_uri)
@name = args[:name] if args.key?(:name)
@parent = args[:parent] if args.key?(:parent)
@resource_name = args[:resource_name] if args.key?(:resource_name)
@security_marks = args[:security_marks] if args.key?(:security_marks)
@source_properties = args[:source_properties] if args.key?(:source_properties)
@state = args[:state] if args.key?(:state)
end
end
# Cloud SCC's Notification
class GoogleCloudSecuritycenterV1NotificationMessage
include Google::Apis::Core::Hashable
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
# Corresponds to the JSON property `finding`
# @return [Google::Apis::SecuritycenterV1p1alpha1::Finding]
attr_accessor :finding
# Name of the notification config that generated current notification.
# Corresponds to the JSON property `notificationConfigName`
# @return [String]
attr_accessor :notification_config_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@finding = args[:finding] if args.key?(:finding)
@notification_config_name = args[:notification_config_name] if args.key?(:notification_config_name)
end
end
# Response of asset discovery run
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
include Google::Apis::Core::Hashable
@ -573,6 +705,45 @@ module Google
end
end
# User specified security marks that are attached to the parent Cloud Security
# Command Center (Cloud SCC) resource. Security marks are scoped within a Cloud
# SCC organization -- they can be modified and viewed by all users who have
# proper permissions on the organization.
class SecurityMarks
include Google::Apis::Core::Hashable
# Mutable user specified security marks belonging to the parent resource.
# Constraints are as follows:
# * Keys and values are treated as case insensitive
# * Keys must be between 1 - 256 characters (inclusive)
# * Keys must be letters, numbers, underscores, or dashes
# * Values have leading and trailing whitespace trimmed, remaining
# characters must be between 1 - 4096 characters (inclusive)
# Corresponds to the JSON property `marks`
# @return [Hash<String,String>]
attr_accessor :marks
# The relative resource name of the SecurityMarks. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Examples:
# "organizations/`organization_id`/assets/`asset_id`/securityMarks"
# "organizations/`organization_id`/sources/`source_id`/findings/`finding_id`/
# securityMarks".
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@marks = args[:marks] if args.key?(:marks)
@name = args[:name] if args.key?(:name)
end
end
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains

View File

@ -28,6 +28,18 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class Finding
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1NotificationMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -100,6 +112,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class SecurityMarks
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -112,6 +130,32 @@ module Google
end
end
class Finding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :category, as: 'category'
property :create_time, as: 'createTime'
property :event_time, as: 'eventTime'
property :external_uri, as: 'externalUri'
property :name, as: 'name'
property :parent, as: 'parent'
property :resource_name, as: 'resourceName'
property :security_marks, as: 'securityMarks', class: Google::Apis::SecuritycenterV1p1alpha1::SecurityMarks, decorator: Google::Apis::SecuritycenterV1p1alpha1::SecurityMarks::Representation
hash :source_properties, as: 'sourceProperties'
property :state, as: 'state'
end
end
class GoogleCloudSecuritycenterV1NotificationMessage
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :finding, as: 'finding', class: Google::Apis::SecuritycenterV1p1alpha1::Finding, decorator: Google::Apis::SecuritycenterV1p1alpha1::Finding::Representation
property :notification_config_name, as: 'notificationConfigName'
end
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -239,6 +283,14 @@ module Google
end
end
class SecurityMarks
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :marks, as: 'marks'
property :name, as: 'name'
end
end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation

View File

@ -26,7 +26,7 @@ module Google
# @see https://console.cloud.google.com/apis/api/securitycenter.googleapis.com/overview
module SecuritycenterV1p1beta1
VERSION = 'V1p1beta1'
REVISION = '20200228'
REVISION = '20200306'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -328,6 +328,108 @@ module Google
end
end
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
class Finding
include Google::Apis::Core::Hashable
# The additional taxonomy group within findings from a given source.
# This field is immutable after creation time.
# Example: "XSS_FLASH_INJECTION"
# Corresponds to the JSON property `category`
# @return [String]
attr_accessor :category
# The time at which the finding was created in Cloud SCC.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# The time at which the event took place. For example, if the finding
# represents an open firewall it would capture the time the detector believes
# the firewall became open. The accuracy is determined by the detector.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
# The URI that, if available, points to a web page outside of Cloud SCC
# where additional information about the finding can be found. This field is
# guaranteed to be either empty or a well formed URL.
# Corresponds to the JSON property `externalUri`
# @return [String]
attr_accessor :external_uri
# The relative resource name of this finding. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Example:
# "organizations/`organization_id`/sources/`source_id`/findings/`finding_id`"
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The relative resource name of the source the finding belongs to. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# This field is immutable after creation time.
# For example:
# "organizations/`organization_id`/sources/`source_id`"
# Corresponds to the JSON property `parent`
# @return [String]
attr_accessor :parent
# For findings on Google Cloud Platform (GCP) resources, the full resource
# name of the GCP resource this finding is for. See:
# https://cloud.google.com/apis/design/resource_names#full_resource_name
# When the finding is for a non-GCP resource, the resourceName can be a
# customer or partner defined string.
# This field is immutable after creation time.
# Corresponds to the JSON property `resourceName`
# @return [String]
attr_accessor :resource_name
# User specified security marks that are attached to the parent Cloud Security
# Command Center (Cloud SCC) resource. Security marks are scoped within a Cloud
# SCC organization -- they can be modified and viewed by all users who have
# proper permissions on the organization.
# Corresponds to the JSON property `securityMarks`
# @return [Google::Apis::SecuritycenterV1p1beta1::SecurityMarks]
attr_accessor :security_marks
# Source specific properties. These properties are managed by the source
# that writes the finding. The key names in the source_properties map must be
# between 1 and 255 characters, and must start with a letter and contain
# alphanumeric characters or underscores only.
# Corresponds to the JSON property `sourceProperties`
# @return [Hash<String,Object>]
attr_accessor :source_properties
# The state of the finding.
# Corresponds to the JSON property `state`
# @return [String]
attr_accessor :state
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@category = args[:category] if args.key?(:category)
@create_time = args[:create_time] if args.key?(:create_time)
@event_time = args[:event_time] if args.key?(:event_time)
@external_uri = args[:external_uri] if args.key?(:external_uri)
@name = args[:name] if args.key?(:name)
@parent = args[:parent] if args.key?(:parent)
@resource_name = args[:resource_name] if args.key?(:resource_name)
@security_marks = args[:security_marks] if args.key?(:security_marks)
@source_properties = args[:source_properties] if args.key?(:source_properties)
@state = args[:state] if args.key?(:state)
end
end
# Request message for `GetIamPolicy` method.
class GetIamPolicyRequest
include Google::Apis::Core::Hashable
@ -371,6 +473,36 @@ module Google
end
end
# Cloud SCC's Notification
class GoogleCloudSecuritycenterV1NotificationMessage
include Google::Apis::Core::Hashable
# Cloud Security Command Center (Cloud SCC) finding.
# A finding is a record of assessment data like security, risk, health, or
# privacy, that is ingested into Cloud SCC for presentation, notification,
# analysis, policy testing, and enforcement. For example, a
# cross-site scripting (XSS) vulnerability in an App Engine application is a
# finding.
# Corresponds to the JSON property `finding`
# @return [Google::Apis::SecuritycenterV1p1beta1::Finding]
attr_accessor :finding
# Name of the notification config that generated current notification.
# Corresponds to the JSON property `notificationConfigName`
# @return [String]
attr_accessor :notification_config_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@finding = args[:finding] if args.key?(:finding)
@notification_config_name = args[:notification_config_name] if args.key?(:notification_config_name)
end
end
# Response of asset discovery run
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
include Google::Apis::Core::Hashable
@ -1730,6 +1862,45 @@ module Google
end
end
# User specified security marks that are attached to the parent Cloud Security
# Command Center (Cloud SCC) resource. Security marks are scoped within a Cloud
# SCC organization -- they can be modified and viewed by all users who have
# proper permissions on the organization.
class SecurityMarks
include Google::Apis::Core::Hashable
# Mutable user specified security marks belonging to the parent resource.
# Constraints are as follows:
# * Keys and values are treated as case insensitive
# * Keys must be between 1 - 256 characters (inclusive)
# * Keys must be letters, numbers, underscores, or dashes
# * Values have leading and trailing whitespace trimmed, remaining
# characters must be between 1 - 4096 characters (inclusive)
# Corresponds to the JSON property `marks`
# @return [Hash<String,String>]
attr_accessor :marks
# The relative resource name of the SecurityMarks. See:
# https://cloud.google.com/apis/design/resource_names#relative_resource_name
# Examples:
# "organizations/`organization_id`/assets/`asset_id`/securityMarks"
# "organizations/`organization_id`/sources/`source_id`/findings/`finding_id`/
# securityMarks".
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@marks = args[:marks] if args.key?(:marks)
@name = args[:name] if args.key?(:name)
end
end
# Request message for updating a finding's state.
class SetFindingStateRequest
include Google::Apis::Core::Hashable

View File

@ -58,6 +58,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class Finding
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -70,6 +76,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1NotificationMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -238,6 +250,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class SecurityMarks
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SetFindingStateRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -331,6 +349,23 @@ module Google
end
end
class Finding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :category, as: 'category'
property :create_time, as: 'createTime'
property :event_time, as: 'eventTime'
property :external_uri, as: 'externalUri'
property :name, as: 'name'
property :parent, as: 'parent'
property :resource_name, as: 'resourceName'
property :security_marks, as: 'securityMarks', class: Google::Apis::SecuritycenterV1p1beta1::SecurityMarks, decorator: Google::Apis::SecuritycenterV1p1beta1::SecurityMarks::Representation
hash :source_properties, as: 'sourceProperties'
property :state, as: 'state'
end
end
class GetIamPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -346,6 +381,15 @@ module Google
end
end
class GoogleCloudSecuritycenterV1NotificationMessage
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :finding, as: 'finding', class: Google::Apis::SecuritycenterV1p1beta1::Finding, decorator: Google::Apis::SecuritycenterV1p1beta1::Finding::Representation
property :notification_config_name, as: 'notificationConfigName'
end
end
class GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -639,6 +683,14 @@ module Google
end
end
class SecurityMarks
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :marks, as: 'marks'
property :name, as: 'name'
end
end
class SetFindingStateRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/translate/docs/quickstarts
module TranslateV3
VERSION = 'V3'
REVISION = '20200221'
REVISION = '20200306'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -230,9 +230,12 @@ module Google
class GcsDestination
include Google::Apis::Core::Hashable
# Required. There must be no files under 'output_uri_prefix'.
# 'output_uri_prefix' must end with "/" and start with "gs://", otherwise an
# INVALID_ARGUMENT (400) error is returned.
# Required. The bucket used in 'output_uri_prefix' must exist and there must be
# no
# files under 'output_uri_prefix'. 'output_uri_prefix' must end with "/" and
# start with "gs://". One 'output_uri_prefix' can only be used by one batch
# translation job at a time. Otherwise an INVALID_ARGUMENT (400) error is
# returned.
# Corresponds to the JSON property `outputUriPrefix`
# @return [String]
attr_accessor :output_uri_prefix