// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. package wafv2 import ( "fmt" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awsutil" "github.com/aws/aws-sdk-go/aws/request" "github.com/aws/aws-sdk-go/private/protocol" "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" ) const opAssociateWebACL = "AssociateWebACL" // AssociateWebACLRequest generates a "aws/request.Request" representing the // client's request for the AssociateWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See AssociateWebACL for more information on using the AssociateWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the AssociateWebACLRequest method. // req, resp := client.AssociateWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/AssociateWebACL func (c *WAFV2) AssociateWebACLRequest(input *AssociateWebACLInput) (req *request.Request, output *AssociateWebACLOutput) { op := &request.Operation{ Name: opAssociateWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &AssociateWebACLInput{} } output = &AssociateWebACLOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // AssociateWebACL API operation for AWS WAFV2. // // Associates a web ACL with a regional application resource, to protect the // resource. A regional application can be an Application Load Balancer (ALB), // an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito // user pool, an App Runner service, or an Amazon Web Services Verified Access // instance. // // For Amazon CloudFront, don't use this call. Instead, use your CloudFront // distribution configuration. To associate a web ACL, in the CloudFront call // UpdateDistribution, set the web ACL ID to the Amazon Resource Name (ARN) // of the web ACL. For information, see UpdateDistribution (https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html) // in the Amazon CloudFront Developer Guide. // // When you make changes to web ACLs or web ACL components, like rules and rule // groups, WAF propagates the changes everywhere that the web ACL and its components // are stored and used. Your changes are applied within seconds, but there might // be a brief period of inconsistency when the changes have arrived in some // places and not in others. So, for example, if you change a rule action setting, // the action might be the old action in one area and the new action in another // area. Or if you add an IP address to an IP set used in a blocking rule, the // new address might briefly be blocked in one area while still allowed in another. // This temporary inconsistency can occur when you first associate a web ACL // with an Amazon Web Services resource and when you change a web ACL that is // already associated with a resource. Generally, any inconsistencies of this // type last only a few seconds. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation AssociateWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/AssociateWebACL func (c *WAFV2) AssociateWebACL(input *AssociateWebACLInput) (*AssociateWebACLOutput, error) { req, out := c.AssociateWebACLRequest(input) return out, req.Send() } // AssociateWebACLWithContext is the same as AssociateWebACL with the addition of // the ability to pass a context and additional request options. // // See AssociateWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) AssociateWebACLWithContext(ctx aws.Context, input *AssociateWebACLInput, opts ...request.Option) (*AssociateWebACLOutput, error) { req, out := c.AssociateWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opCheckCapacity = "CheckCapacity" // CheckCapacityRequest generates a "aws/request.Request" representing the // client's request for the CheckCapacity operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See CheckCapacity for more information on using the CheckCapacity // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the CheckCapacityRequest method. // req, resp := client.CheckCapacityRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CheckCapacity func (c *WAFV2) CheckCapacityRequest(input *CheckCapacityInput) (req *request.Request, output *CheckCapacityOutput) { op := &request.Operation{ Name: opCheckCapacity, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &CheckCapacityInput{} } output = &CheckCapacityOutput{} req = c.newRequest(op, input, output) return } // CheckCapacity API operation for AWS WAFV2. // // Returns the web ACL capacity unit (WCU) requirements for a specified scope // and set of rules. You can use this to check the capacity requirements for // the rules you want to use in a RuleGroup or WebACL. // // WAF uses WCUs to calculate and control the operating resources that are used // to run your rules, rule groups, and web ACLs. WAF calculates capacity differently // for each rule type, to reflect the relative cost of each rule. Simple rules // that cost little to run use fewer WCUs than more complex rules that use more // processing power. Rule group capacity is fixed at creation, which helps users // plan their web ACL WCU usage when they use a rule group. For more information, // see WAF web ACL capacity units (WCU) (https://docs.aws.amazon.com/waf/latest/developerguide/aws-waf-capacity-units.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation CheckCapacity for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFInvalidResourceException // WAF couldn’t perform the operation because the resource that you requested // isn’t valid. Check the resource, and try again. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFSubscriptionNotFoundException // You tried to use a managed rule group that's available by subscription, but // you aren't subscribed to it yet. // // - WAFExpiredManagedRuleGroupVersionException // The operation failed because the specified version for the managed rule group // has expired. You can retrieve the available versions for the managed rule // group by calling ListAvailableManagedRuleGroupVersions. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CheckCapacity func (c *WAFV2) CheckCapacity(input *CheckCapacityInput) (*CheckCapacityOutput, error) { req, out := c.CheckCapacityRequest(input) return out, req.Send() } // CheckCapacityWithContext is the same as CheckCapacity with the addition of // the ability to pass a context and additional request options. // // See CheckCapacity for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) CheckCapacityWithContext(ctx aws.Context, input *CheckCapacityInput, opts ...request.Option) (*CheckCapacityOutput, error) { req, out := c.CheckCapacityRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opCreateAPIKey = "CreateAPIKey" // CreateAPIKeyRequest generates a "aws/request.Request" representing the // client's request for the CreateAPIKey operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See CreateAPIKey for more information on using the CreateAPIKey // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the CreateAPIKeyRequest method. // req, resp := client.CreateAPIKeyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateAPIKey func (c *WAFV2) CreateAPIKeyRequest(input *CreateAPIKeyInput) (req *request.Request, output *CreateAPIKeyOutput) { op := &request.Operation{ Name: opCreateAPIKey, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &CreateAPIKeyInput{} } output = &CreateAPIKeyOutput{} req = c.newRequest(op, input, output) return } // CreateAPIKey API operation for AWS WAFV2. // // Creates an API key that contains a set of token domains. // // API keys are required for the integration of the CAPTCHA API in your JavaScript // client applications. The API lets you customize the placement and characteristics // of the CAPTCHA puzzle for your end users. For more information about the // CAPTCHA JavaScript integration, see WAF client application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. // // You can use a single key for up to 5 domains. After you generate a key, you // can copy it for use in your JavaScript integration. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation CreateAPIKey for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateAPIKey func (c *WAFV2) CreateAPIKey(input *CreateAPIKeyInput) (*CreateAPIKeyOutput, error) { req, out := c.CreateAPIKeyRequest(input) return out, req.Send() } // CreateAPIKeyWithContext is the same as CreateAPIKey with the addition of // the ability to pass a context and additional request options. // // See CreateAPIKey for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) CreateAPIKeyWithContext(ctx aws.Context, input *CreateAPIKeyInput, opts ...request.Option) (*CreateAPIKeyOutput, error) { req, out := c.CreateAPIKeyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opCreateIPSet = "CreateIPSet" // CreateIPSetRequest generates a "aws/request.Request" representing the // client's request for the CreateIPSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See CreateIPSet for more information on using the CreateIPSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the CreateIPSetRequest method. // req, resp := client.CreateIPSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateIPSet func (c *WAFV2) CreateIPSetRequest(input *CreateIPSetInput) (req *request.Request, output *CreateIPSetOutput) { op := &request.Operation{ Name: opCreateIPSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &CreateIPSetInput{} } output = &CreateIPSetOutput{} req = c.newRequest(op, input, output) return } // CreateIPSet API operation for AWS WAFV2. // // Creates an IPSet, which you use to identify web requests that originate from // specific IP addresses or ranges of IP addresses. For example, if you're receiving // a lot of requests from a ranges of IP addresses, you can configure WAF to // block them using an IPSet that lists those IP addresses. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation CreateIPSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateIPSet func (c *WAFV2) CreateIPSet(input *CreateIPSetInput) (*CreateIPSetOutput, error) { req, out := c.CreateIPSetRequest(input) return out, req.Send() } // CreateIPSetWithContext is the same as CreateIPSet with the addition of // the ability to pass a context and additional request options. // // See CreateIPSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) CreateIPSetWithContext(ctx aws.Context, input *CreateIPSetInput, opts ...request.Option) (*CreateIPSetOutput, error) { req, out := c.CreateIPSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opCreateRegexPatternSet = "CreateRegexPatternSet" // CreateRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the CreateRegexPatternSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See CreateRegexPatternSet for more information on using the CreateRegexPatternSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the CreateRegexPatternSetRequest method. // req, resp := client.CreateRegexPatternSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRegexPatternSet func (c *WAFV2) CreateRegexPatternSetRequest(input *CreateRegexPatternSetInput) (req *request.Request, output *CreateRegexPatternSetOutput) { op := &request.Operation{ Name: opCreateRegexPatternSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &CreateRegexPatternSetInput{} } output = &CreateRegexPatternSetOutput{} req = c.newRequest(op, input, output) return } // CreateRegexPatternSet API operation for AWS WAFV2. // // Creates a RegexPatternSet, which you reference in a RegexPatternSetReferenceStatement, // to have WAF inspect a web request component for the specified patterns. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation CreateRegexPatternSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRegexPatternSet func (c *WAFV2) CreateRegexPatternSet(input *CreateRegexPatternSetInput) (*CreateRegexPatternSetOutput, error) { req, out := c.CreateRegexPatternSetRequest(input) return out, req.Send() } // CreateRegexPatternSetWithContext is the same as CreateRegexPatternSet with the addition of // the ability to pass a context and additional request options. // // See CreateRegexPatternSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) CreateRegexPatternSetWithContext(ctx aws.Context, input *CreateRegexPatternSetInput, opts ...request.Option) (*CreateRegexPatternSetOutput, error) { req, out := c.CreateRegexPatternSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opCreateRuleGroup = "CreateRuleGroup" // CreateRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateRuleGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See CreateRuleGroup for more information on using the CreateRuleGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the CreateRuleGroupRequest method. // req, resp := client.CreateRuleGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRuleGroup func (c *WAFV2) CreateRuleGroupRequest(input *CreateRuleGroupInput) (req *request.Request, output *CreateRuleGroupOutput) { op := &request.Operation{ Name: opCreateRuleGroup, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &CreateRuleGroupInput{} } output = &CreateRuleGroupOutput{} req = c.newRequest(op, input, output) return } // CreateRuleGroup API operation for AWS WAFV2. // // Creates a RuleGroup per the specifications provided. // // A rule group defines a collection of rules to inspect and control web requests // that you can use in a WebACL. When you create a rule group, you define an // immutable capacity limit. If you update a rule group, you must stay within // the capacity. This allows others to reuse the rule group with confidence // in its capacity requirements. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation CreateRuleGroup for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFSubscriptionNotFoundException // You tried to use a managed rule group that's available by subscription, but // you aren't subscribed to it yet. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRuleGroup func (c *WAFV2) CreateRuleGroup(input *CreateRuleGroupInput) (*CreateRuleGroupOutput, error) { req, out := c.CreateRuleGroupRequest(input) return out, req.Send() } // CreateRuleGroupWithContext is the same as CreateRuleGroup with the addition of // the ability to pass a context and additional request options. // // See CreateRuleGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) CreateRuleGroupWithContext(ctx aws.Context, input *CreateRuleGroupInput, opts ...request.Option) (*CreateRuleGroupOutput, error) { req, out := c.CreateRuleGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opCreateWebACL = "CreateWebACL" // CreateWebACLRequest generates a "aws/request.Request" representing the // client's request for the CreateWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See CreateWebACL for more information on using the CreateWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the CreateWebACLRequest method. // req, resp := client.CreateWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateWebACL func (c *WAFV2) CreateWebACLRequest(input *CreateWebACLInput) (req *request.Request, output *CreateWebACLOutput) { op := &request.Operation{ Name: opCreateWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &CreateWebACLInput{} } output = &CreateWebACLOutput{} req = c.newRequest(op, input, output) return } // CreateWebACL API operation for AWS WAFV2. // // Creates a WebACL per the specifications provided. // // A web ACL defines a collection of rules to use to inspect and control web // requests. Each rule has an action defined (allow, block, or count) for requests // that match the statement of the rule. In the web ACL, you assign a default // action to take (allow, block) for any request that does not match any of // the rules. The rules in a web ACL can be a combination of the types Rule, // RuleGroup, and managed rule group. You can associate a web ACL with one or // more Amazon Web Services resources to protect. The resources can be an Amazon // CloudFront distribution, an Amazon API Gateway REST API, an Application Load // Balancer, an AppSync GraphQL API, an Amazon Cognito user pool, an App Runner // service, or an Amazon Web Services Verified Access instance. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation CreateWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFInvalidResourceException // WAF couldn’t perform the operation because the resource that you requested // isn’t valid. Check the resource, and try again. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFSubscriptionNotFoundException // You tried to use a managed rule group that's available by subscription, but // you aren't subscribed to it yet. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFConfigurationWarningException // The operation failed because you are inspecting the web request body, headers, // or cookies without specifying how to handle oversize components. Rules that // inspect the body must either provide an OversizeHandling configuration or // they must be preceded by a SizeConstraintStatement that blocks the body content // from being too large. Rules that inspect the headers or cookies must provide // an OversizeHandling configuration. // // Provide the handling configuration and retry your operation. // // Alternately, you can suppress this warning by adding the following tag to // the resource that you provide to this operation: Tag (key:WAF:OversizeFieldsHandlingConstraintOptOut, // value:true). // // - WAFExpiredManagedRuleGroupVersionException // The operation failed because the specified version for the managed rule group // has expired. You can retrieve the available versions for the managed rule // group by calling ListAvailableManagedRuleGroupVersions. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateWebACL func (c *WAFV2) CreateWebACL(input *CreateWebACLInput) (*CreateWebACLOutput, error) { req, out := c.CreateWebACLRequest(input) return out, req.Send() } // CreateWebACLWithContext is the same as CreateWebACL with the addition of // the ability to pass a context and additional request options. // // See CreateWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) CreateWebACLWithContext(ctx aws.Context, input *CreateWebACLInput, opts ...request.Option) (*CreateWebACLOutput, error) { req, out := c.CreateWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeleteFirewallManagerRuleGroups = "DeleteFirewallManagerRuleGroups" // DeleteFirewallManagerRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the DeleteFirewallManagerRuleGroups operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeleteFirewallManagerRuleGroups for more information on using the DeleteFirewallManagerRuleGroups // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeleteFirewallManagerRuleGroupsRequest method. // req, resp := client.DeleteFirewallManagerRuleGroupsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteFirewallManagerRuleGroups func (c *WAFV2) DeleteFirewallManagerRuleGroupsRequest(input *DeleteFirewallManagerRuleGroupsInput) (req *request.Request, output *DeleteFirewallManagerRuleGroupsOutput) { op := &request.Operation{ Name: opDeleteFirewallManagerRuleGroups, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeleteFirewallManagerRuleGroupsInput{} } output = &DeleteFirewallManagerRuleGroupsOutput{} req = c.newRequest(op, input, output) return } // DeleteFirewallManagerRuleGroups API operation for AWS WAFV2. // // Deletes all rule groups that are managed by Firewall Manager for the specified // web ACL. // // You can only use this if ManagedByFirewallManager is false in the specified // WebACL. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeleteFirewallManagerRuleGroups for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteFirewallManagerRuleGroups func (c *WAFV2) DeleteFirewallManagerRuleGroups(input *DeleteFirewallManagerRuleGroupsInput) (*DeleteFirewallManagerRuleGroupsOutput, error) { req, out := c.DeleteFirewallManagerRuleGroupsRequest(input) return out, req.Send() } // DeleteFirewallManagerRuleGroupsWithContext is the same as DeleteFirewallManagerRuleGroups with the addition of // the ability to pass a context and additional request options. // // See DeleteFirewallManagerRuleGroups for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeleteFirewallManagerRuleGroupsWithContext(ctx aws.Context, input *DeleteFirewallManagerRuleGroupsInput, opts ...request.Option) (*DeleteFirewallManagerRuleGroupsOutput, error) { req, out := c.DeleteFirewallManagerRuleGroupsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeleteIPSet = "DeleteIPSet" // DeleteIPSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteIPSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeleteIPSet for more information on using the DeleteIPSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeleteIPSetRequest method. // req, resp := client.DeleteIPSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteIPSet func (c *WAFV2) DeleteIPSetRequest(input *DeleteIPSetInput) (req *request.Request, output *DeleteIPSetOutput) { op := &request.Operation{ Name: opDeleteIPSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeleteIPSetInput{} } output = &DeleteIPSetOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DeleteIPSet API operation for AWS WAFV2. // // Deletes the specified IPSet. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeleteIPSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFAssociatedItemException // WAF couldn’t perform the operation because your resource is being used // by another resource or it’s associated with another resource. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteIPSet func (c *WAFV2) DeleteIPSet(input *DeleteIPSetInput) (*DeleteIPSetOutput, error) { req, out := c.DeleteIPSetRequest(input) return out, req.Send() } // DeleteIPSetWithContext is the same as DeleteIPSet with the addition of // the ability to pass a context and additional request options. // // See DeleteIPSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeleteIPSetWithContext(ctx aws.Context, input *DeleteIPSetInput, opts ...request.Option) (*DeleteIPSetOutput, error) { req, out := c.DeleteIPSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeleteLoggingConfiguration = "DeleteLoggingConfiguration" // DeleteLoggingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoggingConfiguration operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeleteLoggingConfiguration for more information on using the DeleteLoggingConfiguration // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeleteLoggingConfigurationRequest method. // req, resp := client.DeleteLoggingConfigurationRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteLoggingConfiguration func (c *WAFV2) DeleteLoggingConfigurationRequest(input *DeleteLoggingConfigurationInput) (req *request.Request, output *DeleteLoggingConfigurationOutput) { op := &request.Operation{ Name: opDeleteLoggingConfiguration, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeleteLoggingConfigurationInput{} } output = &DeleteLoggingConfigurationOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DeleteLoggingConfiguration API operation for AWS WAFV2. // // Deletes the LoggingConfiguration from the specified web ACL. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeleteLoggingConfiguration for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteLoggingConfiguration func (c *WAFV2) DeleteLoggingConfiguration(input *DeleteLoggingConfigurationInput) (*DeleteLoggingConfigurationOutput, error) { req, out := c.DeleteLoggingConfigurationRequest(input) return out, req.Send() } // DeleteLoggingConfigurationWithContext is the same as DeleteLoggingConfiguration with the addition of // the ability to pass a context and additional request options. // // See DeleteLoggingConfiguration for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeleteLoggingConfigurationWithContext(ctx aws.Context, input *DeleteLoggingConfigurationInput, opts ...request.Option) (*DeleteLoggingConfigurationOutput, error) { req, out := c.DeleteLoggingConfigurationRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeletePermissionPolicy = "DeletePermissionPolicy" // DeletePermissionPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeletePermissionPolicy operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeletePermissionPolicy for more information on using the DeletePermissionPolicy // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeletePermissionPolicyRequest method. // req, resp := client.DeletePermissionPolicyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeletePermissionPolicy func (c *WAFV2) DeletePermissionPolicyRequest(input *DeletePermissionPolicyInput) (req *request.Request, output *DeletePermissionPolicyOutput) { op := &request.Operation{ Name: opDeletePermissionPolicy, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeletePermissionPolicyInput{} } output = &DeletePermissionPolicyOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DeletePermissionPolicy API operation for AWS WAFV2. // // Permanently deletes an IAM policy from the specified rule group. // // You must be the owner of the rule group to perform this operation. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeletePermissionPolicy for usage and error information. // // Returned Error Types: // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeletePermissionPolicy func (c *WAFV2) DeletePermissionPolicy(input *DeletePermissionPolicyInput) (*DeletePermissionPolicyOutput, error) { req, out := c.DeletePermissionPolicyRequest(input) return out, req.Send() } // DeletePermissionPolicyWithContext is the same as DeletePermissionPolicy with the addition of // the ability to pass a context and additional request options. // // See DeletePermissionPolicy for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeletePermissionPolicyWithContext(ctx aws.Context, input *DeletePermissionPolicyInput, opts ...request.Option) (*DeletePermissionPolicyOutput, error) { req, out := c.DeletePermissionPolicyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeleteRegexPatternSet = "DeleteRegexPatternSet" // DeleteRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteRegexPatternSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeleteRegexPatternSet for more information on using the DeleteRegexPatternSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeleteRegexPatternSetRequest method. // req, resp := client.DeleteRegexPatternSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRegexPatternSet func (c *WAFV2) DeleteRegexPatternSetRequest(input *DeleteRegexPatternSetInput) (req *request.Request, output *DeleteRegexPatternSetOutput) { op := &request.Operation{ Name: opDeleteRegexPatternSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeleteRegexPatternSetInput{} } output = &DeleteRegexPatternSetOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DeleteRegexPatternSet API operation for AWS WAFV2. // // Deletes the specified RegexPatternSet. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeleteRegexPatternSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFAssociatedItemException // WAF couldn’t perform the operation because your resource is being used // by another resource or it’s associated with another resource. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRegexPatternSet func (c *WAFV2) DeleteRegexPatternSet(input *DeleteRegexPatternSetInput) (*DeleteRegexPatternSetOutput, error) { req, out := c.DeleteRegexPatternSetRequest(input) return out, req.Send() } // DeleteRegexPatternSetWithContext is the same as DeleteRegexPatternSet with the addition of // the ability to pass a context and additional request options. // // See DeleteRegexPatternSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeleteRegexPatternSetWithContext(ctx aws.Context, input *DeleteRegexPatternSetInput, opts ...request.Option) (*DeleteRegexPatternSetOutput, error) { req, out := c.DeleteRegexPatternSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeleteRuleGroup = "DeleteRuleGroup" // DeleteRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteRuleGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeleteRuleGroup for more information on using the DeleteRuleGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeleteRuleGroupRequest method. // req, resp := client.DeleteRuleGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRuleGroup func (c *WAFV2) DeleteRuleGroupRequest(input *DeleteRuleGroupInput) (req *request.Request, output *DeleteRuleGroupOutput) { op := &request.Operation{ Name: opDeleteRuleGroup, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeleteRuleGroupInput{} } output = &DeleteRuleGroupOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DeleteRuleGroup API operation for AWS WAFV2. // // Deletes the specified RuleGroup. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeleteRuleGroup for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFAssociatedItemException // WAF couldn’t perform the operation because your resource is being used // by another resource or it’s associated with another resource. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRuleGroup func (c *WAFV2) DeleteRuleGroup(input *DeleteRuleGroupInput) (*DeleteRuleGroupOutput, error) { req, out := c.DeleteRuleGroupRequest(input) return out, req.Send() } // DeleteRuleGroupWithContext is the same as DeleteRuleGroup with the addition of // the ability to pass a context and additional request options. // // See DeleteRuleGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeleteRuleGroupWithContext(ctx aws.Context, input *DeleteRuleGroupInput, opts ...request.Option) (*DeleteRuleGroupOutput, error) { req, out := c.DeleteRuleGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDeleteWebACL = "DeleteWebACL" // DeleteWebACLRequest generates a "aws/request.Request" representing the // client's request for the DeleteWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DeleteWebACL for more information on using the DeleteWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DeleteWebACLRequest method. // req, resp := client.DeleteWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteWebACL func (c *WAFV2) DeleteWebACLRequest(input *DeleteWebACLInput) (req *request.Request, output *DeleteWebACLOutput) { op := &request.Operation{ Name: opDeleteWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DeleteWebACLInput{} } output = &DeleteWebACLOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DeleteWebACL API operation for AWS WAFV2. // // Deletes the specified WebACL. // // You can only use this if ManagedByFirewallManager is false in the specified // WebACL. // // Before deleting any web ACL, first disassociate it from all resources. // // - To retrieve a list of the resources that are associated with a web ACL, // use the following calls: For regional resources, call ListResourcesForWebACL. // For Amazon CloudFront distributions, use the CloudFront call ListDistributionsByWebACLId. // For information, see ListDistributionsByWebACLId (https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByWebACLId.html) // in the Amazon CloudFront API Reference. // // - To disassociate a resource from a web ACL, use the following calls: // For regional resources, call DisassociateWebACL. For Amazon CloudFront // distributions, provide an empty web ACL ID in the CloudFront call UpdateDistribution. // For information, see UpdateDistribution (https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html) // in the Amazon CloudFront API Reference. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DeleteWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFAssociatedItemException // WAF couldn’t perform the operation because your resource is being used // by another resource or it’s associated with another resource. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteWebACL func (c *WAFV2) DeleteWebACL(input *DeleteWebACLInput) (*DeleteWebACLOutput, error) { req, out := c.DeleteWebACLRequest(input) return out, req.Send() } // DeleteWebACLWithContext is the same as DeleteWebACL with the addition of // the ability to pass a context and additional request options. // // See DeleteWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DeleteWebACLWithContext(ctx aws.Context, input *DeleteWebACLInput, opts ...request.Option) (*DeleteWebACLOutput, error) { req, out := c.DeleteWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDescribeAllManagedProducts = "DescribeAllManagedProducts" // DescribeAllManagedProductsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAllManagedProducts operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DescribeAllManagedProducts for more information on using the DescribeAllManagedProducts // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DescribeAllManagedProductsRequest method. // req, resp := client.DescribeAllManagedProductsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeAllManagedProducts func (c *WAFV2) DescribeAllManagedProductsRequest(input *DescribeAllManagedProductsInput) (req *request.Request, output *DescribeAllManagedProductsOutput) { op := &request.Operation{ Name: opDescribeAllManagedProducts, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DescribeAllManagedProductsInput{} } output = &DescribeAllManagedProductsOutput{} req = c.newRequest(op, input, output) return } // DescribeAllManagedProducts API operation for AWS WAFV2. // // Provides high-level information for the Amazon Web Services Managed Rules // rule groups and Amazon Web Services Marketplace managed rule groups. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DescribeAllManagedProducts for usage and error information. // // Returned Error Types: // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeAllManagedProducts func (c *WAFV2) DescribeAllManagedProducts(input *DescribeAllManagedProductsInput) (*DescribeAllManagedProductsOutput, error) { req, out := c.DescribeAllManagedProductsRequest(input) return out, req.Send() } // DescribeAllManagedProductsWithContext is the same as DescribeAllManagedProducts with the addition of // the ability to pass a context and additional request options. // // See DescribeAllManagedProducts for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DescribeAllManagedProductsWithContext(ctx aws.Context, input *DescribeAllManagedProductsInput, opts ...request.Option) (*DescribeAllManagedProductsOutput, error) { req, out := c.DescribeAllManagedProductsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDescribeManagedProductsByVendor = "DescribeManagedProductsByVendor" // DescribeManagedProductsByVendorRequest generates a "aws/request.Request" representing the // client's request for the DescribeManagedProductsByVendor operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DescribeManagedProductsByVendor for more information on using the DescribeManagedProductsByVendor // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DescribeManagedProductsByVendorRequest method. // req, resp := client.DescribeManagedProductsByVendorRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeManagedProductsByVendor func (c *WAFV2) DescribeManagedProductsByVendorRequest(input *DescribeManagedProductsByVendorInput) (req *request.Request, output *DescribeManagedProductsByVendorOutput) { op := &request.Operation{ Name: opDescribeManagedProductsByVendor, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DescribeManagedProductsByVendorInput{} } output = &DescribeManagedProductsByVendorOutput{} req = c.newRequest(op, input, output) return } // DescribeManagedProductsByVendor API operation for AWS WAFV2. // // Provides high-level information for the managed rule groups owned by a specific // vendor. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DescribeManagedProductsByVendor for usage and error information. // // Returned Error Types: // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeManagedProductsByVendor func (c *WAFV2) DescribeManagedProductsByVendor(input *DescribeManagedProductsByVendorInput) (*DescribeManagedProductsByVendorOutput, error) { req, out := c.DescribeManagedProductsByVendorRequest(input) return out, req.Send() } // DescribeManagedProductsByVendorWithContext is the same as DescribeManagedProductsByVendor with the addition of // the ability to pass a context and additional request options. // // See DescribeManagedProductsByVendor for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DescribeManagedProductsByVendorWithContext(ctx aws.Context, input *DescribeManagedProductsByVendorInput, opts ...request.Option) (*DescribeManagedProductsByVendorOutput, error) { req, out := c.DescribeManagedProductsByVendorRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDescribeManagedRuleGroup = "DescribeManagedRuleGroup" // DescribeManagedRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the DescribeManagedRuleGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DescribeManagedRuleGroup for more information on using the DescribeManagedRuleGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DescribeManagedRuleGroupRequest method. // req, resp := client.DescribeManagedRuleGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeManagedRuleGroup func (c *WAFV2) DescribeManagedRuleGroupRequest(input *DescribeManagedRuleGroupInput) (req *request.Request, output *DescribeManagedRuleGroupOutput) { op := &request.Operation{ Name: opDescribeManagedRuleGroup, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DescribeManagedRuleGroupInput{} } output = &DescribeManagedRuleGroupOutput{} req = c.newRequest(op, input, output) return } // DescribeManagedRuleGroup API operation for AWS WAFV2. // // Provides high-level information for a managed rule group, including descriptions // of the rules. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DescribeManagedRuleGroup for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidResourceException // WAF couldn’t perform the operation because the resource that you requested // isn’t valid. Check the resource, and try again. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFExpiredManagedRuleGroupVersionException // The operation failed because the specified version for the managed rule group // has expired. You can retrieve the available versions for the managed rule // group by calling ListAvailableManagedRuleGroupVersions. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeManagedRuleGroup func (c *WAFV2) DescribeManagedRuleGroup(input *DescribeManagedRuleGroupInput) (*DescribeManagedRuleGroupOutput, error) { req, out := c.DescribeManagedRuleGroupRequest(input) return out, req.Send() } // DescribeManagedRuleGroupWithContext is the same as DescribeManagedRuleGroup with the addition of // the ability to pass a context and additional request options. // // See DescribeManagedRuleGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DescribeManagedRuleGroupWithContext(ctx aws.Context, input *DescribeManagedRuleGroupInput, opts ...request.Option) (*DescribeManagedRuleGroupOutput, error) { req, out := c.DescribeManagedRuleGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opDisassociateWebACL = "DisassociateWebACL" // DisassociateWebACLRequest generates a "aws/request.Request" representing the // client's request for the DisassociateWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See DisassociateWebACL for more information on using the DisassociateWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the DisassociateWebACLRequest method. // req, resp := client.DisassociateWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DisassociateWebACL func (c *WAFV2) DisassociateWebACLRequest(input *DisassociateWebACLInput) (req *request.Request, output *DisassociateWebACLOutput) { op := &request.Operation{ Name: opDisassociateWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &DisassociateWebACLInput{} } output = &DisassociateWebACLOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // DisassociateWebACL API operation for AWS WAFV2. // // Disassociates the specified regional application resource from any existing // web ACL association. A resource can have at most one web ACL association. // A regional application can be an Application Load Balancer (ALB), an Amazon // API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito user pool, // an App Runner service, or an Amazon Web Services Verified Access instance. // // For Amazon CloudFront, don't use this call. Instead, use your CloudFront // distribution configuration. To disassociate a web ACL, provide an empty web // ACL ID in the CloudFront call UpdateDistribution. For information, see UpdateDistribution // (https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html) // in the Amazon CloudFront API Reference. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation DisassociateWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DisassociateWebACL func (c *WAFV2) DisassociateWebACL(input *DisassociateWebACLInput) (*DisassociateWebACLOutput, error) { req, out := c.DisassociateWebACLRequest(input) return out, req.Send() } // DisassociateWebACLWithContext is the same as DisassociateWebACL with the addition of // the ability to pass a context and additional request options. // // See DisassociateWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) DisassociateWebACLWithContext(ctx aws.Context, input *DisassociateWebACLInput, opts ...request.Option) (*DisassociateWebACLOutput, error) { req, out := c.DisassociateWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGenerateMobileSdkReleaseUrl = "GenerateMobileSdkReleaseUrl" // GenerateMobileSdkReleaseUrlRequest generates a "aws/request.Request" representing the // client's request for the GenerateMobileSdkReleaseUrl operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GenerateMobileSdkReleaseUrl for more information on using the GenerateMobileSdkReleaseUrl // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GenerateMobileSdkReleaseUrlRequest method. // req, resp := client.GenerateMobileSdkReleaseUrlRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GenerateMobileSdkReleaseUrl func (c *WAFV2) GenerateMobileSdkReleaseUrlRequest(input *GenerateMobileSdkReleaseUrlInput) (req *request.Request, output *GenerateMobileSdkReleaseUrlOutput) { op := &request.Operation{ Name: opGenerateMobileSdkReleaseUrl, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GenerateMobileSdkReleaseUrlInput{} } output = &GenerateMobileSdkReleaseUrlOutput{} req = c.newRequest(op, input, output) return } // GenerateMobileSdkReleaseUrl API operation for AWS WAFV2. // // Generates a presigned download URL for the specified release of the mobile // SDK. // // The mobile SDK is not generally available. Customers who have access to the // mobile SDK can use it to establish and manage WAF tokens for use in HTTP(S) // requests from a mobile device to WAF. For more information, see WAF client // application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GenerateMobileSdkReleaseUrl for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GenerateMobileSdkReleaseUrl func (c *WAFV2) GenerateMobileSdkReleaseUrl(input *GenerateMobileSdkReleaseUrlInput) (*GenerateMobileSdkReleaseUrlOutput, error) { req, out := c.GenerateMobileSdkReleaseUrlRequest(input) return out, req.Send() } // GenerateMobileSdkReleaseUrlWithContext is the same as GenerateMobileSdkReleaseUrl with the addition of // the ability to pass a context and additional request options. // // See GenerateMobileSdkReleaseUrl for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GenerateMobileSdkReleaseUrlWithContext(ctx aws.Context, input *GenerateMobileSdkReleaseUrlInput, opts ...request.Option) (*GenerateMobileSdkReleaseUrlOutput, error) { req, out := c.GenerateMobileSdkReleaseUrlRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetDecryptedAPIKey = "GetDecryptedAPIKey" // GetDecryptedAPIKeyRequest generates a "aws/request.Request" representing the // client's request for the GetDecryptedAPIKey operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetDecryptedAPIKey for more information on using the GetDecryptedAPIKey // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetDecryptedAPIKeyRequest method. // req, resp := client.GetDecryptedAPIKeyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetDecryptedAPIKey func (c *WAFV2) GetDecryptedAPIKeyRequest(input *GetDecryptedAPIKeyInput) (req *request.Request, output *GetDecryptedAPIKeyOutput) { op := &request.Operation{ Name: opGetDecryptedAPIKey, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetDecryptedAPIKeyInput{} } output = &GetDecryptedAPIKeyOutput{} req = c.newRequest(op, input, output) return } // GetDecryptedAPIKey API operation for AWS WAFV2. // // Returns your API key in decrypted form. Use this to check the token domains // that you have defined for the key. // // API keys are required for the integration of the CAPTCHA API in your JavaScript // client applications. The API lets you customize the placement and characteristics // of the CAPTCHA puzzle for your end users. For more information about the // CAPTCHA JavaScript integration, see WAF client application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetDecryptedAPIKey for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFInvalidResourceException // WAF couldn’t perform the operation because the resource that you requested // isn’t valid. Check the resource, and try again. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetDecryptedAPIKey func (c *WAFV2) GetDecryptedAPIKey(input *GetDecryptedAPIKeyInput) (*GetDecryptedAPIKeyOutput, error) { req, out := c.GetDecryptedAPIKeyRequest(input) return out, req.Send() } // GetDecryptedAPIKeyWithContext is the same as GetDecryptedAPIKey with the addition of // the ability to pass a context and additional request options. // // See GetDecryptedAPIKey for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetDecryptedAPIKeyWithContext(ctx aws.Context, input *GetDecryptedAPIKeyInput, opts ...request.Option) (*GetDecryptedAPIKeyOutput, error) { req, out := c.GetDecryptedAPIKeyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetIPSet = "GetIPSet" // GetIPSetRequest generates a "aws/request.Request" representing the // client's request for the GetIPSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetIPSet for more information on using the GetIPSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetIPSetRequest method. // req, resp := client.GetIPSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetIPSet func (c *WAFV2) GetIPSetRequest(input *GetIPSetInput) (req *request.Request, output *GetIPSetOutput) { op := &request.Operation{ Name: opGetIPSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetIPSetInput{} } output = &GetIPSetOutput{} req = c.newRequest(op, input, output) return } // GetIPSet API operation for AWS WAFV2. // // Retrieves the specified IPSet. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetIPSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetIPSet func (c *WAFV2) GetIPSet(input *GetIPSetInput) (*GetIPSetOutput, error) { req, out := c.GetIPSetRequest(input) return out, req.Send() } // GetIPSetWithContext is the same as GetIPSet with the addition of // the ability to pass a context and additional request options. // // See GetIPSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetIPSetWithContext(ctx aws.Context, input *GetIPSetInput, opts ...request.Option) (*GetIPSetOutput, error) { req, out := c.GetIPSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetLoggingConfiguration = "GetLoggingConfiguration" // GetLoggingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetLoggingConfiguration operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetLoggingConfiguration for more information on using the GetLoggingConfiguration // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetLoggingConfigurationRequest method. // req, resp := client.GetLoggingConfigurationRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetLoggingConfiguration func (c *WAFV2) GetLoggingConfigurationRequest(input *GetLoggingConfigurationInput) (req *request.Request, output *GetLoggingConfigurationOutput) { op := &request.Operation{ Name: opGetLoggingConfiguration, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetLoggingConfigurationInput{} } output = &GetLoggingConfigurationOutput{} req = c.newRequest(op, input, output) return } // GetLoggingConfiguration API operation for AWS WAFV2. // // Returns the LoggingConfiguration for the specified web ACL. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetLoggingConfiguration for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetLoggingConfiguration func (c *WAFV2) GetLoggingConfiguration(input *GetLoggingConfigurationInput) (*GetLoggingConfigurationOutput, error) { req, out := c.GetLoggingConfigurationRequest(input) return out, req.Send() } // GetLoggingConfigurationWithContext is the same as GetLoggingConfiguration with the addition of // the ability to pass a context and additional request options. // // See GetLoggingConfiguration for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetLoggingConfigurationWithContext(ctx aws.Context, input *GetLoggingConfigurationInput, opts ...request.Option) (*GetLoggingConfigurationOutput, error) { req, out := c.GetLoggingConfigurationRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetManagedRuleSet = "GetManagedRuleSet" // GetManagedRuleSetRequest generates a "aws/request.Request" representing the // client's request for the GetManagedRuleSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetManagedRuleSet for more information on using the GetManagedRuleSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetManagedRuleSetRequest method. // req, resp := client.GetManagedRuleSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetManagedRuleSet func (c *WAFV2) GetManagedRuleSetRequest(input *GetManagedRuleSetInput) (req *request.Request, output *GetManagedRuleSetOutput) { op := &request.Operation{ Name: opGetManagedRuleSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetManagedRuleSetInput{} } output = &GetManagedRuleSetOutput{} req = c.newRequest(op, input, output) return } // GetManagedRuleSet API operation for AWS WAFV2. // // Retrieves the specified managed rule set. // // This is intended for use only by vendors of managed rule sets. Vendors are // Amazon Web Services and Amazon Web Services Marketplace sellers. // // Vendors, you can use the managed rule set APIs to provide controlled rollout // of your versioned managed rule group offerings for your customers. The APIs // are ListManagedRuleSets, GetManagedRuleSet, PutManagedRuleSetVersions, and // UpdateManagedRuleSetVersionExpiryDate. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetManagedRuleSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetManagedRuleSet func (c *WAFV2) GetManagedRuleSet(input *GetManagedRuleSetInput) (*GetManagedRuleSetOutput, error) { req, out := c.GetManagedRuleSetRequest(input) return out, req.Send() } // GetManagedRuleSetWithContext is the same as GetManagedRuleSet with the addition of // the ability to pass a context and additional request options. // // See GetManagedRuleSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetManagedRuleSetWithContext(ctx aws.Context, input *GetManagedRuleSetInput, opts ...request.Option) (*GetManagedRuleSetOutput, error) { req, out := c.GetManagedRuleSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetMobileSdkRelease = "GetMobileSdkRelease" // GetMobileSdkReleaseRequest generates a "aws/request.Request" representing the // client's request for the GetMobileSdkRelease operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetMobileSdkRelease for more information on using the GetMobileSdkRelease // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetMobileSdkReleaseRequest method. // req, resp := client.GetMobileSdkReleaseRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetMobileSdkRelease func (c *WAFV2) GetMobileSdkReleaseRequest(input *GetMobileSdkReleaseInput) (req *request.Request, output *GetMobileSdkReleaseOutput) { op := &request.Operation{ Name: opGetMobileSdkRelease, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetMobileSdkReleaseInput{} } output = &GetMobileSdkReleaseOutput{} req = c.newRequest(op, input, output) return } // GetMobileSdkRelease API operation for AWS WAFV2. // // Retrieves information for the specified mobile SDK release, including release // notes and tags. // // The mobile SDK is not generally available. Customers who have access to the // mobile SDK can use it to establish and manage WAF tokens for use in HTTP(S) // requests from a mobile device to WAF. For more information, see WAF client // application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetMobileSdkRelease for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetMobileSdkRelease func (c *WAFV2) GetMobileSdkRelease(input *GetMobileSdkReleaseInput) (*GetMobileSdkReleaseOutput, error) { req, out := c.GetMobileSdkReleaseRequest(input) return out, req.Send() } // GetMobileSdkReleaseWithContext is the same as GetMobileSdkRelease with the addition of // the ability to pass a context and additional request options. // // See GetMobileSdkRelease for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetMobileSdkReleaseWithContext(ctx aws.Context, input *GetMobileSdkReleaseInput, opts ...request.Option) (*GetMobileSdkReleaseOutput, error) { req, out := c.GetMobileSdkReleaseRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetPermissionPolicy = "GetPermissionPolicy" // GetPermissionPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetPermissionPolicy operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetPermissionPolicy for more information on using the GetPermissionPolicy // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetPermissionPolicyRequest method. // req, resp := client.GetPermissionPolicyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetPermissionPolicy func (c *WAFV2) GetPermissionPolicyRequest(input *GetPermissionPolicyInput) (req *request.Request, output *GetPermissionPolicyOutput) { op := &request.Operation{ Name: opGetPermissionPolicy, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetPermissionPolicyInput{} } output = &GetPermissionPolicyOutput{} req = c.newRequest(op, input, output) return } // GetPermissionPolicy API operation for AWS WAFV2. // // Returns the IAM policy that is attached to the specified rule group. // // You must be the owner of the rule group to perform this operation. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetPermissionPolicy for usage and error information. // // Returned Error Types: // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetPermissionPolicy func (c *WAFV2) GetPermissionPolicy(input *GetPermissionPolicyInput) (*GetPermissionPolicyOutput, error) { req, out := c.GetPermissionPolicyRequest(input) return out, req.Send() } // GetPermissionPolicyWithContext is the same as GetPermissionPolicy with the addition of // the ability to pass a context and additional request options. // // See GetPermissionPolicy for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetPermissionPolicyWithContext(ctx aws.Context, input *GetPermissionPolicyInput, opts ...request.Option) (*GetPermissionPolicyOutput, error) { req, out := c.GetPermissionPolicyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetRateBasedStatementManagedKeys = "GetRateBasedStatementManagedKeys" // GetRateBasedStatementManagedKeysRequest generates a "aws/request.Request" representing the // client's request for the GetRateBasedStatementManagedKeys operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetRateBasedStatementManagedKeys for more information on using the GetRateBasedStatementManagedKeys // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetRateBasedStatementManagedKeysRequest method. // req, resp := client.GetRateBasedStatementManagedKeysRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRateBasedStatementManagedKeys func (c *WAFV2) GetRateBasedStatementManagedKeysRequest(input *GetRateBasedStatementManagedKeysInput) (req *request.Request, output *GetRateBasedStatementManagedKeysOutput) { op := &request.Operation{ Name: opGetRateBasedStatementManagedKeys, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetRateBasedStatementManagedKeysInput{} } output = &GetRateBasedStatementManagedKeysOutput{} req = c.newRequest(op, input, output) return } // GetRateBasedStatementManagedKeys API operation for AWS WAFV2. // // Retrieves the IP addresses that are currently blocked by a rate-based rule // instance. This is only available for rate-based rules that aggregate solely // on the IP address or on the forwarded IP address. // // The maximum number of addresses that can be blocked for a single rate-based // rule instance is 10,000. If more than 10,000 addresses exceed the rate limit, // those with the highest rates are blocked. // // For a rate-based rule that you've defined inside a rule group, provide the // name of the rule group reference statement in your request, in addition to // the rate-based rule name and the web ACL name. // // WAF monitors web requests and manages keys independently for each unique // combination of web ACL, optional rule group, and rate-based rule. For example, // if you define a rate-based rule inside a rule group, and then use the rule // group in a web ACL, WAF monitors web requests and manages keys for that web // ACL, rule group reference statement, and rate-based rule instance. If you // use the same rule group in a second web ACL, WAF monitors web requests and // manages keys for this second usage completely independent of your first. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetRateBasedStatementManagedKeys for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFUnsupportedAggregateKeyTypeException // The rule that you've named doesn't aggregate solely on the IP address or // solely on the forwarded IP address. This call is only available for rate-based // rules with an AggregateKeyType setting of IP or FORWARDED_IP. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRateBasedStatementManagedKeys func (c *WAFV2) GetRateBasedStatementManagedKeys(input *GetRateBasedStatementManagedKeysInput) (*GetRateBasedStatementManagedKeysOutput, error) { req, out := c.GetRateBasedStatementManagedKeysRequest(input) return out, req.Send() } // GetRateBasedStatementManagedKeysWithContext is the same as GetRateBasedStatementManagedKeys with the addition of // the ability to pass a context and additional request options. // // See GetRateBasedStatementManagedKeys for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetRateBasedStatementManagedKeysWithContext(ctx aws.Context, input *GetRateBasedStatementManagedKeysInput, opts ...request.Option) (*GetRateBasedStatementManagedKeysOutput, error) { req, out := c.GetRateBasedStatementManagedKeysRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetRegexPatternSet = "GetRegexPatternSet" // GetRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the GetRegexPatternSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetRegexPatternSet for more information on using the GetRegexPatternSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetRegexPatternSetRequest method. // req, resp := client.GetRegexPatternSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRegexPatternSet func (c *WAFV2) GetRegexPatternSetRequest(input *GetRegexPatternSetInput) (req *request.Request, output *GetRegexPatternSetOutput) { op := &request.Operation{ Name: opGetRegexPatternSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetRegexPatternSetInput{} } output = &GetRegexPatternSetOutput{} req = c.newRequest(op, input, output) return } // GetRegexPatternSet API operation for AWS WAFV2. // // Retrieves the specified RegexPatternSet. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetRegexPatternSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRegexPatternSet func (c *WAFV2) GetRegexPatternSet(input *GetRegexPatternSetInput) (*GetRegexPatternSetOutput, error) { req, out := c.GetRegexPatternSetRequest(input) return out, req.Send() } // GetRegexPatternSetWithContext is the same as GetRegexPatternSet with the addition of // the ability to pass a context and additional request options. // // See GetRegexPatternSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetRegexPatternSetWithContext(ctx aws.Context, input *GetRegexPatternSetInput, opts ...request.Option) (*GetRegexPatternSetOutput, error) { req, out := c.GetRegexPatternSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetRuleGroup = "GetRuleGroup" // GetRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the GetRuleGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetRuleGroup for more information on using the GetRuleGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetRuleGroupRequest method. // req, resp := client.GetRuleGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRuleGroup func (c *WAFV2) GetRuleGroupRequest(input *GetRuleGroupInput) (req *request.Request, output *GetRuleGroupOutput) { op := &request.Operation{ Name: opGetRuleGroup, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetRuleGroupInput{} } output = &GetRuleGroupOutput{} req = c.newRequest(op, input, output) return } // GetRuleGroup API operation for AWS WAFV2. // // Retrieves the specified RuleGroup. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetRuleGroup for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRuleGroup func (c *WAFV2) GetRuleGroup(input *GetRuleGroupInput) (*GetRuleGroupOutput, error) { req, out := c.GetRuleGroupRequest(input) return out, req.Send() } // GetRuleGroupWithContext is the same as GetRuleGroup with the addition of // the ability to pass a context and additional request options. // // See GetRuleGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetRuleGroupWithContext(ctx aws.Context, input *GetRuleGroupInput, opts ...request.Option) (*GetRuleGroupOutput, error) { req, out := c.GetRuleGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetSampledRequests = "GetSampledRequests" // GetSampledRequestsRequest generates a "aws/request.Request" representing the // client's request for the GetSampledRequests operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetSampledRequests for more information on using the GetSampledRequests // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetSampledRequestsRequest method. // req, resp := client.GetSampledRequestsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetSampledRequests func (c *WAFV2) GetSampledRequestsRequest(input *GetSampledRequestsInput) (req *request.Request, output *GetSampledRequestsOutput) { op := &request.Operation{ Name: opGetSampledRequests, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetSampledRequestsInput{} } output = &GetSampledRequestsOutput{} req = c.newRequest(op, input, output) return } // GetSampledRequests API operation for AWS WAFV2. // // Gets detailed information about a specified number of requests--a sample--that // WAF randomly selects from among the first 5,000 requests that your Amazon // Web Services resource received during a time range that you choose. You can // specify a sample size of up to 500 requests, and you can specify any time // range in the previous three hours. // // GetSampledRequests returns a time range, which is usually the time range // that you specified. However, if your resource (such as a CloudFront distribution) // received 5,000 requests before the specified time range elapsed, GetSampledRequests // returns an updated time range. This new time range indicates the actual period // during which WAF selected the requests in the sample. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetSampledRequests for usage and error information. // // Returned Error Types: // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetSampledRequests func (c *WAFV2) GetSampledRequests(input *GetSampledRequestsInput) (*GetSampledRequestsOutput, error) { req, out := c.GetSampledRequestsRequest(input) return out, req.Send() } // GetSampledRequestsWithContext is the same as GetSampledRequests with the addition of // the ability to pass a context and additional request options. // // See GetSampledRequests for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetSampledRequestsWithContext(ctx aws.Context, input *GetSampledRequestsInput, opts ...request.Option) (*GetSampledRequestsOutput, error) { req, out := c.GetSampledRequestsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetWebACL = "GetWebACL" // GetWebACLRequest generates a "aws/request.Request" representing the // client's request for the GetWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetWebACL for more information on using the GetWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetWebACLRequest method. // req, resp := client.GetWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACL func (c *WAFV2) GetWebACLRequest(input *GetWebACLInput) (req *request.Request, output *GetWebACLOutput) { op := &request.Operation{ Name: opGetWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetWebACLInput{} } output = &GetWebACLOutput{} req = c.newRequest(op, input, output) return } // GetWebACL API operation for AWS WAFV2. // // Retrieves the specified WebACL. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACL func (c *WAFV2) GetWebACL(input *GetWebACLInput) (*GetWebACLOutput, error) { req, out := c.GetWebACLRequest(input) return out, req.Send() } // GetWebACLWithContext is the same as GetWebACL with the addition of // the ability to pass a context and additional request options. // // See GetWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetWebACLWithContext(ctx aws.Context, input *GetWebACLInput, opts ...request.Option) (*GetWebACLOutput, error) { req, out := c.GetWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opGetWebACLForResource = "GetWebACLForResource" // GetWebACLForResourceRequest generates a "aws/request.Request" representing the // client's request for the GetWebACLForResource operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See GetWebACLForResource for more information on using the GetWebACLForResource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the GetWebACLForResourceRequest method. // req, resp := client.GetWebACLForResourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACLForResource func (c *WAFV2) GetWebACLForResourceRequest(input *GetWebACLForResourceInput) (req *request.Request, output *GetWebACLForResourceOutput) { op := &request.Operation{ Name: opGetWebACLForResource, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &GetWebACLForResourceInput{} } output = &GetWebACLForResourceOutput{} req = c.newRequest(op, input, output) return } // GetWebACLForResource API operation for AWS WAFV2. // // Retrieves the WebACL for the specified resource. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation GetWebACLForResource for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACLForResource func (c *WAFV2) GetWebACLForResource(input *GetWebACLForResourceInput) (*GetWebACLForResourceOutput, error) { req, out := c.GetWebACLForResourceRequest(input) return out, req.Send() } // GetWebACLForResourceWithContext is the same as GetWebACLForResource with the addition of // the ability to pass a context and additional request options. // // See GetWebACLForResource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) GetWebACLForResourceWithContext(ctx aws.Context, input *GetWebACLForResourceInput, opts ...request.Option) (*GetWebACLForResourceOutput, error) { req, out := c.GetWebACLForResourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListAPIKeys = "ListAPIKeys" // ListAPIKeysRequest generates a "aws/request.Request" representing the // client's request for the ListAPIKeys operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListAPIKeys for more information on using the ListAPIKeys // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListAPIKeysRequest method. // req, resp := client.ListAPIKeysRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAPIKeys func (c *WAFV2) ListAPIKeysRequest(input *ListAPIKeysInput) (req *request.Request, output *ListAPIKeysOutput) { op := &request.Operation{ Name: opListAPIKeys, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListAPIKeysInput{} } output = &ListAPIKeysOutput{} req = c.newRequest(op, input, output) return } // ListAPIKeys API operation for AWS WAFV2. // // Retrieves a list of the API keys that you've defined for the specified scope. // // API keys are required for the integration of the CAPTCHA API in your JavaScript // client applications. The API lets you customize the placement and characteristics // of the CAPTCHA puzzle for your end users. For more information about the // CAPTCHA JavaScript integration, see WAF client application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListAPIKeys for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFInvalidResourceException // WAF couldn’t perform the operation because the resource that you requested // isn’t valid. Check the resource, and try again. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAPIKeys func (c *WAFV2) ListAPIKeys(input *ListAPIKeysInput) (*ListAPIKeysOutput, error) { req, out := c.ListAPIKeysRequest(input) return out, req.Send() } // ListAPIKeysWithContext is the same as ListAPIKeys with the addition of // the ability to pass a context and additional request options. // // See ListAPIKeys for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListAPIKeysWithContext(ctx aws.Context, input *ListAPIKeysInput, opts ...request.Option) (*ListAPIKeysOutput, error) { req, out := c.ListAPIKeysRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListAvailableManagedRuleGroupVersions = "ListAvailableManagedRuleGroupVersions" // ListAvailableManagedRuleGroupVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListAvailableManagedRuleGroupVersions operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListAvailableManagedRuleGroupVersions for more information on using the ListAvailableManagedRuleGroupVersions // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListAvailableManagedRuleGroupVersionsRequest method. // req, resp := client.ListAvailableManagedRuleGroupVersionsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAvailableManagedRuleGroupVersions func (c *WAFV2) ListAvailableManagedRuleGroupVersionsRequest(input *ListAvailableManagedRuleGroupVersionsInput) (req *request.Request, output *ListAvailableManagedRuleGroupVersionsOutput) { op := &request.Operation{ Name: opListAvailableManagedRuleGroupVersions, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListAvailableManagedRuleGroupVersionsInput{} } output = &ListAvailableManagedRuleGroupVersionsOutput{} req = c.newRequest(op, input, output) return } // ListAvailableManagedRuleGroupVersions API operation for AWS WAFV2. // // Returns a list of the available versions for the specified managed rule group. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListAvailableManagedRuleGroupVersions for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAvailableManagedRuleGroupVersions func (c *WAFV2) ListAvailableManagedRuleGroupVersions(input *ListAvailableManagedRuleGroupVersionsInput) (*ListAvailableManagedRuleGroupVersionsOutput, error) { req, out := c.ListAvailableManagedRuleGroupVersionsRequest(input) return out, req.Send() } // ListAvailableManagedRuleGroupVersionsWithContext is the same as ListAvailableManagedRuleGroupVersions with the addition of // the ability to pass a context and additional request options. // // See ListAvailableManagedRuleGroupVersions for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListAvailableManagedRuleGroupVersionsWithContext(ctx aws.Context, input *ListAvailableManagedRuleGroupVersionsInput, opts ...request.Option) (*ListAvailableManagedRuleGroupVersionsOutput, error) { req, out := c.ListAvailableManagedRuleGroupVersionsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListAvailableManagedRuleGroups = "ListAvailableManagedRuleGroups" // ListAvailableManagedRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListAvailableManagedRuleGroups operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListAvailableManagedRuleGroups for more information on using the ListAvailableManagedRuleGroups // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListAvailableManagedRuleGroupsRequest method. // req, resp := client.ListAvailableManagedRuleGroupsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAvailableManagedRuleGroups func (c *WAFV2) ListAvailableManagedRuleGroupsRequest(input *ListAvailableManagedRuleGroupsInput) (req *request.Request, output *ListAvailableManagedRuleGroupsOutput) { op := &request.Operation{ Name: opListAvailableManagedRuleGroups, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListAvailableManagedRuleGroupsInput{} } output = &ListAvailableManagedRuleGroupsOutput{} req = c.newRequest(op, input, output) return } // ListAvailableManagedRuleGroups API operation for AWS WAFV2. // // Retrieves an array of managed rule groups that are available for you to use. // This list includes all Amazon Web Services Managed Rules rule groups and // all of the Amazon Web Services Marketplace managed rule groups that you're // subscribed to. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListAvailableManagedRuleGroups for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAvailableManagedRuleGroups func (c *WAFV2) ListAvailableManagedRuleGroups(input *ListAvailableManagedRuleGroupsInput) (*ListAvailableManagedRuleGroupsOutput, error) { req, out := c.ListAvailableManagedRuleGroupsRequest(input) return out, req.Send() } // ListAvailableManagedRuleGroupsWithContext is the same as ListAvailableManagedRuleGroups with the addition of // the ability to pass a context and additional request options. // // See ListAvailableManagedRuleGroups for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListAvailableManagedRuleGroupsWithContext(ctx aws.Context, input *ListAvailableManagedRuleGroupsInput, opts ...request.Option) (*ListAvailableManagedRuleGroupsOutput, error) { req, out := c.ListAvailableManagedRuleGroupsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListIPSets = "ListIPSets" // ListIPSetsRequest generates a "aws/request.Request" representing the // client's request for the ListIPSets operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListIPSets for more information on using the ListIPSets // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListIPSetsRequest method. // req, resp := client.ListIPSetsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListIPSets func (c *WAFV2) ListIPSetsRequest(input *ListIPSetsInput) (req *request.Request, output *ListIPSetsOutput) { op := &request.Operation{ Name: opListIPSets, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListIPSetsInput{} } output = &ListIPSetsOutput{} req = c.newRequest(op, input, output) return } // ListIPSets API operation for AWS WAFV2. // // Retrieves an array of IPSetSummary objects for the IP sets that you manage. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListIPSets for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListIPSets func (c *WAFV2) ListIPSets(input *ListIPSetsInput) (*ListIPSetsOutput, error) { req, out := c.ListIPSetsRequest(input) return out, req.Send() } // ListIPSetsWithContext is the same as ListIPSets with the addition of // the ability to pass a context and additional request options. // // See ListIPSets for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListIPSetsWithContext(ctx aws.Context, input *ListIPSetsInput, opts ...request.Option) (*ListIPSetsOutput, error) { req, out := c.ListIPSetsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListLoggingConfigurations = "ListLoggingConfigurations" // ListLoggingConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the ListLoggingConfigurations operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListLoggingConfigurations for more information on using the ListLoggingConfigurations // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListLoggingConfigurationsRequest method. // req, resp := client.ListLoggingConfigurationsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListLoggingConfigurations func (c *WAFV2) ListLoggingConfigurationsRequest(input *ListLoggingConfigurationsInput) (req *request.Request, output *ListLoggingConfigurationsOutput) { op := &request.Operation{ Name: opListLoggingConfigurations, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListLoggingConfigurationsInput{} } output = &ListLoggingConfigurationsOutput{} req = c.newRequest(op, input, output) return } // ListLoggingConfigurations API operation for AWS WAFV2. // // Retrieves an array of your LoggingConfiguration objects. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListLoggingConfigurations for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListLoggingConfigurations func (c *WAFV2) ListLoggingConfigurations(input *ListLoggingConfigurationsInput) (*ListLoggingConfigurationsOutput, error) { req, out := c.ListLoggingConfigurationsRequest(input) return out, req.Send() } // ListLoggingConfigurationsWithContext is the same as ListLoggingConfigurations with the addition of // the ability to pass a context and additional request options. // // See ListLoggingConfigurations for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListLoggingConfigurationsWithContext(ctx aws.Context, input *ListLoggingConfigurationsInput, opts ...request.Option) (*ListLoggingConfigurationsOutput, error) { req, out := c.ListLoggingConfigurationsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListManagedRuleSets = "ListManagedRuleSets" // ListManagedRuleSetsRequest generates a "aws/request.Request" representing the // client's request for the ListManagedRuleSets operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListManagedRuleSets for more information on using the ListManagedRuleSets // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListManagedRuleSetsRequest method. // req, resp := client.ListManagedRuleSetsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListManagedRuleSets func (c *WAFV2) ListManagedRuleSetsRequest(input *ListManagedRuleSetsInput) (req *request.Request, output *ListManagedRuleSetsOutput) { op := &request.Operation{ Name: opListManagedRuleSets, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListManagedRuleSetsInput{} } output = &ListManagedRuleSetsOutput{} req = c.newRequest(op, input, output) return } // ListManagedRuleSets API operation for AWS WAFV2. // // Retrieves the managed rule sets that you own. // // This is intended for use only by vendors of managed rule sets. Vendors are // Amazon Web Services and Amazon Web Services Marketplace sellers. // // Vendors, you can use the managed rule set APIs to provide controlled rollout // of your versioned managed rule group offerings for your customers. The APIs // are ListManagedRuleSets, GetManagedRuleSet, PutManagedRuleSetVersions, and // UpdateManagedRuleSetVersionExpiryDate. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListManagedRuleSets for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListManagedRuleSets func (c *WAFV2) ListManagedRuleSets(input *ListManagedRuleSetsInput) (*ListManagedRuleSetsOutput, error) { req, out := c.ListManagedRuleSetsRequest(input) return out, req.Send() } // ListManagedRuleSetsWithContext is the same as ListManagedRuleSets with the addition of // the ability to pass a context and additional request options. // // See ListManagedRuleSets for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListManagedRuleSetsWithContext(ctx aws.Context, input *ListManagedRuleSetsInput, opts ...request.Option) (*ListManagedRuleSetsOutput, error) { req, out := c.ListManagedRuleSetsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListMobileSdkReleases = "ListMobileSdkReleases" // ListMobileSdkReleasesRequest generates a "aws/request.Request" representing the // client's request for the ListMobileSdkReleases operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListMobileSdkReleases for more information on using the ListMobileSdkReleases // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListMobileSdkReleasesRequest method. // req, resp := client.ListMobileSdkReleasesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListMobileSdkReleases func (c *WAFV2) ListMobileSdkReleasesRequest(input *ListMobileSdkReleasesInput) (req *request.Request, output *ListMobileSdkReleasesOutput) { op := &request.Operation{ Name: opListMobileSdkReleases, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListMobileSdkReleasesInput{} } output = &ListMobileSdkReleasesOutput{} req = c.newRequest(op, input, output) return } // ListMobileSdkReleases API operation for AWS WAFV2. // // Retrieves a list of the available releases for the mobile SDK and the specified // device platform. // // The mobile SDK is not generally available. Customers who have access to the // mobile SDK can use it to establish and manage WAF tokens for use in HTTP(S) // requests from a mobile device to WAF. For more information, see WAF client // application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListMobileSdkReleases for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListMobileSdkReleases func (c *WAFV2) ListMobileSdkReleases(input *ListMobileSdkReleasesInput) (*ListMobileSdkReleasesOutput, error) { req, out := c.ListMobileSdkReleasesRequest(input) return out, req.Send() } // ListMobileSdkReleasesWithContext is the same as ListMobileSdkReleases with the addition of // the ability to pass a context and additional request options. // // See ListMobileSdkReleases for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListMobileSdkReleasesWithContext(ctx aws.Context, input *ListMobileSdkReleasesInput, opts ...request.Option) (*ListMobileSdkReleasesOutput, error) { req, out := c.ListMobileSdkReleasesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListRegexPatternSets = "ListRegexPatternSets" // ListRegexPatternSetsRequest generates a "aws/request.Request" representing the // client's request for the ListRegexPatternSets operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListRegexPatternSets for more information on using the ListRegexPatternSets // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListRegexPatternSetsRequest method. // req, resp := client.ListRegexPatternSetsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRegexPatternSets func (c *WAFV2) ListRegexPatternSetsRequest(input *ListRegexPatternSetsInput) (req *request.Request, output *ListRegexPatternSetsOutput) { op := &request.Operation{ Name: opListRegexPatternSets, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListRegexPatternSetsInput{} } output = &ListRegexPatternSetsOutput{} req = c.newRequest(op, input, output) return } // ListRegexPatternSets API operation for AWS WAFV2. // // Retrieves an array of RegexPatternSetSummary objects for the regex pattern // sets that you manage. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListRegexPatternSets for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRegexPatternSets func (c *WAFV2) ListRegexPatternSets(input *ListRegexPatternSetsInput) (*ListRegexPatternSetsOutput, error) { req, out := c.ListRegexPatternSetsRequest(input) return out, req.Send() } // ListRegexPatternSetsWithContext is the same as ListRegexPatternSets with the addition of // the ability to pass a context and additional request options. // // See ListRegexPatternSets for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListRegexPatternSetsWithContext(ctx aws.Context, input *ListRegexPatternSetsInput, opts ...request.Option) (*ListRegexPatternSetsOutput, error) { req, out := c.ListRegexPatternSetsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListResourcesForWebACL = "ListResourcesForWebACL" // ListResourcesForWebACLRequest generates a "aws/request.Request" representing the // client's request for the ListResourcesForWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListResourcesForWebACL for more information on using the ListResourcesForWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListResourcesForWebACLRequest method. // req, resp := client.ListResourcesForWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListResourcesForWebACL func (c *WAFV2) ListResourcesForWebACLRequest(input *ListResourcesForWebACLInput) (req *request.Request, output *ListResourcesForWebACLOutput) { op := &request.Operation{ Name: opListResourcesForWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListResourcesForWebACLInput{} } output = &ListResourcesForWebACLOutput{} req = c.newRequest(op, input, output) return } // ListResourcesForWebACL API operation for AWS WAFV2. // // Retrieves an array of the Amazon Resource Names (ARNs) for the regional resources // that are associated with the specified web ACL. If you want the list of Amazon // CloudFront resources, use the CloudFront call ListDistributionsByWebACLId. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListResourcesForWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListResourcesForWebACL func (c *WAFV2) ListResourcesForWebACL(input *ListResourcesForWebACLInput) (*ListResourcesForWebACLOutput, error) { req, out := c.ListResourcesForWebACLRequest(input) return out, req.Send() } // ListResourcesForWebACLWithContext is the same as ListResourcesForWebACL with the addition of // the ability to pass a context and additional request options. // // See ListResourcesForWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListResourcesForWebACLWithContext(ctx aws.Context, input *ListResourcesForWebACLInput, opts ...request.Option) (*ListResourcesForWebACLOutput, error) { req, out := c.ListResourcesForWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListRuleGroups = "ListRuleGroups" // ListRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListRuleGroups operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListRuleGroups for more information on using the ListRuleGroups // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListRuleGroupsRequest method. // req, resp := client.ListRuleGroupsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRuleGroups func (c *WAFV2) ListRuleGroupsRequest(input *ListRuleGroupsInput) (req *request.Request, output *ListRuleGroupsOutput) { op := &request.Operation{ Name: opListRuleGroups, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListRuleGroupsInput{} } output = &ListRuleGroupsOutput{} req = c.newRequest(op, input, output) return } // ListRuleGroups API operation for AWS WAFV2. // // Retrieves an array of RuleGroupSummary objects for the rule groups that you // manage. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListRuleGroups for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRuleGroups func (c *WAFV2) ListRuleGroups(input *ListRuleGroupsInput) (*ListRuleGroupsOutput, error) { req, out := c.ListRuleGroupsRequest(input) return out, req.Send() } // ListRuleGroupsWithContext is the same as ListRuleGroups with the addition of // the ability to pass a context and additional request options. // // See ListRuleGroups for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListRuleGroupsWithContext(ctx aws.Context, input *ListRuleGroupsInput, opts ...request.Option) (*ListRuleGroupsOutput, error) { req, out := c.ListRuleGroupsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListTagsForResource for more information on using the ListTagsForResource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListTagsForResourceRequest method. // req, resp := client.ListTagsForResourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListTagsForResource func (c *WAFV2) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { op := &request.Operation{ Name: opListTagsForResource, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListTagsForResourceInput{} } output = &ListTagsForResourceOutput{} req = c.newRequest(op, input, output) return } // ListTagsForResource API operation for AWS WAFV2. // // Retrieves the TagInfoForResource for the specified resource. Tags are key:value // pairs that you can use to categorize and manage your resources, for purposes // like billing. For example, you might set the tag key to "customer" and the // value to the customer name or ID. You can specify one or more tags to add // to each Amazon Web Services resource, up to 50 tags for a resource. // // You can tag the Amazon Web Services resources that you manage through WAF: // web ACLs, rule groups, IP sets, and regex pattern sets. You can't manage // or view tags through the WAF console. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListTagsForResource for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListTagsForResource func (c *WAFV2) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { req, out := c.ListTagsForResourceRequest(input) return out, req.Send() } // ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of // the ability to pass a context and additional request options. // // See ListTagsForResource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { req, out := c.ListTagsForResourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opListWebACLs = "ListWebACLs" // ListWebACLsRequest generates a "aws/request.Request" representing the // client's request for the ListWebACLs operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See ListWebACLs for more information on using the ListWebACLs // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the ListWebACLsRequest method. // req, resp := client.ListWebACLsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListWebACLs func (c *WAFV2) ListWebACLsRequest(input *ListWebACLsInput) (req *request.Request, output *ListWebACLsOutput) { op := &request.Operation{ Name: opListWebACLs, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &ListWebACLsInput{} } output = &ListWebACLsOutput{} req = c.newRequest(op, input, output) return } // ListWebACLs API operation for AWS WAFV2. // // Retrieves an array of WebACLSummary objects for the web ACLs that you manage. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation ListWebACLs for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListWebACLs func (c *WAFV2) ListWebACLs(input *ListWebACLsInput) (*ListWebACLsOutput, error) { req, out := c.ListWebACLsRequest(input) return out, req.Send() } // ListWebACLsWithContext is the same as ListWebACLs with the addition of // the ability to pass a context and additional request options. // // See ListWebACLs for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) ListWebACLsWithContext(ctx aws.Context, input *ListWebACLsInput, opts ...request.Option) (*ListWebACLsOutput, error) { req, out := c.ListWebACLsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opPutLoggingConfiguration = "PutLoggingConfiguration" // PutLoggingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutLoggingConfiguration operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See PutLoggingConfiguration for more information on using the PutLoggingConfiguration // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the PutLoggingConfigurationRequest method. // req, resp := client.PutLoggingConfigurationRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutLoggingConfiguration func (c *WAFV2) PutLoggingConfigurationRequest(input *PutLoggingConfigurationInput) (req *request.Request, output *PutLoggingConfigurationOutput) { op := &request.Operation{ Name: opPutLoggingConfiguration, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &PutLoggingConfigurationInput{} } output = &PutLoggingConfigurationOutput{} req = c.newRequest(op, input, output) return } // PutLoggingConfiguration API operation for AWS WAFV2. // // Enables the specified LoggingConfiguration, to start logging from a web ACL, // according to the configuration provided. // // This operation completely replaces any mutable specifications that you already // have for a logging configuration with the ones that you provide to this call. // // To modify an existing logging configuration, do the following: // // # Retrieve it by calling GetLoggingConfiguration // // # Update its settings as needed // // # Provide the complete logging configuration specification to this call // // You can define one logging destination per web ACL. // // You can access information about the traffic that WAF inspects using the // following steps: // // Create your logging destination. You can use an Amazon CloudWatch Logs log // group, an Amazon Simple Storage Service (Amazon S3) bucket, or an Amazon // Kinesis Data Firehose. // // The name that you give the destination must start with aws-waf-logs-. Depending // on the type of destination, you might need to configure additional settings // or permissions. // // For configuration requirements and pricing information for each destination // type, see Logging web ACL traffic (https://docs.aws.amazon.com/waf/latest/developerguide/logging.html) // in the WAF Developer Guide. // // Associate your logging destination to your web ACL using a PutLoggingConfiguration // request. // // When you successfully enable logging using a PutLoggingConfiguration request, // WAF creates an additional role or policy that is required to write logs to // the logging destination. For an Amazon CloudWatch Logs log group, WAF creates // a resource policy on the log group. For an Amazon S3 bucket, WAF creates // a bucket policy. For an Amazon Kinesis Data Firehose, WAF creates a service-linked // role. // // For additional information about web ACL logging, see Logging web ACL traffic // information (https://docs.aws.amazon.com/waf/latest/developerguide/logging.html) // in the WAF Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation PutLoggingConfiguration for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFServiceLinkedRoleErrorException // WAF is not able to access the service linked role. This can be caused by // a previous PutLoggingConfiguration request, which can lock the service linked // role for about 20 seconds. Please try your request again. The service linked // role can also be locked by a previous DeleteServiceLinkedRole request, which // can lock the role for 15 minutes or more. If you recently made a call to // DeleteServiceLinkedRole, wait at least 15 minutes and try the request again. // If you receive this same exception again, you will have to wait additional // time until the role is unlocked. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFLogDestinationPermissionIssueException // The operation failed because you don't have the permissions that your logging // configuration requires. For information, see Logging web ACL traffic information // (https://docs.aws.amazon.com/waf/latest/developerguide/logging.html) in the // WAF Developer Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutLoggingConfiguration func (c *WAFV2) PutLoggingConfiguration(input *PutLoggingConfigurationInput) (*PutLoggingConfigurationOutput, error) { req, out := c.PutLoggingConfigurationRequest(input) return out, req.Send() } // PutLoggingConfigurationWithContext is the same as PutLoggingConfiguration with the addition of // the ability to pass a context and additional request options. // // See PutLoggingConfiguration for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) PutLoggingConfigurationWithContext(ctx aws.Context, input *PutLoggingConfigurationInput, opts ...request.Option) (*PutLoggingConfigurationOutput, error) { req, out := c.PutLoggingConfigurationRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opPutManagedRuleSetVersions = "PutManagedRuleSetVersions" // PutManagedRuleSetVersionsRequest generates a "aws/request.Request" representing the // client's request for the PutManagedRuleSetVersions operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See PutManagedRuleSetVersions for more information on using the PutManagedRuleSetVersions // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the PutManagedRuleSetVersionsRequest method. // req, resp := client.PutManagedRuleSetVersionsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutManagedRuleSetVersions func (c *WAFV2) PutManagedRuleSetVersionsRequest(input *PutManagedRuleSetVersionsInput) (req *request.Request, output *PutManagedRuleSetVersionsOutput) { op := &request.Operation{ Name: opPutManagedRuleSetVersions, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &PutManagedRuleSetVersionsInput{} } output = &PutManagedRuleSetVersionsOutput{} req = c.newRequest(op, input, output) return } // PutManagedRuleSetVersions API operation for AWS WAFV2. // // Defines the versions of your managed rule set that you are offering to the // customers. Customers see your offerings as managed rule groups with versioning. // // This is intended for use only by vendors of managed rule sets. Vendors are // Amazon Web Services and Amazon Web Services Marketplace sellers. // // Vendors, you can use the managed rule set APIs to provide controlled rollout // of your versioned managed rule group offerings for your customers. The APIs // are ListManagedRuleSets, GetManagedRuleSet, PutManagedRuleSetVersions, and // UpdateManagedRuleSetVersionExpiryDate. // // Customers retrieve their managed rule group list by calling ListAvailableManagedRuleGroups. // The name that you provide here for your managed rule set is the name the // customer sees for the corresponding managed rule group. Customers can retrieve // the available versions for a managed rule group by calling ListAvailableManagedRuleGroupVersions. // You provide a rule group specification for each version. For each managed // rule set, you must specify a version that you recommend using. // // To initiate the expiration of a managed rule group version, use UpdateManagedRuleSetVersionExpiryDate. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation PutManagedRuleSetVersions for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutManagedRuleSetVersions func (c *WAFV2) PutManagedRuleSetVersions(input *PutManagedRuleSetVersionsInput) (*PutManagedRuleSetVersionsOutput, error) { req, out := c.PutManagedRuleSetVersionsRequest(input) return out, req.Send() } // PutManagedRuleSetVersionsWithContext is the same as PutManagedRuleSetVersions with the addition of // the ability to pass a context and additional request options. // // See PutManagedRuleSetVersions for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) PutManagedRuleSetVersionsWithContext(ctx aws.Context, input *PutManagedRuleSetVersionsInput, opts ...request.Option) (*PutManagedRuleSetVersionsOutput, error) { req, out := c.PutManagedRuleSetVersionsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opPutPermissionPolicy = "PutPermissionPolicy" // PutPermissionPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutPermissionPolicy operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See PutPermissionPolicy for more information on using the PutPermissionPolicy // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the PutPermissionPolicyRequest method. // req, resp := client.PutPermissionPolicyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutPermissionPolicy func (c *WAFV2) PutPermissionPolicyRequest(input *PutPermissionPolicyInput) (req *request.Request, output *PutPermissionPolicyOutput) { op := &request.Operation{ Name: opPutPermissionPolicy, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &PutPermissionPolicyInput{} } output = &PutPermissionPolicyOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // PutPermissionPolicy API operation for AWS WAFV2. // // Attaches an IAM policy to the specified resource. Use this to share a rule // group across accounts. // // You must be the owner of the rule group to perform this operation. // // This action is subject to the following restrictions: // // - You can attach only one policy with each PutPermissionPolicy request. // // - The ARN in the request must be a valid WAF RuleGroup ARN and the rule // group must exist in the same Region. // // - The user making the request must be the owner of the rule group. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation PutPermissionPolicy for usage and error information. // // Returned Error Types: // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFInvalidPermissionPolicyException // The operation failed because the specified policy isn't in the proper format. // // The policy specifications must conform to the following: // // - The policy must be composed using IAM Policy version 2012-10-17. // // - The policy must include specifications for Effect, Action, and Principal. // // - Effect must specify Allow. // // - Action must specify wafv2:CreateWebACL, wafv2:UpdateWebACL, and wafv2:PutFirewallManagerRuleGroups // and may optionally specify wafv2:GetRuleGroup. WAF rejects any extra actions // or wildcard actions in the policy. // // - The policy must not include a Resource parameter. // // For more information, see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html). // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutPermissionPolicy func (c *WAFV2) PutPermissionPolicy(input *PutPermissionPolicyInput) (*PutPermissionPolicyOutput, error) { req, out := c.PutPermissionPolicyRequest(input) return out, req.Send() } // PutPermissionPolicyWithContext is the same as PutPermissionPolicy with the addition of // the ability to pass a context and additional request options. // // See PutPermissionPolicy for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) PutPermissionPolicyWithContext(ctx aws.Context, input *PutPermissionPolicyInput, opts ...request.Option) (*PutPermissionPolicyOutput, error) { req, out := c.PutPermissionPolicyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See TagResource for more information on using the TagResource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the TagResourceRequest method. // req, resp := client.TagResourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/TagResource func (c *WAFV2) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { op := &request.Operation{ Name: opTagResource, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &TagResourceInput{} } output = &TagResourceOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // TagResource API operation for AWS WAFV2. // // Associates tags with the specified Amazon Web Services resource. Tags are // key:value pairs that you can use to categorize and manage your resources, // for purposes like billing. For example, you might set the tag key to "customer" // and the value to the customer name or ID. You can specify one or more tags // to add to each Amazon Web Services resource, up to 50 tags for a resource. // // You can tag the Amazon Web Services resources that you manage through WAF: // web ACLs, rule groups, IP sets, and regex pattern sets. You can't manage // or view tags through the WAF console. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation TagResource for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/TagResource func (c *WAFV2) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { req, out := c.TagResourceRequest(input) return out, req.Send() } // TagResourceWithContext is the same as TagResource with the addition of // the ability to pass a context and additional request options. // // See TagResource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { req, out := c.TagResourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See UntagResource for more information on using the UntagResource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the UntagResourceRequest method. // req, resp := client.UntagResourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UntagResource func (c *WAFV2) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { op := &request.Operation{ Name: opUntagResource, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &UntagResourceInput{} } output = &UntagResourceOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } // UntagResource API operation for AWS WAFV2. // // Disassociates tags from an Amazon Web Services resource. Tags are key:value // pairs that you can associate with Amazon Web Services resources. For example, // the tag key might be "customer" and the tag value might be "companyA." You // can specify one or more tags to add to each container. You can add up to // 50 tags to each Amazon Web Services resource. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation UntagResource for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFTagOperationException // An error occurred during the tagging operation. Retry your request. // // - WAFTagOperationInternalErrorException // WAF couldn’t perform your tagging operation because of an internal error. // Retry your request. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UntagResource func (c *WAFV2) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { req, out := c.UntagResourceRequest(input) return out, req.Send() } // UntagResourceWithContext is the same as UntagResource with the addition of // the ability to pass a context and additional request options. // // See UntagResource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { req, out := c.UntagResourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opUpdateIPSet = "UpdateIPSet" // UpdateIPSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateIPSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See UpdateIPSet for more information on using the UpdateIPSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the UpdateIPSetRequest method. // req, resp := client.UpdateIPSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateIPSet func (c *WAFV2) UpdateIPSetRequest(input *UpdateIPSetInput) (req *request.Request, output *UpdateIPSetOutput) { op := &request.Operation{ Name: opUpdateIPSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &UpdateIPSetInput{} } output = &UpdateIPSetOutput{} req = c.newRequest(op, input, output) return } // UpdateIPSet API operation for AWS WAFV2. // // Updates the specified IPSet. // // This operation completely replaces the mutable specifications that you already // have for the IP set with the ones that you provide to this call. // // To modify an IP set, do the following: // // # Retrieve it by calling GetIPSet // // # Update its settings as needed // // # Provide the complete IP set specification to this call // // When you make changes to web ACLs or web ACL components, like rules and rule // groups, WAF propagates the changes everywhere that the web ACL and its components // are stored and used. Your changes are applied within seconds, but there might // be a brief period of inconsistency when the changes have arrived in some // places and not in others. So, for example, if you change a rule action setting, // the action might be the old action in one area and the new action in another // area. Or if you add an IP address to an IP set used in a blocking rule, the // new address might briefly be blocked in one area while still allowed in another. // This temporary inconsistency can occur when you first associate a web ACL // with an Amazon Web Services resource and when you change a web ACL that is // already associated with a resource. Generally, any inconsistencies of this // type last only a few seconds. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation UpdateIPSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateIPSet func (c *WAFV2) UpdateIPSet(input *UpdateIPSetInput) (*UpdateIPSetOutput, error) { req, out := c.UpdateIPSetRequest(input) return out, req.Send() } // UpdateIPSetWithContext is the same as UpdateIPSet with the addition of // the ability to pass a context and additional request options. // // See UpdateIPSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) UpdateIPSetWithContext(ctx aws.Context, input *UpdateIPSetInput, opts ...request.Option) (*UpdateIPSetOutput, error) { req, out := c.UpdateIPSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opUpdateManagedRuleSetVersionExpiryDate = "UpdateManagedRuleSetVersionExpiryDate" // UpdateManagedRuleSetVersionExpiryDateRequest generates a "aws/request.Request" representing the // client's request for the UpdateManagedRuleSetVersionExpiryDate operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See UpdateManagedRuleSetVersionExpiryDate for more information on using the UpdateManagedRuleSetVersionExpiryDate // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the UpdateManagedRuleSetVersionExpiryDateRequest method. // req, resp := client.UpdateManagedRuleSetVersionExpiryDateRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateManagedRuleSetVersionExpiryDate func (c *WAFV2) UpdateManagedRuleSetVersionExpiryDateRequest(input *UpdateManagedRuleSetVersionExpiryDateInput) (req *request.Request, output *UpdateManagedRuleSetVersionExpiryDateOutput) { op := &request.Operation{ Name: opUpdateManagedRuleSetVersionExpiryDate, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &UpdateManagedRuleSetVersionExpiryDateInput{} } output = &UpdateManagedRuleSetVersionExpiryDateOutput{} req = c.newRequest(op, input, output) return } // UpdateManagedRuleSetVersionExpiryDate API operation for AWS WAFV2. // // Updates the expiration information for your managed rule set. Use this to // initiate the expiration of a managed rule group version. After you initiate // expiration for a version, WAF excludes it from the response to ListAvailableManagedRuleGroupVersions // for the managed rule group. // // This is intended for use only by vendors of managed rule sets. Vendors are // Amazon Web Services and Amazon Web Services Marketplace sellers. // // Vendors, you can use the managed rule set APIs to provide controlled rollout // of your versioned managed rule group offerings for your customers. The APIs // are ListManagedRuleSets, GetManagedRuleSet, PutManagedRuleSetVersions, and // UpdateManagedRuleSetVersionExpiryDate. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation UpdateManagedRuleSetVersionExpiryDate for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateManagedRuleSetVersionExpiryDate func (c *WAFV2) UpdateManagedRuleSetVersionExpiryDate(input *UpdateManagedRuleSetVersionExpiryDateInput) (*UpdateManagedRuleSetVersionExpiryDateOutput, error) { req, out := c.UpdateManagedRuleSetVersionExpiryDateRequest(input) return out, req.Send() } // UpdateManagedRuleSetVersionExpiryDateWithContext is the same as UpdateManagedRuleSetVersionExpiryDate with the addition of // the ability to pass a context and additional request options. // // See UpdateManagedRuleSetVersionExpiryDate for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) UpdateManagedRuleSetVersionExpiryDateWithContext(ctx aws.Context, input *UpdateManagedRuleSetVersionExpiryDateInput, opts ...request.Option) (*UpdateManagedRuleSetVersionExpiryDateOutput, error) { req, out := c.UpdateManagedRuleSetVersionExpiryDateRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opUpdateRegexPatternSet = "UpdateRegexPatternSet" // UpdateRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateRegexPatternSet operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See UpdateRegexPatternSet for more information on using the UpdateRegexPatternSet // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the UpdateRegexPatternSetRequest method. // req, resp := client.UpdateRegexPatternSetRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRegexPatternSet func (c *WAFV2) UpdateRegexPatternSetRequest(input *UpdateRegexPatternSetInput) (req *request.Request, output *UpdateRegexPatternSetOutput) { op := &request.Operation{ Name: opUpdateRegexPatternSet, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &UpdateRegexPatternSetInput{} } output = &UpdateRegexPatternSetOutput{} req = c.newRequest(op, input, output) return } // UpdateRegexPatternSet API operation for AWS WAFV2. // // Updates the specified RegexPatternSet. // // This operation completely replaces the mutable specifications that you already // have for the regex pattern set with the ones that you provide to this call. // // To modify a regex pattern set, do the following: // // # Retrieve it by calling GetRegexPatternSet // // # Update its settings as needed // // # Provide the complete regex pattern set specification to this call // // When you make changes to web ACLs or web ACL components, like rules and rule // groups, WAF propagates the changes everywhere that the web ACL and its components // are stored and used. Your changes are applied within seconds, but there might // be a brief period of inconsistency when the changes have arrived in some // places and not in others. So, for example, if you change a rule action setting, // the action might be the old action in one area and the new action in another // area. Or if you add an IP address to an IP set used in a blocking rule, the // new address might briefly be blocked in one area while still allowed in another. // This temporary inconsistency can occur when you first associate a web ACL // with an Amazon Web Services resource and when you change a web ACL that is // already associated with a resource. Generally, any inconsistencies of this // type last only a few seconds. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation UpdateRegexPatternSet for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFInvalidOperationException // The operation isn't valid. // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRegexPatternSet func (c *WAFV2) UpdateRegexPatternSet(input *UpdateRegexPatternSetInput) (*UpdateRegexPatternSetOutput, error) { req, out := c.UpdateRegexPatternSetRequest(input) return out, req.Send() } // UpdateRegexPatternSetWithContext is the same as UpdateRegexPatternSet with the addition of // the ability to pass a context and additional request options. // // See UpdateRegexPatternSet for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) UpdateRegexPatternSetWithContext(ctx aws.Context, input *UpdateRegexPatternSetInput, opts ...request.Option) (*UpdateRegexPatternSetOutput, error) { req, out := c.UpdateRegexPatternSetRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opUpdateRuleGroup = "UpdateRuleGroup" // UpdateRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateRuleGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See UpdateRuleGroup for more information on using the UpdateRuleGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the UpdateRuleGroupRequest method. // req, resp := client.UpdateRuleGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRuleGroup func (c *WAFV2) UpdateRuleGroupRequest(input *UpdateRuleGroupInput) (req *request.Request, output *UpdateRuleGroupOutput) { op := &request.Operation{ Name: opUpdateRuleGroup, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &UpdateRuleGroupInput{} } output = &UpdateRuleGroupOutput{} req = c.newRequest(op, input, output) return } // UpdateRuleGroup API operation for AWS WAFV2. // // Updates the specified RuleGroup. // // This operation completely replaces the mutable specifications that you already // have for the rule group with the ones that you provide to this call. // // To modify a rule group, do the following: // // # Retrieve it by calling GetRuleGroup // // # Update its settings as needed // // # Provide the complete rule group specification to this call // // When you make changes to web ACLs or web ACL components, like rules and rule // groups, WAF propagates the changes everywhere that the web ACL and its components // are stored and used. Your changes are applied within seconds, but there might // be a brief period of inconsistency when the changes have arrived in some // places and not in others. So, for example, if you change a rule action setting, // the action might be the old action in one area and the new action in another // area. Or if you add an IP address to an IP set used in a blocking rule, the // new address might briefly be blocked in one area while still allowed in another. // This temporary inconsistency can occur when you first associate a web ACL // with an Amazon Web Services resource and when you change a web ACL that is // already associated with a resource. Generally, any inconsistencies of this // type last only a few seconds. // // A rule group defines a collection of rules to inspect and control web requests // that you can use in a WebACL. When you create a rule group, you define an // immutable capacity limit. If you update a rule group, you must stay within // the capacity. This allows others to reuse the rule group with confidence // in its capacity requirements. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation UpdateRuleGroup for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFSubscriptionNotFoundException // You tried to use a managed rule group that's available by subscription, but // you aren't subscribed to it yet. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFConfigurationWarningException // The operation failed because you are inspecting the web request body, headers, // or cookies without specifying how to handle oversize components. Rules that // inspect the body must either provide an OversizeHandling configuration or // they must be preceded by a SizeConstraintStatement that blocks the body content // from being too large. Rules that inspect the headers or cookies must provide // an OversizeHandling configuration. // // Provide the handling configuration and retry your operation. // // Alternately, you can suppress this warning by adding the following tag to // the resource that you provide to this operation: Tag (key:WAF:OversizeFieldsHandlingConstraintOptOut, // value:true). // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRuleGroup func (c *WAFV2) UpdateRuleGroup(input *UpdateRuleGroupInput) (*UpdateRuleGroupOutput, error) { req, out := c.UpdateRuleGroupRequest(input) return out, req.Send() } // UpdateRuleGroupWithContext is the same as UpdateRuleGroup with the addition of // the ability to pass a context and additional request options. // // See UpdateRuleGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) UpdateRuleGroupWithContext(ctx aws.Context, input *UpdateRuleGroupInput, opts ...request.Option) (*UpdateRuleGroupOutput, error) { req, out := c.UpdateRuleGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } const opUpdateWebACL = "UpdateWebACL" // UpdateWebACLRequest generates a "aws/request.Request" representing the // client's request for the UpdateWebACL operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // // See UpdateWebACL for more information on using the UpdateWebACL // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // // Example sending a request using the UpdateWebACLRequest method. // req, resp := client.UpdateWebACLRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateWebACL func (c *WAFV2) UpdateWebACLRequest(input *UpdateWebACLInput) (req *request.Request, output *UpdateWebACLOutput) { op := &request.Operation{ Name: opUpdateWebACL, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { input = &UpdateWebACLInput{} } output = &UpdateWebACLOutput{} req = c.newRequest(op, input, output) return } // UpdateWebACL API operation for AWS WAFV2. // // Updates the specified WebACL. While updating a web ACL, WAF provides continuous // coverage to the resources that you have associated with the web ACL. // // This operation completely replaces the mutable specifications that you already // have for the web ACL with the ones that you provide to this call. // // To modify a web ACL, do the following: // // # Retrieve it by calling GetWebACL // // # Update its settings as needed // // # Provide the complete web ACL specification to this call // // When you make changes to web ACLs or web ACL components, like rules and rule // groups, WAF propagates the changes everywhere that the web ACL and its components // are stored and used. Your changes are applied within seconds, but there might // be a brief period of inconsistency when the changes have arrived in some // places and not in others. So, for example, if you change a rule action setting, // the action might be the old action in one area and the new action in another // area. Or if you add an IP address to an IP set used in a blocking rule, the // new address might briefly be blocked in one area while still allowed in another. // This temporary inconsistency can occur when you first associate a web ACL // with an Amazon Web Services resource and when you change a web ACL that is // already associated with a resource. Generally, any inconsistencies of this // type last only a few seconds. // // A web ACL defines a collection of rules to use to inspect and control web // requests. Each rule has an action defined (allow, block, or count) for requests // that match the statement of the rule. In the web ACL, you assign a default // action to take (allow, block) for any request that does not match any of // the rules. The rules in a web ACL can be a combination of the types Rule, // RuleGroup, and managed rule group. You can associate a web ACL with one or // more Amazon Web Services resources to protect. The resources can be an Amazon // CloudFront distribution, an Amazon API Gateway REST API, an Application Load // Balancer, an AppSync GraphQL API, an Amazon Cognito user pool, an App Runner // service, or an Amazon Web Services Verified Access instance. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS WAFV2's // API operation UpdateWebACL for usage and error information. // // Returned Error Types: // // - WAFInternalErrorException // Your request is valid, but WAF couldn’t perform the operation because of // a system problem. Retry your request. // // - WAFInvalidParameterException // The operation failed because WAF didn't recognize a parameter in the request. // For example: // // - You specified a parameter name or value that isn't valid. // // - Your nested statement isn't valid. You might have tried to nest a statement // that can’t be nested. // // - You tried to update a WebACL with a DefaultAction that isn't among the // types available at DefaultAction. // // - Your request references an ARN that is malformed, or corresponds to // a resource with which a web ACL can't be associated. // // - WAFNonexistentItemException // WAF couldn’t perform the operation because your resource doesn't exist. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. // // - WAFDuplicateItemException // WAF couldn’t perform the operation because the resource that you tried // to save is a duplicate of an existing one. // // - WAFOptimisticLockException // WAF couldn’t save your changes because you tried to update or delete a // resource that has changed since you last retrieved it. Get the resource again, // make any changes you need to make to the new copy, and retry your operation. // // - WAFLimitsExceededException // WAF couldn’t perform the operation because you exceeded your resource limit. // For example, the maximum number of WebACL objects that you can create for // an Amazon Web Services account. For more information, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // - WAFInvalidResourceException // WAF couldn’t perform the operation because the resource that you requested // isn’t valid. Check the resource, and try again. // // - WAFUnavailableEntityException // WAF couldn’t retrieve a resource that you specified for this operation. // If you've just created a resource that you're using in this operation, you // might just need to wait a few minutes. It can take from a few seconds to // a number of minutes for changes to propagate. Verify the resources that you // are specifying in your request parameters and then retry the operation. // // - WAFSubscriptionNotFoundException // You tried to use a managed rule group that's available by subscription, but // you aren't subscribed to it yet. // // - WAFInvalidOperationException // The operation isn't valid. // // - WAFExpiredManagedRuleGroupVersionException // The operation failed because the specified version for the managed rule group // has expired. You can retrieve the available versions for the managed rule // group by calling ListAvailableManagedRuleGroupVersions. // // - WAFConfigurationWarningException // The operation failed because you are inspecting the web request body, headers, // or cookies without specifying how to handle oversize components. Rules that // inspect the body must either provide an OversizeHandling configuration or // they must be preceded by a SizeConstraintStatement that blocks the body content // from being too large. Rules that inspect the headers or cookies must provide // an OversizeHandling configuration. // // Provide the handling configuration and retry your operation. // // Alternately, you can suppress this warning by adding the following tag to // the resource that you provide to this operation: Tag (key:WAF:OversizeFieldsHandlingConstraintOptOut, // value:true). // // See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateWebACL func (c *WAFV2) UpdateWebACL(input *UpdateWebACLInput) (*UpdateWebACLOutput, error) { req, out := c.UpdateWebACLRequest(input) return out, req.Send() } // UpdateWebACLWithContext is the same as UpdateWebACL with the addition of // the ability to pass a context and additional request options. // // See UpdateWebACL for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. func (c *WAFV2) UpdateWebACLWithContext(ctx aws.Context, input *UpdateWebACLInput, opts ...request.Option) (*UpdateWebACLOutput, error) { req, out := c.UpdateWebACLRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } // Information for a single API key. // // API keys are required for the integration of the CAPTCHA API in your JavaScript // client applications. The API lets you customize the placement and characteristics // of the CAPTCHA puzzle for your end users. For more information about the // CAPTCHA JavaScript integration, see WAF client application integration (https://docs.aws.amazon.com/waf/latest/developerguide/waf-application-integration.html) // in the WAF Developer Guide. type APIKeySummary struct { _ struct{} `type:"structure"` // The generated, encrypted API key. You can copy this for use in your JavaScript // CAPTCHA integration. APIKey *string `min:"1" type:"string"` // The date and time that the key was created. CreationTimestamp *time.Time `type:"timestamp"` // The token domains that are defined in this API key. TokenDomains []*string `type:"list"` // Internal value used by WAF to manage the key. Version *int64 `type:"integer"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s APIKeySummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s APIKeySummary) GoString() string { return s.String() } // SetAPIKey sets the APIKey field's value. func (s *APIKeySummary) SetAPIKey(v string) *APIKeySummary { s.APIKey = &v return s } // SetCreationTimestamp sets the CreationTimestamp field's value. func (s *APIKeySummary) SetCreationTimestamp(v time.Time) *APIKeySummary { s.CreationTimestamp = &v return s } // SetTokenDomains sets the TokenDomains field's value. func (s *APIKeySummary) SetTokenDomains(v []*string) *APIKeySummary { s.TokenDomains = v return s } // SetVersion sets the Version field's value. func (s *APIKeySummary) SetVersion(v int64) *APIKeySummary { s.Version = &v return s } // Details for your use of the account creation fraud prevention managed rule // group, AWSManagedRulesACFPRuleSet. This configuration is used in ManagedRuleGroupConfig. type AWSManagedRulesACFPRuleSet struct { _ struct{} `type:"structure"` // The path of the account creation endpoint for your application. This is the // page on your website that accepts the completed registration form for a new // user. This page must accept POST requests. // // For example, for the URL https://example.com/web/signup, you would provide // the path /web/signup. // // CreationPath is a required field CreationPath *string `min:"1" type:"string" required:"true"` // Allow the use of regular expressions in the registration page path and the // account creation path. EnableRegexInPath *bool `type:"boolean"` // The path of the account registration endpoint for your application. This // is the page on your website that presents the registration form to new users. // // This page must accept GET text/html requests. // // For example, for the URL https://example.com/web/register, you would provide // the path /web/register. // // RegistrationPagePath is a required field RegistrationPagePath *string `min:"1" type:"string" required:"true"` // The criteria for inspecting account creation requests, used by the ACFP rule // group to validate and track account creation attempts. // // RequestInspection is a required field RequestInspection *RequestInspectionACFP `type:"structure" required:"true"` // The criteria for inspecting responses to account creation requests, used // by the ACFP rule group to track account creation success rates. // // Response inspection is available only in web ACLs that protect Amazon CloudFront // distributions. // // The ACFP rule group evaluates the responses that your protected resources // send back to client account creation attempts, keeping count of successful // and failed attempts from each IP address and client session. Using this information, // the rule group labels and mitigates requests from client sessions and IP // addresses that have had too many successful account creation attempts in // a short amount of time. ResponseInspection *ResponseInspection `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AWSManagedRulesACFPRuleSet) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AWSManagedRulesACFPRuleSet) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AWSManagedRulesACFPRuleSet) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AWSManagedRulesACFPRuleSet"} if s.CreationPath == nil { invalidParams.Add(request.NewErrParamRequired("CreationPath")) } if s.CreationPath != nil && len(*s.CreationPath) < 1 { invalidParams.Add(request.NewErrParamMinLen("CreationPath", 1)) } if s.RegistrationPagePath == nil { invalidParams.Add(request.NewErrParamRequired("RegistrationPagePath")) } if s.RegistrationPagePath != nil && len(*s.RegistrationPagePath) < 1 { invalidParams.Add(request.NewErrParamMinLen("RegistrationPagePath", 1)) } if s.RequestInspection == nil { invalidParams.Add(request.NewErrParamRequired("RequestInspection")) } if s.RequestInspection != nil { if err := s.RequestInspection.Validate(); err != nil { invalidParams.AddNested("RequestInspection", err.(request.ErrInvalidParams)) } } if s.ResponseInspection != nil { if err := s.ResponseInspection.Validate(); err != nil { invalidParams.AddNested("ResponseInspection", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCreationPath sets the CreationPath field's value. func (s *AWSManagedRulesACFPRuleSet) SetCreationPath(v string) *AWSManagedRulesACFPRuleSet { s.CreationPath = &v return s } // SetEnableRegexInPath sets the EnableRegexInPath field's value. func (s *AWSManagedRulesACFPRuleSet) SetEnableRegexInPath(v bool) *AWSManagedRulesACFPRuleSet { s.EnableRegexInPath = &v return s } // SetRegistrationPagePath sets the RegistrationPagePath field's value. func (s *AWSManagedRulesACFPRuleSet) SetRegistrationPagePath(v string) *AWSManagedRulesACFPRuleSet { s.RegistrationPagePath = &v return s } // SetRequestInspection sets the RequestInspection field's value. func (s *AWSManagedRulesACFPRuleSet) SetRequestInspection(v *RequestInspectionACFP) *AWSManagedRulesACFPRuleSet { s.RequestInspection = v return s } // SetResponseInspection sets the ResponseInspection field's value. func (s *AWSManagedRulesACFPRuleSet) SetResponseInspection(v *ResponseInspection) *AWSManagedRulesACFPRuleSet { s.ResponseInspection = v return s } // Details for your use of the account takeover prevention managed rule group, // AWSManagedRulesATPRuleSet. This configuration is used in ManagedRuleGroupConfig. type AWSManagedRulesATPRuleSet struct { _ struct{} `type:"structure"` // Allow the use of regular expressions in the login page path. EnableRegexInPath *bool `type:"boolean"` // The path of the login endpoint for your application. For example, for the // URL https://example.com/web/login, you would provide the path /web/login. // // The rule group inspects only HTTP POST requests to your specified login endpoint. // // LoginPath is a required field LoginPath *string `type:"string" required:"true"` // The criteria for inspecting login requests, used by the ATP rule group to // validate credentials usage. RequestInspection *RequestInspection `type:"structure"` // The criteria for inspecting responses to login requests, used by the ATP // rule group to track login failure rates. // // Response inspection is available only in web ACLs that protect Amazon CloudFront // distributions. // // The ATP rule group evaluates the responses that your protected resources // send back to client login attempts, keeping count of successful and failed // attempts for each IP address and client session. Using this information, // the rule group labels and mitigates requests from client sessions and IP // addresses that have had too many failed login attempts in a short amount // of time. ResponseInspection *ResponseInspection `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AWSManagedRulesATPRuleSet) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AWSManagedRulesATPRuleSet) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AWSManagedRulesATPRuleSet) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AWSManagedRulesATPRuleSet"} if s.LoginPath == nil { invalidParams.Add(request.NewErrParamRequired("LoginPath")) } if s.RequestInspection != nil { if err := s.RequestInspection.Validate(); err != nil { invalidParams.AddNested("RequestInspection", err.(request.ErrInvalidParams)) } } if s.ResponseInspection != nil { if err := s.ResponseInspection.Validate(); err != nil { invalidParams.AddNested("ResponseInspection", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetEnableRegexInPath sets the EnableRegexInPath field's value. func (s *AWSManagedRulesATPRuleSet) SetEnableRegexInPath(v bool) *AWSManagedRulesATPRuleSet { s.EnableRegexInPath = &v return s } // SetLoginPath sets the LoginPath field's value. func (s *AWSManagedRulesATPRuleSet) SetLoginPath(v string) *AWSManagedRulesATPRuleSet { s.LoginPath = &v return s } // SetRequestInspection sets the RequestInspection field's value. func (s *AWSManagedRulesATPRuleSet) SetRequestInspection(v *RequestInspection) *AWSManagedRulesATPRuleSet { s.RequestInspection = v return s } // SetResponseInspection sets the ResponseInspection field's value. func (s *AWSManagedRulesATPRuleSet) SetResponseInspection(v *ResponseInspection) *AWSManagedRulesATPRuleSet { s.ResponseInspection = v return s } // Details for your use of the Bot Control managed rule group, AWSManagedRulesBotControlRuleSet. // This configuration is used in ManagedRuleGroupConfig. type AWSManagedRulesBotControlRuleSet struct { _ struct{} `type:"structure"` // The inspection level to use for the Bot Control rule group. The common level // is the least expensive. The targeted level includes all common level rules // and adds rules with more advanced inspection criteria. For details, see WAF // Bot Control rule group (https://docs.aws.amazon.com/waf/latest/developerguide/aws-managed-rule-groups-bot.html) // in the WAF Developer Guide. // // InspectionLevel is a required field InspectionLevel *string `type:"string" required:"true" enum:"InspectionLevel"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AWSManagedRulesBotControlRuleSet) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AWSManagedRulesBotControlRuleSet) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AWSManagedRulesBotControlRuleSet) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AWSManagedRulesBotControlRuleSet"} if s.InspectionLevel == nil { invalidParams.Add(request.NewErrParamRequired("InspectionLevel")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetInspectionLevel sets the InspectionLevel field's value. func (s *AWSManagedRulesBotControlRuleSet) SetInspectionLevel(v string) *AWSManagedRulesBotControlRuleSet { s.InspectionLevel = &v return s } // A single action condition for a Condition in a logging filter. type ActionCondition struct { _ struct{} `type:"structure"` // The action setting that a log record must contain in order to meet the condition. // This is the action that WAF applied to the web request. // // For rule groups, this is either the configured rule action setting, or if // you've applied a rule action override to the rule, it's the override action. // The value EXCLUDED_AS_COUNT matches on excluded rules and also on rules that // have a rule action override of Count. // // Action is a required field Action *string `type:"string" required:"true" enum:"ActionValue"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ActionCondition) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ActionCondition) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *ActionCondition) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ActionCondition"} if s.Action == nil { invalidParams.Add(request.NewErrParamRequired("Action")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetAction sets the Action field's value. func (s *ActionCondition) SetAction(v string) *ActionCondition { s.Action = &v return s } // The name of a field in the request payload that contains part or all of your // customer's primary physical address. // // This data type is used in the RequestInspectionACFP data type. type AddressField struct { _ struct{} `type:"structure"` // The name of a single primary address field. // // How you specify the address fields depends on the request inspection payload // type. // // * For JSON payloads, specify the field identifiers in JSON pointer syntax. // For information about the JSON Pointer syntax, see the Internet Engineering // Task Force (IETF) documentation JavaScript Object Notation (JSON) Pointer // (https://tools.ietf.org/html/rfc6901). For example, for the JSON payload // { "form": { "primaryaddressline1": "THE_ADDRESS1", "primaryaddressline2": // "THE_ADDRESS2", "primaryaddressline3": "THE_ADDRESS3" } }, the address // field idenfiers are /form/primaryaddressline1, /form/primaryaddressline2, // and /form/primaryaddressline3. // // * For form encoded payload types, use the HTML form names. For example, // for an HTML form with input elements named primaryaddressline1, primaryaddressline2, // and primaryaddressline3, the address fields identifiers are primaryaddressline1, // primaryaddressline2, and primaryaddressline3. // // Identifier is a required field Identifier *string `min:"1" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AddressField) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AddressField) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AddressField) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AddressField"} if s.Identifier == nil { invalidParams.Add(request.NewErrParamRequired("Identifier")) } if s.Identifier != nil && len(*s.Identifier) < 1 { invalidParams.Add(request.NewErrParamMinLen("Identifier", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetIdentifier sets the Identifier field's value. func (s *AddressField) SetIdentifier(v string) *AddressField { s.Identifier = &v return s } // Inspect all of the elements that WAF has parsed and extracted from the web // request component that you've identified in your FieldToMatch specifications. // // This is used in the FieldToMatch specification for some web request component // types. // // JSON specification: "All": {} type All struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s All) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s All) GoString() string { return s.String() } // Inspect all query arguments of the web request. // // This is used in the FieldToMatch specification for some web request component // types. // // JSON specification: "AllQueryArguments": {} type AllQueryArguments struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AllQueryArguments) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AllQueryArguments) GoString() string { return s.String() } // Specifies that WAF should allow the request and optionally defines additional // custom handling for the request. // // This is used in the context of other settings, for example to specify values // for RuleAction and web ACL DefaultAction. type AllowAction struct { _ struct{} `type:"structure"` // Defines custom handling for the web request. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. CustomRequestHandling *CustomRequestHandling `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AllowAction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AllowAction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AllowAction) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AllowAction"} if s.CustomRequestHandling != nil { if err := s.CustomRequestHandling.Validate(); err != nil { invalidParams.AddNested("CustomRequestHandling", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCustomRequestHandling sets the CustomRequestHandling field's value. func (s *AllowAction) SetCustomRequestHandling(v *CustomRequestHandling) *AllowAction { s.CustomRequestHandling = v return s } // A logical rule statement used to combine other rule statements with AND logic. // You provide more than one Statement within the AndStatement. type AndStatement struct { _ struct{} `type:"structure"` // The statements to combine with AND logic. You can use any statements that // can be nested. // // Statements is a required field Statements []*Statement `type:"list" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AndStatement) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AndStatement) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AndStatement) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AndStatement"} if s.Statements == nil { invalidParams.Add(request.NewErrParamRequired("Statements")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetStatements sets the Statements field's value. func (s *AndStatement) SetStatements(v []*Statement) *AndStatement { s.Statements = v return s } type AssociateWebACLInput struct { _ struct{} `type:"structure"` // The Amazon Resource Name (ARN) of the resource to associate with the web // ACL. // // The ARN must be in one of the following formats: // // * For an Application Load Balancer: arn:partition:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id // // * For an Amazon API Gateway REST API: arn:partition:apigateway:region::/restapis/api-id/stages/stage-name // // * For an AppSync GraphQL API: arn:partition:appsync:region:account-id:apis/GraphQLApiId // // * For an Amazon Cognito user pool: arn:partition:cognito-idp:region:account-id:userpool/user-pool-id // // * For an App Runner service: arn:partition:apprunner:region:account-id:service/apprunner-service-name/apprunner-service-id // // * For an Amazon Web Services Verified Access instance: arn:partition:ec2:region:account-id:verified-access-instance/instance-id // // ResourceArn is a required field ResourceArn *string `min:"20" type:"string" required:"true"` // The Amazon Resource Name (ARN) of the web ACL that you want to associate // with the resource. // // WebACLArn is a required field WebACLArn *string `min:"20" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AssociateWebACLInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AssociateWebACLInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AssociateWebACLInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AssociateWebACLInput"} if s.ResourceArn == nil { invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) } if s.WebACLArn == nil { invalidParams.Add(request.NewErrParamRequired("WebACLArn")) } if s.WebACLArn != nil && len(*s.WebACLArn) < 20 { invalidParams.Add(request.NewErrParamMinLen("WebACLArn", 20)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetResourceArn sets the ResourceArn field's value. func (s *AssociateWebACLInput) SetResourceArn(v string) *AssociateWebACLInput { s.ResourceArn = &v return s } // SetWebACLArn sets the WebACLArn field's value. func (s *AssociateWebACLInput) SetWebACLArn(v string) *AssociateWebACLInput { s.WebACLArn = &v return s } type AssociateWebACLOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AssociateWebACLOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AssociateWebACLOutput) GoString() string { return s.String() } // Specifies custom configurations for the associations between the web ACL // and protected resources. // // Use this to customize the maximum size of the request body that your protected // CloudFront distributions forward to WAF for inspection. The default is 16 // KB (16,384 kilobytes). // // You are charged additional fees when your protected resources forward body // sizes that are larger than the default. For more information, see WAF Pricing // (http://aws.amazon.com/waf/pricing/). type AssociationConfig struct { _ struct{} `type:"structure"` // Customizes the maximum size of the request body that your protected CloudFront // distributions forward to WAF for inspection. The default size is 16 KB (16,384 // kilobytes). // // You are charged additional fees when your protected resources forward body // sizes that are larger than the default. For more information, see WAF Pricing // (http://aws.amazon.com/waf/pricing/). RequestBody map[string]*RequestBodyAssociatedResourceTypeConfig `type:"map"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AssociationConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s AssociationConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *AssociationConfig) Validate() error { invalidParams := request.ErrInvalidParams{Context: "AssociationConfig"} if s.RequestBody != nil { for i, v := range s.RequestBody { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RequestBody", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetRequestBody sets the RequestBody field's value. func (s *AssociationConfig) SetRequestBody(v map[string]*RequestBodyAssociatedResourceTypeConfig) *AssociationConfig { s.RequestBody = v return s } // Specifies that WAF should block the request and optionally defines additional // custom handling for the response to the web request. // // This is used in the context of other settings, for example to specify values // for RuleAction and web ACL DefaultAction. type BlockAction struct { _ struct{} `type:"structure"` // Defines a custom response for the web request. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. CustomResponse *CustomResponse `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s BlockAction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s BlockAction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *BlockAction) Validate() error { invalidParams := request.ErrInvalidParams{Context: "BlockAction"} if s.CustomResponse != nil { if err := s.CustomResponse.Validate(); err != nil { invalidParams.AddNested("CustomResponse", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCustomResponse sets the CustomResponse field's value. func (s *BlockAction) SetCustomResponse(v *CustomResponse) *BlockAction { s.CustomResponse = v return s } // Inspect the body of the web request. The body immediately follows the request // headers. // // This is used to indicate the web request component to inspect, in the FieldToMatch // specification. type Body struct { _ struct{} `type:"structure"` // What WAF should do if the body is larger than WAF can inspect. WAF does not // support inspecting the entire contents of the web request body if the body // exceeds the limit for the resource type. If the body is larger than the limit, // the underlying host service only forwards the contents that are below the // limit to WAF for inspection. // // The default limit is 8 KB (8,192 kilobytes) for regional resources and 16 // KB (16,384 kilobytes) for CloudFront distributions. For CloudFront distributions, // you can increase the limit in the web ACL AssociationConfig, for additional // processing fees. // // The options for oversize handling are the following: // // * CONTINUE - Inspect the available body contents normally, according to // the rule inspection criteria. // // * MATCH - Treat the web request as matching the rule statement. WAF applies // the rule action to the request. // // * NO_MATCH - Treat the web request as not matching the rule statement. // // You can combine the MATCH or NO_MATCH settings for oversize handling with // your rule and web ACL action settings, so that you block any request whose // body is over the limit. // // Default: CONTINUE OversizeHandling *string `type:"string" enum:"OversizeHandling"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s Body) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s Body) GoString() string { return s.String() } // SetOversizeHandling sets the OversizeHandling field's value. func (s *Body) SetOversizeHandling(v string) *Body { s.OversizeHandling = &v return s } // A rule statement that defines a string match search for WAF to apply to web // requests. The byte match statement provides the bytes to search for, the // location in requests that you want WAF to search, and other settings. The // bytes to search for are typically a string that corresponds with ASCII characters. // In the WAF console and the developer guide, this is called a string match // statement. type ByteMatchStatement struct { _ struct{} `type:"structure"` // The part of the web request that you want WAF to inspect. // // FieldToMatch is a required field FieldToMatch *FieldToMatch `type:"structure" required:"true"` // The area within the portion of the web request that you want WAF to search // for SearchString. Valid values include the following: // // CONTAINS // // The specified part of the web request must include the value of SearchString, // but the location doesn't matter. // // CONTAINS_WORD // // The specified part of the web request must include the value of SearchString, // and SearchString must contain only alphanumeric characters or underscore // (A-Z, a-z, 0-9, or _). In addition, SearchString must be a word, which means // that both of the following are true: // // * SearchString is at the beginning of the specified part of the web request // or is preceded by a character other than an alphanumeric character or // underscore (_). Examples include the value of a header and ;BadBot. // // * SearchString is at the end of the specified part of the web request // or is followed by a character other than an alphanumeric character or // underscore (_), for example, BadBot; and -BadBot;. // // EXACTLY // // The value of the specified part of the web request must exactly match the // value of SearchString. // // STARTS_WITH // // The value of SearchString must appear at the beginning of the specified part // of the web request. // // ENDS_WITH // // The value of SearchString must appear at the end of the specified part of // the web request. // // PositionalConstraint is a required field PositionalConstraint *string `type:"string" required:"true" enum:"PositionalConstraint"` // A string value that you want WAF to search for. WAF searches only in the // part of web requests that you designate for inspection in FieldToMatch. The // maximum length of the value is 200 bytes. // // Valid values depend on the component that you specify for inspection in FieldToMatch: // // * Method: The HTTP method that you want WAF to search for. This indicates // the type of operation specified in the request. // // * UriPath: The value that you want WAF to search for in the URI path, // for example, /images/daily-ad.jpg. // // * HeaderOrder: The comma-separated list of header names to match for. // WAF creates a string that contains the ordered list of header names, from // the headers in the web request, and then matches against that string. // // If SearchString includes alphabetic characters A-Z and a-z, note that the // value is case sensitive. // // If you're using the WAF API // // Specify a base64-encoded version of the value. The maximum length of the // value before you base64-encode it is 200 bytes. // // For example, suppose the value of Type is HEADER and the value of Data is // User-Agent. If you want to search the User-Agent header for the value BadBot, // you base64-encode BadBot using MIME base64-encoding and include the resulting // value, QmFkQm90, in the value of SearchString. // // If you're using the CLI or one of the Amazon Web Services SDKs // // The value that you want WAF to search for. The SDK automatically base64 encodes // the value. // SearchString is automatically base64 encoded/decoded by the SDK. // // SearchString is a required field SearchString []byte `type:"blob" required:"true"` // Text transformations eliminate some of the unusual formatting that attackers // use in web requests in an effort to bypass detection. Text transformations // are used in rule match statements, to transform the FieldToMatch request // component before inspecting it, and they're used in rate-based rule statements, // to transform request components before using them as custom aggregation keys. // If you specify one or more transformations to apply, WAF performs all transformations // on the specified content, starting from the lowest priority setting, and // then uses the component contents. // // TextTransformations is a required field TextTransformations []*TextTransformation `min:"1" type:"list" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ByteMatchStatement) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ByteMatchStatement) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *ByteMatchStatement) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ByteMatchStatement"} if s.FieldToMatch == nil { invalidParams.Add(request.NewErrParamRequired("FieldToMatch")) } if s.PositionalConstraint == nil { invalidParams.Add(request.NewErrParamRequired("PositionalConstraint")) } if s.SearchString == nil { invalidParams.Add(request.NewErrParamRequired("SearchString")) } if s.TextTransformations == nil { invalidParams.Add(request.NewErrParamRequired("TextTransformations")) } if s.TextTransformations != nil && len(s.TextTransformations) < 1 { invalidParams.Add(request.NewErrParamMinLen("TextTransformations", 1)) } if s.FieldToMatch != nil { if err := s.FieldToMatch.Validate(); err != nil { invalidParams.AddNested("FieldToMatch", err.(request.ErrInvalidParams)) } } if s.TextTransformations != nil { for i, v := range s.TextTransformations { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TextTransformations", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetFieldToMatch sets the FieldToMatch field's value. func (s *ByteMatchStatement) SetFieldToMatch(v *FieldToMatch) *ByteMatchStatement { s.FieldToMatch = v return s } // SetPositionalConstraint sets the PositionalConstraint field's value. func (s *ByteMatchStatement) SetPositionalConstraint(v string) *ByteMatchStatement { s.PositionalConstraint = &v return s } // SetSearchString sets the SearchString field's value. func (s *ByteMatchStatement) SetSearchString(v []byte) *ByteMatchStatement { s.SearchString = v return s } // SetTextTransformations sets the TextTransformations field's value. func (s *ByteMatchStatement) SetTextTransformations(v []*TextTransformation) *ByteMatchStatement { s.TextTransformations = v return s } // Specifies that WAF should run a CAPTCHA check against the request: // // - If the request includes a valid, unexpired CAPTCHA token, WAF applies // any custom request handling and labels that you've configured and then // allows the web request inspection to proceed to the next rule, similar // to a CountAction. // // - If the request doesn't include a valid, unexpired token, WAF discontinues // the web ACL evaluation of the request and blocks it from going to its // intended destination. WAF generates a response that it sends back to the // client, which includes the following: The header x-amzn-waf-action with // a value of captcha. The HTTP status code 405 Method Not Allowed. If the // request contains an Accept header with a value of text/html, the response // includes a CAPTCHA JavaScript page interstitial. // // You can configure the expiration time in the CaptchaConfig ImmunityTimeProperty // setting at the rule and web ACL level. The rule setting overrides the web // ACL setting. // // This action option is available for rules. It isn't available for web ACL // default actions. type CaptchaAction struct { _ struct{} `type:"structure"` // Defines custom handling for the web request, used when the CAPTCHA inspection // determines that the request's token is valid and unexpired. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. CustomRequestHandling *CustomRequestHandling `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CaptchaAction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CaptchaAction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CaptchaAction) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CaptchaAction"} if s.CustomRequestHandling != nil { if err := s.CustomRequestHandling.Validate(); err != nil { invalidParams.AddNested("CustomRequestHandling", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCustomRequestHandling sets the CustomRequestHandling field's value. func (s *CaptchaAction) SetCustomRequestHandling(v *CustomRequestHandling) *CaptchaAction { s.CustomRequestHandling = v return s } // Specifies how WAF should handle CAPTCHA evaluations. This is available at // the web ACL level and in each rule. type CaptchaConfig struct { _ struct{} `type:"structure"` // Determines how long a CAPTCHA timestamp in the token remains valid after // the client successfully solves a CAPTCHA puzzle. ImmunityTimeProperty *ImmunityTimeProperty `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CaptchaConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CaptchaConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CaptchaConfig) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CaptchaConfig"} if s.ImmunityTimeProperty != nil { if err := s.ImmunityTimeProperty.Validate(); err != nil { invalidParams.AddNested("ImmunityTimeProperty", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetImmunityTimeProperty sets the ImmunityTimeProperty field's value. func (s *CaptchaConfig) SetImmunityTimeProperty(v *ImmunityTimeProperty) *CaptchaConfig { s.ImmunityTimeProperty = v return s } // The result from the inspection of the web request for a valid CAPTCHA token. type CaptchaResponse struct { _ struct{} `type:"structure"` // The reason for failure, populated when the evaluation of the token fails. FailureReason *string `type:"string" enum:"FailureReason"` // The HTTP response code indicating the status of the CAPTCHA token in the // web request. If the token is missing, invalid, or expired, this code is 405 // Method Not Allowed. ResponseCode *int64 `type:"integer"` // The time that the CAPTCHA was last solved for the supplied token. SolveTimestamp *int64 `type:"long"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CaptchaResponse) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CaptchaResponse) GoString() string { return s.String() } // SetFailureReason sets the FailureReason field's value. func (s *CaptchaResponse) SetFailureReason(v string) *CaptchaResponse { s.FailureReason = &v return s } // SetResponseCode sets the ResponseCode field's value. func (s *CaptchaResponse) SetResponseCode(v int64) *CaptchaResponse { s.ResponseCode = &v return s } // SetSolveTimestamp sets the SolveTimestamp field's value. func (s *CaptchaResponse) SetSolveTimestamp(v int64) *CaptchaResponse { s.SolveTimestamp = &v return s } // Specifies that WAF should run a Challenge check against the request to verify // that the request is coming from a legitimate client session: // // - If the request includes a valid, unexpired challenge token, WAF applies // any custom request handling and labels that you've configured and then // allows the web request inspection to proceed to the next rule, similar // to a CountAction. // // - If the request doesn't include a valid, unexpired challenge token, WAF // discontinues the web ACL evaluation of the request and blocks it from // going to its intended destination. WAF then generates a challenge response // that it sends back to the client, which includes the following: The header // x-amzn-waf-action with a value of challenge. The HTTP status code 202 // Request Accepted. If the request contains an Accept header with a value // of text/html, the response includes a JavaScript page interstitial with // a challenge script. Challenges run silent browser interrogations in the // background, and don't generally affect the end user experience. A challenge // enforces token acquisition using an interstitial JavaScript challenge // that inspects the client session for legitimate behavior. The challenge // blocks bots or at least increases the cost of operating sophisticated // bots. After the client session successfully responds to the challenge, // it receives a new token from WAF, which the challenge script uses to resubmit // the original request. // // You can configure the expiration time in the ChallengeConfig ImmunityTimeProperty // setting at the rule and web ACL level. The rule setting overrides the web // ACL setting. // // This action option is available for rules. It isn't available for web ACL // default actions. type ChallengeAction struct { _ struct{} `type:"structure"` // Defines custom handling for the web request, used when the challenge inspection // determines that the request's token is valid and unexpired. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. CustomRequestHandling *CustomRequestHandling `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ChallengeAction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ChallengeAction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *ChallengeAction) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ChallengeAction"} if s.CustomRequestHandling != nil { if err := s.CustomRequestHandling.Validate(); err != nil { invalidParams.AddNested("CustomRequestHandling", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCustomRequestHandling sets the CustomRequestHandling field's value. func (s *ChallengeAction) SetCustomRequestHandling(v *CustomRequestHandling) *ChallengeAction { s.CustomRequestHandling = v return s } // Specifies how WAF should handle Challenge evaluations. This is available // at the web ACL level and in each rule. type ChallengeConfig struct { _ struct{} `type:"structure"` // Determines how long a challenge timestamp in the token remains valid after // the client successfully responds to a challenge. ImmunityTimeProperty *ImmunityTimeProperty `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ChallengeConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ChallengeConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *ChallengeConfig) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ChallengeConfig"} if s.ImmunityTimeProperty != nil { if err := s.ImmunityTimeProperty.Validate(); err != nil { invalidParams.AddNested("ImmunityTimeProperty", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetImmunityTimeProperty sets the ImmunityTimeProperty field's value. func (s *ChallengeConfig) SetImmunityTimeProperty(v *ImmunityTimeProperty) *ChallengeConfig { s.ImmunityTimeProperty = v return s } // The result from the inspection of the web request for a valid challenge token. type ChallengeResponse struct { _ struct{} `type:"structure"` // The reason for failure, populated when the evaluation of the token fails. FailureReason *string `type:"string" enum:"FailureReason"` // The HTTP response code indicating the status of the challenge token in the // web request. If the token is missing, invalid, or expired, this code is 202 // Request Accepted. ResponseCode *int64 `type:"integer"` // The time that the challenge was last solved for the supplied token. SolveTimestamp *int64 `type:"long"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ChallengeResponse) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s ChallengeResponse) GoString() string { return s.String() } // SetFailureReason sets the FailureReason field's value. func (s *ChallengeResponse) SetFailureReason(v string) *ChallengeResponse { s.FailureReason = &v return s } // SetResponseCode sets the ResponseCode field's value. func (s *ChallengeResponse) SetResponseCode(v int64) *ChallengeResponse { s.ResponseCode = &v return s } // SetSolveTimestamp sets the SolveTimestamp field's value. func (s *ChallengeResponse) SetSolveTimestamp(v int64) *ChallengeResponse { s.SolveTimestamp = &v return s } type CheckCapacityInput struct { _ struct{} `type:"structure"` // An array of Rule that you're configuring to use in a rule group or web ACL. // // Rules is a required field Rules []*Rule `type:"list" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CheckCapacityInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CheckCapacityInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CheckCapacityInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CheckCapacityInput"} if s.Rules == nil { invalidParams.Add(request.NewErrParamRequired("Rules")) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.Rules != nil { for i, v := range s.Rules { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetRules sets the Rules field's value. func (s *CheckCapacityInput) SetRules(v []*Rule) *CheckCapacityInput { s.Rules = v return s } // SetScope sets the Scope field's value. func (s *CheckCapacityInput) SetScope(v string) *CheckCapacityInput { s.Scope = &v return s } type CheckCapacityOutput struct { _ struct{} `type:"structure"` // The capacity required by the rules and scope. Capacity *int64 `type:"long"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CheckCapacityOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CheckCapacityOutput) GoString() string { return s.String() } // SetCapacity sets the Capacity field's value. func (s *CheckCapacityOutput) SetCapacity(v int64) *CheckCapacityOutput { s.Capacity = &v return s } // A single match condition for a Filter. type Condition struct { _ struct{} `type:"structure"` // A single action condition. This is the action setting that a log record must // contain in order to meet the condition. ActionCondition *ActionCondition `type:"structure"` // A single label name condition. This is the fully qualified label name that // a log record must contain in order to meet the condition. Fully qualified // labels have a prefix, optional namespaces, and label name. The prefix identifies // the rule group or web ACL context of the rule that added the label. LabelNameCondition *LabelNameCondition `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s Condition) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s Condition) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *Condition) Validate() error { invalidParams := request.ErrInvalidParams{Context: "Condition"} if s.ActionCondition != nil { if err := s.ActionCondition.Validate(); err != nil { invalidParams.AddNested("ActionCondition", err.(request.ErrInvalidParams)) } } if s.LabelNameCondition != nil { if err := s.LabelNameCondition.Validate(); err != nil { invalidParams.AddNested("LabelNameCondition", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetActionCondition sets the ActionCondition field's value. func (s *Condition) SetActionCondition(v *ActionCondition) *Condition { s.ActionCondition = v return s } // SetLabelNameCondition sets the LabelNameCondition field's value. func (s *Condition) SetLabelNameCondition(v *LabelNameCondition) *Condition { s.LabelNameCondition = v return s } // The filter to use to identify the subset of cookies to inspect in a web request. // // You must specify exactly one setting: either All, IncludedCookies, or ExcludedCookies. // // Example JSON: "MatchPattern": { "IncludedCookies": [ "session-id-time", "session-id" // ] } type CookieMatchPattern struct { _ struct{} `type:"structure"` // Inspect all cookies. All *All `type:"structure"` // Inspect only the cookies whose keys don't match any of the strings specified // here. ExcludedCookies []*string `min:"1" type:"list"` // Inspect only the cookies that have a key that matches one of the strings // specified here. IncludedCookies []*string `min:"1" type:"list"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CookieMatchPattern) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CookieMatchPattern) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CookieMatchPattern) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CookieMatchPattern"} if s.ExcludedCookies != nil && len(s.ExcludedCookies) < 1 { invalidParams.Add(request.NewErrParamMinLen("ExcludedCookies", 1)) } if s.IncludedCookies != nil && len(s.IncludedCookies) < 1 { invalidParams.Add(request.NewErrParamMinLen("IncludedCookies", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetAll sets the All field's value. func (s *CookieMatchPattern) SetAll(v *All) *CookieMatchPattern { s.All = v return s } // SetExcludedCookies sets the ExcludedCookies field's value. func (s *CookieMatchPattern) SetExcludedCookies(v []*string) *CookieMatchPattern { s.ExcludedCookies = v return s } // SetIncludedCookies sets the IncludedCookies field's value. func (s *CookieMatchPattern) SetIncludedCookies(v []*string) *CookieMatchPattern { s.IncludedCookies = v return s } // Inspect the cookies in the web request. You can specify the parts of the // cookies to inspect and you can narrow the set of cookies to inspect by including // or excluding specific keys. // // This is used to indicate the web request component to inspect, in the FieldToMatch // specification. // // Example JSON: "Cookies": { "MatchPattern": { "All": {} }, "MatchScope": "KEY", // "OversizeHandling": "MATCH" } type Cookies struct { _ struct{} `type:"structure"` // The filter to use to identify the subset of cookies to inspect in a web request. // // You must specify exactly one setting: either All, IncludedCookies, or ExcludedCookies. // // Example JSON: "MatchPattern": { "IncludedCookies": [ "session-id-time", "session-id" // ] } // // MatchPattern is a required field MatchPattern *CookieMatchPattern `type:"structure" required:"true"` // The parts of the cookies to inspect with the rule inspection criteria. If // you specify All, WAF inspects both keys and values. // // MatchScope is a required field MatchScope *string `type:"string" required:"true" enum:"MapMatchScope"` // What WAF should do if the cookies of the request are more numerous or larger // than WAF can inspect. WAF does not support inspecting the entire contents // of request cookies when they exceed 8 KB (8192 bytes) or 200 total cookies. // The underlying host service forwards a maximum of 200 cookies and at most // 8 KB of cookie contents to WAF. // // The options for oversize handling are the following: // // * CONTINUE - Inspect the available cookies normally, according to the // rule inspection criteria. // // * MATCH - Treat the web request as matching the rule statement. WAF applies // the rule action to the request. // // * NO_MATCH - Treat the web request as not matching the rule statement. // // OversizeHandling is a required field OversizeHandling *string `type:"string" required:"true" enum:"OversizeHandling"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s Cookies) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s Cookies) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *Cookies) Validate() error { invalidParams := request.ErrInvalidParams{Context: "Cookies"} if s.MatchPattern == nil { invalidParams.Add(request.NewErrParamRequired("MatchPattern")) } if s.MatchScope == nil { invalidParams.Add(request.NewErrParamRequired("MatchScope")) } if s.OversizeHandling == nil { invalidParams.Add(request.NewErrParamRequired("OversizeHandling")) } if s.MatchPattern != nil { if err := s.MatchPattern.Validate(); err != nil { invalidParams.AddNested("MatchPattern", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetMatchPattern sets the MatchPattern field's value. func (s *Cookies) SetMatchPattern(v *CookieMatchPattern) *Cookies { s.MatchPattern = v return s } // SetMatchScope sets the MatchScope field's value. func (s *Cookies) SetMatchScope(v string) *Cookies { s.MatchScope = &v return s } // SetOversizeHandling sets the OversizeHandling field's value. func (s *Cookies) SetOversizeHandling(v string) *Cookies { s.OversizeHandling = &v return s } // Specifies that WAF should count the request. Optionally defines additional // custom handling for the request. // // This is used in the context of other settings, for example to specify values // for RuleAction and web ACL DefaultAction. type CountAction struct { _ struct{} `type:"structure"` // Defines custom handling for the web request. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. CustomRequestHandling *CustomRequestHandling `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CountAction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CountAction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CountAction) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CountAction"} if s.CustomRequestHandling != nil { if err := s.CustomRequestHandling.Validate(); err != nil { invalidParams.AddNested("CustomRequestHandling", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCustomRequestHandling sets the CustomRequestHandling field's value. func (s *CountAction) SetCustomRequestHandling(v *CustomRequestHandling) *CountAction { s.CustomRequestHandling = v return s } type CreateAPIKeyInput struct { _ struct{} `type:"structure"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // The client application domains that you want to use this API key for. // // Example JSON: "TokenDomains": ["abc.com", "store.abc.com"] // // Public suffixes aren't allowed. For example, you can't use usa.gov or co.uk // as token domains. // // TokenDomains is a required field TokenDomains []*string `min:"1" type:"list" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateAPIKeyInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateAPIKeyInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CreateAPIKeyInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CreateAPIKeyInput"} if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.TokenDomains == nil { invalidParams.Add(request.NewErrParamRequired("TokenDomains")) } if s.TokenDomains != nil && len(s.TokenDomains) < 1 { invalidParams.Add(request.NewErrParamMinLen("TokenDomains", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetScope sets the Scope field's value. func (s *CreateAPIKeyInput) SetScope(v string) *CreateAPIKeyInput { s.Scope = &v return s } // SetTokenDomains sets the TokenDomains field's value. func (s *CreateAPIKeyInput) SetTokenDomains(v []*string) *CreateAPIKeyInput { s.TokenDomains = v return s } type CreateAPIKeyOutput struct { _ struct{} `type:"structure"` // The generated, encrypted API key. You can copy this for use in your JavaScript // CAPTCHA integration. APIKey *string `min:"1" type:"string"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateAPIKeyOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateAPIKeyOutput) GoString() string { return s.String() } // SetAPIKey sets the APIKey field's value. func (s *CreateAPIKeyOutput) SetAPIKey(v string) *CreateAPIKeyOutput { s.APIKey = &v return s } type CreateIPSetInput struct { _ struct{} `type:"structure"` // Contains an array of strings that specifies zero or more IP addresses or // blocks of IP addresses. All addresses must be specified using Classless Inter-Domain // Routing (CIDR) notation. WAF supports all IPv4 and IPv6 CIDR ranges except // for /0. // // Example address strings: // // * To configure WAF to allow, block, or count requests that originated // from the IP address 192.0.2.44, specify 192.0.2.44/32. // // * To configure WAF to allow, block, or count requests that originated // from IP addresses from 192.0.2.0 to 192.0.2.255, specify 192.0.2.0/24. // // * To configure WAF to allow, block, or count requests that originated // from the IP address 1111:0000:0000:0000:0000:0000:0000:0111, specify 1111:0000:0000:0000:0000:0000:0000:0111/128. // // * To configure WAF to allow, block, or count requests that originated // from IP addresses 1111:0000:0000:0000:0000:0000:0000:0000 to 1111:0000:0000:0000:ffff:ffff:ffff:ffff, // specify 1111:0000:0000:0000:0000:0000:0000:0000/64. // // For more information about CIDR notation, see the Wikipedia entry Classless // Inter-Domain Routing (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing). // // Example JSON Addresses specifications: // // * Empty array: "Addresses": [] // // * Array with one address: "Addresses": ["192.0.2.44/32"] // // * Array with three addresses: "Addresses": ["192.0.2.44/32", "192.0.2.0/24", // "192.0.0.0/16"] // // * INVALID specification: "Addresses": [""] INVALID // // Addresses is a required field Addresses []*string `type:"list" required:"true"` // A description of the IP set that helps with identification. Description *string `min:"1" type:"string"` // The version of the IP addresses, either IPV4 or IPV6. // // IPAddressVersion is a required field IPAddressVersion *string `type:"string" required:"true" enum:"IPAddressVersion"` // The name of the IP set. You cannot change the name of an IPSet after you // create it. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // An array of key:value pairs to associate with the resource. Tags []*Tag `min:"1" type:"list"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateIPSetInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateIPSetInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CreateIPSetInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CreateIPSetInput"} if s.Addresses == nil { invalidParams.Add(request.NewErrParamRequired("Addresses")) } if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } if s.IPAddressVersion == nil { invalidParams.Add(request.NewErrParamRequired("IPAddressVersion")) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.Tags != nil && len(s.Tags) < 1 { invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) } if s.Tags != nil { for i, v := range s.Tags { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetAddresses sets the Addresses field's value. func (s *CreateIPSetInput) SetAddresses(v []*string) *CreateIPSetInput { s.Addresses = v return s } // SetDescription sets the Description field's value. func (s *CreateIPSetInput) SetDescription(v string) *CreateIPSetInput { s.Description = &v return s } // SetIPAddressVersion sets the IPAddressVersion field's value. func (s *CreateIPSetInput) SetIPAddressVersion(v string) *CreateIPSetInput { s.IPAddressVersion = &v return s } // SetName sets the Name field's value. func (s *CreateIPSetInput) SetName(v string) *CreateIPSetInput { s.Name = &v return s } // SetScope sets the Scope field's value. func (s *CreateIPSetInput) SetScope(v string) *CreateIPSetInput { s.Scope = &v return s } // SetTags sets the Tags field's value. func (s *CreateIPSetInput) SetTags(v []*Tag) *CreateIPSetInput { s.Tags = v return s } type CreateIPSetOutput struct { _ struct{} `type:"structure"` // High-level information about an IPSet, returned by operations like create // and list. This provides information like the ID, that you can use to retrieve // and manage an IPSet, and the ARN, that you provide to the IPSetReferenceStatement // to use the address set in a Rule. Summary *IPSetSummary `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateIPSetOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateIPSetOutput) GoString() string { return s.String() } // SetSummary sets the Summary field's value. func (s *CreateIPSetOutput) SetSummary(v *IPSetSummary) *CreateIPSetOutput { s.Summary = v return s } type CreateRegexPatternSetInput struct { _ struct{} `type:"structure"` // A description of the set that helps with identification. Description *string `min:"1" type:"string"` // The name of the set. You cannot change the name after you create the set. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Array of regular expression strings. // // RegularExpressionList is a required field RegularExpressionList []*Regex `type:"list" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // An array of key:value pairs to associate with the resource. Tags []*Tag `min:"1" type:"list"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRegexPatternSetInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRegexPatternSetInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CreateRegexPatternSetInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CreateRegexPatternSetInput"} if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.RegularExpressionList == nil { invalidParams.Add(request.NewErrParamRequired("RegularExpressionList")) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.Tags != nil && len(s.Tags) < 1 { invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) } if s.RegularExpressionList != nil { for i, v := range s.RegularExpressionList { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RegularExpressionList", i), err.(request.ErrInvalidParams)) } } } if s.Tags != nil { for i, v := range s.Tags { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetDescription sets the Description field's value. func (s *CreateRegexPatternSetInput) SetDescription(v string) *CreateRegexPatternSetInput { s.Description = &v return s } // SetName sets the Name field's value. func (s *CreateRegexPatternSetInput) SetName(v string) *CreateRegexPatternSetInput { s.Name = &v return s } // SetRegularExpressionList sets the RegularExpressionList field's value. func (s *CreateRegexPatternSetInput) SetRegularExpressionList(v []*Regex) *CreateRegexPatternSetInput { s.RegularExpressionList = v return s } // SetScope sets the Scope field's value. func (s *CreateRegexPatternSetInput) SetScope(v string) *CreateRegexPatternSetInput { s.Scope = &v return s } // SetTags sets the Tags field's value. func (s *CreateRegexPatternSetInput) SetTags(v []*Tag) *CreateRegexPatternSetInput { s.Tags = v return s } type CreateRegexPatternSetOutput struct { _ struct{} `type:"structure"` // High-level information about a RegexPatternSet, returned by operations like // create and list. This provides information like the ID, that you can use // to retrieve and manage a RegexPatternSet, and the ARN, that you provide to // the RegexPatternSetReferenceStatement to use the pattern set in a Rule. Summary *RegexPatternSetSummary `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRegexPatternSetOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRegexPatternSetOutput) GoString() string { return s.String() } // SetSummary sets the Summary field's value. func (s *CreateRegexPatternSetOutput) SetSummary(v *RegexPatternSetSummary) *CreateRegexPatternSetOutput { s.Summary = v return s } type CreateRuleGroupInput struct { _ struct{} `type:"structure"` // The web ACL capacity units (WCUs) required for this rule group. // // When you create your own rule group, you define this, and you cannot change // it after creation. When you add or modify the rules in a rule group, WAF // enforces this limit. You can check the capacity for a set of rules using // CheckCapacity. // // WAF uses WCUs to calculate and control the operating resources that are used // to run your rules, rule groups, and web ACLs. WAF calculates capacity differently // for each rule type, to reflect the relative cost of each rule. Simple rules // that cost little to run use fewer WCUs than more complex rules that use more // processing power. Rule group capacity is fixed at creation, which helps users // plan their web ACL WCU usage when they use a rule group. For more information, // see WAF web ACL capacity units (WCU) (https://docs.aws.amazon.com/waf/latest/developerguide/aws-waf-capacity-units.html) // in the WAF Developer Guide. // // Capacity is a required field Capacity *int64 `min:"1" type:"long" required:"true"` // A map of custom response keys and content bodies. When you create a rule // with a block action, you can send a custom response to the web request. You // define these for the rule group, and then use them in the rules that you // define in the rule group. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. // // For information about the limits on count and size for custom request and // response settings, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. CustomResponseBodies map[string]*CustomResponseBody `min:"1" type:"map"` // A description of the rule group that helps with identification. Description *string `min:"1" type:"string"` // The name of the rule group. You cannot change the name of a rule group after // you create it. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // The Rule statements used to identify the web requests that you want to allow, // block, or count. Each rule includes one top-level statement that WAF uses // to identify matching web requests, and parameters that govern how WAF handles // them. Rules []*Rule `type:"list"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // An array of key:value pairs to associate with the resource. Tags []*Tag `min:"1" type:"list"` // Defines and enables Amazon CloudWatch metrics and web request sample collection. // // VisibilityConfig is a required field VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRuleGroupInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRuleGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CreateRuleGroupInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CreateRuleGroupInput"} if s.Capacity == nil { invalidParams.Add(request.NewErrParamRequired("Capacity")) } if s.Capacity != nil && *s.Capacity < 1 { invalidParams.Add(request.NewErrParamMinValue("Capacity", 1)) } if s.CustomResponseBodies != nil && len(s.CustomResponseBodies) < 1 { invalidParams.Add(request.NewErrParamMinLen("CustomResponseBodies", 1)) } if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.Tags != nil && len(s.Tags) < 1 { invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) } if s.VisibilityConfig == nil { invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) } if s.CustomResponseBodies != nil { for i, v := range s.CustomResponseBodies { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "CustomResponseBodies", i), err.(request.ErrInvalidParams)) } } } if s.Rules != nil { for i, v := range s.Rules { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) } } } if s.Tags != nil { for i, v := range s.Tags { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) } } } if s.VisibilityConfig != nil { if err := s.VisibilityConfig.Validate(); err != nil { invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCapacity sets the Capacity field's value. func (s *CreateRuleGroupInput) SetCapacity(v int64) *CreateRuleGroupInput { s.Capacity = &v return s } // SetCustomResponseBodies sets the CustomResponseBodies field's value. func (s *CreateRuleGroupInput) SetCustomResponseBodies(v map[string]*CustomResponseBody) *CreateRuleGroupInput { s.CustomResponseBodies = v return s } // SetDescription sets the Description field's value. func (s *CreateRuleGroupInput) SetDescription(v string) *CreateRuleGroupInput { s.Description = &v return s } // SetName sets the Name field's value. func (s *CreateRuleGroupInput) SetName(v string) *CreateRuleGroupInput { s.Name = &v return s } // SetRules sets the Rules field's value. func (s *CreateRuleGroupInput) SetRules(v []*Rule) *CreateRuleGroupInput { s.Rules = v return s } // SetScope sets the Scope field's value. func (s *CreateRuleGroupInput) SetScope(v string) *CreateRuleGroupInput { s.Scope = &v return s } // SetTags sets the Tags field's value. func (s *CreateRuleGroupInput) SetTags(v []*Tag) *CreateRuleGroupInput { s.Tags = v return s } // SetVisibilityConfig sets the VisibilityConfig field's value. func (s *CreateRuleGroupInput) SetVisibilityConfig(v *VisibilityConfig) *CreateRuleGroupInput { s.VisibilityConfig = v return s } type CreateRuleGroupOutput struct { _ struct{} `type:"structure"` // High-level information about a RuleGroup, returned by operations like create // and list. This provides information like the ID, that you can use to retrieve // and manage a RuleGroup, and the ARN, that you provide to the RuleGroupReferenceStatement // to use the rule group in a Rule. Summary *RuleGroupSummary `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRuleGroupOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateRuleGroupOutput) GoString() string { return s.String() } // SetSummary sets the Summary field's value. func (s *CreateRuleGroupOutput) SetSummary(v *RuleGroupSummary) *CreateRuleGroupOutput { s.Summary = v return s } type CreateWebACLInput struct { _ struct{} `type:"structure"` // Specifies custom configurations for the associations between the web ACL // and protected resources. // // Use this to customize the maximum size of the request body that your protected // CloudFront distributions forward to WAF for inspection. The default is 16 // KB (16,384 kilobytes). // // You are charged additional fees when your protected resources forward body // sizes that are larger than the default. For more information, see WAF Pricing // (http://aws.amazon.com/waf/pricing/). AssociationConfig *AssociationConfig `type:"structure"` // Specifies how WAF should handle CAPTCHA evaluations for rules that don't // have their own CaptchaConfig settings. If you don't specify this, WAF uses // its default settings for CaptchaConfig. CaptchaConfig *CaptchaConfig `type:"structure"` // Specifies how WAF should handle challenge evaluations for rules that don't // have their own ChallengeConfig settings. If you don't specify this, WAF uses // its default settings for ChallengeConfig. ChallengeConfig *ChallengeConfig `type:"structure"` // A map of custom response keys and content bodies. When you create a rule // with a block action, you can send a custom response to the web request. You // define these for the web ACL, and then use them in the rules and default // actions that you define in the web ACL. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. // // For information about the limits on count and size for custom request and // response settings, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. CustomResponseBodies map[string]*CustomResponseBody `min:"1" type:"map"` // The action to perform if none of the Rules contained in the WebACL match. // // DefaultAction is a required field DefaultAction *DefaultAction `type:"structure" required:"true"` // A description of the web ACL that helps with identification. Description *string `min:"1" type:"string"` // The name of the web ACL. You cannot change the name of a web ACL after you // create it. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // The Rule statements used to identify the web requests that you want to allow, // block, or count. Each rule includes one top-level statement that WAF uses // to identify matching web requests, and parameters that govern how WAF handles // them. Rules []*Rule `type:"list"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // An array of key:value pairs to associate with the resource. Tags []*Tag `min:"1" type:"list"` // Specifies the domains that WAF should accept in a web request token. This // enables the use of tokens across multiple protected websites. When WAF provides // a token, it uses the domain of the Amazon Web Services resource that the // web ACL is protecting. If you don't specify a list of token domains, WAF // accepts tokens only for the domain of the protected resource. With a token // domain list, WAF accepts the resource's host domain plus all domains in the // token domain list, including their prefixed subdomains. // // Example JSON: "TokenDomains": { "mywebsite.com", "myotherwebsite.com" } // // Public suffixes aren't allowed. For example, you can't use usa.gov or co.uk // as token domains. TokenDomains []*string `type:"list"` // Defines and enables Amazon CloudWatch metrics and web request sample collection. // // VisibilityConfig is a required field VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateWebACLInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateWebACLInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CreateWebACLInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CreateWebACLInput"} if s.CustomResponseBodies != nil && len(s.CustomResponseBodies) < 1 { invalidParams.Add(request.NewErrParamMinLen("CustomResponseBodies", 1)) } if s.DefaultAction == nil { invalidParams.Add(request.NewErrParamRequired("DefaultAction")) } if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.Tags != nil && len(s.Tags) < 1 { invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) } if s.VisibilityConfig == nil { invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) } if s.AssociationConfig != nil { if err := s.AssociationConfig.Validate(); err != nil { invalidParams.AddNested("AssociationConfig", err.(request.ErrInvalidParams)) } } if s.CaptchaConfig != nil { if err := s.CaptchaConfig.Validate(); err != nil { invalidParams.AddNested("CaptchaConfig", err.(request.ErrInvalidParams)) } } if s.ChallengeConfig != nil { if err := s.ChallengeConfig.Validate(); err != nil { invalidParams.AddNested("ChallengeConfig", err.(request.ErrInvalidParams)) } } if s.CustomResponseBodies != nil { for i, v := range s.CustomResponseBodies { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "CustomResponseBodies", i), err.(request.ErrInvalidParams)) } } } if s.DefaultAction != nil { if err := s.DefaultAction.Validate(); err != nil { invalidParams.AddNested("DefaultAction", err.(request.ErrInvalidParams)) } } if s.Rules != nil { for i, v := range s.Rules { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) } } } if s.Tags != nil { for i, v := range s.Tags { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) } } } if s.VisibilityConfig != nil { if err := s.VisibilityConfig.Validate(); err != nil { invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetAssociationConfig sets the AssociationConfig field's value. func (s *CreateWebACLInput) SetAssociationConfig(v *AssociationConfig) *CreateWebACLInput { s.AssociationConfig = v return s } // SetCaptchaConfig sets the CaptchaConfig field's value. func (s *CreateWebACLInput) SetCaptchaConfig(v *CaptchaConfig) *CreateWebACLInput { s.CaptchaConfig = v return s } // SetChallengeConfig sets the ChallengeConfig field's value. func (s *CreateWebACLInput) SetChallengeConfig(v *ChallengeConfig) *CreateWebACLInput { s.ChallengeConfig = v return s } // SetCustomResponseBodies sets the CustomResponseBodies field's value. func (s *CreateWebACLInput) SetCustomResponseBodies(v map[string]*CustomResponseBody) *CreateWebACLInput { s.CustomResponseBodies = v return s } // SetDefaultAction sets the DefaultAction field's value. func (s *CreateWebACLInput) SetDefaultAction(v *DefaultAction) *CreateWebACLInput { s.DefaultAction = v return s } // SetDescription sets the Description field's value. func (s *CreateWebACLInput) SetDescription(v string) *CreateWebACLInput { s.Description = &v return s } // SetName sets the Name field's value. func (s *CreateWebACLInput) SetName(v string) *CreateWebACLInput { s.Name = &v return s } // SetRules sets the Rules field's value. func (s *CreateWebACLInput) SetRules(v []*Rule) *CreateWebACLInput { s.Rules = v return s } // SetScope sets the Scope field's value. func (s *CreateWebACLInput) SetScope(v string) *CreateWebACLInput { s.Scope = &v return s } // SetTags sets the Tags field's value. func (s *CreateWebACLInput) SetTags(v []*Tag) *CreateWebACLInput { s.Tags = v return s } // SetTokenDomains sets the TokenDomains field's value. func (s *CreateWebACLInput) SetTokenDomains(v []*string) *CreateWebACLInput { s.TokenDomains = v return s } // SetVisibilityConfig sets the VisibilityConfig field's value. func (s *CreateWebACLInput) SetVisibilityConfig(v *VisibilityConfig) *CreateWebACLInput { s.VisibilityConfig = v return s } type CreateWebACLOutput struct { _ struct{} `type:"structure"` // High-level information about a WebACL, returned by operations like create // and list. This provides information like the ID, that you can use to retrieve // and manage a WebACL, and the ARN, that you provide to operations like AssociateWebACL. Summary *WebACLSummary `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateWebACLOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CreateWebACLOutput) GoString() string { return s.String() } // SetSummary sets the Summary field's value. func (s *CreateWebACLOutput) SetSummary(v *WebACLSummary) *CreateWebACLOutput { s.Summary = v return s } // A custom header for custom request and response handling. This is used in // CustomResponse and CustomRequestHandling. type CustomHTTPHeader struct { _ struct{} `type:"structure"` // The name of the custom header. // // For custom request header insertion, when WAF inserts the header into the // request, it prefixes this name x-amzn-waf-, to avoid confusion with the headers // that are already in the request. For example, for the header name sample, // WAF inserts the header x-amzn-waf-sample. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // The value of the custom header. // // Value is a required field Value *string `min:"1" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomHTTPHeader) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomHTTPHeader) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CustomHTTPHeader) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CustomHTTPHeader"} if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Value == nil { invalidParams.Add(request.NewErrParamRequired("Value")) } if s.Value != nil && len(*s.Value) < 1 { invalidParams.Add(request.NewErrParamMinLen("Value", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetName sets the Name field's value. func (s *CustomHTTPHeader) SetName(v string) *CustomHTTPHeader { s.Name = &v return s } // SetValue sets the Value field's value. func (s *CustomHTTPHeader) SetValue(v string) *CustomHTTPHeader { s.Value = &v return s } // Custom request handling behavior that inserts custom headers into a web request. // You can add custom request handling for WAF to use when the rule action doesn't // block the request. For example, CaptchaAction for requests with valid t okens, // and AllowAction. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. type CustomRequestHandling struct { _ struct{} `type:"structure"` // The HTTP headers to insert into the request. Duplicate header names are not // allowed. // // For information about the limits on count and size for custom request and // response settings, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // InsertHeaders is a required field InsertHeaders []*CustomHTTPHeader `min:"1" type:"list" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomRequestHandling) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomRequestHandling) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CustomRequestHandling) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CustomRequestHandling"} if s.InsertHeaders == nil { invalidParams.Add(request.NewErrParamRequired("InsertHeaders")) } if s.InsertHeaders != nil && len(s.InsertHeaders) < 1 { invalidParams.Add(request.NewErrParamMinLen("InsertHeaders", 1)) } if s.InsertHeaders != nil { for i, v := range s.InsertHeaders { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "InsertHeaders", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetInsertHeaders sets the InsertHeaders field's value. func (s *CustomRequestHandling) SetInsertHeaders(v []*CustomHTTPHeader) *CustomRequestHandling { s.InsertHeaders = v return s } // A custom response to send to the client. You can define a custom response // for rule actions and default web ACL actions that are set to BlockAction. // // For information about customizing web requests and responses, see Customizing // web requests and responses in WAF (https://docs.aws.amazon.com/waf/latest/developerguide/waf-custom-request-response.html) // in the WAF Developer Guide. type CustomResponse struct { _ struct{} `type:"structure"` // References the response body that you want WAF to return to the web request // client. You can define a custom response for a rule action or a default web // ACL action that is set to block. To do this, you first define the response // body key and value in the CustomResponseBodies setting for the WebACL or // RuleGroup where you want to use it. Then, in the rule action or web ACL default // action BlockAction setting, you reference the response body using this key. CustomResponseBodyKey *string `min:"1" type:"string"` // The HTTP status code to return to the client. // // For a list of status codes that you can use in your custom responses, see // Supported status codes for custom response (https://docs.aws.amazon.com/waf/latest/developerguide/customizing-the-response-status-codes.html) // in the WAF Developer Guide. // // ResponseCode is a required field ResponseCode *int64 `min:"200" type:"integer" required:"true"` // The HTTP headers to use in the response. Duplicate header names are not allowed. // // For information about the limits on count and size for custom request and // response settings, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. ResponseHeaders []*CustomHTTPHeader `min:"1" type:"list"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomResponse) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomResponse) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CustomResponse) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CustomResponse"} if s.CustomResponseBodyKey != nil && len(*s.CustomResponseBodyKey) < 1 { invalidParams.Add(request.NewErrParamMinLen("CustomResponseBodyKey", 1)) } if s.ResponseCode == nil { invalidParams.Add(request.NewErrParamRequired("ResponseCode")) } if s.ResponseCode != nil && *s.ResponseCode < 200 { invalidParams.Add(request.NewErrParamMinValue("ResponseCode", 200)) } if s.ResponseHeaders != nil && len(s.ResponseHeaders) < 1 { invalidParams.Add(request.NewErrParamMinLen("ResponseHeaders", 1)) } if s.ResponseHeaders != nil { for i, v := range s.ResponseHeaders { if v == nil { continue } if err := v.Validate(); err != nil { invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ResponseHeaders", i), err.(request.ErrInvalidParams)) } } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetCustomResponseBodyKey sets the CustomResponseBodyKey field's value. func (s *CustomResponse) SetCustomResponseBodyKey(v string) *CustomResponse { s.CustomResponseBodyKey = &v return s } // SetResponseCode sets the ResponseCode field's value. func (s *CustomResponse) SetResponseCode(v int64) *CustomResponse { s.ResponseCode = &v return s } // SetResponseHeaders sets the ResponseHeaders field's value. func (s *CustomResponse) SetResponseHeaders(v []*CustomHTTPHeader) *CustomResponse { s.ResponseHeaders = v return s } // The response body to use in a custom response to a web request. This is referenced // by key from CustomResponse CustomResponseBodyKey. type CustomResponseBody struct { _ struct{} `type:"structure"` // The payload of the custom response. // // You can use JSON escape strings in JSON content. To do this, you must specify // JSON content in the ContentType setting. // // For information about the limits on count and size for custom request and // response settings, see WAF quotas (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) // in the WAF Developer Guide. // // Content is a required field Content *string `min:"1" type:"string" required:"true"` // The type of content in the payload that you are defining in the Content string. // // ContentType is a required field ContentType *string `type:"string" required:"true" enum:"ResponseContentType"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomResponseBody) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s CustomResponseBody) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *CustomResponseBody) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CustomResponseBody"} if s.Content == nil { invalidParams.Add(request.NewErrParamRequired("Content")) } if s.Content != nil && len(*s.Content) < 1 { invalidParams.Add(request.NewErrParamMinLen("Content", 1)) } if s.ContentType == nil { invalidParams.Add(request.NewErrParamRequired("ContentType")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetContent sets the Content field's value. func (s *CustomResponseBody) SetContent(v string) *CustomResponseBody { s.Content = &v return s } // SetContentType sets the ContentType field's value. func (s *CustomResponseBody) SetContentType(v string) *CustomResponseBody { s.ContentType = &v return s } // In a WebACL, this is the action that you want WAF to perform when a web request // doesn't match any of the rules in the WebACL. The default action must be // a terminating action. type DefaultAction struct { _ struct{} `type:"structure"` // Specifies that WAF should allow requests by default. Allow *AllowAction `type:"structure"` // Specifies that WAF should block requests by default. Block *BlockAction `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DefaultAction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DefaultAction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DefaultAction) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DefaultAction"} if s.Allow != nil { if err := s.Allow.Validate(); err != nil { invalidParams.AddNested("Allow", err.(request.ErrInvalidParams)) } } if s.Block != nil { if err := s.Block.Validate(); err != nil { invalidParams.AddNested("Block", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetAllow sets the Allow field's value. func (s *DefaultAction) SetAllow(v *AllowAction) *DefaultAction { s.Allow = v return s } // SetBlock sets the Block field's value. func (s *DefaultAction) SetBlock(v *BlockAction) *DefaultAction { s.Block = v return s } type DeleteFirewallManagerRuleGroupsInput struct { _ struct{} `type:"structure"` // The Amazon Resource Name (ARN) of the web ACL. // // WebACLArn is a required field WebACLArn *string `min:"20" type:"string" required:"true"` // A token used for optimistic locking. WAF returns a token to your get and // list requests, to mark the state of the entity at the time of the request. // To make changes to the entity associated with the token, you provide the // token to operations like update and delete. WAF uses the token to ensure // that no changes have been made to the entity since you last retrieved it. // If a change has been made, the update fails with a WAFOptimisticLockException. // If this happens, perform another get, and use the new token returned by that // operation. // // WebACLLockToken is a required field WebACLLockToken *string `min:"1" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteFirewallManagerRuleGroupsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteFirewallManagerRuleGroupsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeleteFirewallManagerRuleGroupsInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeleteFirewallManagerRuleGroupsInput"} if s.WebACLArn == nil { invalidParams.Add(request.NewErrParamRequired("WebACLArn")) } if s.WebACLArn != nil && len(*s.WebACLArn) < 20 { invalidParams.Add(request.NewErrParamMinLen("WebACLArn", 20)) } if s.WebACLLockToken == nil { invalidParams.Add(request.NewErrParamRequired("WebACLLockToken")) } if s.WebACLLockToken != nil && len(*s.WebACLLockToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("WebACLLockToken", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetWebACLArn sets the WebACLArn field's value. func (s *DeleteFirewallManagerRuleGroupsInput) SetWebACLArn(v string) *DeleteFirewallManagerRuleGroupsInput { s.WebACLArn = &v return s } // SetWebACLLockToken sets the WebACLLockToken field's value. func (s *DeleteFirewallManagerRuleGroupsInput) SetWebACLLockToken(v string) *DeleteFirewallManagerRuleGroupsInput { s.WebACLLockToken = &v return s } type DeleteFirewallManagerRuleGroupsOutput struct { _ struct{} `type:"structure"` // A token used for optimistic locking. WAF returns a token to your get and // list requests, to mark the state of the entity at the time of the request. // To make changes to the entity associated with the token, you provide the // token to operations like update and delete. WAF uses the token to ensure // that no changes have been made to the entity since you last retrieved it. // If a change has been made, the update fails with a WAFOptimisticLockException. // If this happens, perform another get, and use the new token returned by that // operation. NextWebACLLockToken *string `min:"1" type:"string"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteFirewallManagerRuleGroupsOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteFirewallManagerRuleGroupsOutput) GoString() string { return s.String() } // SetNextWebACLLockToken sets the NextWebACLLockToken field's value. func (s *DeleteFirewallManagerRuleGroupsOutput) SetNextWebACLLockToken(v string) *DeleteFirewallManagerRuleGroupsOutput { s.NextWebACLLockToken = &v return s } type DeleteIPSetInput struct { _ struct{} `type:"structure"` // A unique identifier for the set. This ID is returned in the responses to // create and list commands. You provide it to operations like update and delete. // // Id is a required field Id *string `min:"1" type:"string" required:"true"` // A token used for optimistic locking. WAF returns a token to your get and // list requests, to mark the state of the entity at the time of the request. // To make changes to the entity associated with the token, you provide the // token to operations like update and delete. WAF uses the token to ensure // that no changes have been made to the entity since you last retrieved it. // If a change has been made, the update fails with a WAFOptimisticLockException. // If this happens, perform another get, and use the new token returned by that // operation. // // LockToken is a required field LockToken *string `min:"1" type:"string" required:"true"` // The name of the IP set. You cannot change the name of an IPSet after you // create it. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteIPSetInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteIPSetInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeleteIPSetInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeleteIPSetInput"} if s.Id == nil { invalidParams.Add(request.NewErrParamRequired("Id")) } if s.Id != nil && len(*s.Id) < 1 { invalidParams.Add(request.NewErrParamMinLen("Id", 1)) } if s.LockToken == nil { invalidParams.Add(request.NewErrParamRequired("LockToken")) } if s.LockToken != nil && len(*s.LockToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetId sets the Id field's value. func (s *DeleteIPSetInput) SetId(v string) *DeleteIPSetInput { s.Id = &v return s } // SetLockToken sets the LockToken field's value. func (s *DeleteIPSetInput) SetLockToken(v string) *DeleteIPSetInput { s.LockToken = &v return s } // SetName sets the Name field's value. func (s *DeleteIPSetInput) SetName(v string) *DeleteIPSetInput { s.Name = &v return s } // SetScope sets the Scope field's value. func (s *DeleteIPSetInput) SetScope(v string) *DeleteIPSetInput { s.Scope = &v return s } type DeleteIPSetOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteIPSetOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteIPSetOutput) GoString() string { return s.String() } type DeleteLoggingConfigurationInput struct { _ struct{} `type:"structure"` // The Amazon Resource Name (ARN) of the web ACL from which you want to delete // the LoggingConfiguration. // // ResourceArn is a required field ResourceArn *string `min:"20" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteLoggingConfigurationInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteLoggingConfigurationInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeleteLoggingConfigurationInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeleteLoggingConfigurationInput"} if s.ResourceArn == nil { invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetResourceArn sets the ResourceArn field's value. func (s *DeleteLoggingConfigurationInput) SetResourceArn(v string) *DeleteLoggingConfigurationInput { s.ResourceArn = &v return s } type DeleteLoggingConfigurationOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteLoggingConfigurationOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteLoggingConfigurationOutput) GoString() string { return s.String() } type DeletePermissionPolicyInput struct { _ struct{} `type:"structure"` // The Amazon Resource Name (ARN) of the rule group from which you want to delete // the policy. // // You must be the owner of the rule group to perform this operation. // // ResourceArn is a required field ResourceArn *string `min:"20" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeletePermissionPolicyInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeletePermissionPolicyInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeletePermissionPolicyInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeletePermissionPolicyInput"} if s.ResourceArn == nil { invalidParams.Add(request.NewErrParamRequired("ResourceArn")) } if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetResourceArn sets the ResourceArn field's value. func (s *DeletePermissionPolicyInput) SetResourceArn(v string) *DeletePermissionPolicyInput { s.ResourceArn = &v return s } type DeletePermissionPolicyOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeletePermissionPolicyOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeletePermissionPolicyOutput) GoString() string { return s.String() } type DeleteRegexPatternSetInput struct { _ struct{} `type:"structure"` // A unique identifier for the set. This ID is returned in the responses to // create and list commands. You provide it to operations like update and delete. // // Id is a required field Id *string `min:"1" type:"string" required:"true"` // A token used for optimistic locking. WAF returns a token to your get and // list requests, to mark the state of the entity at the time of the request. // To make changes to the entity associated with the token, you provide the // token to operations like update and delete. WAF uses the token to ensure // that no changes have been made to the entity since you last retrieved it. // If a change has been made, the update fails with a WAFOptimisticLockException. // If this happens, perform another get, and use the new token returned by that // operation. // // LockToken is a required field LockToken *string `min:"1" type:"string" required:"true"` // The name of the set. You cannot change the name after you create the set. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRegexPatternSetInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRegexPatternSetInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeleteRegexPatternSetInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeleteRegexPatternSetInput"} if s.Id == nil { invalidParams.Add(request.NewErrParamRequired("Id")) } if s.Id != nil && len(*s.Id) < 1 { invalidParams.Add(request.NewErrParamMinLen("Id", 1)) } if s.LockToken == nil { invalidParams.Add(request.NewErrParamRequired("LockToken")) } if s.LockToken != nil && len(*s.LockToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetId sets the Id field's value. func (s *DeleteRegexPatternSetInput) SetId(v string) *DeleteRegexPatternSetInput { s.Id = &v return s } // SetLockToken sets the LockToken field's value. func (s *DeleteRegexPatternSetInput) SetLockToken(v string) *DeleteRegexPatternSetInput { s.LockToken = &v return s } // SetName sets the Name field's value. func (s *DeleteRegexPatternSetInput) SetName(v string) *DeleteRegexPatternSetInput { s.Name = &v return s } // SetScope sets the Scope field's value. func (s *DeleteRegexPatternSetInput) SetScope(v string) *DeleteRegexPatternSetInput { s.Scope = &v return s } type DeleteRegexPatternSetOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRegexPatternSetOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRegexPatternSetOutput) GoString() string { return s.String() } type DeleteRuleGroupInput struct { _ struct{} `type:"structure"` // A unique identifier for the rule group. This ID is returned in the responses // to create and list commands. You provide it to operations like update and // delete. // // Id is a required field Id *string `min:"1" type:"string" required:"true"` // A token used for optimistic locking. WAF returns a token to your get and // list requests, to mark the state of the entity at the time of the request. // To make changes to the entity associated with the token, you provide the // token to operations like update and delete. WAF uses the token to ensure // that no changes have been made to the entity since you last retrieved it. // If a change has been made, the update fails with a WAFOptimisticLockException. // If this happens, perform another get, and use the new token returned by that // operation. // // LockToken is a required field LockToken *string `min:"1" type:"string" required:"true"` // The name of the rule group. You cannot change the name of a rule group after // you create it. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRuleGroupInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRuleGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeleteRuleGroupInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeleteRuleGroupInput"} if s.Id == nil { invalidParams.Add(request.NewErrParamRequired("Id")) } if s.Id != nil && len(*s.Id) < 1 { invalidParams.Add(request.NewErrParamMinLen("Id", 1)) } if s.LockToken == nil { invalidParams.Add(request.NewErrParamRequired("LockToken")) } if s.LockToken != nil && len(*s.LockToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetId sets the Id field's value. func (s *DeleteRuleGroupInput) SetId(v string) *DeleteRuleGroupInput { s.Id = &v return s } // SetLockToken sets the LockToken field's value. func (s *DeleteRuleGroupInput) SetLockToken(v string) *DeleteRuleGroupInput { s.LockToken = &v return s } // SetName sets the Name field's value. func (s *DeleteRuleGroupInput) SetName(v string) *DeleteRuleGroupInput { s.Name = &v return s } // SetScope sets the Scope field's value. func (s *DeleteRuleGroupInput) SetScope(v string) *DeleteRuleGroupInput { s.Scope = &v return s } type DeleteRuleGroupOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRuleGroupOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteRuleGroupOutput) GoString() string { return s.String() } type DeleteWebACLInput struct { _ struct{} `type:"structure"` // The unique identifier for the web ACL. This ID is returned in the responses // to create and list commands. You provide it to operations like update and // delete. // // Id is a required field Id *string `min:"1" type:"string" required:"true"` // A token used for optimistic locking. WAF returns a token to your get and // list requests, to mark the state of the entity at the time of the request. // To make changes to the entity associated with the token, you provide the // token to operations like update and delete. WAF uses the token to ensure // that no changes have been made to the entity since you last retrieved it. // If a change has been made, the update fails with a WAFOptimisticLockException. // If this happens, perform another get, and use the new token returned by that // operation. // // LockToken is a required field LockToken *string `min:"1" type:"string" required:"true"` // The name of the web ACL. You cannot change the name of a web ACL after you // create it. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteWebACLInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteWebACLInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DeleteWebACLInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DeleteWebACLInput"} if s.Id == nil { invalidParams.Add(request.NewErrParamRequired("Id")) } if s.Id != nil && len(*s.Id) < 1 { invalidParams.Add(request.NewErrParamMinLen("Id", 1)) } if s.LockToken == nil { invalidParams.Add(request.NewErrParamRequired("LockToken")) } if s.LockToken != nil && len(*s.LockToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) } if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetId sets the Id field's value. func (s *DeleteWebACLInput) SetId(v string) *DeleteWebACLInput { s.Id = &v return s } // SetLockToken sets the LockToken field's value. func (s *DeleteWebACLInput) SetLockToken(v string) *DeleteWebACLInput { s.LockToken = &v return s } // SetName sets the Name field's value. func (s *DeleteWebACLInput) SetName(v string) *DeleteWebACLInput { s.Name = &v return s } // SetScope sets the Scope field's value. func (s *DeleteWebACLInput) SetScope(v string) *DeleteWebACLInput { s.Scope = &v return s } type DeleteWebACLOutput struct { _ struct{} `type:"structure"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteWebACLOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DeleteWebACLOutput) GoString() string { return s.String() } type DescribeAllManagedProductsInput struct { _ struct{} `type:"structure"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeAllManagedProductsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeAllManagedProductsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DescribeAllManagedProductsInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DescribeAllManagedProductsInput"} if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetScope sets the Scope field's value. func (s *DescribeAllManagedProductsInput) SetScope(v string) *DescribeAllManagedProductsInput { s.Scope = &v return s } type DescribeAllManagedProductsOutput struct { _ struct{} `type:"structure"` // High-level information for the Amazon Web Services Managed Rules rule groups // and Amazon Web Services Marketplace managed rule groups. ManagedProducts []*ManagedProductDescriptor `type:"list"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeAllManagedProductsOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeAllManagedProductsOutput) GoString() string { return s.String() } // SetManagedProducts sets the ManagedProducts field's value. func (s *DescribeAllManagedProductsOutput) SetManagedProducts(v []*ManagedProductDescriptor) *DescribeAllManagedProductsOutput { s.ManagedProducts = v return s } type DescribeManagedProductsByVendorInput struct { _ struct{} `type:"structure"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // The name of the managed rule group vendor. You use this, along with the rule // group name, to identify a rule group. // // VendorName is a required field VendorName *string `min:"1" type:"string" required:"true"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeManagedProductsByVendorInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeManagedProductsByVendorInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DescribeManagedProductsByVendorInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DescribeManagedProductsByVendorInput"} if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.VendorName == nil { invalidParams.Add(request.NewErrParamRequired("VendorName")) } if s.VendorName != nil && len(*s.VendorName) < 1 { invalidParams.Add(request.NewErrParamMinLen("VendorName", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetScope sets the Scope field's value. func (s *DescribeManagedProductsByVendorInput) SetScope(v string) *DescribeManagedProductsByVendorInput { s.Scope = &v return s } // SetVendorName sets the VendorName field's value. func (s *DescribeManagedProductsByVendorInput) SetVendorName(v string) *DescribeManagedProductsByVendorInput { s.VendorName = &v return s } type DescribeManagedProductsByVendorOutput struct { _ struct{} `type:"structure"` // High-level information for the managed rule groups owned by the specified // vendor. ManagedProducts []*ManagedProductDescriptor `type:"list"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeManagedProductsByVendorOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeManagedProductsByVendorOutput) GoString() string { return s.String() } // SetManagedProducts sets the ManagedProducts field's value. func (s *DescribeManagedProductsByVendorOutput) SetManagedProducts(v []*ManagedProductDescriptor) *DescribeManagedProductsByVendorOutput { s.ManagedProducts = v return s } type DescribeManagedRuleGroupInput struct { _ struct{} `type:"structure"` // The name of the managed rule group. You use this, along with the vendor name, // to identify the rule group. // // Name is a required field Name *string `min:"1" type:"string" required:"true"` // Specifies whether this is for an Amazon CloudFront distribution or for a // regional application. A regional application can be an Application Load Balancer // (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon // Cognito user pool, an App Runner service, or an Amazon Web Services Verified // Access instance. // // To work with CloudFront, you must also specify the Region US East (N. Virginia) // as follows: // // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT // --region=us-east-1. // // * API and SDKs - For all calls, use the Region endpoint us-east-1. // // Scope is a required field Scope *string `type:"string" required:"true" enum:"Scope"` // The name of the managed rule group vendor. You use this, along with the rule // group name, to identify a rule group. // // VendorName is a required field VendorName *string `min:"1" type:"string" required:"true"` // The version of the rule group. You can only use a version that is not scheduled // for expiration. If you don't provide this, WAF uses the vendor's default // version. VersionName *string `min:"1" type:"string"` } // String returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeManagedRuleGroupInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". func (s DescribeManagedRuleGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. func (s *DescribeManagedRuleGroupInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DescribeManagedRuleGroupInput"} if s.Name == nil { invalidParams.Add(request.NewErrParamRequired("Name")) } if s.Name != nil && len(*s.Name) < 1 { invalidParams.Add(request.NewErrParamMinLen("Name", 1)) } if s.Scope == nil { invalidParams.Add(request.NewErrParamRequired("Scope")) } if s.VendorName == nil { invalidParams.Add(request.NewErrParamRequired("VendorName")) } if s.VendorName != nil && len(*s.VendorName) < 1 { invalidParams.Add(request.NewErrParamMinLen("VendorName", 1)) } if s.VersionName != nil && len(*s.VersionName) < 1 { invalidParams.Add(request.NewErrParamMinLen("VersionName", 1)) } if invalidParams.Len() > 0 { return invalidParams } return nil } // SetName sets the Name field's value. func (s *DescribeManagedRuleGroupInput) SetName(v string) *DescribeManagedRuleGroupInput { s.Name = &v return s } // SetScope sets the Scope field's value. func (s *DescribeManagedRuleGroupInput) SetScope(v string) *DescribeManagedRuleGroupInput { s.Scope = &v return s } // SetVendorName sets the VendorName field's value. func (s *DescribeManagedRuleGroupInput) SetVendorName(v string) *DescribeManagedRuleGroupInput { s.VendorName = &v return s } // SetVersionName sets the VersionName field's value. func (s *DescribeManagedRuleGroupInput) SetVersionName(v string) *DescribeManagedRuleGroupInput { s.VersionName = &v return s } type DescribeManagedRuleGroupOutput struct { _ struct{} `type:"structure"` // The labels that one or more rules in this rule group add to matching web // requests. These labels are defined in the RuleLabels for a Rule. AvailableLabels []*LabelSummary `type:"list"` // The web ACL capacity units (WCUs) required for this rule group. // // WAF uses WCUs to calculate and control the operating resources that are used // to run your rules, rule groups, and web ACLs. WAF calculates capacity differently // for each rule type, to reflect the relative cost of each rule. Simple rules // that cost little to run use fewer WCUs than more complex rules that use more // processing power. Rule group capacity is fixed at creation, which helps users // plan their web ACL WCU usage when they use a rule group. For more information, // see WAF web ACL capacity units (WCU) (https://docs.aws.amazon.com/waf/latest/developerguide/aws-waf-capacity-units.html) // in the WAF Developer Guide. Capacity *int64 `min:"1" type:"long"` // The labels that one or more rules in this rule group match against in label // match statements. These labels are defined in a LabelMatchStatement specification, // in the Statement definition of a rule. ConsumedLabels []*LabelSummary `type:"list"` // The label namespace prefix for this rule group. All labels added by rules // in this rule group have this prefix. // // * The syntax for the label namespace prefix for a managed rule group is // the following: awswaf:managed::: // // * When a rule with a label matches a web request, WAF adds the fully qualified // label to the request. A fully qualified label is made up of the label // namespace from the rule group or web ACL where the rule is defined and // the label from the rule, separated by a colon: