1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. WafAutoDenyRules
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.WafAutoDenyRules

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Provides a resource to create a waf auto_deny_rules

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const example = new tencentcloud.WafAutoDenyRules("example", {
        attackThreshold: 20,
        denyTimeThreshold: 5,
        domain: "demo.waf.com",
        timeThreshold: 12,
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    example = tencentcloud.WafAutoDenyRules("example",
        attack_threshold=20,
        deny_time_threshold=5,
        domain="demo.waf.com",
        time_threshold=12)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewWafAutoDenyRules(ctx, "example", &tencentcloud.WafAutoDenyRulesArgs{
    			AttackThreshold:   pulumi.Float64(20),
    			DenyTimeThreshold: pulumi.Float64(5),
    			Domain:            pulumi.String("demo.waf.com"),
    			TimeThreshold:     pulumi.Float64(12),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Tencentcloud.WafAutoDenyRules("example", new()
        {
            AttackThreshold = 20,
            DenyTimeThreshold = 5,
            Domain = "demo.waf.com",
            TimeThreshold = 12,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.WafAutoDenyRules;
    import com.pulumi.tencentcloud.WafAutoDenyRulesArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new WafAutoDenyRules("example", WafAutoDenyRulesArgs.builder()
                .attackThreshold(20)
                .denyTimeThreshold(5)
                .domain("demo.waf.com")
                .timeThreshold(12)
                .build());
    
        }
    }
    
    resources:
      example:
        type: tencentcloud:WafAutoDenyRules
        properties:
          attackThreshold: 20
          denyTimeThreshold: 5
          domain: demo.waf.com
          timeThreshold: 12
    

    Create WafAutoDenyRules Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new WafAutoDenyRules(name: string, args: WafAutoDenyRulesArgs, opts?: CustomResourceOptions);
    @overload
    def WafAutoDenyRules(resource_name: str,
                         args: WafAutoDenyRulesArgs,
                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def WafAutoDenyRules(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         attack_threshold: Optional[float] = None,
                         deny_time_threshold: Optional[float] = None,
                         domain: Optional[str] = None,
                         time_threshold: Optional[float] = None,
                         waf_auto_deny_rules_id: Optional[str] = None)
    func NewWafAutoDenyRules(ctx *Context, name string, args WafAutoDenyRulesArgs, opts ...ResourceOption) (*WafAutoDenyRules, error)
    public WafAutoDenyRules(string name, WafAutoDenyRulesArgs args, CustomResourceOptions? opts = null)
    public WafAutoDenyRules(String name, WafAutoDenyRulesArgs args)
    public WafAutoDenyRules(String name, WafAutoDenyRulesArgs args, CustomResourceOptions options)
    
    type: tencentcloud:WafAutoDenyRules
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args WafAutoDenyRulesArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args WafAutoDenyRulesArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args WafAutoDenyRulesArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args WafAutoDenyRulesArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args WafAutoDenyRulesArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    WafAutoDenyRules Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The WafAutoDenyRules resource accepts the following input properties:

    AttackThreshold double
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    DenyTimeThreshold double
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    Domain string
    Domain.
    TimeThreshold double
    IP autodeny statistical time, ranging from 1-60 minutes.
    WafAutoDenyRulesId string
    ID of the resource.
    AttackThreshold float64
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    DenyTimeThreshold float64
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    Domain string
    Domain.
    TimeThreshold float64
    IP autodeny statistical time, ranging from 1-60 minutes.
    WafAutoDenyRulesId string
    ID of the resource.
    attackThreshold Double
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    denyTimeThreshold Double
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain String
    Domain.
    timeThreshold Double
    IP autodeny statistical time, ranging from 1-60 minutes.
    wafAutoDenyRulesId String
    ID of the resource.
    attackThreshold number
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    denyTimeThreshold number
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain string
    Domain.
    timeThreshold number
    IP autodeny statistical time, ranging from 1-60 minutes.
    wafAutoDenyRulesId string
    ID of the resource.
    attack_threshold float
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    deny_time_threshold float
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain str
    Domain.
    time_threshold float
    IP autodeny statistical time, ranging from 1-60 minutes.
    waf_auto_deny_rules_id str
    ID of the resource.
    attackThreshold Number
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    denyTimeThreshold Number
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain String
    Domain.
    timeThreshold Number
    IP autodeny statistical time, ranging from 1-60 minutes.
    wafAutoDenyRulesId String
    ID of the resource.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the WafAutoDenyRules resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing WafAutoDenyRules Resource

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

    public static get(name: string, id: Input<ID>, state?: WafAutoDenyRulesState, opts?: CustomResourceOptions): WafAutoDenyRules
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            attack_threshold: Optional[float] = None,
            deny_time_threshold: Optional[float] = None,
            domain: Optional[str] = None,
            time_threshold: Optional[float] = None,
            waf_auto_deny_rules_id: Optional[str] = None) -> WafAutoDenyRules
    func GetWafAutoDenyRules(ctx *Context, name string, id IDInput, state *WafAutoDenyRulesState, opts ...ResourceOption) (*WafAutoDenyRules, error)
    public static WafAutoDenyRules Get(string name, Input<string> id, WafAutoDenyRulesState? state, CustomResourceOptions? opts = null)
    public static WafAutoDenyRules get(String name, Output<String> id, WafAutoDenyRulesState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:WafAutoDenyRules    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AttackThreshold double
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    DenyTimeThreshold double
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    Domain string
    Domain.
    TimeThreshold double
    IP autodeny statistical time, ranging from 1-60 minutes.
    WafAutoDenyRulesId string
    ID of the resource.
    AttackThreshold float64
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    DenyTimeThreshold float64
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    Domain string
    Domain.
    TimeThreshold float64
    IP autodeny statistical time, ranging from 1-60 minutes.
    WafAutoDenyRulesId string
    ID of the resource.
    attackThreshold Double
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    denyTimeThreshold Double
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain String
    Domain.
    timeThreshold Double
    IP autodeny statistical time, ranging from 1-60 minutes.
    wafAutoDenyRulesId String
    ID of the resource.
    attackThreshold number
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    denyTimeThreshold number
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain string
    Domain.
    timeThreshold number
    IP autodeny statistical time, ranging from 1-60 minutes.
    wafAutoDenyRulesId string
    ID of the resource.
    attack_threshold float
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    deny_time_threshold float
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain str
    Domain.
    time_threshold float
    IP autodeny statistical time, ranging from 1-60 minutes.
    waf_auto_deny_rules_id str
    ID of the resource.
    attackThreshold Number
    The threshold number of attacks that triggers IP autodeny, ranging from 2 to 100 times.
    denyTimeThreshold Number
    The IP autodeny time after triggering the IP autodeny, ranging from 5 to 360 minutes.
    domain String
    Domain.
    timeThreshold Number
    IP autodeny statistical time, ranging from 1-60 minutes.
    wafAutoDenyRulesId String
    ID of the resource.

    Import

    waf auto_deny_rules can be imported using the id, e.g.

    $ pulumi import tencentcloud:index/wafAutoDenyRules:WafAutoDenyRules example demo.waf.com
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    tencentcloud logo
    tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack