public static class ProtectionRule.Builder extends Object
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
ProtectionRule.Builder |
action(ProtectionRule.Action action)
The action to take when the traffic is detected as malicious.
|
ProtectionRule |
build() |
ProtectionRule.Builder |
copy(ProtectionRule model) |
ProtectionRule.Builder |
description(String description)
The description of the protection rule.
|
ProtectionRule.Builder |
exclusions(List<ProtectionRuleExclusion> exclusions) |
ProtectionRule.Builder |
key(String key)
The unique key of the protection rule.
|
ProtectionRule.Builder |
labels(List<String> labels)
The list of labels for the protection rule.
|
ProtectionRule.Builder |
modSecurityRuleIds(List<String> modSecurityRuleIds)
The list of the ModSecurity rule IDs that apply to this protection rule.
|
ProtectionRule.Builder |
name(String name)
The name of the protection rule.
|
public ProtectionRule.Builder key(String key)
The unique key of the protection rule.
key
- the value to setpublic ProtectionRule.Builder modSecurityRuleIds(List<String> modSecurityRuleIds)
The list of the ModSecurity rule IDs that apply to this protection rule. For more information about ModSecurity’s open source WAF rules, see Mod Security’s documentation.
modSecurityRuleIds
- the value to setpublic ProtectionRule.Builder name(String name)
The name of the protection rule.
name
- the value to setpublic ProtectionRule.Builder description(String description)
The description of the protection rule.
description
- the value to setpublic ProtectionRule.Builder action(ProtectionRule.Action action)
The action to take when the traffic is detected as malicious. If unspecified, defaults to
OFF
.
action
- the value to setpublic ProtectionRule.Builder labels(List<String> labels)
The list of labels for the protection rule.
*Note:** Protection rules with a ResponseBody
label will have no effect unless
isResponseInspected
is true.
labels
- the value to setpublic ProtectionRule.Builder exclusions(List<ProtectionRuleExclusion> exclusions)
public ProtectionRule build()
public ProtectionRule.Builder copy(ProtectionRule model)
Copyright © 2016–2024. All rights reserved.