@@ -53,9 +53,9 @@ public class NewAzureRmFrontDoorWafCustomRuleObject : AzureFrontDoorCmdletBase
53
53
public PSMatchCondition [ ] MatchCondition { get ; set ; }
54
54
55
55
/// <summary>
56
- /// Type of Actions. Possible values include: 'Allow', 'Block', 'Log'
56
+ /// Type of Actions. Possible values include: 'Allow', 'Block', 'Log', 'Redirect'
57
57
/// </summary>
58
- [ Parameter ( Mandatory = true , HelpMessage = "Type of Actions. Possible values include: 'Allow', 'Block', 'Log'. " ) ]
58
+ [ Parameter ( Mandatory = true , HelpMessage = "Type of Actions. Possible values include: 'Allow', 'Block', 'Log', 'Redirect'. " ) ]
59
59
[ PSArgumentCompleter ( "Allow" , "Block" , "Log" , "Redirect" ) ]
60
60
public string Action { get ; set ; }
61
61
@@ -77,6 +77,13 @@ public class NewAzureRmFrontDoorWafCustomRuleObject : AzureFrontDoorCmdletBase
77
77
[ Parameter ( Mandatory = false , HelpMessage = "Rate limit threshold" ) ]
78
78
public int ? RateLimitThreshold { get ; set ; }
79
79
80
+ /// <summary>
81
+ /// Enabled State. Possible values include: 'Enabled', 'Disabled'
82
+ /// </summary>
83
+ [ Parameter ( Mandatory = false , HelpMessage = "Enabled State. Possible values include: 'Enabled', 'Disabled'." ) ]
84
+ [ PSArgumentCompleter ( "Enabled" , "Disabled" ) ]
85
+ public string EnabledState { get ; set ; }
86
+
80
87
public override void ExecuteCmdlet ( )
81
88
{
82
89
var CustomRule = new PSCustomRule
@@ -87,7 +94,8 @@ public override void ExecuteCmdlet()
87
94
RuleType = RuleType ,
88
95
RateLimitDurationInMinutes = ! this . IsParameterBound ( c => c . RateLimitDurationInMinutes ) ? 1 : RateLimitDurationInMinutes ,
89
96
RateLimitThreshold = RateLimitThreshold ,
90
- Action = Action
97
+ Action = Action ,
98
+ EnabledState = ! this . IsParameterBound ( c => c . EnabledState ) ? "Enabled" : EnabledState
91
99
} ;
92
100
WriteObject ( CustomRule ) ;
93
101
}
0 commit comments