getAppSecCustomDeny

Use the akamai.AppSecCustomDeny data source to retrieve information about custom deny actions for a specific security configuration, or about a particular custom deny action. The information available is described here.

Example Usage

using Pulumi;
using Akamai = Pulumi.Akamai;

class MyStack : Stack
{
    public MyStack()
    {
        var configuration = Output.Create(Akamai.GetAppSecConfiguration.InvokeAsync(new Akamai.GetAppSecConfigurationArgs
        {
            Name = @var.Security_configuration,
        }));
        var customDenyList = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecCustomDeny.InvokeAsync(new Akamai.GetAppSecCustomDenyArgs
        {
            ConfigId = configuration.ConfigId,
        })));
        this.CustomDenyListOutput = customDenyList.Apply(customDenyList => customDenyList.OutputText);
        this.CustomDenyListJson = customDenyList.Apply(customDenyList => customDenyList.Json);
        var customDeny = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecCustomDeny.InvokeAsync(new Akamai.GetAppSecCustomDenyArgs
        {
            ConfigId = configuration.ConfigId,
            CustomDenyId = @var.Custom_deny_id,
        })));
        this.CustomDenyJson = customDeny.Apply(customDeny => customDeny.Json);
        this.CustomDenyOutput = customDeny.Apply(customDeny => customDeny.OutputText);
    }

    [Output("customDenyListOutput")]
    public Output<string> CustomDenyListOutput { get; set; }
    [Output("customDenyListJson")]
    public Output<string> CustomDenyListJson { get; set; }
    [Output("customDenyJson")]
    public Output<string> CustomDenyJson { get; set; }
    [Output("customDenyOutput")]
    public Output<string> CustomDenyOutput { get; set; }
}
package main

import (
	"github.com/pulumi/pulumi-akamai/sdk/v2/go/akamai"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		opt0 := _var.Security_configuration
		configuration, err := akamai.LookupAppSecConfiguration(ctx, &akamai.LookupAppSecConfigurationArgs{
			Name: &opt0,
		}, nil)
		if err != nil {
			return err
		}
		customDenyList, err := akamai.LookupAppSecCustomDeny(ctx, &akamai.LookupAppSecCustomDenyArgs{
			ConfigId: configuration.ConfigId,
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("customDenyListOutput", customDenyList.OutputText)
		ctx.Export("customDenyListJson", customDenyList.Json)
		opt1 := _var.Custom_deny_id
		customDeny, err := akamai.LookupAppSecCustomDeny(ctx, &akamai.LookupAppSecCustomDenyArgs{
			ConfigId:     configuration.ConfigId,
			CustomDenyId: &opt1,
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("customDenyJson", customDeny.Json)
		ctx.Export("customDenyOutput", customDeny.OutputText)
		return nil
	})
}
import pulumi
import pulumi_akamai as akamai

configuration = akamai.get_app_sec_configuration(name=var["security_configuration"])
custom_deny_list = akamai.get_app_sec_custom_deny(config_id=configuration.config_id)
pulumi.export("customDenyListOutput", custom_deny_list.output_text)
pulumi.export("customDenyListJson", custom_deny_list.json)
custom_deny = akamai.get_app_sec_custom_deny(config_id=configuration.config_id,
    custom_deny_id=var["custom_deny_id"])
pulumi.export("customDenyJson", custom_deny.json)
pulumi.export("customDenyOutput", custom_deny.output_text)
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";

const configuration = akamai.getAppSecConfiguration({
    name: _var.security_configuration,
});
const customDenyList = configuration.then(configuration => akamai.getAppSecCustomDeny({
    configId: configuration.configId,
}));
export const customDenyListOutput = customDenyList.then(customDenyList => customDenyList.outputText);
export const customDenyListJson = customDenyList.then(customDenyList => customDenyList.json);
const customDeny = configuration.then(configuration => akamai.getAppSecCustomDeny({
    configId: configuration.configId,
    customDenyId: _var.custom_deny_id,
}));
export const customDenyJson = customDeny.then(customDeny => customDeny.json);
export const customDenyOutput = customDeny.then(customDeny => customDeny.outputText);

Using getAppSecCustomDeny

function getAppSecCustomDeny(args: GetAppSecCustomDenyArgs, opts?: InvokeOptions): Promise<GetAppSecCustomDenyResult>
def get_app_sec_custom_deny(config_id: Optional[int] = None,
                            custom_deny_id: Optional[str] = None,
                            opts: Optional[InvokeOptions] = None) -> GetAppSecCustomDenyResult
func LookupAppSecCustomDeny(ctx *Context, args *LookupAppSecCustomDenyArgs, opts ...InvokeOption) (*LookupAppSecCustomDenyResult, error)

Note: This function is named LookupAppSecCustomDeny in the Go SDK.

public static class GetAppSecCustomDeny {
    public static Task<GetAppSecCustomDenyResult> InvokeAsync(GetAppSecCustomDenyArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

ConfigId int
The configuration ID to use.
CustomDenyId string
The ID of a specific custom deny action.
ConfigId int
The configuration ID to use.
CustomDenyId string
The ID of a specific custom deny action.
configId number
The configuration ID to use.
customDenyId string
The ID of a specific custom deny action.
config_id int
The configuration ID to use.
custom_deny_id str
The ID of a specific custom deny action.

getAppSecCustomDeny Result

The following output properties are available:

ConfigId int
Id string
The provider-assigned unique ID for this managed resource.
Json string
A JSON-formatted list of the custom deny action information.
OutputText string
A tabular display showing the custom deny action information.
CustomDenyId string
ConfigId int
Id string
The provider-assigned unique ID for this managed resource.
Json string
A JSON-formatted list of the custom deny action information.
OutputText string
A tabular display showing the custom deny action information.
CustomDenyId string
configId number
id string
The provider-assigned unique ID for this managed resource.
json string
A JSON-formatted list of the custom deny action information.
outputText string
A tabular display showing the custom deny action information.
customDenyId string
config_id int
id str
The provider-assigned unique ID for this managed resource.
json str
A JSON-formatted list of the custom deny action information.
output_text str
A tabular display showing the custom deny action information.
custom_deny_id str

Package Details

Repository
https://github.com/pulumi/pulumi-akamai
License
Apache-2.0
Notes
This Pulumi package is based on the akamai Terraform Provider.