Show / Hide Table of Contents

Class WafRule

Provides a Cloudflare WAF rule resource for a particular zone. This can be used to configure firewall behaviour for pre-defined firewall rules.

Example Usage

using Pulumi;
using Cloudflare = Pulumi.Cloudflare;

class MyStack : Stack
{
public MyStack()
{
    var _00000 = new Cloudflare.WafRule("100000", new Cloudflare.WafRuleArgs
    {
        Mode = "simulate",
        RuleId = "100000",
        ZoneId = "ae36f999674d196762efcc5abb06b345",
    });
}

}
Inheritance
System.Object
Resource
CustomResource
WafRule
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Cloudflare
Assembly: Pulumi.Cloudflare.dll
Syntax
public class WafRule : CustomResource

Constructors

View Source

WafRule(String, WafRuleArgs, CustomResourceOptions)

Create a WafRule resource with the given unique name, arguments, and options.

Declaration
public WafRule(string name, WafRuleArgs args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

WafRuleArgs args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

GroupId

The ID of the WAF Rule Group that contains the rule.

Declaration
public Output<string> GroupId { get; }
Property Value
Type Description
Output<System.String>
View Source

Mode

The mode of the rule, can be one of ["block", "challenge", "default", "disable", "simulate"].

Declaration
public Output<string> Mode { get; }
Property Value
Type Description
Output<System.String>
View Source

PackageId

The ID of the WAF Rule Package that contains the rule.

Declaration
public Output<string> PackageId { get; }
Property Value
Type Description
Output<System.String>
View Source

RuleId

The WAF Rule ID.

Declaration
public Output<string> RuleId { get; }
Property Value
Type Description
Output<System.String>
View Source

ZoneId

The DNS zone ID to apply to.

Declaration
public Output<string> ZoneId { get; }
Property Value
Type Description
Output<System.String>

Methods

View Source

Get(String, Input<String>, WafRuleState, CustomResourceOptions)

Get an existing WafRule resource's state with the given name, ID, and optional extra properties used to qualify the lookup.

Declaration
public static WafRule Get(string name, Input<string> id, WafRuleState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

WafRuleState state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
WafRule
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.