AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

WafAction

import "github.com/aws/aws-sdk-go/service/waf"

type WafAction struct { Type *string `type:"string" required:"true" enum:"WafActionType"` }

For the action that is associated with a rule in a WebACL, specifies the action that you want AWS WAF to perform when a web request matches all of the conditions in a rule. For the default action in a WebACL, specifies the action that you want AWS WAF to take when a web request doesn't match all of the conditions in any of the rules in a WebACL.

Type

Type: *string

Specifies how you want AWS WAF to respond to requests that match the settings in a Rule. Valid settings include the following:

  • ALLOW: AWS WAF allows requests

  • BLOCK: AWS WAF blocks requests

  • COUNT: AWS WAF increments a counter of the requests that match all of the conditions in the rule. AWS WAF then continues to inspect the web request based on the remaining rules in the web ACL. You can't specify COUNT for the default action for a WebACL.

Type is a required field

Method

GoString

func (s WafAction) GoString() string

GoString returns the string representation

SetType

func (s *WafAction) SetType(v string) *WafAction

SetType sets the Type field's value.

String

func (s WafAction) String() string

String returns the string representation

Validate

func (s *WafAction) Validate() error

Validate inspects the fields of the type to determine if they are valid.

On this page: