akamai.AppSecEvalGroup

Scopes: Evaluation attack group

Modifies the action and the conditions and exceptions for an evaluation mode attack group.

Note that this resource is only available to organizations running the Adaptive Security Engine (ASE) beta. For more information about ASE, please contact your Akamai representative.

Example Usage

Basic usage

using System.Collections.Generic;
using System.IO;
using Pulumi;
using Akamai = Pulumi.Akamai;

return await Deployment.RunAsync(() => 
{
    var configuration = Akamai.GetAppSecConfiguration.Invoke(new()
    {
        Name = "Documentation",
    });

    var evalAttackGroup = new Akamai.AppSecEvalGroup("evalAttackGroup", new()
    {
        ConfigId = configuration.Apply(getAppSecConfigurationResult => getAppSecConfigurationResult.ConfigId),
        SecurityPolicyId = "gms1_134637",
        AttackGroup = "SQL",
        AttackGroupAction = "deny",
        ConditionException = File.ReadAllText($"{path.Module}/condition_exception.json"),
    });

});
package main

import (
	"fmt"
	"os"

	"github.com/pulumi/pulumi-akamai/sdk/v4/go/akamai"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func readFileOrPanic(path string) pulumi.StringPtrInput {
	data, err := os.ReadFile(path)
	if err != nil {
		panic(err.Error())
	}
	return pulumi.String(string(data))
}

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		configuration, err := akamai.LookupAppSecConfiguration(ctx, &akamai.LookupAppSecConfigurationArgs{
			Name: pulumi.StringRef("Documentation"),
		}, nil)
		if err != nil {
			return err
		}
		_, err = akamai.NewAppSecEvalGroup(ctx, "evalAttackGroup", &akamai.AppSecEvalGroupArgs{
			ConfigId:           *pulumi.Int(configuration.ConfigId),
			SecurityPolicyId:   pulumi.String("gms1_134637"),
			AttackGroup:        pulumi.String("SQL"),
			AttackGroupAction:  pulumi.String("deny"),
			ConditionException: readFileOrPanic(fmt.Sprintf("%v/condition_exception.json", path.Module)),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.akamai.AkamaiFunctions;
import com.pulumi.akamai.inputs.GetAppSecConfigurationArgs;
import com.pulumi.akamai.AppSecEvalGroup;
import com.pulumi.akamai.AppSecEvalGroupArgs;
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) {
        final var configuration = AkamaiFunctions.getAppSecConfiguration(GetAppSecConfigurationArgs.builder()
            .name("Documentation")
            .build());

        var evalAttackGroup = new AppSecEvalGroup("evalAttackGroup", AppSecEvalGroupArgs.builder()        
            .configId(configuration.applyValue(getAppSecConfigurationResult -> getAppSecConfigurationResult.configId()))
            .securityPolicyId("gms1_134637")
            .attackGroup("SQL")
            .attackGroupAction("deny")
            .conditionException(Files.readString(Paths.get(String.format("%s/condition_exception.json", path.module()))))
            .build());

    }
}
import pulumi
import pulumi_akamai as akamai

configuration = akamai.get_app_sec_configuration(name="Documentation")
eval_attack_group = akamai.AppSecEvalGroup("evalAttackGroup",
    config_id=configuration.config_id,
    security_policy_id="gms1_134637",
    attack_group="SQL",
    attack_group_action="deny",
    condition_exception=(lambda path: open(path).read())(f"{path['module']}/condition_exception.json"))
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";
import * as fs from "fs";

const configuration = akamai.getAppSecConfiguration({
    name: "Documentation",
});
const evalAttackGroup = new akamai.AppSecEvalGroup("evalAttackGroup", {
    configId: configuration.then(configuration => configuration.configId),
    securityPolicyId: "gms1_134637",
    attackGroup: "SQL",
    attackGroupAction: "deny",
    conditionException: fs.readFileSync(`${path.module}/condition_exception.json`),
});
resources:
  evalAttackGroup:
    type: akamai:AppSecEvalGroup
    properties:
      configId: ${configuration.configId}
      securityPolicyId: gms1_134637
      attackGroup: SQL
      attackGroupAction: deny
      conditionException:
        fn::readFile: ${path.module}/condition_exception.json
variables:
  configuration:
    fn::invoke:
      Function: akamai:getAppSecConfiguration
      Arguments:
        name: Documentation

Create AppSecEvalGroup Resource

new AppSecEvalGroup(name: string, args: AppSecEvalGroupArgs, opts?: CustomResourceOptions);
@overload
def AppSecEvalGroup(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    attack_group: Optional[str] = None,
                    attack_group_action: Optional[str] = None,
                    condition_exception: Optional[str] = None,
                    config_id: Optional[int] = None,
                    security_policy_id: Optional[str] = None)
@overload
def AppSecEvalGroup(resource_name: str,
                    args: AppSecEvalGroupArgs,
                    opts: Optional[ResourceOptions] = None)
func NewAppSecEvalGroup(ctx *Context, name string, args AppSecEvalGroupArgs, opts ...ResourceOption) (*AppSecEvalGroup, error)
public AppSecEvalGroup(string name, AppSecEvalGroupArgs args, CustomResourceOptions? opts = null)
public AppSecEvalGroup(String name, AppSecEvalGroupArgs args)
public AppSecEvalGroup(String name, AppSecEvalGroupArgs args, CustomResourceOptions options)
type: akamai:AppSecEvalGroup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args AppSecEvalGroupArgs
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 AppSecEvalGroupArgs
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 AppSecEvalGroupArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args AppSecEvalGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args AppSecEvalGroupArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

AppSecEvalGroup Resource Properties

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

Inputs

The AppSecEvalGroup resource accepts the following input properties:

AttackGroup string

. Unique identifier of the evaluation attack group being modified.

AttackGroupAction string

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
ConfigId int

. Unique identifier of the security configuration where evaluation is taking place.

SecurityPolicyId string

. Unique identifier of the security policy associated with the evaluation process.

ConditionException string

. Path to a JSON file containing properties and property values for the attack group.

AttackGroup string

. Unique identifier of the evaluation attack group being modified.

AttackGroupAction string

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
ConfigId int

. Unique identifier of the security configuration where evaluation is taking place.

SecurityPolicyId string

. Unique identifier of the security policy associated with the evaluation process.

ConditionException string

. Path to a JSON file containing properties and property values for the attack group.

attackGroup String

. Unique identifier of the evaluation attack group being modified.

attackGroupAction String

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
configId Integer

. Unique identifier of the security configuration where evaluation is taking place.

securityPolicyId String

. Unique identifier of the security policy associated with the evaluation process.

conditionException String

. Path to a JSON file containing properties and property values for the attack group.

attackGroup string

. Unique identifier of the evaluation attack group being modified.

attackGroupAction string

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
configId number

. Unique identifier of the security configuration where evaluation is taking place.

securityPolicyId string

. Unique identifier of the security policy associated with the evaluation process.

conditionException string

. Path to a JSON file containing properties and property values for the attack group.

attack_group str

. Unique identifier of the evaluation attack group being modified.

attack_group_action str

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
config_id int

. Unique identifier of the security configuration where evaluation is taking place.

security_policy_id str

. Unique identifier of the security policy associated with the evaluation process.

condition_exception str

. Path to a JSON file containing properties and property values for the attack group.

attackGroup String

. Unique identifier of the evaluation attack group being modified.

attackGroupAction String

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
configId Number

. Unique identifier of the security configuration where evaluation is taking place.

securityPolicyId String

. Unique identifier of the security policy associated with the evaluation process.

conditionException String

. Path to a JSON file containing properties and property values for the attack group.

Outputs

All input properties are implicitly available as output properties. Additionally, the AppSecEvalGroup 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 AppSecEvalGroup Resource

Get an existing AppSecEvalGroup 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?: AppSecEvalGroupState, opts?: CustomResourceOptions): AppSecEvalGroup
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        attack_group: Optional[str] = None,
        attack_group_action: Optional[str] = None,
        condition_exception: Optional[str] = None,
        config_id: Optional[int] = None,
        security_policy_id: Optional[str] = None) -> AppSecEvalGroup
func GetAppSecEvalGroup(ctx *Context, name string, id IDInput, state *AppSecEvalGroupState, opts ...ResourceOption) (*AppSecEvalGroup, error)
public static AppSecEvalGroup Get(string name, Input<string> id, AppSecEvalGroupState? state, CustomResourceOptions? opts = null)
public static AppSecEvalGroup get(String name, Output<String> id, AppSecEvalGroupState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
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:
AttackGroup string

. Unique identifier of the evaluation attack group being modified.

AttackGroupAction string

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
ConditionException string

. Path to a JSON file containing properties and property values for the attack group.

ConfigId int

. Unique identifier of the security configuration where evaluation is taking place.

SecurityPolicyId string

. Unique identifier of the security policy associated with the evaluation process.

AttackGroup string

. Unique identifier of the evaluation attack group being modified.

AttackGroupAction string

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
ConditionException string

. Path to a JSON file containing properties and property values for the attack group.

ConfigId int

. Unique identifier of the security configuration where evaluation is taking place.

SecurityPolicyId string

. Unique identifier of the security policy associated with the evaluation process.

attackGroup String

. Unique identifier of the evaluation attack group being modified.

attackGroupAction String

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
conditionException String

. Path to a JSON file containing properties and property values for the attack group.

configId Integer

. Unique identifier of the security configuration where evaluation is taking place.

securityPolicyId String

. Unique identifier of the security policy associated with the evaluation process.

attackGroup string

. Unique identifier of the evaluation attack group being modified.

attackGroupAction string

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
conditionException string

. Path to a JSON file containing properties and property values for the attack group.

configId number

. Unique identifier of the security configuration where evaluation is taking place.

securityPolicyId string

. Unique identifier of the security policy associated with the evaluation process.

attack_group str

. Unique identifier of the evaluation attack group being modified.

attack_group_action str

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
condition_exception str

. Path to a JSON file containing properties and property values for the attack group.

config_id int

. Unique identifier of the security configuration where evaluation is taking place.

security_policy_id str

. Unique identifier of the security policy associated with the evaluation process.

attackGroup String

. Unique identifier of the evaluation attack group being modified.

attackGroupAction String

. Action to be taken any time the attack group is triggered. Allowed values are:

  • alert. Record the event.
  • deny. Block the request.
  • **deny_custom_{custom_deny_id}**. Take the action specified by the custom deny.
  • none. Take no action.
conditionException String

. Path to a JSON file containing properties and property values for the attack group.

configId Number

. Unique identifier of the security configuration where evaluation is taking place.

securityPolicyId String

. Unique identifier of the security policy associated with the evaluation process.

Package Details

Repository
Akamai pulumi/pulumi-akamai
License
Apache-2.0
Notes

This Pulumi package is based on the akamai Terraform Provider.