Partager via


CustomRule Constructors

Definition

Overloads

CustomRule()

Initializes a new instance of the CustomRule class.

CustomRule(Int32, String, IList<MatchCondition>, String, String, String, Nullable<Int32>, Nullable<Int32>, IList<GroupByVariable>)

Initializes a new instance of the CustomRule class.

CustomRule()

Initializes a new instance of the CustomRule class.

public CustomRule ();
Public Sub New ()

Applies to

CustomRule(Int32, String, IList<MatchCondition>, String, String, String, Nullable<Int32>, Nullable<Int32>, IList<GroupByVariable>)

Initializes a new instance of the CustomRule class.

public CustomRule (int priority, string ruleType, System.Collections.Generic.IList<Microsoft.Azure.Management.FrontDoor.Models.MatchCondition> matchConditions, string action, string name = default, string enabledState = default, int? rateLimitDurationInMinutes = default, int? rateLimitThreshold = default, System.Collections.Generic.IList<Microsoft.Azure.Management.FrontDoor.Models.GroupByVariable> groupBy = default);
new Microsoft.Azure.Management.FrontDoor.Models.CustomRule : int * string * System.Collections.Generic.IList<Microsoft.Azure.Management.FrontDoor.Models.MatchCondition> * string * string * string * Nullable<int> * Nullable<int> * System.Collections.Generic.IList<Microsoft.Azure.Management.FrontDoor.Models.GroupByVariable> -> Microsoft.Azure.Management.FrontDoor.Models.CustomRule
Public Sub New (priority As Integer, ruleType As String, matchConditions As IList(Of MatchCondition), action As String, Optional name As String = Nothing, Optional enabledState As String = Nothing, Optional rateLimitDurationInMinutes As Nullable(Of Integer) = Nothing, Optional rateLimitThreshold As Nullable(Of Integer) = Nothing, Optional groupBy As IList(Of GroupByVariable) = Nothing)

Parameters

priority
Int32

Describes priority of the rule. Rules with a lower value will be evaluated before rules with a higher value.

ruleType
String

Describes type of rule. Possible values include: 'MatchRule', 'RateLimitRule'

matchConditions
IList<MatchCondition>

List of match conditions.

action
String

Describes what action to be applied when rule matches. Possible values include: 'Allow', 'Block', 'Log', 'Redirect', 'AnomalyScoring', 'JSChallenge'

name
String

Describes the name of the rule.

enabledState
String

Describes if the custom rule is in enabled or disabled state. Defaults to Enabled if not specified. Possible values include: 'Disabled', 'Enabled'

rateLimitDurationInMinutes
Nullable<Int32>

Time window for resetting the rate limit count. Default is 1 minute.

rateLimitThreshold
Nullable<Int32>

Number of allowed requests per client within the time window.

groupBy
IList<GroupByVariable>

Describes the list of variables to group the rate limit requests

Applies to