Class: Google::Apis::SecuritycenterV1beta2::GoogleCloudSecuritycenterV1ResourceValueConfig

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/securitycenter_v1beta2/classes.rb,
lib/google/apis/securitycenter_v1beta2/representations.rb,
lib/google/apis/securitycenter_v1beta2/representations.rb

Overview

A resource value config is a mapping configuration of user's tag values to resource values. Used by the attack path simulation.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudSecuritycenterV1ResourceValueConfig

Returns a new instance of GoogleCloudSecuritycenterV1ResourceValueConfig.



2007
2008
2009
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 2007

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#create_timeString

Output only. Timestamp this resource value config was created. Corresponds to the JSON property createTime

Returns:

  • (String)


1955
1956
1957
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1955

def create_time
  @create_time
end

#descriptionString

Description of the resource value config. Corresponds to the JSON property description

Returns:

  • (String)


1960
1961
1962
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1960

def description
  @description
end

#nameString

Name for the resource value config Corresponds to the JSON property name

Returns:

  • (String)


1965
1966
1967
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1965

def name
  @name
end

#resource_labels_selectorHash<String,String>

List of resource labels to search for, evaluated with AND. E.g. " resource_labels_selector": "key": "value", "env": "prod" will match resources with labels "key": "value" AND "env": "prod" https://cloud.google. com/resource-manager/docs/creating-managing-labels Corresponds to the JSON property resourceLabelsSelector

Returns:

  • (Hash<String,String>)


1973
1974
1975
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1973

def resource_labels_selector
  @resource_labels_selector
end

#resource_typeString

Apply resource_value only to resources that match resource_type. resource_type will be checked with "AND" of other resources. E.g. "storage.googleapis.com/ Bucket" with resource_value "HIGH" will apply "HIGH" value only to "storage. googleapis.com/Bucket" resources. Corresponds to the JSON property resourceType

Returns:

  • (String)


1981
1982
1983
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1981

def resource_type
  @resource_type
end

#resource_valueString

Required. Resource value level this expression represents Corresponds to the JSON property resourceValue

Returns:

  • (String)


1986
1987
1988
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1986

def resource_value
  @resource_value
end

#scopeString

Project or folder to scope this config to. For example, "project/456" would apply this config only to resources in "project/456" scope will be checked with "AND" of other resources. Corresponds to the JSON property scope

Returns:

  • (String)


1993
1994
1995
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 1993

def scope
  @scope
end

#tag_valuesArray<String>

Required. Tag values combined with AND to check against. Values in the form " tagValues/123" E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing Corresponds to the JSON property tagValues

Returns:

  • (Array<String>)


2000
2001
2002
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 2000

def tag_values
  @tag_values
end

#update_timeString

Output only. Timestamp this resource value config was last updated. Corresponds to the JSON property updateTime

Returns:

  • (String)


2005
2006
2007
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 2005

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
# File 'lib/google/apis/securitycenter_v1beta2/classes.rb', line 2012

def update!(**args)
  @create_time = args[:create_time] if args.key?(:create_time)
  @description = args[:description] if args.key?(:description)
  @name = args[:name] if args.key?(:name)
  @resource_labels_selector = args[:resource_labels_selector] if args.key?(:resource_labels_selector)
  @resource_type = args[:resource_type] if args.key?(:resource_type)
  @resource_value = args[:resource_value] if args.key?(:resource_value)
  @scope = args[:scope] if args.key?(:scope)
  @tag_values = args[:tag_values] if args.key?(:tag_values)
  @update_time = args[:update_time] if args.key?(:update_time)
end