google-apis-networksecurity_v1beta1 0.72.0 → 0.74.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.
@@ -3435,6 +3435,37 @@ module Google
3435
3435
  end
3436
3436
  end
3437
3437
 
3438
+ # Contains a response to listing `RateLimitPolicy` resources.
3439
+ class ListRateLimitPoliciesResponse
3440
+ include Google::Apis::Core::Hashable
3441
+
3442
+ # Identifies a token for a page of results the server should return.
3443
+ # Corresponds to the JSON property `nextPageToken`
3444
+ # @return [String]
3445
+ attr_accessor :next_page_token
3446
+
3447
+ # Contains a list of `RateLimitPolicy` resources.
3448
+ # Corresponds to the JSON property `rateLimitPolicies`
3449
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicy>]
3450
+ attr_accessor :rate_limit_policies
3451
+
3452
+ # Unordered list. Lists locations that could not be reached.
3453
+ # Corresponds to the JSON property `unreachable`
3454
+ # @return [Array<String>]
3455
+ attr_accessor :unreachable
3456
+
3457
+ def initialize(**args)
3458
+ update!(**args)
3459
+ end
3460
+
3461
+ # Update properties of this object
3462
+ def update!(**args)
3463
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
3464
+ @rate_limit_policies = args[:rate_limit_policies] if args.key?(:rate_limit_policies)
3465
+ @unreachable = args[:unreachable] if args.key?(:unreachable)
3466
+ end
3467
+ end
3468
+
3438
3469
  # Response for `ListSACAttachments` method.
3439
3470
  class ListSacAttachmentsResponse
3440
3471
  include Google::Apis::Core::Hashable
@@ -3749,6 +3780,12 @@ module Google
3749
3780
  # @return [String]
3750
3781
  attr_accessor :client_validation_mode
3751
3782
 
3783
+ # A list of validation relaxations to apply when `client_validation_mode` is set
3784
+ # to ALLOW_VALIDATION_RELAXATIONS.
3785
+ # Corresponds to the JSON property `clientValidationRelaxations`
3786
+ # @return [Array<String>]
3787
+ attr_accessor :client_validation_relaxations
3788
+
3752
3789
  # Reference to the TrustConfig from certificatemanager.googleapis.com namespace.
3753
3790
  # If specified, the chain validation will be performed against certificates
3754
3791
  # configured in the given TrustConfig. Allowed only if the policy is to be used
@@ -3765,6 +3802,7 @@ module Google
3765
3802
  def update!(**args)
3766
3803
  @client_validation_ca = args[:client_validation_ca] if args.key?(:client_validation_ca)
3767
3804
  @client_validation_mode = args[:client_validation_mode] if args.key?(:client_validation_mode)
3805
+ @client_validation_relaxations = args[:client_validation_relaxations] if args.key?(:client_validation_relaxations)
3768
3806
  @client_validation_trust_config = args[:client_validation_trust_config] if args.key?(:client_validation_trust_config)
3769
3807
  end
3770
3808
  end
@@ -4428,6 +4466,722 @@ module Google
4428
4466
  end
4429
4467
  end
4430
4468
 
4469
+ # Describes a `RateLimitPolicy` object.
4470
+ class RateLimitPolicy
4471
+ include Google::Apis::Core::Hashable
4472
+
4473
+ # Output only. Represents the create timestamp.
4474
+ # Corresponds to the JSON property `createTime`
4475
+ # @return [String]
4476
+ attr_accessor :create_time
4477
+
4478
+ # Optional. Provides a human-readable description of the resource.
4479
+ # Corresponds to the JSON property `description`
4480
+ # @return [String]
4481
+ attr_accessor :description
4482
+
4483
+ # Optional. Specifies a list of rate limit HTTP rules to match against the
4484
+ # incoming request.
4485
+ # Corresponds to the JSON property `httpRules`
4486
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRule>]
4487
+ attr_accessor :http_rules
4488
+
4489
+ # Optional. Stores labels as key value pairs.
4490
+ # Corresponds to the JSON property `labels`
4491
+ # @return [Hash<String,String>]
4492
+ attr_accessor :labels
4493
+
4494
+ # Identifier. Specifies the name of the `RateLimitPolicy` resource.
4495
+ # Corresponds to the JSON property `name`
4496
+ # @return [String]
4497
+ attr_accessor :name
4498
+
4499
+ # Optional. Specifies a list of rate limit buckets to be used for rate limiting.
4500
+ # Rate limit buckets will be referenced by the rate limit actions by name.
4501
+ # Corresponds to the JSON property `rateLimitBuckets`
4502
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucket>]
4503
+ attr_accessor :rate_limit_buckets
4504
+
4505
+ # Required. Specifies a list of targets to which this policy applies.
4506
+ # Corresponds to the JSON property `targets`
4507
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyTarget>]
4508
+ attr_accessor :targets
4509
+
4510
+ # Output only. Represents the update timestamp.
4511
+ # Corresponds to the JSON property `updateTime`
4512
+ # @return [String]
4513
+ attr_accessor :update_time
4514
+
4515
+ def initialize(**args)
4516
+ update!(**args)
4517
+ end
4518
+
4519
+ # Update properties of this object
4520
+ def update!(**args)
4521
+ @create_time = args[:create_time] if args.key?(:create_time)
4522
+ @description = args[:description] if args.key?(:description)
4523
+ @http_rules = args[:http_rules] if args.key?(:http_rules)
4524
+ @labels = args[:labels] if args.key?(:labels)
4525
+ @name = args[:name] if args.key?(:name)
4526
+ @rate_limit_buckets = args[:rate_limit_buckets] if args.key?(:rate_limit_buckets)
4527
+ @targets = args[:targets] if args.key?(:targets)
4528
+ @update_time = args[:update_time] if args.key?(:update_time)
4529
+ end
4530
+ end
4531
+
4532
+ # Describes properties of a rate limit bucket.
4533
+ class RateLimitPolicyRateLimitBucket
4534
+ include Google::Apis::Core::Hashable
4535
+
4536
+ # Describes a limit for enforcement.
4537
+ # Corresponds to the JSON property `defaultLimit`
4538
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketLimit]
4539
+ attr_accessor :default_limit
4540
+
4541
+ # Optional. Specifies whether the rate limit bucket is in dry-run mode.
4542
+ # Corresponds to the JSON property `dryRun`
4543
+ # @return [Boolean]
4544
+ attr_accessor :dry_run
4545
+ alias_method :dry_run?, :dry_run
4546
+
4547
+ # Required. Specifies the keys to use for rate limiting. At least one key is
4548
+ # required. If multiple keys are specified, the keys will be combined and used
4549
+ # as a single key.
4550
+ # Corresponds to the JSON property `keys`
4551
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketKey>]
4552
+ attr_accessor :keys
4553
+
4554
+ # Required. Specifies the name of the rate limit bucket. Name will be used to
4555
+ # reference the bucket in the RateLimitAction.
4556
+ # Corresponds to the JSON property `name`
4557
+ # @return [String]
4558
+ attr_accessor :name
4559
+
4560
+ # Optional. Specifies a list of user overrides to apply to the rate limit bucket.
4561
+ # Corresponds to the JSON property `userOverrides`
4562
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketUserOverride>]
4563
+ attr_accessor :user_overrides
4564
+
4565
+ def initialize(**args)
4566
+ update!(**args)
4567
+ end
4568
+
4569
+ # Update properties of this object
4570
+ def update!(**args)
4571
+ @default_limit = args[:default_limit] if args.key?(:default_limit)
4572
+ @dry_run = args[:dry_run] if args.key?(:dry_run)
4573
+ @keys = args[:keys] if args.key?(:keys)
4574
+ @name = args[:name] if args.key?(:name)
4575
+ @user_overrides = args[:user_overrides] if args.key?(:user_overrides)
4576
+ end
4577
+ end
4578
+
4579
+ # Describes the count limit for enforcement.
4580
+ class RateLimitPolicyRateLimitBucketCountLimit
4581
+ include Google::Apis::Core::Hashable
4582
+
4583
+ # Required. Specifies the maximum number of costs allowed in the specified
4584
+ # interval. Must be non-negative.
4585
+ # Corresponds to the JSON property `count`
4586
+ # @return [Fixnum]
4587
+ attr_accessor :count
4588
+
4589
+ # Required. Specifies the interval in units for which the count limit is
4590
+ # enforced. Must be positive.
4591
+ # Corresponds to the JSON property `interval`
4592
+ # @return [Fixnum]
4593
+ attr_accessor :interval
4594
+
4595
+ # Required. Specifies the unit of the interval. Defaults to MINUTES.
4596
+ # Corresponds to the JSON property `intervalUnit`
4597
+ # @return [String]
4598
+ attr_accessor :interval_unit
4599
+
4600
+ def initialize(**args)
4601
+ update!(**args)
4602
+ end
4603
+
4604
+ # Update properties of this object
4605
+ def update!(**args)
4606
+ @count = args[:count] if args.key?(:count)
4607
+ @interval = args[:interval] if args.key?(:interval)
4608
+ @interval_unit = args[:interval_unit] if args.key?(:interval_unit)
4609
+ end
4610
+ end
4611
+
4612
+ # Describes properties of a key to use for rate limiting.
4613
+ class RateLimitPolicyRateLimitBucketKey
4614
+ include Google::Apis::Core::Hashable
4615
+
4616
+ # Optional. Specifies the header name if key_type is HTTP_HEADER.
4617
+ # Corresponds to the JSON property `header`
4618
+ # @return [String]
4619
+ attr_accessor :header
4620
+
4621
+ # Required. Specifies the type of key to use for rate limiting.
4622
+ # Corresponds to the JSON property `keyType`
4623
+ # @return [String]
4624
+ attr_accessor :key_type
4625
+
4626
+ # Optional. Specifies the principal type if key_type is PRINCIPAL.
4627
+ # Corresponds to the JSON property `principalType`
4628
+ # @return [String]
4629
+ attr_accessor :principal_type
4630
+
4631
+ def initialize(**args)
4632
+ update!(**args)
4633
+ end
4634
+
4635
+ # Update properties of this object
4636
+ def update!(**args)
4637
+ @header = args[:header] if args.key?(:header)
4638
+ @key_type = args[:key_type] if args.key?(:key_type)
4639
+ @principal_type = args[:principal_type] if args.key?(:principal_type)
4640
+ end
4641
+ end
4642
+
4643
+ # Describes a limit for enforcement.
4644
+ class RateLimitPolicyRateLimitBucketLimit
4645
+ include Google::Apis::Core::Hashable
4646
+
4647
+ # Describes the count limit for enforcement.
4648
+ # Corresponds to the JSON property `countLimit`
4649
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketCountLimit]
4650
+ attr_accessor :count_limit
4651
+
4652
+ def initialize(**args)
4653
+ update!(**args)
4654
+ end
4655
+
4656
+ # Update properties of this object
4657
+ def update!(**args)
4658
+ @count_limit = args[:count_limit] if args.key?(:count_limit)
4659
+ end
4660
+ end
4661
+
4662
+ # Describes properties of a user override for the rate limit bucket.
4663
+ class RateLimitPolicyRateLimitBucketUserOverride
4664
+ include Google::Apis::Core::Hashable
4665
+
4666
+ # Describes a limit for enforcement.
4667
+ # Corresponds to the JSON property `limit`
4668
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketLimit]
4669
+ attr_accessor :limit
4670
+
4671
+ # Specifies the key to override. Key fields must match the key types specified
4672
+ # in the rate limit bucket. Key type ALL does not support overrides.
4673
+ # Corresponds to the JSON property `overrideKey`
4674
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketUserOverrideOverrideKey]
4675
+ attr_accessor :override_key
4676
+
4677
+ def initialize(**args)
4678
+ update!(**args)
4679
+ end
4680
+
4681
+ # Update properties of this object
4682
+ def update!(**args)
4683
+ @limit = args[:limit] if args.key?(:limit)
4684
+ @override_key = args[:override_key] if args.key?(:override_key)
4685
+ end
4686
+ end
4687
+
4688
+ # Specifies the key to override. Key fields must match the key types specified
4689
+ # in the rate limit bucket. Key type ALL does not support overrides.
4690
+ class RateLimitPolicyRateLimitBucketUserOverrideOverrideKey
4691
+ include Google::Apis::Core::Hashable
4692
+
4693
+ # Optional. Specifies the HTTP headers if the rate limit bucket keys contain
4694
+ # keys of type HTTP_HEADER. Number of headers and header names must match the
4695
+ # rate limit bucket key.
4696
+ # Corresponds to the JSON property `httpHeaders`
4697
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketUserOverrideOverrideKeyHttpHeader>]
4698
+ attr_accessor :http_headers
4699
+
4700
+ # Optional. Specifies the HTTP path if the rate limit bucket keys contain a key
4701
+ # of type HTTP_PATH.
4702
+ # Corresponds to the JSON property `httpPath`
4703
+ # @return [String]
4704
+ attr_accessor :http_path
4705
+
4706
+ # Optional. Specifies the MCP tool if the rate limit bucket keys contain a key
4707
+ # of type MCP_TOOL.
4708
+ # Corresponds to the JSON property `mcpTool`
4709
+ # @return [String]
4710
+ attr_accessor :mcp_tool
4711
+
4712
+ # Optional. Specifies the principals if the rate limit bucket keys contain keys
4713
+ # of PRINCIPAL. Number of principals and principal types must match the rate
4714
+ # limit bucket key.
4715
+ # Corresponds to the JSON property `principals`
4716
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitBucketUserOverrideOverrideKeyPrincipal>]
4717
+ attr_accessor :principals
4718
+
4719
+ # Optional. Specifies the source IP if the rate limit bucket keys contain a key
4720
+ # of type SOURCE_IP.
4721
+ # Corresponds to the JSON property `sourceIp`
4722
+ # @return [String]
4723
+ attr_accessor :source_ip
4724
+
4725
+ def initialize(**args)
4726
+ update!(**args)
4727
+ end
4728
+
4729
+ # Update properties of this object
4730
+ def update!(**args)
4731
+ @http_headers = args[:http_headers] if args.key?(:http_headers)
4732
+ @http_path = args[:http_path] if args.key?(:http_path)
4733
+ @mcp_tool = args[:mcp_tool] if args.key?(:mcp_tool)
4734
+ @principals = args[:principals] if args.key?(:principals)
4735
+ @source_ip = args[:source_ip] if args.key?(:source_ip)
4736
+ end
4737
+ end
4738
+
4739
+ # Specifies the key in the type HTTP header to override.
4740
+ class RateLimitPolicyRateLimitBucketUserOverrideOverrideKeyHttpHeader
4741
+ include Google::Apis::Core::Hashable
4742
+
4743
+ # Required. Specifies the header name of the key.
4744
+ # Corresponds to the JSON property `header`
4745
+ # @return [String]
4746
+ attr_accessor :header
4747
+
4748
+ # Required. Specifies the header value of the key.
4749
+ # Corresponds to the JSON property `value`
4750
+ # @return [String]
4751
+ attr_accessor :value
4752
+
4753
+ def initialize(**args)
4754
+ update!(**args)
4755
+ end
4756
+
4757
+ # Update properties of this object
4758
+ def update!(**args)
4759
+ @header = args[:header] if args.key?(:header)
4760
+ @value = args[:value] if args.key?(:value)
4761
+ end
4762
+ end
4763
+
4764
+ # Specifies the key in the type PRINCIPAL to override.
4765
+ class RateLimitPolicyRateLimitBucketUserOverrideOverrideKeyPrincipal
4766
+ include Google::Apis::Core::Hashable
4767
+
4768
+ # Required. Specifies the principal value of the key.
4769
+ # Corresponds to the JSON property `principal`
4770
+ # @return [String]
4771
+ attr_accessor :principal
4772
+
4773
+ # Required. Specifies the principal type of the key.
4774
+ # Corresponds to the JSON property `principalType`
4775
+ # @return [String]
4776
+ attr_accessor :principal_type
4777
+
4778
+ def initialize(**args)
4779
+ update!(**args)
4780
+ end
4781
+
4782
+ # Update properties of this object
4783
+ def update!(**args)
4784
+ @principal = args[:principal] if args.key?(:principal)
4785
+ @principal_type = args[:principal_type] if args.key?(:principal_type)
4786
+ end
4787
+ end
4788
+
4789
+ # Specifies conditions to match against the incoming request.
4790
+ class RateLimitPolicyRateLimitRule
4791
+ include Google::Apis::Core::Hashable
4792
+
4793
+ # Describes properties of the sources of a request.
4794
+ # Corresponds to the JSON property `from`
4795
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleFrom]
4796
+ attr_accessor :from
4797
+
4798
+ # Optional. Specifies the actions to take when this rule is matched.
4799
+ # Corresponds to the JSON property `rateLimitActions`
4800
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleRateLimitAction>]
4801
+ attr_accessor :rate_limit_actions
4802
+
4803
+ # Describes properties of the targets of a request.
4804
+ # Corresponds to the JSON property `to`
4805
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleTo]
4806
+ attr_accessor :to
4807
+
4808
+ def initialize(**args)
4809
+ update!(**args)
4810
+ end
4811
+
4812
+ # Update properties of this object
4813
+ def update!(**args)
4814
+ @from = args[:from] if args.key?(:from)
4815
+ @rate_limit_actions = args[:rate_limit_actions] if args.key?(:rate_limit_actions)
4816
+ @to = args[:to] if args.key?(:to)
4817
+ end
4818
+ end
4819
+
4820
+ # Describes properties of the sources of a request.
4821
+ class RateLimitPolicyRateLimitRuleFrom
4822
+ include Google::Apis::Core::Hashable
4823
+
4824
+ # Describes the properties of a request source.
4825
+ # Corresponds to the JSON property `notSource`
4826
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleFromSource]
4827
+ attr_accessor :not_source
4828
+
4829
+ # Describes the properties of a request source.
4830
+ # Corresponds to the JSON property `source`
4831
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleFromSource]
4832
+ attr_accessor :source
4833
+
4834
+ def initialize(**args)
4835
+ update!(**args)
4836
+ end
4837
+
4838
+ # Update properties of this object
4839
+ def update!(**args)
4840
+ @not_source = args[:not_source] if args.key?(:not_source)
4841
+ @source = args[:source] if args.key?(:source)
4842
+ end
4843
+ end
4844
+
4845
+ # Describes the properties of a request source.
4846
+ class RateLimitPolicyRateLimitRuleFromSource
4847
+ include Google::Apis::Core::Hashable
4848
+
4849
+ # Required. Contains a list of identities derived from the client's certificate.
4850
+ # This field does not match on a request unless frontend mutual TLS is enabled
4851
+ # for the Gateway and the client certificate is successfully validated by mTLS.
4852
+ # Each identity is a string whose value is matched against a list of URI SANs,
4853
+ # DNS Name SANs, or the common name in the client's certificate. A match happens
4854
+ # when any principal matches with the rule.
4855
+ # Corresponds to the JSON property `principals`
4856
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRulePrincipal>]
4857
+ attr_accessor :principals
4858
+
4859
+ def initialize(**args)
4860
+ update!(**args)
4861
+ end
4862
+
4863
+ # Update properties of this object
4864
+ def update!(**args)
4865
+ @principals = args[:principals] if args.key?(:principals)
4866
+ end
4867
+ end
4868
+
4869
+ # Determines how an HTTP header is matched.
4870
+ class RateLimitPolicyRateLimitRuleHeaderMatch
4871
+ include Google::Apis::Core::Hashable
4872
+
4873
+ # Optional. Specifies the name of the header in the request.
4874
+ # Corresponds to the JSON property `name`
4875
+ # @return [String]
4876
+ attr_accessor :name
4877
+
4878
+ # Determines how a string value is matched.
4879
+ # Corresponds to the JSON property `value`
4880
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleStringMatch]
4881
+ attr_accessor :value
4882
+
4883
+ def initialize(**args)
4884
+ update!(**args)
4885
+ end
4886
+
4887
+ # Update properties of this object
4888
+ def update!(**args)
4889
+ @name = args[:name] if args.key?(:name)
4890
+ @value = args[:value] if args.key?(:value)
4891
+ end
4892
+ end
4893
+
4894
+ # Describes the properties of a principal for matching.
4895
+ class RateLimitPolicyRateLimitRulePrincipal
4896
+ include Google::Apis::Core::Hashable
4897
+
4898
+ # Determines how a string value is matched.
4899
+ # Corresponds to the JSON property `principal`
4900
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleStringMatch]
4901
+ attr_accessor :principal
4902
+
4903
+ # Optional. Decides what principal value the principal rule will match against.
4904
+ # If not specified, defaults to CLIENT_CERT_URI_SAN.
4905
+ # Corresponds to the JSON property `principalSelector`
4906
+ # @return [String]
4907
+ attr_accessor :principal_selector
4908
+
4909
+ def initialize(**args)
4910
+ update!(**args)
4911
+ end
4912
+
4913
+ # Update properties of this object
4914
+ def update!(**args)
4915
+ @principal = args[:principal] if args.key?(:principal)
4916
+ @principal_selector = args[:principal_selector] if args.key?(:principal_selector)
4917
+ end
4918
+ end
4919
+
4920
+ # Describes the action to take when the rate limit rule is matched.
4921
+ class RateLimitPolicyRateLimitRuleRateLimitAction
4922
+ include Google::Apis::Core::Hashable
4923
+
4924
+ # Required. Specifies the name of the rate limit bucket to apply when this rule
4925
+ # is matched.
4926
+ # Corresponds to the JSON property `rateLimitBucket`
4927
+ # @return [String]
4928
+ attr_accessor :rate_limit_bucket
4929
+
4930
+ def initialize(**args)
4931
+ update!(**args)
4932
+ end
4933
+
4934
+ # Update properties of this object
4935
+ def update!(**args)
4936
+ @rate_limit_bucket = args[:rate_limit_bucket] if args.key?(:rate_limit_bucket)
4937
+ end
4938
+ end
4939
+
4940
+ # Determines how a string value is matched.
4941
+ class RateLimitPolicyRateLimitRuleStringMatch
4942
+ include Google::Apis::Core::Hashable
4943
+
4944
+ # Checks if the input string contains the substring specified here. Note: empty
4945
+ # contains match is not allowed, please use regex instead. Examples: * ``abc``
4946
+ # matches the value ``xyz.abc.def``
4947
+ # Corresponds to the JSON property `contains`
4948
+ # @return [String]
4949
+ attr_accessor :contains
4950
+
4951
+ # Matches the input string exactly to the string specified here. Examples: * ``
4952
+ # abc`` only matches the value ``abc``.
4953
+ # Corresponds to the JSON property `exact`
4954
+ # @return [String]
4955
+ attr_accessor :exact
4956
+
4957
+ # Optional. Indicates if the exact/prefix/suffix/contains matching should be
4958
+ # case insensitive. For example, when true, the matcher ``data`` matches both
4959
+ # input strings ``Data`` and ``data``.
4960
+ # Corresponds to the JSON property `ignoreCase`
4961
+ # @return [Boolean]
4962
+ attr_accessor :ignore_case
4963
+ alias_method :ignore_case?, :ignore_case
4964
+
4965
+ # Checks if the input string has the prefix specified here. Note: empty prefix
4966
+ # is not allowed, please use regex instead. Examples: * ``abc`` matches the
4967
+ # value ``abc.xyz``
4968
+ # Corresponds to the JSON property `prefix`
4969
+ # @return [String]
4970
+ attr_accessor :prefix
4971
+
4972
+ # Checks if the input string has the suffix specified here. Note: empty suffix
4973
+ # is not allowed, please use regex instead. Examples: * ``abc`` matches the
4974
+ # value ``xyz.abc``
4975
+ # Corresponds to the JSON property `suffix`
4976
+ # @return [String]
4977
+ attr_accessor :suffix
4978
+
4979
+ def initialize(**args)
4980
+ update!(**args)
4981
+ end
4982
+
4983
+ # Update properties of this object
4984
+ def update!(**args)
4985
+ @contains = args[:contains] if args.key?(:contains)
4986
+ @exact = args[:exact] if args.key?(:exact)
4987
+ @ignore_case = args[:ignore_case] if args.key?(:ignore_case)
4988
+ @prefix = args[:prefix] if args.key?(:prefix)
4989
+ @suffix = args[:suffix] if args.key?(:suffix)
4990
+ end
4991
+ end
4992
+
4993
+ # Describes properties of the targets of a request.
4994
+ class RateLimitPolicyRateLimitRuleTo
4995
+ include Google::Apis::Core::Hashable
4996
+
4997
+ # Describes properties of a request target.
4998
+ # Corresponds to the JSON property `destination`
4999
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleToDestination]
5000
+ attr_accessor :destination
5001
+
5002
+ # Describes properties of a request target.
5003
+ # Corresponds to the JSON property `notDestination`
5004
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleToDestination]
5005
+ attr_accessor :not_destination
5006
+
5007
+ def initialize(**args)
5008
+ update!(**args)
5009
+ end
5010
+
5011
+ # Update properties of this object
5012
+ def update!(**args)
5013
+ @destination = args[:destination] if args.key?(:destination)
5014
+ @not_destination = args[:not_destination] if args.key?(:not_destination)
5015
+ end
5016
+ end
5017
+
5018
+ # Describes properties of a request target.
5019
+ class RateLimitPolicyRateLimitRuleToDestination
5020
+ include Google::Apis::Core::Hashable
5021
+
5022
+ # Describes a set of HTTP headers to match against.
5023
+ # Corresponds to the JSON property `headerSet`
5024
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleToDestinationHeaderSet]
5025
+ attr_accessor :header_set
5026
+
5027
+ # Optional. Specifies a list of HTTP Hosts to match against. The match can be
5028
+ # one of exact, prefix, suffix, or contains (substring match). Matches are
5029
+ # always case sensitive unless the ignoreCase is set. The match follows OR
5030
+ # semantics which means that if any of the hosts match, the operation is
5031
+ # considered to be matched.
5032
+ # Corresponds to the JSON property `hosts`
5033
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleStringMatch>]
5034
+ attr_accessor :hosts
5035
+
5036
+ # Describes a set of MCP protocol attributes to match against for a given MCP
5037
+ # request. This field is only valid if the targeted Gateway or Forwarding Rule
5038
+ # has an Agent Gateway attached to it.
5039
+ # Corresponds to the JSON property `mcp`
5040
+ # @return [Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleToDestinationMcp]
5041
+ attr_accessor :mcp
5042
+
5043
+ # Optional. Specifies a list of HTTP methods to match against. Each entry must
5044
+ # be a valid HTTP method name (GET, PUT, POST, HEAD, PATCH, DELETE, OPTIONS). It
5045
+ # only allows exact match and is always case sensitive. The match follows OR
5046
+ # semantics which means that if any of the methods match, the operation is
5047
+ # considered to be matched.
5048
+ # Corresponds to the JSON property `methods`
5049
+ # @return [Array<String>]
5050
+ attr_accessor :methods_prop
5051
+
5052
+ # Optional. Specifies a list of paths to match against. The match can be one of
5053
+ # exact, prefix, suffix, or contains (substring match). Matches are always case
5054
+ # sensitive unless the ignoreCase is set. The match follows OR semantics which
5055
+ # means that if any of the paths match, the operation is considered to be
5056
+ # matched. Note that this path match includes the query parameters. For gRPC
5057
+ # services, this should be a fully-qualified name of the form /package.service/
5058
+ # method.
5059
+ # Corresponds to the JSON property `paths`
5060
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleStringMatch>]
5061
+ attr_accessor :paths
5062
+
5063
+ def initialize(**args)
5064
+ update!(**args)
5065
+ end
5066
+
5067
+ # Update properties of this object
5068
+ def update!(**args)
5069
+ @header_set = args[:header_set] if args.key?(:header_set)
5070
+ @hosts = args[:hosts] if args.key?(:hosts)
5071
+ @mcp = args[:mcp] if args.key?(:mcp)
5072
+ @methods_prop = args[:methods_prop] if args.key?(:methods_prop)
5073
+ @paths = args[:paths] if args.key?(:paths)
5074
+ end
5075
+ end
5076
+
5077
+ # Describes a set of HTTP headers to match against.
5078
+ class RateLimitPolicyRateLimitRuleToDestinationHeaderSet
5079
+ include Google::Apis::Core::Hashable
5080
+
5081
+ # Required. Contains a list of headers to match against in http header. The
5082
+ # match can be one of exact, prefix, suffix, or contains (substring match). The
5083
+ # match follows AND semantics which means all the headers must match. Matches
5084
+ # are always case sensitive unless the ignoreCase is set.
5085
+ # Corresponds to the JSON property `headers`
5086
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleHeaderMatch>]
5087
+ attr_accessor :headers
5088
+
5089
+ def initialize(**args)
5090
+ update!(**args)
5091
+ end
5092
+
5093
+ # Update properties of this object
5094
+ def update!(**args)
5095
+ @headers = args[:headers] if args.key?(:headers)
5096
+ end
5097
+ end
5098
+
5099
+ # Describes a set of MCP protocol attributes to match against for a given MCP
5100
+ # request. This field is only valid if the targeted Gateway or Forwarding Rule
5101
+ # has an Agent Gateway attached to it.
5102
+ class RateLimitPolicyRateLimitRuleToDestinationMcp
5103
+ include Google::Apis::Core::Hashable
5104
+
5105
+ # Optional. If specified, matches on the MCP protocol’s non-access specific
5106
+ # methods namely: * initialize * completion/ * logging/ * notifications/ * ping
5107
+ # Defaults to SKIP_BASE_PROTOCOL_METHODS if not specified.
5108
+ # Corresponds to the JSON property `baseProtocolMethodsOption`
5109
+ # @return [String]
5110
+ attr_accessor :base_protocol_methods_option
5111
+
5112
+ # Optional. A list of MCP methods and associated parameter names to match on. It
5113
+ # is recommended to use this field to match on tools, prompts and resource
5114
+ # accesses while setting the baseProtocolMethodsOption to
5115
+ # MATCH_BASE_PROTOCOL_METHODS to match on all the other MCP protocol methods.
5116
+ # Limited to 10 MCP methods per Rate Limit Policy.
5117
+ # Corresponds to the JSON property `methods`
5118
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleToDestinationMcpMethod>]
5119
+ attr_accessor :methods_prop
5120
+
5121
+ def initialize(**args)
5122
+ update!(**args)
5123
+ end
5124
+
5125
+ # Update properties of this object
5126
+ def update!(**args)
5127
+ @base_protocol_methods_option = args[:base_protocol_methods_option] if args.key?(:base_protocol_methods_option)
5128
+ @methods_prop = args[:methods_prop] if args.key?(:methods_prop)
5129
+ end
5130
+ end
5131
+
5132
+ # Describes a set of MCP methods to match against. This field is only valid if
5133
+ # the targeted Gateway or Forwarding Rule has an Agent Gateway attached to it.
5134
+ class RateLimitPolicyRateLimitRuleToDestinationMcpMethod
5135
+ include Google::Apis::Core::Hashable
5136
+
5137
+ # Required. Specifies the MCP method to match against. Allowed values are as
5138
+ # follows: 1. `tools`, `prompts`, `resources` - these will match against all sub
5139
+ # methods under the respective methods. 2. `prompts/list`, `tools/list`, `
5140
+ # resources/list`, `resources/templates/list` 3. `prompts/get`, `tools/call`, `
5141
+ # resources/subscribe`, `resources/unsubscribe`, `resources/read` Params cannot
5142
+ # be specified for categories 1 and 2.
5143
+ # Corresponds to the JSON property `name`
5144
+ # @return [String]
5145
+ attr_accessor :name
5146
+
5147
+ # Optional. Specifies a list of MCP method parameter names to match against. The
5148
+ # match can be one of exact, prefix, suffix, or contains (substring match).
5149
+ # Matches are always case sensitive unless the ignoreCase is set.
5150
+ # Corresponds to the JSON property `params`
5151
+ # @return [Array<Google::Apis::NetworksecurityV1beta1::RateLimitPolicyRateLimitRuleStringMatch>]
5152
+ attr_accessor :params
5153
+
5154
+ def initialize(**args)
5155
+ update!(**args)
5156
+ end
5157
+
5158
+ # Update properties of this object
5159
+ def update!(**args)
5160
+ @name = args[:name] if args.key?(:name)
5161
+ @params = args[:params] if args.key?(:params)
5162
+ end
5163
+ end
5164
+
5165
+ # Specifies the target to which this policy applies.
5166
+ class RateLimitPolicyTarget
5167
+ include Google::Apis::Core::Hashable
5168
+
5169
+ # Required. Reference to a Gateway or Forwarding Rule resource on which this
5170
+ # policy will be applied.
5171
+ # Corresponds to the JSON property `resource`
5172
+ # @return [String]
5173
+ attr_accessor :resource
5174
+
5175
+ def initialize(**args)
5176
+ update!(**args)
5177
+ end
5178
+
5179
+ # Update properties of this object
5180
+ def update!(**args)
5181
+ @resource = args[:resource] if args.key?(:resource)
5182
+ end
5183
+ end
5184
+
4431
5185
  # Request used by the RemoveAddressGroupItems method.
4432
5186
  class RemoveAddressGroupItemsRequest
4433
5187
  include Google::Apis::Core::Hashable