Class: Google::Apis::SecuritycenterV1::GoogleCloudSecuritycenterV2IpRules

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

Overview

IP rules associated with the finding.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudSecuritycenterV2IpRules

Returns a new instance of GoogleCloudSecuritycenterV2IpRules.



8708
8709
8710
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8708

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

Instance Attribute Details

#allowedGoogle::Apis::SecuritycenterV1::GoogleCloudSecuritycenterV2Allowed

Allowed IP rule. Corresponds to the JSON property allowed



8675
8676
8677
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8675

def allowed
  @allowed
end

#deniedGoogle::Apis::SecuritycenterV1::GoogleCloudSecuritycenterV2Denied

Denied IP rule. Corresponds to the JSON property denied



8680
8681
8682
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8680

def denied
  @denied
end

#destination_ip_rangesArray<String>

If destination IP ranges are specified, the firewall rule applies only to traffic that has a destination IP address in these ranges. These ranges must be expressed in CIDR format. Only supports IPv4. Corresponds to the JSON property destinationIpRanges

Returns:

  • (Array<String>)


8687
8688
8689
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8687

def destination_ip_ranges
  @destination_ip_ranges
end

#directionString

The direction that the rule is applicable to, one of ingress or egress. Corresponds to the JSON property direction

Returns:

  • (String)


8692
8693
8694
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8692

def direction
  @direction
end

#exposed_servicesArray<String>

Name of the network protocol service, such as FTP, that is exposed by the open port. Follows the naming convention available at: https://www.iana.org/ assignments/service-names-port-numbers/service-names-port-numbers.xhtml. Corresponds to the JSON property exposedServices

Returns:

  • (Array<String>)


8699
8700
8701
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8699

def exposed_services
  @exposed_services
end

#source_ip_rangesArray<String>

If source IP ranges are specified, the firewall rule applies only to traffic that has a source IP address in these ranges. These ranges must be expressed in CIDR format. Only supports IPv4. Corresponds to the JSON property sourceIpRanges

Returns:

  • (Array<String>)


8706
8707
8708
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8706

def source_ip_ranges
  @source_ip_ranges
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



8713
8714
8715
8716
8717
8718
8719
8720
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 8713

def update!(**args)
  @allowed = args[:allowed] if args.key?(:allowed)
  @denied = args[:denied] if args.key?(:denied)
  @destination_ip_ranges = args[:destination_ip_ranges] if args.key?(:destination_ip_ranges)
  @direction = args[:direction] if args.key?(:direction)
  @exposed_services = args[:exposed_services] if args.key?(:exposed_services)
  @source_ip_ranges = args[:source_ip_ranges] if args.key?(:source_ip_ranges)
end