Malware policy actions

akamai_appsec_malware_policy_actions

Creates, modifies, or deletes the actions associated with one or more policies within a given security policy. By default, malware policies take no action when triggered.

Note that you must set separate actions for requests that are scanned according to the specified malware policy and those that are unscanned.

Scopes: Malware protection

Example

terraform {
  required_providers {
    akamai = {
      source = "akamai/akamai"
    }
  }
}

provider "akamai" {
  edgerc = "~/.edgerc"
}
// USE CASE: User wants to create a malware policy and malware policy actions for a security configuration.

data "akamai_appsec_configuration" "configuration" {
  name = "Documentation"
}
resource "akamai_appsec_malware_policy" "appsec_malware_policy" {
  config_id      = data.akamai_appsec_configuration.configuration.config_id
  malware_policy = file("${path.module}/malware_policy.json")
}
resource "akamai_appsec_malware_policy_actions" "appsec_malware_policy_actions" {
  config_id              = data.akamai_appsec_configuration.configuration.config_id
  security_policy_id     = "gms1_134637"
  malware_policy_actions = file("${path.module}/malware_policy_actions.json")
}

Argument reference

This resource supports the following arguments:

  • config_id (Required). Unique identifier of the security configuration associated with the malware policy action being modified.
  • security_policy_id (Required). Unique identifier of the security policy associated with the malware policy whose action is being modified.
  • malware_policy_actions (Required). Path to a JSON file containing the malware policy IDs and their respective actions.