SecurityPolicyRuleRateLimitOptions class
Constructors
-
SecurityPolicyRuleRateLimitOptions({Input<int?>? banDurationSec, Input<SecurityPolicyRuleRateLimitOptionsBanThreshold?>? banThreshold, Input<String?>? conformAction, Input<String?>? enforceOnKey, Input<List<SecurityPolicyRuleRateLimitOptionsEnforceOnKeyConfig>?>? enforceOnKeyConfigs, Input<String?>? enforceOnKeyName, Input<String?>? exceedAction, Input<SecurityPolicyRuleRateLimitOptionsExceedRedirectOptions?>? exceedRedirectOptions, Input<SecurityPolicyRuleRateLimitOptionsRateLimitThreshold?>? rateLimitThreshold})
-
Creates a new SecurityPolicyRuleRateLimitOptions.
banDurationSec Can only be specified if the action for the rule is "rateBasedBan".
banThreshold Can only be specified if the action for the rule is "rateBasedBan".
conformAction Action to take for requests that are under the configured rate limit threshold.
enforceOnKey Determines the key to enforce the rateLimitThreshold on. Possible values are:
enforceOnKeyConfigs If specified, any combination of values of enforceOnKeyType/enforceOnKeyName is treated as the key on which ratelimit threshold/action is enforced.
enforceOnKeyName Rate limit key name applicable only for the following key types:
exceedAction Action to take for requests that are above the configured rate limit threshold, to either deny with a specified HTTP response code, or redirect to a different endpoint.
exceedRedirectOptions Parameters defining the redirect action that is used as the exceed action. Cannot be specified if the exceed action is not redirect. This field is only supported in Global Security Policies of type CLOUD_ARMOR.
rateLimitThreshold Threshold at which to begin ratelimiting.
const
-
SecurityPolicyRuleRateLimitOptions.fromMap(Map<String, dynamic> map)
-
factory
Properties
-
banDurationSec
→ Input<int?>?
-
Can only be specified if the action for the rule is "rateBasedBan".
If specified, determines the time (in seconds) the traffic will continue to be banned by the rate limit after the rate falls below the threshold.
final
-
banThreshold
→ Input<SecurityPolicyRuleRateLimitOptionsBanThreshold?>?
-
Can only be specified if the action for the rule is "rateBasedBan".
If specified, the key will be banned for the configured 'banDurationSec' when the number of requests that exceed the 'rateLimitThreshold' also exceed this 'banThreshold'.
Structure is documented below.
final
-
conformAction
→ Input<String?>?
-
Action to take for requests that are under the configured rate limit threshold.
Valid option is "allow" only.
final
-
enforceOnKey
→ Input<String?>?
-
Determines the key to enforce the rateLimitThreshold on. Possible values are:
final
-
enforceOnKeyConfigs
→ Input<List<SecurityPolicyRuleRateLimitOptionsEnforceOnKeyConfig>?>?
-
If specified, any combination of values of enforceOnKeyType/enforceOnKeyName is treated as the key on which ratelimit threshold/action is enforced.
You can specify up to 3 enforceOnKeyConfigs.
If enforceOnKeyConfigs is specified, enforceOnKey must not be specified.
Structure is documented below.
final
-
enforceOnKeyName
→ Input<String?>?
-
Rate limit key name applicable only for the following key types:
HTTP_HEADER -- Name of the HTTP header whose value is taken as the key value.
HTTP_COOKIE -- Name of the HTTP cookie whose value is taken as the key value.
final
-
exceedAction
→ Input<String?>?
-
Action to take for requests that are above the configured rate limit threshold, to either deny with a specified HTTP response code, or redirect to a different endpoint.
Valid options are deny(STATUS), where valid values for STATUS are 403, 404, 429, and 502.
final
-
exceedRedirectOptions
→ Input<SecurityPolicyRuleRateLimitOptionsExceedRedirectOptions?>?
-
Parameters defining the redirect action that is used as the exceed action. Cannot be specified if the exceed action is not redirect. This field is only supported in Global Security Policies of type CLOUD_ARMOR.
Structure is documented below.
final
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
rateLimitThreshold
→ Input<SecurityPolicyRuleRateLimitOptionsRateLimitThreshold?>?
-
Threshold at which to begin ratelimiting.
Structure is documented below.
final
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited