1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package wafv2 4 5import ( 6 "fmt" 7 "time" 8 9 "github.com/aws/aws-sdk-go/aws" 10 "github.com/aws/aws-sdk-go/aws/awsutil" 11 "github.com/aws/aws-sdk-go/aws/request" 12 "github.com/aws/aws-sdk-go/private/protocol" 13 "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" 14) 15 16const opAssociateWebACL = "AssociateWebACL" 17 18// AssociateWebACLRequest generates a "aws/request.Request" representing the 19// client's request for the AssociateWebACL operation. The "output" return 20// value will be populated with the request's response once the request completes 21// successfully. 22// 23// Use "Send" method on the returned Request to send the API call to the service. 24// the "output" return value is not valid until after Send returns without error. 25// 26// See AssociateWebACL for more information on using the AssociateWebACL 27// API call, and error handling. 28// 29// This method is useful when you want to inject custom logic or configuration 30// into the SDK's request lifecycle. Such as custom headers, or retry logic. 31// 32// 33// // Example sending a request using the AssociateWebACLRequest method. 34// req, resp := client.AssociateWebACLRequest(params) 35// 36// err := req.Send() 37// if err == nil { // resp is now filled 38// fmt.Println(resp) 39// } 40// 41// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/AssociateWebACL 42func (c *WAFV2) AssociateWebACLRequest(input *AssociateWebACLInput) (req *request.Request, output *AssociateWebACLOutput) { 43 op := &request.Operation{ 44 Name: opAssociateWebACL, 45 HTTPMethod: "POST", 46 HTTPPath: "/", 47 } 48 49 if input == nil { 50 input = &AssociateWebACLInput{} 51 } 52 53 output = &AssociateWebACLOutput{} 54 req = c.newRequest(op, input, output) 55 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 56 return 57} 58 59// AssociateWebACL API operation for AWS WAFV2. 60// 61// 62// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 63// 2019. For information, including how to migrate your AWS WAF resources from 64// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 65// 66// Associates a Web ACL with a regional application resource, to protect the 67// resource. A regional application can be an Application Load Balancer (ALB), 68// an API Gateway REST API, or an AppSync GraphQL API. 69// 70// For AWS CloudFront, don't use this call. Instead, use your CloudFront distribution 71// configuration. To associate a Web ACL, in the CloudFront call UpdateDistribution, 72// set the web ACL ID to the Amazon Resource Name (ARN) of the Web ACL. For 73// information, see UpdateDistribution (https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html). 74// 75// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 76// with awserr.Error's Code and Message methods to get detailed information about 77// the error. 78// 79// See the AWS API reference guide for AWS WAFV2's 80// API operation AssociateWebACL for usage and error information. 81// 82// Returned Error Types: 83// * WAFInternalErrorException 84// Your request is valid, but AWS WAF couldn’t perform the operation because 85// of a system problem. Retry your request. 86// 87// * WAFInvalidParameterException 88// The operation failed because AWS WAF didn't recognize a parameter in the 89// request. For example: 90// 91// * You specified an invalid parameter name or value. 92// 93// * Your nested statement isn't valid. You might have tried to nest a statement 94// that can’t be nested. 95// 96// * You tried to update a WebACL with a DefaultAction that isn't among the 97// types available at DefaultAction. 98// 99// * Your request references an ARN that is malformed, or corresponds to 100// a resource with which a Web ACL cannot be associated. 101// 102// * WAFNonexistentItemException 103// AWS WAF couldn’t perform the operation because your resource doesn’t 104// exist. 105// 106// * WAFUnavailableEntityException 107// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 108// 109// * WAFInvalidOperationException 110// The operation isn't valid. 111// 112// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/AssociateWebACL 113func (c *WAFV2) AssociateWebACL(input *AssociateWebACLInput) (*AssociateWebACLOutput, error) { 114 req, out := c.AssociateWebACLRequest(input) 115 return out, req.Send() 116} 117 118// AssociateWebACLWithContext is the same as AssociateWebACL with the addition of 119// the ability to pass a context and additional request options. 120// 121// See AssociateWebACL for details on how to use this API operation. 122// 123// The context must be non-nil and will be used for request cancellation. If 124// the context is nil a panic will occur. In the future the SDK may create 125// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 126// for more information on using Contexts. 127func (c *WAFV2) AssociateWebACLWithContext(ctx aws.Context, input *AssociateWebACLInput, opts ...request.Option) (*AssociateWebACLOutput, error) { 128 req, out := c.AssociateWebACLRequest(input) 129 req.SetContext(ctx) 130 req.ApplyOptions(opts...) 131 return out, req.Send() 132} 133 134const opCheckCapacity = "CheckCapacity" 135 136// CheckCapacityRequest generates a "aws/request.Request" representing the 137// client's request for the CheckCapacity operation. The "output" return 138// value will be populated with the request's response once the request completes 139// successfully. 140// 141// Use "Send" method on the returned Request to send the API call to the service. 142// the "output" return value is not valid until after Send returns without error. 143// 144// See CheckCapacity for more information on using the CheckCapacity 145// API call, and error handling. 146// 147// This method is useful when you want to inject custom logic or configuration 148// into the SDK's request lifecycle. Such as custom headers, or retry logic. 149// 150// 151// // Example sending a request using the CheckCapacityRequest method. 152// req, resp := client.CheckCapacityRequest(params) 153// 154// err := req.Send() 155// if err == nil { // resp is now filled 156// fmt.Println(resp) 157// } 158// 159// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CheckCapacity 160func (c *WAFV2) CheckCapacityRequest(input *CheckCapacityInput) (req *request.Request, output *CheckCapacityOutput) { 161 op := &request.Operation{ 162 Name: opCheckCapacity, 163 HTTPMethod: "POST", 164 HTTPPath: "/", 165 } 166 167 if input == nil { 168 input = &CheckCapacityInput{} 169 } 170 171 output = &CheckCapacityOutput{} 172 req = c.newRequest(op, input, output) 173 return 174} 175 176// CheckCapacity API operation for AWS WAFV2. 177// 178// 179// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 180// 2019. For information, including how to migrate your AWS WAF resources from 181// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 182// 183// Returns the web ACL capacity unit (WCU) requirements for a specified scope 184// and set of rules. You can use this to check the capacity requirements for 185// the rules you want to use in a RuleGroup or WebACL. 186// 187// AWS WAF uses WCUs to calculate and control the operating resources that are 188// used to run your rules, rule groups, and web ACLs. AWS WAF calculates capacity 189// differently for each rule type, to reflect the relative cost of each rule. 190// Simple rules that cost little to run use fewer WCUs than more complex rules 191// that use more processing power. Rule group capacity is fixed at creation, 192// which helps users plan their web ACL WCU usage when they use a rule group. 193// The WCU limit for web ACLs is 1,500. 194// 195// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 196// with awserr.Error's Code and Message methods to get detailed information about 197// the error. 198// 199// See the AWS API reference guide for AWS WAFV2's 200// API operation CheckCapacity for usage and error information. 201// 202// Returned Error Types: 203// * WAFInternalErrorException 204// Your request is valid, but AWS WAF couldn’t perform the operation because 205// of a system problem. Retry your request. 206// 207// * WAFInvalidParameterException 208// The operation failed because AWS WAF didn't recognize a parameter in the 209// request. For example: 210// 211// * You specified an invalid parameter name or value. 212// 213// * Your nested statement isn't valid. You might have tried to nest a statement 214// that can’t be nested. 215// 216// * You tried to update a WebACL with a DefaultAction that isn't among the 217// types available at DefaultAction. 218// 219// * Your request references an ARN that is malformed, or corresponds to 220// a resource with which a Web ACL cannot be associated. 221// 222// * WAFNonexistentItemException 223// AWS WAF couldn’t perform the operation because your resource doesn’t 224// exist. 225// 226// * WAFLimitsExceededException 227// AWS WAF couldn’t perform the operation because you exceeded your resource 228// limit. For example, the maximum number of WebACL objects that you can create 229// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 230// in the AWS WAF Developer Guide. 231// 232// * WAFInvalidResourceException 233// AWS WAF couldn’t perform the operation because the resource that you requested 234// isn’t valid. Check the resource, and try again. 235// 236// * WAFUnavailableEntityException 237// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 238// 239// * WAFSubscriptionNotFoundException 240// 241// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CheckCapacity 242func (c *WAFV2) CheckCapacity(input *CheckCapacityInput) (*CheckCapacityOutput, error) { 243 req, out := c.CheckCapacityRequest(input) 244 return out, req.Send() 245} 246 247// CheckCapacityWithContext is the same as CheckCapacity with the addition of 248// the ability to pass a context and additional request options. 249// 250// See CheckCapacity for details on how to use this API operation. 251// 252// The context must be non-nil and will be used for request cancellation. If 253// the context is nil a panic will occur. In the future the SDK may create 254// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 255// for more information on using Contexts. 256func (c *WAFV2) CheckCapacityWithContext(ctx aws.Context, input *CheckCapacityInput, opts ...request.Option) (*CheckCapacityOutput, error) { 257 req, out := c.CheckCapacityRequest(input) 258 req.SetContext(ctx) 259 req.ApplyOptions(opts...) 260 return out, req.Send() 261} 262 263const opCreateIPSet = "CreateIPSet" 264 265// CreateIPSetRequest generates a "aws/request.Request" representing the 266// client's request for the CreateIPSet operation. The "output" return 267// value will be populated with the request's response once the request completes 268// successfully. 269// 270// Use "Send" method on the returned Request to send the API call to the service. 271// the "output" return value is not valid until after Send returns without error. 272// 273// See CreateIPSet for more information on using the CreateIPSet 274// API call, and error handling. 275// 276// This method is useful when you want to inject custom logic or configuration 277// into the SDK's request lifecycle. Such as custom headers, or retry logic. 278// 279// 280// // Example sending a request using the CreateIPSetRequest method. 281// req, resp := client.CreateIPSetRequest(params) 282// 283// err := req.Send() 284// if err == nil { // resp is now filled 285// fmt.Println(resp) 286// } 287// 288// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateIPSet 289func (c *WAFV2) CreateIPSetRequest(input *CreateIPSetInput) (req *request.Request, output *CreateIPSetOutput) { 290 op := &request.Operation{ 291 Name: opCreateIPSet, 292 HTTPMethod: "POST", 293 HTTPPath: "/", 294 } 295 296 if input == nil { 297 input = &CreateIPSetInput{} 298 } 299 300 output = &CreateIPSetOutput{} 301 req = c.newRequest(op, input, output) 302 return 303} 304 305// CreateIPSet API operation for AWS WAFV2. 306// 307// 308// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 309// 2019. For information, including how to migrate your AWS WAF resources from 310// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 311// 312// Creates an IPSet, which you use to identify web requests that originate from 313// specific IP addresses or ranges of IP addresses. For example, if you're receiving 314// a lot of requests from a ranges of IP addresses, you can configure AWS WAF 315// to block them using an IPSet that lists those IP addresses. 316// 317// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 318// with awserr.Error's Code and Message methods to get detailed information about 319// the error. 320// 321// See the AWS API reference guide for AWS WAFV2's 322// API operation CreateIPSet for usage and error information. 323// 324// Returned Error Types: 325// * WAFInternalErrorException 326// Your request is valid, but AWS WAF couldn’t perform the operation because 327// of a system problem. Retry your request. 328// 329// * WAFInvalidParameterException 330// The operation failed because AWS WAF didn't recognize a parameter in the 331// request. For example: 332// 333// * You specified an invalid parameter name or value. 334// 335// * Your nested statement isn't valid. You might have tried to nest a statement 336// that can’t be nested. 337// 338// * You tried to update a WebACL with a DefaultAction that isn't among the 339// types available at DefaultAction. 340// 341// * Your request references an ARN that is malformed, or corresponds to 342// a resource with which a Web ACL cannot be associated. 343// 344// * WAFDuplicateItemException 345// AWS WAF couldn’t perform the operation because the resource that you tried 346// to save is a duplicate of an existing one. 347// 348// * WAFOptimisticLockException 349// AWS WAF couldn’t save your changes because you tried to update or delete 350// a resource that has changed since you last retrieved it. Get the resource 351// again, make any changes you need to make to the new copy, and retry your 352// operation. 353// 354// * WAFLimitsExceededException 355// AWS WAF couldn’t perform the operation because you exceeded your resource 356// limit. For example, the maximum number of WebACL objects that you can create 357// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 358// in the AWS WAF Developer Guide. 359// 360// * WAFTagOperationException 361// An error occurred during the tagging operation. Retry your request. 362// 363// * WAFTagOperationInternalErrorException 364// AWS WAF couldn’t perform your tagging operation because of an internal 365// error. Retry your request. 366// 367// * WAFInvalidOperationException 368// The operation isn't valid. 369// 370// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateIPSet 371func (c *WAFV2) CreateIPSet(input *CreateIPSetInput) (*CreateIPSetOutput, error) { 372 req, out := c.CreateIPSetRequest(input) 373 return out, req.Send() 374} 375 376// CreateIPSetWithContext is the same as CreateIPSet with the addition of 377// the ability to pass a context and additional request options. 378// 379// See CreateIPSet for details on how to use this API operation. 380// 381// The context must be non-nil and will be used for request cancellation. If 382// the context is nil a panic will occur. In the future the SDK may create 383// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 384// for more information on using Contexts. 385func (c *WAFV2) CreateIPSetWithContext(ctx aws.Context, input *CreateIPSetInput, opts ...request.Option) (*CreateIPSetOutput, error) { 386 req, out := c.CreateIPSetRequest(input) 387 req.SetContext(ctx) 388 req.ApplyOptions(opts...) 389 return out, req.Send() 390} 391 392const opCreateRegexPatternSet = "CreateRegexPatternSet" 393 394// CreateRegexPatternSetRequest generates a "aws/request.Request" representing the 395// client's request for the CreateRegexPatternSet operation. The "output" return 396// value will be populated with the request's response once the request completes 397// successfully. 398// 399// Use "Send" method on the returned Request to send the API call to the service. 400// the "output" return value is not valid until after Send returns without error. 401// 402// See CreateRegexPatternSet for more information on using the CreateRegexPatternSet 403// API call, and error handling. 404// 405// This method is useful when you want to inject custom logic or configuration 406// into the SDK's request lifecycle. Such as custom headers, or retry logic. 407// 408// 409// // Example sending a request using the CreateRegexPatternSetRequest method. 410// req, resp := client.CreateRegexPatternSetRequest(params) 411// 412// err := req.Send() 413// if err == nil { // resp is now filled 414// fmt.Println(resp) 415// } 416// 417// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRegexPatternSet 418func (c *WAFV2) CreateRegexPatternSetRequest(input *CreateRegexPatternSetInput) (req *request.Request, output *CreateRegexPatternSetOutput) { 419 op := &request.Operation{ 420 Name: opCreateRegexPatternSet, 421 HTTPMethod: "POST", 422 HTTPPath: "/", 423 } 424 425 if input == nil { 426 input = &CreateRegexPatternSetInput{} 427 } 428 429 output = &CreateRegexPatternSetOutput{} 430 req = c.newRequest(op, input, output) 431 return 432} 433 434// CreateRegexPatternSet API operation for AWS WAFV2. 435// 436// 437// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 438// 2019. For information, including how to migrate your AWS WAF resources from 439// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 440// 441// Creates a RegexPatternSet, which you reference in a RegexPatternSetReferenceStatement, 442// to have AWS WAF inspect a web request component for the specified patterns. 443// 444// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 445// with awserr.Error's Code and Message methods to get detailed information about 446// the error. 447// 448// See the AWS API reference guide for AWS WAFV2's 449// API operation CreateRegexPatternSet for usage and error information. 450// 451// Returned Error Types: 452// * WAFInternalErrorException 453// Your request is valid, but AWS WAF couldn’t perform the operation because 454// of a system problem. Retry your request. 455// 456// * WAFInvalidParameterException 457// The operation failed because AWS WAF didn't recognize a parameter in the 458// request. For example: 459// 460// * You specified an invalid parameter name or value. 461// 462// * Your nested statement isn't valid. You might have tried to nest a statement 463// that can’t be nested. 464// 465// * You tried to update a WebACL with a DefaultAction that isn't among the 466// types available at DefaultAction. 467// 468// * Your request references an ARN that is malformed, or corresponds to 469// a resource with which a Web ACL cannot be associated. 470// 471// * WAFDuplicateItemException 472// AWS WAF couldn’t perform the operation because the resource that you tried 473// to save is a duplicate of an existing one. 474// 475// * WAFOptimisticLockException 476// AWS WAF couldn’t save your changes because you tried to update or delete 477// a resource that has changed since you last retrieved it. Get the resource 478// again, make any changes you need to make to the new copy, and retry your 479// operation. 480// 481// * WAFLimitsExceededException 482// AWS WAF couldn’t perform the operation because you exceeded your resource 483// limit. For example, the maximum number of WebACL objects that you can create 484// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 485// in the AWS WAF Developer Guide. 486// 487// * WAFTagOperationException 488// An error occurred during the tagging operation. Retry your request. 489// 490// * WAFTagOperationInternalErrorException 491// AWS WAF couldn’t perform your tagging operation because of an internal 492// error. Retry your request. 493// 494// * WAFInvalidOperationException 495// The operation isn't valid. 496// 497// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRegexPatternSet 498func (c *WAFV2) CreateRegexPatternSet(input *CreateRegexPatternSetInput) (*CreateRegexPatternSetOutput, error) { 499 req, out := c.CreateRegexPatternSetRequest(input) 500 return out, req.Send() 501} 502 503// CreateRegexPatternSetWithContext is the same as CreateRegexPatternSet with the addition of 504// the ability to pass a context and additional request options. 505// 506// See CreateRegexPatternSet for details on how to use this API operation. 507// 508// The context must be non-nil and will be used for request cancellation. If 509// the context is nil a panic will occur. In the future the SDK may create 510// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 511// for more information on using Contexts. 512func (c *WAFV2) CreateRegexPatternSetWithContext(ctx aws.Context, input *CreateRegexPatternSetInput, opts ...request.Option) (*CreateRegexPatternSetOutput, error) { 513 req, out := c.CreateRegexPatternSetRequest(input) 514 req.SetContext(ctx) 515 req.ApplyOptions(opts...) 516 return out, req.Send() 517} 518 519const opCreateRuleGroup = "CreateRuleGroup" 520 521// CreateRuleGroupRequest generates a "aws/request.Request" representing the 522// client's request for the CreateRuleGroup operation. The "output" return 523// value will be populated with the request's response once the request completes 524// successfully. 525// 526// Use "Send" method on the returned Request to send the API call to the service. 527// the "output" return value is not valid until after Send returns without error. 528// 529// See CreateRuleGroup for more information on using the CreateRuleGroup 530// API call, and error handling. 531// 532// This method is useful when you want to inject custom logic or configuration 533// into the SDK's request lifecycle. Such as custom headers, or retry logic. 534// 535// 536// // Example sending a request using the CreateRuleGroupRequest method. 537// req, resp := client.CreateRuleGroupRequest(params) 538// 539// err := req.Send() 540// if err == nil { // resp is now filled 541// fmt.Println(resp) 542// } 543// 544// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRuleGroup 545func (c *WAFV2) CreateRuleGroupRequest(input *CreateRuleGroupInput) (req *request.Request, output *CreateRuleGroupOutput) { 546 op := &request.Operation{ 547 Name: opCreateRuleGroup, 548 HTTPMethod: "POST", 549 HTTPPath: "/", 550 } 551 552 if input == nil { 553 input = &CreateRuleGroupInput{} 554 } 555 556 output = &CreateRuleGroupOutput{} 557 req = c.newRequest(op, input, output) 558 return 559} 560 561// CreateRuleGroup API operation for AWS WAFV2. 562// 563// 564// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 565// 2019. For information, including how to migrate your AWS WAF resources from 566// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 567// 568// Creates a RuleGroup per the specifications provided. 569// 570// A rule group defines a collection of rules to inspect and control web requests 571// that you can use in a WebACL. When you create a rule group, you define an 572// immutable capacity limit. If you update a rule group, you must stay within 573// the capacity. This allows others to reuse the rule group with confidence 574// in its capacity requirements. 575// 576// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 577// with awserr.Error's Code and Message methods to get detailed information about 578// the error. 579// 580// See the AWS API reference guide for AWS WAFV2's 581// API operation CreateRuleGroup for usage and error information. 582// 583// Returned Error Types: 584// * WAFInternalErrorException 585// Your request is valid, but AWS WAF couldn’t perform the operation because 586// of a system problem. Retry your request. 587// 588// * WAFInvalidParameterException 589// The operation failed because AWS WAF didn't recognize a parameter in the 590// request. For example: 591// 592// * You specified an invalid parameter name or value. 593// 594// * Your nested statement isn't valid. You might have tried to nest a statement 595// that can’t be nested. 596// 597// * You tried to update a WebACL with a DefaultAction that isn't among the 598// types available at DefaultAction. 599// 600// * Your request references an ARN that is malformed, or corresponds to 601// a resource with which a Web ACL cannot be associated. 602// 603// * WAFDuplicateItemException 604// AWS WAF couldn’t perform the operation because the resource that you tried 605// to save is a duplicate of an existing one. 606// 607// * WAFOptimisticLockException 608// AWS WAF couldn’t save your changes because you tried to update or delete 609// a resource that has changed since you last retrieved it. Get the resource 610// again, make any changes you need to make to the new copy, and retry your 611// operation. 612// 613// * WAFLimitsExceededException 614// AWS WAF couldn’t perform the operation because you exceeded your resource 615// limit. For example, the maximum number of WebACL objects that you can create 616// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 617// in the AWS WAF Developer Guide. 618// 619// * WAFUnavailableEntityException 620// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 621// 622// * WAFTagOperationException 623// An error occurred during the tagging operation. Retry your request. 624// 625// * WAFTagOperationInternalErrorException 626// AWS WAF couldn’t perform your tagging operation because of an internal 627// error. Retry your request. 628// 629// * WAFSubscriptionNotFoundException 630// 631// * WAFNonexistentItemException 632// AWS WAF couldn’t perform the operation because your resource doesn’t 633// exist. 634// 635// * WAFInvalidOperationException 636// The operation isn't valid. 637// 638// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateRuleGroup 639func (c *WAFV2) CreateRuleGroup(input *CreateRuleGroupInput) (*CreateRuleGroupOutput, error) { 640 req, out := c.CreateRuleGroupRequest(input) 641 return out, req.Send() 642} 643 644// CreateRuleGroupWithContext is the same as CreateRuleGroup with the addition of 645// the ability to pass a context and additional request options. 646// 647// See CreateRuleGroup for details on how to use this API operation. 648// 649// The context must be non-nil and will be used for request cancellation. If 650// the context is nil a panic will occur. In the future the SDK may create 651// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 652// for more information on using Contexts. 653func (c *WAFV2) CreateRuleGroupWithContext(ctx aws.Context, input *CreateRuleGroupInput, opts ...request.Option) (*CreateRuleGroupOutput, error) { 654 req, out := c.CreateRuleGroupRequest(input) 655 req.SetContext(ctx) 656 req.ApplyOptions(opts...) 657 return out, req.Send() 658} 659 660const opCreateWebACL = "CreateWebACL" 661 662// CreateWebACLRequest generates a "aws/request.Request" representing the 663// client's request for the CreateWebACL operation. The "output" return 664// value will be populated with the request's response once the request completes 665// successfully. 666// 667// Use "Send" method on the returned Request to send the API call to the service. 668// the "output" return value is not valid until after Send returns without error. 669// 670// See CreateWebACL for more information on using the CreateWebACL 671// API call, and error handling. 672// 673// This method is useful when you want to inject custom logic or configuration 674// into the SDK's request lifecycle. Such as custom headers, or retry logic. 675// 676// 677// // Example sending a request using the CreateWebACLRequest method. 678// req, resp := client.CreateWebACLRequest(params) 679// 680// err := req.Send() 681// if err == nil { // resp is now filled 682// fmt.Println(resp) 683// } 684// 685// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateWebACL 686func (c *WAFV2) CreateWebACLRequest(input *CreateWebACLInput) (req *request.Request, output *CreateWebACLOutput) { 687 op := &request.Operation{ 688 Name: opCreateWebACL, 689 HTTPMethod: "POST", 690 HTTPPath: "/", 691 } 692 693 if input == nil { 694 input = &CreateWebACLInput{} 695 } 696 697 output = &CreateWebACLOutput{} 698 req = c.newRequest(op, input, output) 699 return 700} 701 702// CreateWebACL API operation for AWS WAFV2. 703// 704// 705// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 706// 2019. For information, including how to migrate your AWS WAF resources from 707// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 708// 709// Creates a WebACL per the specifications provided. 710// 711// A Web ACL defines a collection of rules to use to inspect and control web 712// requests. Each rule has an action defined (allow, block, or count) for requests 713// that match the statement of the rule. In the Web ACL, you assign a default 714// action to take (allow, block) for any request that does not match any of 715// the rules. The rules in a Web ACL can be a combination of the types Rule, 716// RuleGroup, and managed rule group. You can associate a Web ACL with one or 717// more AWS resources to protect. The resources can be Amazon CloudFront, an 718// Amazon API Gateway REST API, an Application Load Balancer, or an AWS AppSync 719// GraphQL API. 720// 721// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 722// with awserr.Error's Code and Message methods to get detailed information about 723// the error. 724// 725// See the AWS API reference guide for AWS WAFV2's 726// API operation CreateWebACL for usage and error information. 727// 728// Returned Error Types: 729// * WAFInternalErrorException 730// Your request is valid, but AWS WAF couldn’t perform the operation because 731// of a system problem. Retry your request. 732// 733// * WAFInvalidParameterException 734// The operation failed because AWS WAF didn't recognize a parameter in the 735// request. For example: 736// 737// * You specified an invalid parameter name or value. 738// 739// * Your nested statement isn't valid. You might have tried to nest a statement 740// that can’t be nested. 741// 742// * You tried to update a WebACL with a DefaultAction that isn't among the 743// types available at DefaultAction. 744// 745// * Your request references an ARN that is malformed, or corresponds to 746// a resource with which a Web ACL cannot be associated. 747// 748// * WAFDuplicateItemException 749// AWS WAF couldn’t perform the operation because the resource that you tried 750// to save is a duplicate of an existing one. 751// 752// * WAFOptimisticLockException 753// AWS WAF couldn’t save your changes because you tried to update or delete 754// a resource that has changed since you last retrieved it. Get the resource 755// again, make any changes you need to make to the new copy, and retry your 756// operation. 757// 758// * WAFLimitsExceededException 759// AWS WAF couldn’t perform the operation because you exceeded your resource 760// limit. For example, the maximum number of WebACL objects that you can create 761// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 762// in the AWS WAF Developer Guide. 763// 764// * WAFInvalidResourceException 765// AWS WAF couldn’t perform the operation because the resource that you requested 766// isn’t valid. Check the resource, and try again. 767// 768// * WAFUnavailableEntityException 769// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 770// 771// * WAFNonexistentItemException 772// AWS WAF couldn’t perform the operation because your resource doesn’t 773// exist. 774// 775// * WAFTagOperationException 776// An error occurred during the tagging operation. Retry your request. 777// 778// * WAFTagOperationInternalErrorException 779// AWS WAF couldn’t perform your tagging operation because of an internal 780// error. Retry your request. 781// 782// * WAFSubscriptionNotFoundException 783// 784// * WAFInvalidOperationException 785// The operation isn't valid. 786// 787// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/CreateWebACL 788func (c *WAFV2) CreateWebACL(input *CreateWebACLInput) (*CreateWebACLOutput, error) { 789 req, out := c.CreateWebACLRequest(input) 790 return out, req.Send() 791} 792 793// CreateWebACLWithContext is the same as CreateWebACL with the addition of 794// the ability to pass a context and additional request options. 795// 796// See CreateWebACL for details on how to use this API operation. 797// 798// The context must be non-nil and will be used for request cancellation. If 799// the context is nil a panic will occur. In the future the SDK may create 800// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 801// for more information on using Contexts. 802func (c *WAFV2) CreateWebACLWithContext(ctx aws.Context, input *CreateWebACLInput, opts ...request.Option) (*CreateWebACLOutput, error) { 803 req, out := c.CreateWebACLRequest(input) 804 req.SetContext(ctx) 805 req.ApplyOptions(opts...) 806 return out, req.Send() 807} 808 809const opDeleteFirewallManagerRuleGroups = "DeleteFirewallManagerRuleGroups" 810 811// DeleteFirewallManagerRuleGroupsRequest generates a "aws/request.Request" representing the 812// client's request for the DeleteFirewallManagerRuleGroups operation. The "output" return 813// value will be populated with the request's response once the request completes 814// successfully. 815// 816// Use "Send" method on the returned Request to send the API call to the service. 817// the "output" return value is not valid until after Send returns without error. 818// 819// See DeleteFirewallManagerRuleGroups for more information on using the DeleteFirewallManagerRuleGroups 820// API call, and error handling. 821// 822// This method is useful when you want to inject custom logic or configuration 823// into the SDK's request lifecycle. Such as custom headers, or retry logic. 824// 825// 826// // Example sending a request using the DeleteFirewallManagerRuleGroupsRequest method. 827// req, resp := client.DeleteFirewallManagerRuleGroupsRequest(params) 828// 829// err := req.Send() 830// if err == nil { // resp is now filled 831// fmt.Println(resp) 832// } 833// 834// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteFirewallManagerRuleGroups 835func (c *WAFV2) DeleteFirewallManagerRuleGroupsRequest(input *DeleteFirewallManagerRuleGroupsInput) (req *request.Request, output *DeleteFirewallManagerRuleGroupsOutput) { 836 op := &request.Operation{ 837 Name: opDeleteFirewallManagerRuleGroups, 838 HTTPMethod: "POST", 839 HTTPPath: "/", 840 } 841 842 if input == nil { 843 input = &DeleteFirewallManagerRuleGroupsInput{} 844 } 845 846 output = &DeleteFirewallManagerRuleGroupsOutput{} 847 req = c.newRequest(op, input, output) 848 return 849} 850 851// DeleteFirewallManagerRuleGroups API operation for AWS WAFV2. 852// 853// Deletes all rule groups that are managed by AWS Firewall Manager for the 854// specified web ACL. 855// 856// You can only use this if ManagedByFirewallManager is false in the specified 857// WebACL. 858// 859// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 860// with awserr.Error's Code and Message methods to get detailed information about 861// the error. 862// 863// See the AWS API reference guide for AWS WAFV2's 864// API operation DeleteFirewallManagerRuleGroups for usage and error information. 865// 866// Returned Error Types: 867// * WAFInternalErrorException 868// Your request is valid, but AWS WAF couldn’t perform the operation because 869// of a system problem. Retry your request. 870// 871// * WAFInvalidParameterException 872// The operation failed because AWS WAF didn't recognize a parameter in the 873// request. For example: 874// 875// * You specified an invalid parameter name or value. 876// 877// * Your nested statement isn't valid. You might have tried to nest a statement 878// that can’t be nested. 879// 880// * You tried to update a WebACL with a DefaultAction that isn't among the 881// types available at DefaultAction. 882// 883// * Your request references an ARN that is malformed, or corresponds to 884// a resource with which a Web ACL cannot be associated. 885// 886// * WAFNonexistentItemException 887// AWS WAF couldn’t perform the operation because your resource doesn’t 888// exist. 889// 890// * WAFOptimisticLockException 891// AWS WAF couldn’t save your changes because you tried to update or delete 892// a resource that has changed since you last retrieved it. Get the resource 893// again, make any changes you need to make to the new copy, and retry your 894// operation. 895// 896// * WAFInvalidOperationException 897// The operation isn't valid. 898// 899// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteFirewallManagerRuleGroups 900func (c *WAFV2) DeleteFirewallManagerRuleGroups(input *DeleteFirewallManagerRuleGroupsInput) (*DeleteFirewallManagerRuleGroupsOutput, error) { 901 req, out := c.DeleteFirewallManagerRuleGroupsRequest(input) 902 return out, req.Send() 903} 904 905// DeleteFirewallManagerRuleGroupsWithContext is the same as DeleteFirewallManagerRuleGroups with the addition of 906// the ability to pass a context and additional request options. 907// 908// See DeleteFirewallManagerRuleGroups for details on how to use this API operation. 909// 910// The context must be non-nil and will be used for request cancellation. If 911// the context is nil a panic will occur. In the future the SDK may create 912// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 913// for more information on using Contexts. 914func (c *WAFV2) DeleteFirewallManagerRuleGroupsWithContext(ctx aws.Context, input *DeleteFirewallManagerRuleGroupsInput, opts ...request.Option) (*DeleteFirewallManagerRuleGroupsOutput, error) { 915 req, out := c.DeleteFirewallManagerRuleGroupsRequest(input) 916 req.SetContext(ctx) 917 req.ApplyOptions(opts...) 918 return out, req.Send() 919} 920 921const opDeleteIPSet = "DeleteIPSet" 922 923// DeleteIPSetRequest generates a "aws/request.Request" representing the 924// client's request for the DeleteIPSet operation. The "output" return 925// value will be populated with the request's response once the request completes 926// successfully. 927// 928// Use "Send" method on the returned Request to send the API call to the service. 929// the "output" return value is not valid until after Send returns without error. 930// 931// See DeleteIPSet for more information on using the DeleteIPSet 932// API call, and error handling. 933// 934// This method is useful when you want to inject custom logic or configuration 935// into the SDK's request lifecycle. Such as custom headers, or retry logic. 936// 937// 938// // Example sending a request using the DeleteIPSetRequest method. 939// req, resp := client.DeleteIPSetRequest(params) 940// 941// err := req.Send() 942// if err == nil { // resp is now filled 943// fmt.Println(resp) 944// } 945// 946// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteIPSet 947func (c *WAFV2) DeleteIPSetRequest(input *DeleteIPSetInput) (req *request.Request, output *DeleteIPSetOutput) { 948 op := &request.Operation{ 949 Name: opDeleteIPSet, 950 HTTPMethod: "POST", 951 HTTPPath: "/", 952 } 953 954 if input == nil { 955 input = &DeleteIPSetInput{} 956 } 957 958 output = &DeleteIPSetOutput{} 959 req = c.newRequest(op, input, output) 960 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 961 return 962} 963 964// DeleteIPSet API operation for AWS WAFV2. 965// 966// 967// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 968// 2019. For information, including how to migrate your AWS WAF resources from 969// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 970// 971// Deletes the specified IPSet. 972// 973// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 974// with awserr.Error's Code and Message methods to get detailed information about 975// the error. 976// 977// See the AWS API reference guide for AWS WAFV2's 978// API operation DeleteIPSet for usage and error information. 979// 980// Returned Error Types: 981// * WAFInternalErrorException 982// Your request is valid, but AWS WAF couldn’t perform the operation because 983// of a system problem. Retry your request. 984// 985// * WAFInvalidParameterException 986// The operation failed because AWS WAF didn't recognize a parameter in the 987// request. For example: 988// 989// * You specified an invalid parameter name or value. 990// 991// * Your nested statement isn't valid. You might have tried to nest a statement 992// that can’t be nested. 993// 994// * You tried to update a WebACL with a DefaultAction that isn't among the 995// types available at DefaultAction. 996// 997// * Your request references an ARN that is malformed, or corresponds to 998// a resource with which a Web ACL cannot be associated. 999// 1000// * WAFNonexistentItemException 1001// AWS WAF couldn’t perform the operation because your resource doesn’t 1002// exist. 1003// 1004// * WAFOptimisticLockException 1005// AWS WAF couldn’t save your changes because you tried to update or delete 1006// a resource that has changed since you last retrieved it. Get the resource 1007// again, make any changes you need to make to the new copy, and retry your 1008// operation. 1009// 1010// * WAFAssociatedItemException 1011// AWS WAF couldn’t perform the operation because your resource is being used 1012// by another resource or it’s associated with another resource. 1013// 1014// * WAFTagOperationException 1015// An error occurred during the tagging operation. Retry your request. 1016// 1017// * WAFTagOperationInternalErrorException 1018// AWS WAF couldn’t perform your tagging operation because of an internal 1019// error. Retry your request. 1020// 1021// * WAFInvalidOperationException 1022// The operation isn't valid. 1023// 1024// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteIPSet 1025func (c *WAFV2) DeleteIPSet(input *DeleteIPSetInput) (*DeleteIPSetOutput, error) { 1026 req, out := c.DeleteIPSetRequest(input) 1027 return out, req.Send() 1028} 1029 1030// DeleteIPSetWithContext is the same as DeleteIPSet with the addition of 1031// the ability to pass a context and additional request options. 1032// 1033// See DeleteIPSet for details on how to use this API operation. 1034// 1035// The context must be non-nil and will be used for request cancellation. If 1036// the context is nil a panic will occur. In the future the SDK may create 1037// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1038// for more information on using Contexts. 1039func (c *WAFV2) DeleteIPSetWithContext(ctx aws.Context, input *DeleteIPSetInput, opts ...request.Option) (*DeleteIPSetOutput, error) { 1040 req, out := c.DeleteIPSetRequest(input) 1041 req.SetContext(ctx) 1042 req.ApplyOptions(opts...) 1043 return out, req.Send() 1044} 1045 1046const opDeleteLoggingConfiguration = "DeleteLoggingConfiguration" 1047 1048// DeleteLoggingConfigurationRequest generates a "aws/request.Request" representing the 1049// client's request for the DeleteLoggingConfiguration operation. The "output" return 1050// value will be populated with the request's response once the request completes 1051// successfully. 1052// 1053// Use "Send" method on the returned Request to send the API call to the service. 1054// the "output" return value is not valid until after Send returns without error. 1055// 1056// See DeleteLoggingConfiguration for more information on using the DeleteLoggingConfiguration 1057// API call, and error handling. 1058// 1059// This method is useful when you want to inject custom logic or configuration 1060// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1061// 1062// 1063// // Example sending a request using the DeleteLoggingConfigurationRequest method. 1064// req, resp := client.DeleteLoggingConfigurationRequest(params) 1065// 1066// err := req.Send() 1067// if err == nil { // resp is now filled 1068// fmt.Println(resp) 1069// } 1070// 1071// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteLoggingConfiguration 1072func (c *WAFV2) DeleteLoggingConfigurationRequest(input *DeleteLoggingConfigurationInput) (req *request.Request, output *DeleteLoggingConfigurationOutput) { 1073 op := &request.Operation{ 1074 Name: opDeleteLoggingConfiguration, 1075 HTTPMethod: "POST", 1076 HTTPPath: "/", 1077 } 1078 1079 if input == nil { 1080 input = &DeleteLoggingConfigurationInput{} 1081 } 1082 1083 output = &DeleteLoggingConfigurationOutput{} 1084 req = c.newRequest(op, input, output) 1085 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1086 return 1087} 1088 1089// DeleteLoggingConfiguration API operation for AWS WAFV2. 1090// 1091// 1092// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1093// 2019. For information, including how to migrate your AWS WAF resources from 1094// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1095// 1096// Deletes the LoggingConfiguration from the specified web ACL. 1097// 1098// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1099// with awserr.Error's Code and Message methods to get detailed information about 1100// the error. 1101// 1102// See the AWS API reference guide for AWS WAFV2's 1103// API operation DeleteLoggingConfiguration for usage and error information. 1104// 1105// Returned Error Types: 1106// * WAFInternalErrorException 1107// Your request is valid, but AWS WAF couldn’t perform the operation because 1108// of a system problem. Retry your request. 1109// 1110// * WAFNonexistentItemException 1111// AWS WAF couldn’t perform the operation because your resource doesn’t 1112// exist. 1113// 1114// * WAFOptimisticLockException 1115// AWS WAF couldn’t save your changes because you tried to update or delete 1116// a resource that has changed since you last retrieved it. Get the resource 1117// again, make any changes you need to make to the new copy, and retry your 1118// operation. 1119// 1120// * WAFInvalidParameterException 1121// The operation failed because AWS WAF didn't recognize a parameter in the 1122// request. For example: 1123// 1124// * You specified an invalid parameter name or value. 1125// 1126// * Your nested statement isn't valid. You might have tried to nest a statement 1127// that can’t be nested. 1128// 1129// * You tried to update a WebACL with a DefaultAction that isn't among the 1130// types available at DefaultAction. 1131// 1132// * Your request references an ARN that is malformed, or corresponds to 1133// a resource with which a Web ACL cannot be associated. 1134// 1135// * WAFInvalidOperationException 1136// The operation isn't valid. 1137// 1138// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteLoggingConfiguration 1139func (c *WAFV2) DeleteLoggingConfiguration(input *DeleteLoggingConfigurationInput) (*DeleteLoggingConfigurationOutput, error) { 1140 req, out := c.DeleteLoggingConfigurationRequest(input) 1141 return out, req.Send() 1142} 1143 1144// DeleteLoggingConfigurationWithContext is the same as DeleteLoggingConfiguration with the addition of 1145// the ability to pass a context and additional request options. 1146// 1147// See DeleteLoggingConfiguration for details on how to use this API operation. 1148// 1149// The context must be non-nil and will be used for request cancellation. If 1150// the context is nil a panic will occur. In the future the SDK may create 1151// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1152// for more information on using Contexts. 1153func (c *WAFV2) DeleteLoggingConfigurationWithContext(ctx aws.Context, input *DeleteLoggingConfigurationInput, opts ...request.Option) (*DeleteLoggingConfigurationOutput, error) { 1154 req, out := c.DeleteLoggingConfigurationRequest(input) 1155 req.SetContext(ctx) 1156 req.ApplyOptions(opts...) 1157 return out, req.Send() 1158} 1159 1160const opDeletePermissionPolicy = "DeletePermissionPolicy" 1161 1162// DeletePermissionPolicyRequest generates a "aws/request.Request" representing the 1163// client's request for the DeletePermissionPolicy operation. The "output" return 1164// value will be populated with the request's response once the request completes 1165// successfully. 1166// 1167// Use "Send" method on the returned Request to send the API call to the service. 1168// the "output" return value is not valid until after Send returns without error. 1169// 1170// See DeletePermissionPolicy for more information on using the DeletePermissionPolicy 1171// API call, and error handling. 1172// 1173// This method is useful when you want to inject custom logic or configuration 1174// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1175// 1176// 1177// // Example sending a request using the DeletePermissionPolicyRequest method. 1178// req, resp := client.DeletePermissionPolicyRequest(params) 1179// 1180// err := req.Send() 1181// if err == nil { // resp is now filled 1182// fmt.Println(resp) 1183// } 1184// 1185// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeletePermissionPolicy 1186func (c *WAFV2) DeletePermissionPolicyRequest(input *DeletePermissionPolicyInput) (req *request.Request, output *DeletePermissionPolicyOutput) { 1187 op := &request.Operation{ 1188 Name: opDeletePermissionPolicy, 1189 HTTPMethod: "POST", 1190 HTTPPath: "/", 1191 } 1192 1193 if input == nil { 1194 input = &DeletePermissionPolicyInput{} 1195 } 1196 1197 output = &DeletePermissionPolicyOutput{} 1198 req = c.newRequest(op, input, output) 1199 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1200 return 1201} 1202 1203// DeletePermissionPolicy API operation for AWS WAFV2. 1204// 1205// Permanently deletes an IAM policy from the specified rule group. 1206// 1207// You must be the owner of the rule group to perform this operation. 1208// 1209// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1210// with awserr.Error's Code and Message methods to get detailed information about 1211// the error. 1212// 1213// See the AWS API reference guide for AWS WAFV2's 1214// API operation DeletePermissionPolicy for usage and error information. 1215// 1216// Returned Error Types: 1217// * WAFNonexistentItemException 1218// AWS WAF couldn’t perform the operation because your resource doesn’t 1219// exist. 1220// 1221// * WAFInternalErrorException 1222// Your request is valid, but AWS WAF couldn’t perform the operation because 1223// of a system problem. Retry your request. 1224// 1225// * WAFInvalidParameterException 1226// The operation failed because AWS WAF didn't recognize a parameter in the 1227// request. For example: 1228// 1229// * You specified an invalid parameter name or value. 1230// 1231// * Your nested statement isn't valid. You might have tried to nest a statement 1232// that can’t be nested. 1233// 1234// * You tried to update a WebACL with a DefaultAction that isn't among the 1235// types available at DefaultAction. 1236// 1237// * Your request references an ARN that is malformed, or corresponds to 1238// a resource with which a Web ACL cannot be associated. 1239// 1240// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeletePermissionPolicy 1241func (c *WAFV2) DeletePermissionPolicy(input *DeletePermissionPolicyInput) (*DeletePermissionPolicyOutput, error) { 1242 req, out := c.DeletePermissionPolicyRequest(input) 1243 return out, req.Send() 1244} 1245 1246// DeletePermissionPolicyWithContext is the same as DeletePermissionPolicy with the addition of 1247// the ability to pass a context and additional request options. 1248// 1249// See DeletePermissionPolicy for details on how to use this API operation. 1250// 1251// The context must be non-nil and will be used for request cancellation. If 1252// the context is nil a panic will occur. In the future the SDK may create 1253// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1254// for more information on using Contexts. 1255func (c *WAFV2) DeletePermissionPolicyWithContext(ctx aws.Context, input *DeletePermissionPolicyInput, opts ...request.Option) (*DeletePermissionPolicyOutput, error) { 1256 req, out := c.DeletePermissionPolicyRequest(input) 1257 req.SetContext(ctx) 1258 req.ApplyOptions(opts...) 1259 return out, req.Send() 1260} 1261 1262const opDeleteRegexPatternSet = "DeleteRegexPatternSet" 1263 1264// DeleteRegexPatternSetRequest generates a "aws/request.Request" representing the 1265// client's request for the DeleteRegexPatternSet operation. The "output" return 1266// value will be populated with the request's response once the request completes 1267// successfully. 1268// 1269// Use "Send" method on the returned Request to send the API call to the service. 1270// the "output" return value is not valid until after Send returns without error. 1271// 1272// See DeleteRegexPatternSet for more information on using the DeleteRegexPatternSet 1273// API call, and error handling. 1274// 1275// This method is useful when you want to inject custom logic or configuration 1276// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1277// 1278// 1279// // Example sending a request using the DeleteRegexPatternSetRequest method. 1280// req, resp := client.DeleteRegexPatternSetRequest(params) 1281// 1282// err := req.Send() 1283// if err == nil { // resp is now filled 1284// fmt.Println(resp) 1285// } 1286// 1287// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRegexPatternSet 1288func (c *WAFV2) DeleteRegexPatternSetRequest(input *DeleteRegexPatternSetInput) (req *request.Request, output *DeleteRegexPatternSetOutput) { 1289 op := &request.Operation{ 1290 Name: opDeleteRegexPatternSet, 1291 HTTPMethod: "POST", 1292 HTTPPath: "/", 1293 } 1294 1295 if input == nil { 1296 input = &DeleteRegexPatternSetInput{} 1297 } 1298 1299 output = &DeleteRegexPatternSetOutput{} 1300 req = c.newRequest(op, input, output) 1301 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1302 return 1303} 1304 1305// DeleteRegexPatternSet API operation for AWS WAFV2. 1306// 1307// 1308// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1309// 2019. For information, including how to migrate your AWS WAF resources from 1310// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1311// 1312// Deletes the specified RegexPatternSet. 1313// 1314// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1315// with awserr.Error's Code and Message methods to get detailed information about 1316// the error. 1317// 1318// See the AWS API reference guide for AWS WAFV2's 1319// API operation DeleteRegexPatternSet for usage and error information. 1320// 1321// Returned Error Types: 1322// * WAFInternalErrorException 1323// Your request is valid, but AWS WAF couldn’t perform the operation because 1324// of a system problem. Retry your request. 1325// 1326// * WAFInvalidParameterException 1327// The operation failed because AWS WAF didn't recognize a parameter in the 1328// request. For example: 1329// 1330// * You specified an invalid parameter name or value. 1331// 1332// * Your nested statement isn't valid. You might have tried to nest a statement 1333// that can’t be nested. 1334// 1335// * You tried to update a WebACL with a DefaultAction that isn't among the 1336// types available at DefaultAction. 1337// 1338// * Your request references an ARN that is malformed, or corresponds to 1339// a resource with which a Web ACL cannot be associated. 1340// 1341// * WAFNonexistentItemException 1342// AWS WAF couldn’t perform the operation because your resource doesn’t 1343// exist. 1344// 1345// * WAFOptimisticLockException 1346// AWS WAF couldn’t save your changes because you tried to update or delete 1347// a resource that has changed since you last retrieved it. Get the resource 1348// again, make any changes you need to make to the new copy, and retry your 1349// operation. 1350// 1351// * WAFAssociatedItemException 1352// AWS WAF couldn’t perform the operation because your resource is being used 1353// by another resource or it’s associated with another resource. 1354// 1355// * WAFTagOperationException 1356// An error occurred during the tagging operation. Retry your request. 1357// 1358// * WAFTagOperationInternalErrorException 1359// AWS WAF couldn’t perform your tagging operation because of an internal 1360// error. Retry your request. 1361// 1362// * WAFInvalidOperationException 1363// The operation isn't valid. 1364// 1365// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRegexPatternSet 1366func (c *WAFV2) DeleteRegexPatternSet(input *DeleteRegexPatternSetInput) (*DeleteRegexPatternSetOutput, error) { 1367 req, out := c.DeleteRegexPatternSetRequest(input) 1368 return out, req.Send() 1369} 1370 1371// DeleteRegexPatternSetWithContext is the same as DeleteRegexPatternSet with the addition of 1372// the ability to pass a context and additional request options. 1373// 1374// See DeleteRegexPatternSet for details on how to use this API operation. 1375// 1376// The context must be non-nil and will be used for request cancellation. If 1377// the context is nil a panic will occur. In the future the SDK may create 1378// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1379// for more information on using Contexts. 1380func (c *WAFV2) DeleteRegexPatternSetWithContext(ctx aws.Context, input *DeleteRegexPatternSetInput, opts ...request.Option) (*DeleteRegexPatternSetOutput, error) { 1381 req, out := c.DeleteRegexPatternSetRequest(input) 1382 req.SetContext(ctx) 1383 req.ApplyOptions(opts...) 1384 return out, req.Send() 1385} 1386 1387const opDeleteRuleGroup = "DeleteRuleGroup" 1388 1389// DeleteRuleGroupRequest generates a "aws/request.Request" representing the 1390// client's request for the DeleteRuleGroup operation. The "output" return 1391// value will be populated with the request's response once the request completes 1392// successfully. 1393// 1394// Use "Send" method on the returned Request to send the API call to the service. 1395// the "output" return value is not valid until after Send returns without error. 1396// 1397// See DeleteRuleGroup for more information on using the DeleteRuleGroup 1398// API call, and error handling. 1399// 1400// This method is useful when you want to inject custom logic or configuration 1401// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1402// 1403// 1404// // Example sending a request using the DeleteRuleGroupRequest method. 1405// req, resp := client.DeleteRuleGroupRequest(params) 1406// 1407// err := req.Send() 1408// if err == nil { // resp is now filled 1409// fmt.Println(resp) 1410// } 1411// 1412// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRuleGroup 1413func (c *WAFV2) DeleteRuleGroupRequest(input *DeleteRuleGroupInput) (req *request.Request, output *DeleteRuleGroupOutput) { 1414 op := &request.Operation{ 1415 Name: opDeleteRuleGroup, 1416 HTTPMethod: "POST", 1417 HTTPPath: "/", 1418 } 1419 1420 if input == nil { 1421 input = &DeleteRuleGroupInput{} 1422 } 1423 1424 output = &DeleteRuleGroupOutput{} 1425 req = c.newRequest(op, input, output) 1426 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1427 return 1428} 1429 1430// DeleteRuleGroup API operation for AWS WAFV2. 1431// 1432// 1433// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1434// 2019. For information, including how to migrate your AWS WAF resources from 1435// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1436// 1437// Deletes the specified RuleGroup. 1438// 1439// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1440// with awserr.Error's Code and Message methods to get detailed information about 1441// the error. 1442// 1443// See the AWS API reference guide for AWS WAFV2's 1444// API operation DeleteRuleGroup for usage and error information. 1445// 1446// Returned Error Types: 1447// * WAFInternalErrorException 1448// Your request is valid, but AWS WAF couldn’t perform the operation because 1449// of a system problem. Retry your request. 1450// 1451// * WAFInvalidParameterException 1452// The operation failed because AWS WAF didn't recognize a parameter in the 1453// request. For example: 1454// 1455// * You specified an invalid parameter name or value. 1456// 1457// * Your nested statement isn't valid. You might have tried to nest a statement 1458// that can’t be nested. 1459// 1460// * You tried to update a WebACL with a DefaultAction that isn't among the 1461// types available at DefaultAction. 1462// 1463// * Your request references an ARN that is malformed, or corresponds to 1464// a resource with which a Web ACL cannot be associated. 1465// 1466// * WAFNonexistentItemException 1467// AWS WAF couldn’t perform the operation because your resource doesn’t 1468// exist. 1469// 1470// * WAFOptimisticLockException 1471// AWS WAF couldn’t save your changes because you tried to update or delete 1472// a resource that has changed since you last retrieved it. Get the resource 1473// again, make any changes you need to make to the new copy, and retry your 1474// operation. 1475// 1476// * WAFAssociatedItemException 1477// AWS WAF couldn’t perform the operation because your resource is being used 1478// by another resource or it’s associated with another resource. 1479// 1480// * WAFTagOperationException 1481// An error occurred during the tagging operation. Retry your request. 1482// 1483// * WAFTagOperationInternalErrorException 1484// AWS WAF couldn’t perform your tagging operation because of an internal 1485// error. Retry your request. 1486// 1487// * WAFInvalidOperationException 1488// The operation isn't valid. 1489// 1490// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteRuleGroup 1491func (c *WAFV2) DeleteRuleGroup(input *DeleteRuleGroupInput) (*DeleteRuleGroupOutput, error) { 1492 req, out := c.DeleteRuleGroupRequest(input) 1493 return out, req.Send() 1494} 1495 1496// DeleteRuleGroupWithContext is the same as DeleteRuleGroup with the addition of 1497// the ability to pass a context and additional request options. 1498// 1499// See DeleteRuleGroup for details on how to use this API operation. 1500// 1501// The context must be non-nil and will be used for request cancellation. If 1502// the context is nil a panic will occur. In the future the SDK may create 1503// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1504// for more information on using Contexts. 1505func (c *WAFV2) DeleteRuleGroupWithContext(ctx aws.Context, input *DeleteRuleGroupInput, opts ...request.Option) (*DeleteRuleGroupOutput, error) { 1506 req, out := c.DeleteRuleGroupRequest(input) 1507 req.SetContext(ctx) 1508 req.ApplyOptions(opts...) 1509 return out, req.Send() 1510} 1511 1512const opDeleteWebACL = "DeleteWebACL" 1513 1514// DeleteWebACLRequest generates a "aws/request.Request" representing the 1515// client's request for the DeleteWebACL operation. The "output" return 1516// value will be populated with the request's response once the request completes 1517// successfully. 1518// 1519// Use "Send" method on the returned Request to send the API call to the service. 1520// the "output" return value is not valid until after Send returns without error. 1521// 1522// See DeleteWebACL for more information on using the DeleteWebACL 1523// API call, and error handling. 1524// 1525// This method is useful when you want to inject custom logic or configuration 1526// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1527// 1528// 1529// // Example sending a request using the DeleteWebACLRequest method. 1530// req, resp := client.DeleteWebACLRequest(params) 1531// 1532// err := req.Send() 1533// if err == nil { // resp is now filled 1534// fmt.Println(resp) 1535// } 1536// 1537// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteWebACL 1538func (c *WAFV2) DeleteWebACLRequest(input *DeleteWebACLInput) (req *request.Request, output *DeleteWebACLOutput) { 1539 op := &request.Operation{ 1540 Name: opDeleteWebACL, 1541 HTTPMethod: "POST", 1542 HTTPPath: "/", 1543 } 1544 1545 if input == nil { 1546 input = &DeleteWebACLInput{} 1547 } 1548 1549 output = &DeleteWebACLOutput{} 1550 req = c.newRequest(op, input, output) 1551 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1552 return 1553} 1554 1555// DeleteWebACL API operation for AWS WAFV2. 1556// 1557// 1558// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1559// 2019. For information, including how to migrate your AWS WAF resources from 1560// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1561// 1562// Deletes the specified WebACL. 1563// 1564// You can only use this if ManagedByFirewallManager is false in the specified 1565// WebACL. 1566// 1567// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1568// with awserr.Error's Code and Message methods to get detailed information about 1569// the error. 1570// 1571// See the AWS API reference guide for AWS WAFV2's 1572// API operation DeleteWebACL for usage and error information. 1573// 1574// Returned Error Types: 1575// * WAFInternalErrorException 1576// Your request is valid, but AWS WAF couldn’t perform the operation because 1577// of a system problem. Retry your request. 1578// 1579// * WAFInvalidParameterException 1580// The operation failed because AWS WAF didn't recognize a parameter in the 1581// request. For example: 1582// 1583// * You specified an invalid parameter name or value. 1584// 1585// * Your nested statement isn't valid. You might have tried to nest a statement 1586// that can’t be nested. 1587// 1588// * You tried to update a WebACL with a DefaultAction that isn't among the 1589// types available at DefaultAction. 1590// 1591// * Your request references an ARN that is malformed, or corresponds to 1592// a resource with which a Web ACL cannot be associated. 1593// 1594// * WAFNonexistentItemException 1595// AWS WAF couldn’t perform the operation because your resource doesn’t 1596// exist. 1597// 1598// * WAFOptimisticLockException 1599// AWS WAF couldn’t save your changes because you tried to update or delete 1600// a resource that has changed since you last retrieved it. Get the resource 1601// again, make any changes you need to make to the new copy, and retry your 1602// operation. 1603// 1604// * WAFAssociatedItemException 1605// AWS WAF couldn’t perform the operation because your resource is being used 1606// by another resource or it’s associated with another resource. 1607// 1608// * WAFTagOperationException 1609// An error occurred during the tagging operation. Retry your request. 1610// 1611// * WAFTagOperationInternalErrorException 1612// AWS WAF couldn’t perform your tagging operation because of an internal 1613// error. Retry your request. 1614// 1615// * WAFInvalidOperationException 1616// The operation isn't valid. 1617// 1618// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DeleteWebACL 1619func (c *WAFV2) DeleteWebACL(input *DeleteWebACLInput) (*DeleteWebACLOutput, error) { 1620 req, out := c.DeleteWebACLRequest(input) 1621 return out, req.Send() 1622} 1623 1624// DeleteWebACLWithContext is the same as DeleteWebACL with the addition of 1625// the ability to pass a context and additional request options. 1626// 1627// See DeleteWebACL for details on how to use this API operation. 1628// 1629// The context must be non-nil and will be used for request cancellation. If 1630// the context is nil a panic will occur. In the future the SDK may create 1631// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1632// for more information on using Contexts. 1633func (c *WAFV2) DeleteWebACLWithContext(ctx aws.Context, input *DeleteWebACLInput, opts ...request.Option) (*DeleteWebACLOutput, error) { 1634 req, out := c.DeleteWebACLRequest(input) 1635 req.SetContext(ctx) 1636 req.ApplyOptions(opts...) 1637 return out, req.Send() 1638} 1639 1640const opDescribeManagedRuleGroup = "DescribeManagedRuleGroup" 1641 1642// DescribeManagedRuleGroupRequest generates a "aws/request.Request" representing the 1643// client's request for the DescribeManagedRuleGroup operation. The "output" return 1644// value will be populated with the request's response once the request completes 1645// successfully. 1646// 1647// Use "Send" method on the returned Request to send the API call to the service. 1648// the "output" return value is not valid until after Send returns without error. 1649// 1650// See DescribeManagedRuleGroup for more information on using the DescribeManagedRuleGroup 1651// API call, and error handling. 1652// 1653// This method is useful when you want to inject custom logic or configuration 1654// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1655// 1656// 1657// // Example sending a request using the DescribeManagedRuleGroupRequest method. 1658// req, resp := client.DescribeManagedRuleGroupRequest(params) 1659// 1660// err := req.Send() 1661// if err == nil { // resp is now filled 1662// fmt.Println(resp) 1663// } 1664// 1665// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeManagedRuleGroup 1666func (c *WAFV2) DescribeManagedRuleGroupRequest(input *DescribeManagedRuleGroupInput) (req *request.Request, output *DescribeManagedRuleGroupOutput) { 1667 op := &request.Operation{ 1668 Name: opDescribeManagedRuleGroup, 1669 HTTPMethod: "POST", 1670 HTTPPath: "/", 1671 } 1672 1673 if input == nil { 1674 input = &DescribeManagedRuleGroupInput{} 1675 } 1676 1677 output = &DescribeManagedRuleGroupOutput{} 1678 req = c.newRequest(op, input, output) 1679 return 1680} 1681 1682// DescribeManagedRuleGroup API operation for AWS WAFV2. 1683// 1684// 1685// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1686// 2019. For information, including how to migrate your AWS WAF resources from 1687// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1688// 1689// Provides high-level information for a managed rule group, including descriptions 1690// of the rules. 1691// 1692// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1693// with awserr.Error's Code and Message methods to get detailed information about 1694// the error. 1695// 1696// See the AWS API reference guide for AWS WAFV2's 1697// API operation DescribeManagedRuleGroup for usage and error information. 1698// 1699// Returned Error Types: 1700// * WAFInternalErrorException 1701// Your request is valid, but AWS WAF couldn’t perform the operation because 1702// of a system problem. Retry your request. 1703// 1704// * WAFInvalidParameterException 1705// The operation failed because AWS WAF didn't recognize a parameter in the 1706// request. For example: 1707// 1708// * You specified an invalid parameter name or value. 1709// 1710// * Your nested statement isn't valid. You might have tried to nest a statement 1711// that can’t be nested. 1712// 1713// * You tried to update a WebACL with a DefaultAction that isn't among the 1714// types available at DefaultAction. 1715// 1716// * Your request references an ARN that is malformed, or corresponds to 1717// a resource with which a Web ACL cannot be associated. 1718// 1719// * WAFInvalidResourceException 1720// AWS WAF couldn’t perform the operation because the resource that you requested 1721// isn’t valid. Check the resource, and try again. 1722// 1723// * WAFNonexistentItemException 1724// AWS WAF couldn’t perform the operation because your resource doesn’t 1725// exist. 1726// 1727// * WAFInvalidOperationException 1728// The operation isn't valid. 1729// 1730// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DescribeManagedRuleGroup 1731func (c *WAFV2) DescribeManagedRuleGroup(input *DescribeManagedRuleGroupInput) (*DescribeManagedRuleGroupOutput, error) { 1732 req, out := c.DescribeManagedRuleGroupRequest(input) 1733 return out, req.Send() 1734} 1735 1736// DescribeManagedRuleGroupWithContext is the same as DescribeManagedRuleGroup with the addition of 1737// the ability to pass a context and additional request options. 1738// 1739// See DescribeManagedRuleGroup for details on how to use this API operation. 1740// 1741// The context must be non-nil and will be used for request cancellation. If 1742// the context is nil a panic will occur. In the future the SDK may create 1743// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1744// for more information on using Contexts. 1745func (c *WAFV2) DescribeManagedRuleGroupWithContext(ctx aws.Context, input *DescribeManagedRuleGroupInput, opts ...request.Option) (*DescribeManagedRuleGroupOutput, error) { 1746 req, out := c.DescribeManagedRuleGroupRequest(input) 1747 req.SetContext(ctx) 1748 req.ApplyOptions(opts...) 1749 return out, req.Send() 1750} 1751 1752const opDisassociateWebACL = "DisassociateWebACL" 1753 1754// DisassociateWebACLRequest generates a "aws/request.Request" representing the 1755// client's request for the DisassociateWebACL operation. The "output" return 1756// value will be populated with the request's response once the request completes 1757// successfully. 1758// 1759// Use "Send" method on the returned Request to send the API call to the service. 1760// the "output" return value is not valid until after Send returns without error. 1761// 1762// See DisassociateWebACL for more information on using the DisassociateWebACL 1763// API call, and error handling. 1764// 1765// This method is useful when you want to inject custom logic or configuration 1766// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1767// 1768// 1769// // Example sending a request using the DisassociateWebACLRequest method. 1770// req, resp := client.DisassociateWebACLRequest(params) 1771// 1772// err := req.Send() 1773// if err == nil { // resp is now filled 1774// fmt.Println(resp) 1775// } 1776// 1777// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DisassociateWebACL 1778func (c *WAFV2) DisassociateWebACLRequest(input *DisassociateWebACLInput) (req *request.Request, output *DisassociateWebACLOutput) { 1779 op := &request.Operation{ 1780 Name: opDisassociateWebACL, 1781 HTTPMethod: "POST", 1782 HTTPPath: "/", 1783 } 1784 1785 if input == nil { 1786 input = &DisassociateWebACLInput{} 1787 } 1788 1789 output = &DisassociateWebACLOutput{} 1790 req = c.newRequest(op, input, output) 1791 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1792 return 1793} 1794 1795// DisassociateWebACL API operation for AWS WAFV2. 1796// 1797// 1798// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1799// 2019. For information, including how to migrate your AWS WAF resources from 1800// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1801// 1802// Disassociates a Web ACL from a regional application resource. A regional 1803// application can be an Application Load Balancer (ALB), an API Gateway REST 1804// API, or an AppSync GraphQL API. 1805// 1806// For AWS CloudFront, don't use this call. Instead, use your CloudFront distribution 1807// configuration. To disassociate a Web ACL, provide an empty web ACL ID in 1808// the CloudFront call UpdateDistribution. For information, see UpdateDistribution 1809// (https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html). 1810// 1811// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1812// with awserr.Error's Code and Message methods to get detailed information about 1813// the error. 1814// 1815// See the AWS API reference guide for AWS WAFV2's 1816// API operation DisassociateWebACL for usage and error information. 1817// 1818// Returned Error Types: 1819// * WAFInternalErrorException 1820// Your request is valid, but AWS WAF couldn’t perform the operation because 1821// of a system problem. Retry your request. 1822// 1823// * WAFInvalidParameterException 1824// The operation failed because AWS WAF didn't recognize a parameter in the 1825// request. For example: 1826// 1827// * You specified an invalid parameter name or value. 1828// 1829// * Your nested statement isn't valid. You might have tried to nest a statement 1830// that can’t be nested. 1831// 1832// * You tried to update a WebACL with a DefaultAction that isn't among the 1833// types available at DefaultAction. 1834// 1835// * Your request references an ARN that is malformed, or corresponds to 1836// a resource with which a Web ACL cannot be associated. 1837// 1838// * WAFNonexistentItemException 1839// AWS WAF couldn’t perform the operation because your resource doesn’t 1840// exist. 1841// 1842// * WAFInvalidOperationException 1843// The operation isn't valid. 1844// 1845// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/DisassociateWebACL 1846func (c *WAFV2) DisassociateWebACL(input *DisassociateWebACLInput) (*DisassociateWebACLOutput, error) { 1847 req, out := c.DisassociateWebACLRequest(input) 1848 return out, req.Send() 1849} 1850 1851// DisassociateWebACLWithContext is the same as DisassociateWebACL with the addition of 1852// the ability to pass a context and additional request options. 1853// 1854// See DisassociateWebACL for details on how to use this API operation. 1855// 1856// The context must be non-nil and will be used for request cancellation. If 1857// the context is nil a panic will occur. In the future the SDK may create 1858// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1859// for more information on using Contexts. 1860func (c *WAFV2) DisassociateWebACLWithContext(ctx aws.Context, input *DisassociateWebACLInput, opts ...request.Option) (*DisassociateWebACLOutput, error) { 1861 req, out := c.DisassociateWebACLRequest(input) 1862 req.SetContext(ctx) 1863 req.ApplyOptions(opts...) 1864 return out, req.Send() 1865} 1866 1867const opGetIPSet = "GetIPSet" 1868 1869// GetIPSetRequest generates a "aws/request.Request" representing the 1870// client's request for the GetIPSet operation. The "output" return 1871// value will be populated with the request's response once the request completes 1872// successfully. 1873// 1874// Use "Send" method on the returned Request to send the API call to the service. 1875// the "output" return value is not valid until after Send returns without error. 1876// 1877// See GetIPSet for more information on using the GetIPSet 1878// API call, and error handling. 1879// 1880// This method is useful when you want to inject custom logic or configuration 1881// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1882// 1883// 1884// // Example sending a request using the GetIPSetRequest method. 1885// req, resp := client.GetIPSetRequest(params) 1886// 1887// err := req.Send() 1888// if err == nil { // resp is now filled 1889// fmt.Println(resp) 1890// } 1891// 1892// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetIPSet 1893func (c *WAFV2) GetIPSetRequest(input *GetIPSetInput) (req *request.Request, output *GetIPSetOutput) { 1894 op := &request.Operation{ 1895 Name: opGetIPSet, 1896 HTTPMethod: "POST", 1897 HTTPPath: "/", 1898 } 1899 1900 if input == nil { 1901 input = &GetIPSetInput{} 1902 } 1903 1904 output = &GetIPSetOutput{} 1905 req = c.newRequest(op, input, output) 1906 return 1907} 1908 1909// GetIPSet API operation for AWS WAFV2. 1910// 1911// 1912// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 1913// 2019. For information, including how to migrate your AWS WAF resources from 1914// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 1915// 1916// Retrieves the specified IPSet. 1917// 1918// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1919// with awserr.Error's Code and Message methods to get detailed information about 1920// the error. 1921// 1922// See the AWS API reference guide for AWS WAFV2's 1923// API operation GetIPSet for usage and error information. 1924// 1925// Returned Error Types: 1926// * WAFInternalErrorException 1927// Your request is valid, but AWS WAF couldn’t perform the operation because 1928// of a system problem. Retry your request. 1929// 1930// * WAFInvalidParameterException 1931// The operation failed because AWS WAF didn't recognize a parameter in the 1932// request. For example: 1933// 1934// * You specified an invalid parameter name or value. 1935// 1936// * Your nested statement isn't valid. You might have tried to nest a statement 1937// that can’t be nested. 1938// 1939// * You tried to update a WebACL with a DefaultAction that isn't among the 1940// types available at DefaultAction. 1941// 1942// * Your request references an ARN that is malformed, or corresponds to 1943// a resource with which a Web ACL cannot be associated. 1944// 1945// * WAFNonexistentItemException 1946// AWS WAF couldn’t perform the operation because your resource doesn’t 1947// exist. 1948// 1949// * WAFInvalidOperationException 1950// The operation isn't valid. 1951// 1952// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetIPSet 1953func (c *WAFV2) GetIPSet(input *GetIPSetInput) (*GetIPSetOutput, error) { 1954 req, out := c.GetIPSetRequest(input) 1955 return out, req.Send() 1956} 1957 1958// GetIPSetWithContext is the same as GetIPSet with the addition of 1959// the ability to pass a context and additional request options. 1960// 1961// See GetIPSet for details on how to use this API operation. 1962// 1963// The context must be non-nil and will be used for request cancellation. If 1964// the context is nil a panic will occur. In the future the SDK may create 1965// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1966// for more information on using Contexts. 1967func (c *WAFV2) GetIPSetWithContext(ctx aws.Context, input *GetIPSetInput, opts ...request.Option) (*GetIPSetOutput, error) { 1968 req, out := c.GetIPSetRequest(input) 1969 req.SetContext(ctx) 1970 req.ApplyOptions(opts...) 1971 return out, req.Send() 1972} 1973 1974const opGetLoggingConfiguration = "GetLoggingConfiguration" 1975 1976// GetLoggingConfigurationRequest generates a "aws/request.Request" representing the 1977// client's request for the GetLoggingConfiguration operation. The "output" return 1978// value will be populated with the request's response once the request completes 1979// successfully. 1980// 1981// Use "Send" method on the returned Request to send the API call to the service. 1982// the "output" return value is not valid until after Send returns without error. 1983// 1984// See GetLoggingConfiguration for more information on using the GetLoggingConfiguration 1985// API call, and error handling. 1986// 1987// This method is useful when you want to inject custom logic or configuration 1988// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1989// 1990// 1991// // Example sending a request using the GetLoggingConfigurationRequest method. 1992// req, resp := client.GetLoggingConfigurationRequest(params) 1993// 1994// err := req.Send() 1995// if err == nil { // resp is now filled 1996// fmt.Println(resp) 1997// } 1998// 1999// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetLoggingConfiguration 2000func (c *WAFV2) GetLoggingConfigurationRequest(input *GetLoggingConfigurationInput) (req *request.Request, output *GetLoggingConfigurationOutput) { 2001 op := &request.Operation{ 2002 Name: opGetLoggingConfiguration, 2003 HTTPMethod: "POST", 2004 HTTPPath: "/", 2005 } 2006 2007 if input == nil { 2008 input = &GetLoggingConfigurationInput{} 2009 } 2010 2011 output = &GetLoggingConfigurationOutput{} 2012 req = c.newRequest(op, input, output) 2013 return 2014} 2015 2016// GetLoggingConfiguration API operation for AWS WAFV2. 2017// 2018// 2019// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2020// 2019. For information, including how to migrate your AWS WAF resources from 2021// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2022// 2023// Returns the LoggingConfiguration for the specified web ACL. 2024// 2025// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2026// with awserr.Error's Code and Message methods to get detailed information about 2027// the error. 2028// 2029// See the AWS API reference guide for AWS WAFV2's 2030// API operation GetLoggingConfiguration for usage and error information. 2031// 2032// Returned Error Types: 2033// * WAFInternalErrorException 2034// Your request is valid, but AWS WAF couldn’t perform the operation because 2035// of a system problem. Retry your request. 2036// 2037// * WAFNonexistentItemException 2038// AWS WAF couldn’t perform the operation because your resource doesn’t 2039// exist. 2040// 2041// * WAFInvalidParameterException 2042// The operation failed because AWS WAF didn't recognize a parameter in the 2043// request. For example: 2044// 2045// * You specified an invalid parameter name or value. 2046// 2047// * Your nested statement isn't valid. You might have tried to nest a statement 2048// that can’t be nested. 2049// 2050// * You tried to update a WebACL with a DefaultAction that isn't among the 2051// types available at DefaultAction. 2052// 2053// * Your request references an ARN that is malformed, or corresponds to 2054// a resource with which a Web ACL cannot be associated. 2055// 2056// * WAFInvalidOperationException 2057// The operation isn't valid. 2058// 2059// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetLoggingConfiguration 2060func (c *WAFV2) GetLoggingConfiguration(input *GetLoggingConfigurationInput) (*GetLoggingConfigurationOutput, error) { 2061 req, out := c.GetLoggingConfigurationRequest(input) 2062 return out, req.Send() 2063} 2064 2065// GetLoggingConfigurationWithContext is the same as GetLoggingConfiguration with the addition of 2066// the ability to pass a context and additional request options. 2067// 2068// See GetLoggingConfiguration for details on how to use this API operation. 2069// 2070// The context must be non-nil and will be used for request cancellation. If 2071// the context is nil a panic will occur. In the future the SDK may create 2072// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2073// for more information on using Contexts. 2074func (c *WAFV2) GetLoggingConfigurationWithContext(ctx aws.Context, input *GetLoggingConfigurationInput, opts ...request.Option) (*GetLoggingConfigurationOutput, error) { 2075 req, out := c.GetLoggingConfigurationRequest(input) 2076 req.SetContext(ctx) 2077 req.ApplyOptions(opts...) 2078 return out, req.Send() 2079} 2080 2081const opGetPermissionPolicy = "GetPermissionPolicy" 2082 2083// GetPermissionPolicyRequest generates a "aws/request.Request" representing the 2084// client's request for the GetPermissionPolicy operation. The "output" return 2085// value will be populated with the request's response once the request completes 2086// successfully. 2087// 2088// Use "Send" method on the returned Request to send the API call to the service. 2089// the "output" return value is not valid until after Send returns without error. 2090// 2091// See GetPermissionPolicy for more information on using the GetPermissionPolicy 2092// API call, and error handling. 2093// 2094// This method is useful when you want to inject custom logic or configuration 2095// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2096// 2097// 2098// // Example sending a request using the GetPermissionPolicyRequest method. 2099// req, resp := client.GetPermissionPolicyRequest(params) 2100// 2101// err := req.Send() 2102// if err == nil { // resp is now filled 2103// fmt.Println(resp) 2104// } 2105// 2106// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetPermissionPolicy 2107func (c *WAFV2) GetPermissionPolicyRequest(input *GetPermissionPolicyInput) (req *request.Request, output *GetPermissionPolicyOutput) { 2108 op := &request.Operation{ 2109 Name: opGetPermissionPolicy, 2110 HTTPMethod: "POST", 2111 HTTPPath: "/", 2112 } 2113 2114 if input == nil { 2115 input = &GetPermissionPolicyInput{} 2116 } 2117 2118 output = &GetPermissionPolicyOutput{} 2119 req = c.newRequest(op, input, output) 2120 return 2121} 2122 2123// GetPermissionPolicy API operation for AWS WAFV2. 2124// 2125// Returns the IAM policy that is attached to the specified rule group. 2126// 2127// You must be the owner of the rule group to perform this operation. 2128// 2129// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2130// with awserr.Error's Code and Message methods to get detailed information about 2131// the error. 2132// 2133// See the AWS API reference guide for AWS WAFV2's 2134// API operation GetPermissionPolicy for usage and error information. 2135// 2136// Returned Error Types: 2137// * WAFNonexistentItemException 2138// AWS WAF couldn’t perform the operation because your resource doesn’t 2139// exist. 2140// 2141// * WAFInternalErrorException 2142// Your request is valid, but AWS WAF couldn’t perform the operation because 2143// of a system problem. Retry your request. 2144// 2145// * WAFInvalidParameterException 2146// The operation failed because AWS WAF didn't recognize a parameter in the 2147// request. For example: 2148// 2149// * You specified an invalid parameter name or value. 2150// 2151// * Your nested statement isn't valid. You might have tried to nest a statement 2152// that can’t be nested. 2153// 2154// * You tried to update a WebACL with a DefaultAction that isn't among the 2155// types available at DefaultAction. 2156// 2157// * Your request references an ARN that is malformed, or corresponds to 2158// a resource with which a Web ACL cannot be associated. 2159// 2160// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetPermissionPolicy 2161func (c *WAFV2) GetPermissionPolicy(input *GetPermissionPolicyInput) (*GetPermissionPolicyOutput, error) { 2162 req, out := c.GetPermissionPolicyRequest(input) 2163 return out, req.Send() 2164} 2165 2166// GetPermissionPolicyWithContext is the same as GetPermissionPolicy with the addition of 2167// the ability to pass a context and additional request options. 2168// 2169// See GetPermissionPolicy for details on how to use this API operation. 2170// 2171// The context must be non-nil and will be used for request cancellation. If 2172// the context is nil a panic will occur. In the future the SDK may create 2173// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2174// for more information on using Contexts. 2175func (c *WAFV2) GetPermissionPolicyWithContext(ctx aws.Context, input *GetPermissionPolicyInput, opts ...request.Option) (*GetPermissionPolicyOutput, error) { 2176 req, out := c.GetPermissionPolicyRequest(input) 2177 req.SetContext(ctx) 2178 req.ApplyOptions(opts...) 2179 return out, req.Send() 2180} 2181 2182const opGetRateBasedStatementManagedKeys = "GetRateBasedStatementManagedKeys" 2183 2184// GetRateBasedStatementManagedKeysRequest generates a "aws/request.Request" representing the 2185// client's request for the GetRateBasedStatementManagedKeys operation. The "output" return 2186// value will be populated with the request's response once the request completes 2187// successfully. 2188// 2189// Use "Send" method on the returned Request to send the API call to the service. 2190// the "output" return value is not valid until after Send returns without error. 2191// 2192// See GetRateBasedStatementManagedKeys for more information on using the GetRateBasedStatementManagedKeys 2193// API call, and error handling. 2194// 2195// This method is useful when you want to inject custom logic or configuration 2196// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2197// 2198// 2199// // Example sending a request using the GetRateBasedStatementManagedKeysRequest method. 2200// req, resp := client.GetRateBasedStatementManagedKeysRequest(params) 2201// 2202// err := req.Send() 2203// if err == nil { // resp is now filled 2204// fmt.Println(resp) 2205// } 2206// 2207// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRateBasedStatementManagedKeys 2208func (c *WAFV2) GetRateBasedStatementManagedKeysRequest(input *GetRateBasedStatementManagedKeysInput) (req *request.Request, output *GetRateBasedStatementManagedKeysOutput) { 2209 op := &request.Operation{ 2210 Name: opGetRateBasedStatementManagedKeys, 2211 HTTPMethod: "POST", 2212 HTTPPath: "/", 2213 } 2214 2215 if input == nil { 2216 input = &GetRateBasedStatementManagedKeysInput{} 2217 } 2218 2219 output = &GetRateBasedStatementManagedKeysOutput{} 2220 req = c.newRequest(op, input, output) 2221 return 2222} 2223 2224// GetRateBasedStatementManagedKeys API operation for AWS WAFV2. 2225// 2226// 2227// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2228// 2019. For information, including how to migrate your AWS WAF resources from 2229// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2230// 2231// Retrieves the keys that are currently blocked by a rate-based rule. The maximum 2232// number of managed keys that can be blocked for a single rate-based rule is 2233// 10,000. If more than 10,000 addresses exceed the rate limit, those with the 2234// highest rates are blocked. 2235// 2236// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2237// with awserr.Error's Code and Message methods to get detailed information about 2238// the error. 2239// 2240// See the AWS API reference guide for AWS WAFV2's 2241// API operation GetRateBasedStatementManagedKeys for usage and error information. 2242// 2243// Returned Error Types: 2244// * WAFInternalErrorException 2245// Your request is valid, but AWS WAF couldn’t perform the operation because 2246// of a system problem. Retry your request. 2247// 2248// * WAFInvalidParameterException 2249// The operation failed because AWS WAF didn't recognize a parameter in the 2250// request. For example: 2251// 2252// * You specified an invalid parameter name or value. 2253// 2254// * Your nested statement isn't valid. You might have tried to nest a statement 2255// that can’t be nested. 2256// 2257// * You tried to update a WebACL with a DefaultAction that isn't among the 2258// types available at DefaultAction. 2259// 2260// * Your request references an ARN that is malformed, or corresponds to 2261// a resource with which a Web ACL cannot be associated. 2262// 2263// * WAFNonexistentItemException 2264// AWS WAF couldn’t perform the operation because your resource doesn’t 2265// exist. 2266// 2267// * WAFInvalidOperationException 2268// The operation isn't valid. 2269// 2270// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRateBasedStatementManagedKeys 2271func (c *WAFV2) GetRateBasedStatementManagedKeys(input *GetRateBasedStatementManagedKeysInput) (*GetRateBasedStatementManagedKeysOutput, error) { 2272 req, out := c.GetRateBasedStatementManagedKeysRequest(input) 2273 return out, req.Send() 2274} 2275 2276// GetRateBasedStatementManagedKeysWithContext is the same as GetRateBasedStatementManagedKeys with the addition of 2277// the ability to pass a context and additional request options. 2278// 2279// See GetRateBasedStatementManagedKeys for details on how to use this API operation. 2280// 2281// The context must be non-nil and will be used for request cancellation. If 2282// the context is nil a panic will occur. In the future the SDK may create 2283// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2284// for more information on using Contexts. 2285func (c *WAFV2) GetRateBasedStatementManagedKeysWithContext(ctx aws.Context, input *GetRateBasedStatementManagedKeysInput, opts ...request.Option) (*GetRateBasedStatementManagedKeysOutput, error) { 2286 req, out := c.GetRateBasedStatementManagedKeysRequest(input) 2287 req.SetContext(ctx) 2288 req.ApplyOptions(opts...) 2289 return out, req.Send() 2290} 2291 2292const opGetRegexPatternSet = "GetRegexPatternSet" 2293 2294// GetRegexPatternSetRequest generates a "aws/request.Request" representing the 2295// client's request for the GetRegexPatternSet operation. The "output" return 2296// value will be populated with the request's response once the request completes 2297// successfully. 2298// 2299// Use "Send" method on the returned Request to send the API call to the service. 2300// the "output" return value is not valid until after Send returns without error. 2301// 2302// See GetRegexPatternSet for more information on using the GetRegexPatternSet 2303// API call, and error handling. 2304// 2305// This method is useful when you want to inject custom logic or configuration 2306// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2307// 2308// 2309// // Example sending a request using the GetRegexPatternSetRequest method. 2310// req, resp := client.GetRegexPatternSetRequest(params) 2311// 2312// err := req.Send() 2313// if err == nil { // resp is now filled 2314// fmt.Println(resp) 2315// } 2316// 2317// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRegexPatternSet 2318func (c *WAFV2) GetRegexPatternSetRequest(input *GetRegexPatternSetInput) (req *request.Request, output *GetRegexPatternSetOutput) { 2319 op := &request.Operation{ 2320 Name: opGetRegexPatternSet, 2321 HTTPMethod: "POST", 2322 HTTPPath: "/", 2323 } 2324 2325 if input == nil { 2326 input = &GetRegexPatternSetInput{} 2327 } 2328 2329 output = &GetRegexPatternSetOutput{} 2330 req = c.newRequest(op, input, output) 2331 return 2332} 2333 2334// GetRegexPatternSet API operation for AWS WAFV2. 2335// 2336// 2337// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2338// 2019. For information, including how to migrate your AWS WAF resources from 2339// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2340// 2341// Retrieves the specified RegexPatternSet. 2342// 2343// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2344// with awserr.Error's Code and Message methods to get detailed information about 2345// the error. 2346// 2347// See the AWS API reference guide for AWS WAFV2's 2348// API operation GetRegexPatternSet for usage and error information. 2349// 2350// Returned Error Types: 2351// * WAFInternalErrorException 2352// Your request is valid, but AWS WAF couldn’t perform the operation because 2353// of a system problem. Retry your request. 2354// 2355// * WAFInvalidParameterException 2356// The operation failed because AWS WAF didn't recognize a parameter in the 2357// request. For example: 2358// 2359// * You specified an invalid parameter name or value. 2360// 2361// * Your nested statement isn't valid. You might have tried to nest a statement 2362// that can’t be nested. 2363// 2364// * You tried to update a WebACL with a DefaultAction that isn't among the 2365// types available at DefaultAction. 2366// 2367// * Your request references an ARN that is malformed, or corresponds to 2368// a resource with which a Web ACL cannot be associated. 2369// 2370// * WAFNonexistentItemException 2371// AWS WAF couldn’t perform the operation because your resource doesn’t 2372// exist. 2373// 2374// * WAFInvalidOperationException 2375// The operation isn't valid. 2376// 2377// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRegexPatternSet 2378func (c *WAFV2) GetRegexPatternSet(input *GetRegexPatternSetInput) (*GetRegexPatternSetOutput, error) { 2379 req, out := c.GetRegexPatternSetRequest(input) 2380 return out, req.Send() 2381} 2382 2383// GetRegexPatternSetWithContext is the same as GetRegexPatternSet with the addition of 2384// the ability to pass a context and additional request options. 2385// 2386// See GetRegexPatternSet for details on how to use this API operation. 2387// 2388// The context must be non-nil and will be used for request cancellation. If 2389// the context is nil a panic will occur. In the future the SDK may create 2390// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2391// for more information on using Contexts. 2392func (c *WAFV2) GetRegexPatternSetWithContext(ctx aws.Context, input *GetRegexPatternSetInput, opts ...request.Option) (*GetRegexPatternSetOutput, error) { 2393 req, out := c.GetRegexPatternSetRequest(input) 2394 req.SetContext(ctx) 2395 req.ApplyOptions(opts...) 2396 return out, req.Send() 2397} 2398 2399const opGetRuleGroup = "GetRuleGroup" 2400 2401// GetRuleGroupRequest generates a "aws/request.Request" representing the 2402// client's request for the GetRuleGroup operation. The "output" return 2403// value will be populated with the request's response once the request completes 2404// successfully. 2405// 2406// Use "Send" method on the returned Request to send the API call to the service. 2407// the "output" return value is not valid until after Send returns without error. 2408// 2409// See GetRuleGroup for more information on using the GetRuleGroup 2410// API call, and error handling. 2411// 2412// This method is useful when you want to inject custom logic or configuration 2413// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2414// 2415// 2416// // Example sending a request using the GetRuleGroupRequest method. 2417// req, resp := client.GetRuleGroupRequest(params) 2418// 2419// err := req.Send() 2420// if err == nil { // resp is now filled 2421// fmt.Println(resp) 2422// } 2423// 2424// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRuleGroup 2425func (c *WAFV2) GetRuleGroupRequest(input *GetRuleGroupInput) (req *request.Request, output *GetRuleGroupOutput) { 2426 op := &request.Operation{ 2427 Name: opGetRuleGroup, 2428 HTTPMethod: "POST", 2429 HTTPPath: "/", 2430 } 2431 2432 if input == nil { 2433 input = &GetRuleGroupInput{} 2434 } 2435 2436 output = &GetRuleGroupOutput{} 2437 req = c.newRequest(op, input, output) 2438 return 2439} 2440 2441// GetRuleGroup API operation for AWS WAFV2. 2442// 2443// 2444// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2445// 2019. For information, including how to migrate your AWS WAF resources from 2446// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2447// 2448// Retrieves the specified RuleGroup. 2449// 2450// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2451// with awserr.Error's Code and Message methods to get detailed information about 2452// the error. 2453// 2454// See the AWS API reference guide for AWS WAFV2's 2455// API operation GetRuleGroup for usage and error information. 2456// 2457// Returned Error Types: 2458// * WAFInternalErrorException 2459// Your request is valid, but AWS WAF couldn’t perform the operation because 2460// of a system problem. Retry your request. 2461// 2462// * WAFInvalidParameterException 2463// The operation failed because AWS WAF didn't recognize a parameter in the 2464// request. For example: 2465// 2466// * You specified an invalid parameter name or value. 2467// 2468// * Your nested statement isn't valid. You might have tried to nest a statement 2469// that can’t be nested. 2470// 2471// * You tried to update a WebACL with a DefaultAction that isn't among the 2472// types available at DefaultAction. 2473// 2474// * Your request references an ARN that is malformed, or corresponds to 2475// a resource with which a Web ACL cannot be associated. 2476// 2477// * WAFNonexistentItemException 2478// AWS WAF couldn’t perform the operation because your resource doesn’t 2479// exist. 2480// 2481// * WAFInvalidOperationException 2482// The operation isn't valid. 2483// 2484// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetRuleGroup 2485func (c *WAFV2) GetRuleGroup(input *GetRuleGroupInput) (*GetRuleGroupOutput, error) { 2486 req, out := c.GetRuleGroupRequest(input) 2487 return out, req.Send() 2488} 2489 2490// GetRuleGroupWithContext is the same as GetRuleGroup with the addition of 2491// the ability to pass a context and additional request options. 2492// 2493// See GetRuleGroup for details on how to use this API operation. 2494// 2495// The context must be non-nil and will be used for request cancellation. If 2496// the context is nil a panic will occur. In the future the SDK may create 2497// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2498// for more information on using Contexts. 2499func (c *WAFV2) GetRuleGroupWithContext(ctx aws.Context, input *GetRuleGroupInput, opts ...request.Option) (*GetRuleGroupOutput, error) { 2500 req, out := c.GetRuleGroupRequest(input) 2501 req.SetContext(ctx) 2502 req.ApplyOptions(opts...) 2503 return out, req.Send() 2504} 2505 2506const opGetSampledRequests = "GetSampledRequests" 2507 2508// GetSampledRequestsRequest generates a "aws/request.Request" representing the 2509// client's request for the GetSampledRequests operation. The "output" return 2510// value will be populated with the request's response once the request completes 2511// successfully. 2512// 2513// Use "Send" method on the returned Request to send the API call to the service. 2514// the "output" return value is not valid until after Send returns without error. 2515// 2516// See GetSampledRequests for more information on using the GetSampledRequests 2517// API call, and error handling. 2518// 2519// This method is useful when you want to inject custom logic or configuration 2520// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2521// 2522// 2523// // Example sending a request using the GetSampledRequestsRequest method. 2524// req, resp := client.GetSampledRequestsRequest(params) 2525// 2526// err := req.Send() 2527// if err == nil { // resp is now filled 2528// fmt.Println(resp) 2529// } 2530// 2531// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetSampledRequests 2532func (c *WAFV2) GetSampledRequestsRequest(input *GetSampledRequestsInput) (req *request.Request, output *GetSampledRequestsOutput) { 2533 op := &request.Operation{ 2534 Name: opGetSampledRequests, 2535 HTTPMethod: "POST", 2536 HTTPPath: "/", 2537 } 2538 2539 if input == nil { 2540 input = &GetSampledRequestsInput{} 2541 } 2542 2543 output = &GetSampledRequestsOutput{} 2544 req = c.newRequest(op, input, output) 2545 return 2546} 2547 2548// GetSampledRequests API operation for AWS WAFV2. 2549// 2550// 2551// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2552// 2019. For information, including how to migrate your AWS WAF resources from 2553// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2554// 2555// Gets detailed information about a specified number of requests--a sample--that 2556// AWS WAF randomly selects from among the first 5,000 requests that your AWS 2557// resource received during a time range that you choose. You can specify a 2558// sample size of up to 500 requests, and you can specify any time range in 2559// the previous three hours. 2560// 2561// GetSampledRequests returns a time range, which is usually the time range 2562// that you specified. However, if your resource (such as a CloudFront distribution) 2563// received 5,000 requests before the specified time range elapsed, GetSampledRequests 2564// returns an updated time range. This new time range indicates the actual period 2565// during which AWS WAF selected the requests in the sample. 2566// 2567// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2568// with awserr.Error's Code and Message methods to get detailed information about 2569// the error. 2570// 2571// See the AWS API reference guide for AWS WAFV2's 2572// API operation GetSampledRequests for usage and error information. 2573// 2574// Returned Error Types: 2575// * WAFNonexistentItemException 2576// AWS WAF couldn’t perform the operation because your resource doesn’t 2577// exist. 2578// 2579// * WAFInternalErrorException 2580// Your request is valid, but AWS WAF couldn’t perform the operation because 2581// of a system problem. Retry your request. 2582// 2583// * WAFInvalidParameterException 2584// The operation failed because AWS WAF didn't recognize a parameter in the 2585// request. For example: 2586// 2587// * You specified an invalid parameter name or value. 2588// 2589// * Your nested statement isn't valid. You might have tried to nest a statement 2590// that can’t be nested. 2591// 2592// * You tried to update a WebACL with a DefaultAction that isn't among the 2593// types available at DefaultAction. 2594// 2595// * Your request references an ARN that is malformed, or corresponds to 2596// a resource with which a Web ACL cannot be associated. 2597// 2598// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetSampledRequests 2599func (c *WAFV2) GetSampledRequests(input *GetSampledRequestsInput) (*GetSampledRequestsOutput, error) { 2600 req, out := c.GetSampledRequestsRequest(input) 2601 return out, req.Send() 2602} 2603 2604// GetSampledRequestsWithContext is the same as GetSampledRequests with the addition of 2605// the ability to pass a context and additional request options. 2606// 2607// See GetSampledRequests for details on how to use this API operation. 2608// 2609// The context must be non-nil and will be used for request cancellation. If 2610// the context is nil a panic will occur. In the future the SDK may create 2611// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2612// for more information on using Contexts. 2613func (c *WAFV2) GetSampledRequestsWithContext(ctx aws.Context, input *GetSampledRequestsInput, opts ...request.Option) (*GetSampledRequestsOutput, error) { 2614 req, out := c.GetSampledRequestsRequest(input) 2615 req.SetContext(ctx) 2616 req.ApplyOptions(opts...) 2617 return out, req.Send() 2618} 2619 2620const opGetWebACL = "GetWebACL" 2621 2622// GetWebACLRequest generates a "aws/request.Request" representing the 2623// client's request for the GetWebACL operation. The "output" return 2624// value will be populated with the request's response once the request completes 2625// successfully. 2626// 2627// Use "Send" method on the returned Request to send the API call to the service. 2628// the "output" return value is not valid until after Send returns without error. 2629// 2630// See GetWebACL for more information on using the GetWebACL 2631// API call, and error handling. 2632// 2633// This method is useful when you want to inject custom logic or configuration 2634// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2635// 2636// 2637// // Example sending a request using the GetWebACLRequest method. 2638// req, resp := client.GetWebACLRequest(params) 2639// 2640// err := req.Send() 2641// if err == nil { // resp is now filled 2642// fmt.Println(resp) 2643// } 2644// 2645// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACL 2646func (c *WAFV2) GetWebACLRequest(input *GetWebACLInput) (req *request.Request, output *GetWebACLOutput) { 2647 op := &request.Operation{ 2648 Name: opGetWebACL, 2649 HTTPMethod: "POST", 2650 HTTPPath: "/", 2651 } 2652 2653 if input == nil { 2654 input = &GetWebACLInput{} 2655 } 2656 2657 output = &GetWebACLOutput{} 2658 req = c.newRequest(op, input, output) 2659 return 2660} 2661 2662// GetWebACL API operation for AWS WAFV2. 2663// 2664// 2665// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2666// 2019. For information, including how to migrate your AWS WAF resources from 2667// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2668// 2669// Retrieves the specified WebACL. 2670// 2671// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2672// with awserr.Error's Code and Message methods to get detailed information about 2673// the error. 2674// 2675// See the AWS API reference guide for AWS WAFV2's 2676// API operation GetWebACL for usage and error information. 2677// 2678// Returned Error Types: 2679// * WAFInternalErrorException 2680// Your request is valid, but AWS WAF couldn’t perform the operation because 2681// of a system problem. Retry your request. 2682// 2683// * WAFInvalidParameterException 2684// The operation failed because AWS WAF didn't recognize a parameter in the 2685// request. For example: 2686// 2687// * You specified an invalid parameter name or value. 2688// 2689// * Your nested statement isn't valid. You might have tried to nest a statement 2690// that can’t be nested. 2691// 2692// * You tried to update a WebACL with a DefaultAction that isn't among the 2693// types available at DefaultAction. 2694// 2695// * Your request references an ARN that is malformed, or corresponds to 2696// a resource with which a Web ACL cannot be associated. 2697// 2698// * WAFNonexistentItemException 2699// AWS WAF couldn’t perform the operation because your resource doesn’t 2700// exist. 2701// 2702// * WAFInvalidOperationException 2703// The operation isn't valid. 2704// 2705// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACL 2706func (c *WAFV2) GetWebACL(input *GetWebACLInput) (*GetWebACLOutput, error) { 2707 req, out := c.GetWebACLRequest(input) 2708 return out, req.Send() 2709} 2710 2711// GetWebACLWithContext is the same as GetWebACL with the addition of 2712// the ability to pass a context and additional request options. 2713// 2714// See GetWebACL for details on how to use this API operation. 2715// 2716// The context must be non-nil and will be used for request cancellation. If 2717// the context is nil a panic will occur. In the future the SDK may create 2718// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2719// for more information on using Contexts. 2720func (c *WAFV2) GetWebACLWithContext(ctx aws.Context, input *GetWebACLInput, opts ...request.Option) (*GetWebACLOutput, error) { 2721 req, out := c.GetWebACLRequest(input) 2722 req.SetContext(ctx) 2723 req.ApplyOptions(opts...) 2724 return out, req.Send() 2725} 2726 2727const opGetWebACLForResource = "GetWebACLForResource" 2728 2729// GetWebACLForResourceRequest generates a "aws/request.Request" representing the 2730// client's request for the GetWebACLForResource operation. The "output" return 2731// value will be populated with the request's response once the request completes 2732// successfully. 2733// 2734// Use "Send" method on the returned Request to send the API call to the service. 2735// the "output" return value is not valid until after Send returns without error. 2736// 2737// See GetWebACLForResource for more information on using the GetWebACLForResource 2738// API call, and error handling. 2739// 2740// This method is useful when you want to inject custom logic or configuration 2741// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2742// 2743// 2744// // Example sending a request using the GetWebACLForResourceRequest method. 2745// req, resp := client.GetWebACLForResourceRequest(params) 2746// 2747// err := req.Send() 2748// if err == nil { // resp is now filled 2749// fmt.Println(resp) 2750// } 2751// 2752// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACLForResource 2753func (c *WAFV2) GetWebACLForResourceRequest(input *GetWebACLForResourceInput) (req *request.Request, output *GetWebACLForResourceOutput) { 2754 op := &request.Operation{ 2755 Name: opGetWebACLForResource, 2756 HTTPMethod: "POST", 2757 HTTPPath: "/", 2758 } 2759 2760 if input == nil { 2761 input = &GetWebACLForResourceInput{} 2762 } 2763 2764 output = &GetWebACLForResourceOutput{} 2765 req = c.newRequest(op, input, output) 2766 return 2767} 2768 2769// GetWebACLForResource API operation for AWS WAFV2. 2770// 2771// 2772// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2773// 2019. For information, including how to migrate your AWS WAF resources from 2774// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2775// 2776// Retrieves the WebACL for the specified resource. 2777// 2778// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2779// with awserr.Error's Code and Message methods to get detailed information about 2780// the error. 2781// 2782// See the AWS API reference guide for AWS WAFV2's 2783// API operation GetWebACLForResource for usage and error information. 2784// 2785// Returned Error Types: 2786// * WAFInternalErrorException 2787// Your request is valid, but AWS WAF couldn’t perform the operation because 2788// of a system problem. Retry your request. 2789// 2790// * WAFNonexistentItemException 2791// AWS WAF couldn’t perform the operation because your resource doesn’t 2792// exist. 2793// 2794// * WAFInvalidParameterException 2795// The operation failed because AWS WAF didn't recognize a parameter in the 2796// request. For example: 2797// 2798// * You specified an invalid parameter name or value. 2799// 2800// * Your nested statement isn't valid. You might have tried to nest a statement 2801// that can’t be nested. 2802// 2803// * You tried to update a WebACL with a DefaultAction that isn't among the 2804// types available at DefaultAction. 2805// 2806// * Your request references an ARN that is malformed, or corresponds to 2807// a resource with which a Web ACL cannot be associated. 2808// 2809// * WAFUnavailableEntityException 2810// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 2811// 2812// * WAFInvalidOperationException 2813// The operation isn't valid. 2814// 2815// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/GetWebACLForResource 2816func (c *WAFV2) GetWebACLForResource(input *GetWebACLForResourceInput) (*GetWebACLForResourceOutput, error) { 2817 req, out := c.GetWebACLForResourceRequest(input) 2818 return out, req.Send() 2819} 2820 2821// GetWebACLForResourceWithContext is the same as GetWebACLForResource with the addition of 2822// the ability to pass a context and additional request options. 2823// 2824// See GetWebACLForResource for details on how to use this API operation. 2825// 2826// The context must be non-nil and will be used for request cancellation. If 2827// the context is nil a panic will occur. In the future the SDK may create 2828// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2829// for more information on using Contexts. 2830func (c *WAFV2) GetWebACLForResourceWithContext(ctx aws.Context, input *GetWebACLForResourceInput, opts ...request.Option) (*GetWebACLForResourceOutput, error) { 2831 req, out := c.GetWebACLForResourceRequest(input) 2832 req.SetContext(ctx) 2833 req.ApplyOptions(opts...) 2834 return out, req.Send() 2835} 2836 2837const opListAvailableManagedRuleGroups = "ListAvailableManagedRuleGroups" 2838 2839// ListAvailableManagedRuleGroupsRequest generates a "aws/request.Request" representing the 2840// client's request for the ListAvailableManagedRuleGroups operation. The "output" return 2841// value will be populated with the request's response once the request completes 2842// successfully. 2843// 2844// Use "Send" method on the returned Request to send the API call to the service. 2845// the "output" return value is not valid until after Send returns without error. 2846// 2847// See ListAvailableManagedRuleGroups for more information on using the ListAvailableManagedRuleGroups 2848// API call, and error handling. 2849// 2850// This method is useful when you want to inject custom logic or configuration 2851// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2852// 2853// 2854// // Example sending a request using the ListAvailableManagedRuleGroupsRequest method. 2855// req, resp := client.ListAvailableManagedRuleGroupsRequest(params) 2856// 2857// err := req.Send() 2858// if err == nil { // resp is now filled 2859// fmt.Println(resp) 2860// } 2861// 2862// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAvailableManagedRuleGroups 2863func (c *WAFV2) ListAvailableManagedRuleGroupsRequest(input *ListAvailableManagedRuleGroupsInput) (req *request.Request, output *ListAvailableManagedRuleGroupsOutput) { 2864 op := &request.Operation{ 2865 Name: opListAvailableManagedRuleGroups, 2866 HTTPMethod: "POST", 2867 HTTPPath: "/", 2868 } 2869 2870 if input == nil { 2871 input = &ListAvailableManagedRuleGroupsInput{} 2872 } 2873 2874 output = &ListAvailableManagedRuleGroupsOutput{} 2875 req = c.newRequest(op, input, output) 2876 return 2877} 2878 2879// ListAvailableManagedRuleGroups API operation for AWS WAFV2. 2880// 2881// 2882// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2883// 2019. For information, including how to migrate your AWS WAF resources from 2884// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2885// 2886// Retrieves an array of managed rule groups that are available for you to use. 2887// This list includes all AWS Managed Rules rule groups and the AWS Marketplace 2888// managed rule groups that you're subscribed to. 2889// 2890// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2891// with awserr.Error's Code and Message methods to get detailed information about 2892// the error. 2893// 2894// See the AWS API reference guide for AWS WAFV2's 2895// API operation ListAvailableManagedRuleGroups for usage and error information. 2896// 2897// Returned Error Types: 2898// * WAFInternalErrorException 2899// Your request is valid, but AWS WAF couldn’t perform the operation because 2900// of a system problem. Retry your request. 2901// 2902// * WAFInvalidParameterException 2903// The operation failed because AWS WAF didn't recognize a parameter in the 2904// request. For example: 2905// 2906// * You specified an invalid parameter name or value. 2907// 2908// * Your nested statement isn't valid. You might have tried to nest a statement 2909// that can’t be nested. 2910// 2911// * You tried to update a WebACL with a DefaultAction that isn't among the 2912// types available at DefaultAction. 2913// 2914// * Your request references an ARN that is malformed, or corresponds to 2915// a resource with which a Web ACL cannot be associated. 2916// 2917// * WAFInvalidOperationException 2918// The operation isn't valid. 2919// 2920// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListAvailableManagedRuleGroups 2921func (c *WAFV2) ListAvailableManagedRuleGroups(input *ListAvailableManagedRuleGroupsInput) (*ListAvailableManagedRuleGroupsOutput, error) { 2922 req, out := c.ListAvailableManagedRuleGroupsRequest(input) 2923 return out, req.Send() 2924} 2925 2926// ListAvailableManagedRuleGroupsWithContext is the same as ListAvailableManagedRuleGroups with the addition of 2927// the ability to pass a context and additional request options. 2928// 2929// See ListAvailableManagedRuleGroups for details on how to use this API operation. 2930// 2931// The context must be non-nil and will be used for request cancellation. If 2932// the context is nil a panic will occur. In the future the SDK may create 2933// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2934// for more information on using Contexts. 2935func (c *WAFV2) ListAvailableManagedRuleGroupsWithContext(ctx aws.Context, input *ListAvailableManagedRuleGroupsInput, opts ...request.Option) (*ListAvailableManagedRuleGroupsOutput, error) { 2936 req, out := c.ListAvailableManagedRuleGroupsRequest(input) 2937 req.SetContext(ctx) 2938 req.ApplyOptions(opts...) 2939 return out, req.Send() 2940} 2941 2942const opListIPSets = "ListIPSets" 2943 2944// ListIPSetsRequest generates a "aws/request.Request" representing the 2945// client's request for the ListIPSets operation. The "output" return 2946// value will be populated with the request's response once the request completes 2947// successfully. 2948// 2949// Use "Send" method on the returned Request to send the API call to the service. 2950// the "output" return value is not valid until after Send returns without error. 2951// 2952// See ListIPSets for more information on using the ListIPSets 2953// API call, and error handling. 2954// 2955// This method is useful when you want to inject custom logic or configuration 2956// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2957// 2958// 2959// // Example sending a request using the ListIPSetsRequest method. 2960// req, resp := client.ListIPSetsRequest(params) 2961// 2962// err := req.Send() 2963// if err == nil { // resp is now filled 2964// fmt.Println(resp) 2965// } 2966// 2967// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListIPSets 2968func (c *WAFV2) ListIPSetsRequest(input *ListIPSetsInput) (req *request.Request, output *ListIPSetsOutput) { 2969 op := &request.Operation{ 2970 Name: opListIPSets, 2971 HTTPMethod: "POST", 2972 HTTPPath: "/", 2973 } 2974 2975 if input == nil { 2976 input = &ListIPSetsInput{} 2977 } 2978 2979 output = &ListIPSetsOutput{} 2980 req = c.newRequest(op, input, output) 2981 return 2982} 2983 2984// ListIPSets API operation for AWS WAFV2. 2985// 2986// 2987// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 2988// 2019. For information, including how to migrate your AWS WAF resources from 2989// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 2990// 2991// Retrieves an array of IPSetSummary objects for the IP sets that you manage. 2992// 2993// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2994// with awserr.Error's Code and Message methods to get detailed information about 2995// the error. 2996// 2997// See the AWS API reference guide for AWS WAFV2's 2998// API operation ListIPSets for usage and error information. 2999// 3000// Returned Error Types: 3001// * WAFInternalErrorException 3002// Your request is valid, but AWS WAF couldn’t perform the operation because 3003// of a system problem. Retry your request. 3004// 3005// * WAFInvalidParameterException 3006// The operation failed because AWS WAF didn't recognize a parameter in the 3007// request. For example: 3008// 3009// * You specified an invalid parameter name or value. 3010// 3011// * Your nested statement isn't valid. You might have tried to nest a statement 3012// that can’t be nested. 3013// 3014// * You tried to update a WebACL with a DefaultAction that isn't among the 3015// types available at DefaultAction. 3016// 3017// * Your request references an ARN that is malformed, or corresponds to 3018// a resource with which a Web ACL cannot be associated. 3019// 3020// * WAFInvalidOperationException 3021// The operation isn't valid. 3022// 3023// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListIPSets 3024func (c *WAFV2) ListIPSets(input *ListIPSetsInput) (*ListIPSetsOutput, error) { 3025 req, out := c.ListIPSetsRequest(input) 3026 return out, req.Send() 3027} 3028 3029// ListIPSetsWithContext is the same as ListIPSets with the addition of 3030// the ability to pass a context and additional request options. 3031// 3032// See ListIPSets for details on how to use this API operation. 3033// 3034// The context must be non-nil and will be used for request cancellation. If 3035// the context is nil a panic will occur. In the future the SDK may create 3036// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3037// for more information on using Contexts. 3038func (c *WAFV2) ListIPSetsWithContext(ctx aws.Context, input *ListIPSetsInput, opts ...request.Option) (*ListIPSetsOutput, error) { 3039 req, out := c.ListIPSetsRequest(input) 3040 req.SetContext(ctx) 3041 req.ApplyOptions(opts...) 3042 return out, req.Send() 3043} 3044 3045const opListLoggingConfigurations = "ListLoggingConfigurations" 3046 3047// ListLoggingConfigurationsRequest generates a "aws/request.Request" representing the 3048// client's request for the ListLoggingConfigurations operation. The "output" return 3049// value will be populated with the request's response once the request completes 3050// successfully. 3051// 3052// Use "Send" method on the returned Request to send the API call to the service. 3053// the "output" return value is not valid until after Send returns without error. 3054// 3055// See ListLoggingConfigurations for more information on using the ListLoggingConfigurations 3056// API call, and error handling. 3057// 3058// This method is useful when you want to inject custom logic or configuration 3059// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3060// 3061// 3062// // Example sending a request using the ListLoggingConfigurationsRequest method. 3063// req, resp := client.ListLoggingConfigurationsRequest(params) 3064// 3065// err := req.Send() 3066// if err == nil { // resp is now filled 3067// fmt.Println(resp) 3068// } 3069// 3070// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListLoggingConfigurations 3071func (c *WAFV2) ListLoggingConfigurationsRequest(input *ListLoggingConfigurationsInput) (req *request.Request, output *ListLoggingConfigurationsOutput) { 3072 op := &request.Operation{ 3073 Name: opListLoggingConfigurations, 3074 HTTPMethod: "POST", 3075 HTTPPath: "/", 3076 } 3077 3078 if input == nil { 3079 input = &ListLoggingConfigurationsInput{} 3080 } 3081 3082 output = &ListLoggingConfigurationsOutput{} 3083 req = c.newRequest(op, input, output) 3084 return 3085} 3086 3087// ListLoggingConfigurations API operation for AWS WAFV2. 3088// 3089// 3090// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3091// 2019. For information, including how to migrate your AWS WAF resources from 3092// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3093// 3094// Retrieves an array of your LoggingConfiguration objects. 3095// 3096// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3097// with awserr.Error's Code and Message methods to get detailed information about 3098// the error. 3099// 3100// See the AWS API reference guide for AWS WAFV2's 3101// API operation ListLoggingConfigurations for usage and error information. 3102// 3103// Returned Error Types: 3104// * WAFInternalErrorException 3105// Your request is valid, but AWS WAF couldn’t perform the operation because 3106// of a system problem. Retry your request. 3107// 3108// * WAFInvalidParameterException 3109// The operation failed because AWS WAF didn't recognize a parameter in the 3110// request. For example: 3111// 3112// * You specified an invalid parameter name or value. 3113// 3114// * Your nested statement isn't valid. You might have tried to nest a statement 3115// that can’t be nested. 3116// 3117// * You tried to update a WebACL with a DefaultAction that isn't among the 3118// types available at DefaultAction. 3119// 3120// * Your request references an ARN that is malformed, or corresponds to 3121// a resource with which a Web ACL cannot be associated. 3122// 3123// * WAFInvalidOperationException 3124// The operation isn't valid. 3125// 3126// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListLoggingConfigurations 3127func (c *WAFV2) ListLoggingConfigurations(input *ListLoggingConfigurationsInput) (*ListLoggingConfigurationsOutput, error) { 3128 req, out := c.ListLoggingConfigurationsRequest(input) 3129 return out, req.Send() 3130} 3131 3132// ListLoggingConfigurationsWithContext is the same as ListLoggingConfigurations with the addition of 3133// the ability to pass a context and additional request options. 3134// 3135// See ListLoggingConfigurations for details on how to use this API operation. 3136// 3137// The context must be non-nil and will be used for request cancellation. If 3138// the context is nil a panic will occur. In the future the SDK may create 3139// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3140// for more information on using Contexts. 3141func (c *WAFV2) ListLoggingConfigurationsWithContext(ctx aws.Context, input *ListLoggingConfigurationsInput, opts ...request.Option) (*ListLoggingConfigurationsOutput, error) { 3142 req, out := c.ListLoggingConfigurationsRequest(input) 3143 req.SetContext(ctx) 3144 req.ApplyOptions(opts...) 3145 return out, req.Send() 3146} 3147 3148const opListRegexPatternSets = "ListRegexPatternSets" 3149 3150// ListRegexPatternSetsRequest generates a "aws/request.Request" representing the 3151// client's request for the ListRegexPatternSets operation. The "output" return 3152// value will be populated with the request's response once the request completes 3153// successfully. 3154// 3155// Use "Send" method on the returned Request to send the API call to the service. 3156// the "output" return value is not valid until after Send returns without error. 3157// 3158// See ListRegexPatternSets for more information on using the ListRegexPatternSets 3159// API call, and error handling. 3160// 3161// This method is useful when you want to inject custom logic or configuration 3162// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3163// 3164// 3165// // Example sending a request using the ListRegexPatternSetsRequest method. 3166// req, resp := client.ListRegexPatternSetsRequest(params) 3167// 3168// err := req.Send() 3169// if err == nil { // resp is now filled 3170// fmt.Println(resp) 3171// } 3172// 3173// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRegexPatternSets 3174func (c *WAFV2) ListRegexPatternSetsRequest(input *ListRegexPatternSetsInput) (req *request.Request, output *ListRegexPatternSetsOutput) { 3175 op := &request.Operation{ 3176 Name: opListRegexPatternSets, 3177 HTTPMethod: "POST", 3178 HTTPPath: "/", 3179 } 3180 3181 if input == nil { 3182 input = &ListRegexPatternSetsInput{} 3183 } 3184 3185 output = &ListRegexPatternSetsOutput{} 3186 req = c.newRequest(op, input, output) 3187 return 3188} 3189 3190// ListRegexPatternSets API operation for AWS WAFV2. 3191// 3192// 3193// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3194// 2019. For information, including how to migrate your AWS WAF resources from 3195// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3196// 3197// Retrieves an array of RegexPatternSetSummary objects for the regex pattern 3198// sets that you manage. 3199// 3200// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3201// with awserr.Error's Code and Message methods to get detailed information about 3202// the error. 3203// 3204// See the AWS API reference guide for AWS WAFV2's 3205// API operation ListRegexPatternSets for usage and error information. 3206// 3207// Returned Error Types: 3208// * WAFInternalErrorException 3209// Your request is valid, but AWS WAF couldn’t perform the operation because 3210// of a system problem. Retry your request. 3211// 3212// * WAFInvalidParameterException 3213// The operation failed because AWS WAF didn't recognize a parameter in the 3214// request. For example: 3215// 3216// * You specified an invalid parameter name or value. 3217// 3218// * Your nested statement isn't valid. You might have tried to nest a statement 3219// that can’t be nested. 3220// 3221// * You tried to update a WebACL with a DefaultAction that isn't among the 3222// types available at DefaultAction. 3223// 3224// * Your request references an ARN that is malformed, or corresponds to 3225// a resource with which a Web ACL cannot be associated. 3226// 3227// * WAFInvalidOperationException 3228// The operation isn't valid. 3229// 3230// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRegexPatternSets 3231func (c *WAFV2) ListRegexPatternSets(input *ListRegexPatternSetsInput) (*ListRegexPatternSetsOutput, error) { 3232 req, out := c.ListRegexPatternSetsRequest(input) 3233 return out, req.Send() 3234} 3235 3236// ListRegexPatternSetsWithContext is the same as ListRegexPatternSets with the addition of 3237// the ability to pass a context and additional request options. 3238// 3239// See ListRegexPatternSets for details on how to use this API operation. 3240// 3241// The context must be non-nil and will be used for request cancellation. If 3242// the context is nil a panic will occur. In the future the SDK may create 3243// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3244// for more information on using Contexts. 3245func (c *WAFV2) ListRegexPatternSetsWithContext(ctx aws.Context, input *ListRegexPatternSetsInput, opts ...request.Option) (*ListRegexPatternSetsOutput, error) { 3246 req, out := c.ListRegexPatternSetsRequest(input) 3247 req.SetContext(ctx) 3248 req.ApplyOptions(opts...) 3249 return out, req.Send() 3250} 3251 3252const opListResourcesForWebACL = "ListResourcesForWebACL" 3253 3254// ListResourcesForWebACLRequest generates a "aws/request.Request" representing the 3255// client's request for the ListResourcesForWebACL operation. The "output" return 3256// value will be populated with the request's response once the request completes 3257// successfully. 3258// 3259// Use "Send" method on the returned Request to send the API call to the service. 3260// the "output" return value is not valid until after Send returns without error. 3261// 3262// See ListResourcesForWebACL for more information on using the ListResourcesForWebACL 3263// API call, and error handling. 3264// 3265// This method is useful when you want to inject custom logic or configuration 3266// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3267// 3268// 3269// // Example sending a request using the ListResourcesForWebACLRequest method. 3270// req, resp := client.ListResourcesForWebACLRequest(params) 3271// 3272// err := req.Send() 3273// if err == nil { // resp is now filled 3274// fmt.Println(resp) 3275// } 3276// 3277// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListResourcesForWebACL 3278func (c *WAFV2) ListResourcesForWebACLRequest(input *ListResourcesForWebACLInput) (req *request.Request, output *ListResourcesForWebACLOutput) { 3279 op := &request.Operation{ 3280 Name: opListResourcesForWebACL, 3281 HTTPMethod: "POST", 3282 HTTPPath: "/", 3283 } 3284 3285 if input == nil { 3286 input = &ListResourcesForWebACLInput{} 3287 } 3288 3289 output = &ListResourcesForWebACLOutput{} 3290 req = c.newRequest(op, input, output) 3291 return 3292} 3293 3294// ListResourcesForWebACL API operation for AWS WAFV2. 3295// 3296// 3297// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3298// 2019. For information, including how to migrate your AWS WAF resources from 3299// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3300// 3301// Retrieves an array of the Amazon Resource Names (ARNs) for the regional resources 3302// that are associated with the specified web ACL. If you want the list of AWS 3303// CloudFront resources, use the AWS CloudFront call ListDistributionsByWebACLId. 3304// 3305// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3306// with awserr.Error's Code and Message methods to get detailed information about 3307// the error. 3308// 3309// See the AWS API reference guide for AWS WAFV2's 3310// API operation ListResourcesForWebACL for usage and error information. 3311// 3312// Returned Error Types: 3313// * WAFInternalErrorException 3314// Your request is valid, but AWS WAF couldn’t perform the operation because 3315// of a system problem. Retry your request. 3316// 3317// * WAFNonexistentItemException 3318// AWS WAF couldn’t perform the operation because your resource doesn’t 3319// exist. 3320// 3321// * WAFInvalidParameterException 3322// The operation failed because AWS WAF didn't recognize a parameter in the 3323// request. For example: 3324// 3325// * You specified an invalid parameter name or value. 3326// 3327// * Your nested statement isn't valid. You might have tried to nest a statement 3328// that can’t be nested. 3329// 3330// * You tried to update a WebACL with a DefaultAction that isn't among the 3331// types available at DefaultAction. 3332// 3333// * Your request references an ARN that is malformed, or corresponds to 3334// a resource with which a Web ACL cannot be associated. 3335// 3336// * WAFInvalidOperationException 3337// The operation isn't valid. 3338// 3339// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListResourcesForWebACL 3340func (c *WAFV2) ListResourcesForWebACL(input *ListResourcesForWebACLInput) (*ListResourcesForWebACLOutput, error) { 3341 req, out := c.ListResourcesForWebACLRequest(input) 3342 return out, req.Send() 3343} 3344 3345// ListResourcesForWebACLWithContext is the same as ListResourcesForWebACL with the addition of 3346// the ability to pass a context and additional request options. 3347// 3348// See ListResourcesForWebACL for details on how to use this API operation. 3349// 3350// The context must be non-nil and will be used for request cancellation. If 3351// the context is nil a panic will occur. In the future the SDK may create 3352// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3353// for more information on using Contexts. 3354func (c *WAFV2) ListResourcesForWebACLWithContext(ctx aws.Context, input *ListResourcesForWebACLInput, opts ...request.Option) (*ListResourcesForWebACLOutput, error) { 3355 req, out := c.ListResourcesForWebACLRequest(input) 3356 req.SetContext(ctx) 3357 req.ApplyOptions(opts...) 3358 return out, req.Send() 3359} 3360 3361const opListRuleGroups = "ListRuleGroups" 3362 3363// ListRuleGroupsRequest generates a "aws/request.Request" representing the 3364// client's request for the ListRuleGroups operation. The "output" return 3365// value will be populated with the request's response once the request completes 3366// successfully. 3367// 3368// Use "Send" method on the returned Request to send the API call to the service. 3369// the "output" return value is not valid until after Send returns without error. 3370// 3371// See ListRuleGroups for more information on using the ListRuleGroups 3372// API call, and error handling. 3373// 3374// This method is useful when you want to inject custom logic or configuration 3375// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3376// 3377// 3378// // Example sending a request using the ListRuleGroupsRequest method. 3379// req, resp := client.ListRuleGroupsRequest(params) 3380// 3381// err := req.Send() 3382// if err == nil { // resp is now filled 3383// fmt.Println(resp) 3384// } 3385// 3386// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRuleGroups 3387func (c *WAFV2) ListRuleGroupsRequest(input *ListRuleGroupsInput) (req *request.Request, output *ListRuleGroupsOutput) { 3388 op := &request.Operation{ 3389 Name: opListRuleGroups, 3390 HTTPMethod: "POST", 3391 HTTPPath: "/", 3392 } 3393 3394 if input == nil { 3395 input = &ListRuleGroupsInput{} 3396 } 3397 3398 output = &ListRuleGroupsOutput{} 3399 req = c.newRequest(op, input, output) 3400 return 3401} 3402 3403// ListRuleGroups API operation for AWS WAFV2. 3404// 3405// 3406// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3407// 2019. For information, including how to migrate your AWS WAF resources from 3408// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3409// 3410// Retrieves an array of RuleGroupSummary objects for the rule groups that you 3411// manage. 3412// 3413// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3414// with awserr.Error's Code and Message methods to get detailed information about 3415// the error. 3416// 3417// See the AWS API reference guide for AWS WAFV2's 3418// API operation ListRuleGroups for usage and error information. 3419// 3420// Returned Error Types: 3421// * WAFInternalErrorException 3422// Your request is valid, but AWS WAF couldn’t perform the operation because 3423// of a system problem. Retry your request. 3424// 3425// * WAFInvalidParameterException 3426// The operation failed because AWS WAF didn't recognize a parameter in the 3427// request. For example: 3428// 3429// * You specified an invalid parameter name or value. 3430// 3431// * Your nested statement isn't valid. You might have tried to nest a statement 3432// that can’t be nested. 3433// 3434// * You tried to update a WebACL with a DefaultAction that isn't among the 3435// types available at DefaultAction. 3436// 3437// * Your request references an ARN that is malformed, or corresponds to 3438// a resource with which a Web ACL cannot be associated. 3439// 3440// * WAFInvalidOperationException 3441// The operation isn't valid. 3442// 3443// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListRuleGroups 3444func (c *WAFV2) ListRuleGroups(input *ListRuleGroupsInput) (*ListRuleGroupsOutput, error) { 3445 req, out := c.ListRuleGroupsRequest(input) 3446 return out, req.Send() 3447} 3448 3449// ListRuleGroupsWithContext is the same as ListRuleGroups with the addition of 3450// the ability to pass a context and additional request options. 3451// 3452// See ListRuleGroups for details on how to use this API operation. 3453// 3454// The context must be non-nil and will be used for request cancellation. If 3455// the context is nil a panic will occur. In the future the SDK may create 3456// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3457// for more information on using Contexts. 3458func (c *WAFV2) ListRuleGroupsWithContext(ctx aws.Context, input *ListRuleGroupsInput, opts ...request.Option) (*ListRuleGroupsOutput, error) { 3459 req, out := c.ListRuleGroupsRequest(input) 3460 req.SetContext(ctx) 3461 req.ApplyOptions(opts...) 3462 return out, req.Send() 3463} 3464 3465const opListTagsForResource = "ListTagsForResource" 3466 3467// ListTagsForResourceRequest generates a "aws/request.Request" representing the 3468// client's request for the ListTagsForResource operation. The "output" return 3469// value will be populated with the request's response once the request completes 3470// successfully. 3471// 3472// Use "Send" method on the returned Request to send the API call to the service. 3473// the "output" return value is not valid until after Send returns without error. 3474// 3475// See ListTagsForResource for more information on using the ListTagsForResource 3476// API call, and error handling. 3477// 3478// This method is useful when you want to inject custom logic or configuration 3479// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3480// 3481// 3482// // Example sending a request using the ListTagsForResourceRequest method. 3483// req, resp := client.ListTagsForResourceRequest(params) 3484// 3485// err := req.Send() 3486// if err == nil { // resp is now filled 3487// fmt.Println(resp) 3488// } 3489// 3490// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListTagsForResource 3491func (c *WAFV2) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { 3492 op := &request.Operation{ 3493 Name: opListTagsForResource, 3494 HTTPMethod: "POST", 3495 HTTPPath: "/", 3496 } 3497 3498 if input == nil { 3499 input = &ListTagsForResourceInput{} 3500 } 3501 3502 output = &ListTagsForResourceOutput{} 3503 req = c.newRequest(op, input, output) 3504 return 3505} 3506 3507// ListTagsForResource API operation for AWS WAFV2. 3508// 3509// 3510// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3511// 2019. For information, including how to migrate your AWS WAF resources from 3512// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3513// 3514// Retrieves the TagInfoForResource for the specified resource. Tags are key:value 3515// pairs that you can use to categorize and manage your resources, for purposes 3516// like billing. For example, you might set the tag key to "customer" and the 3517// value to the customer name or ID. You can specify one or more tags to add 3518// to each AWS resource, up to 50 tags for a resource. 3519// 3520// You can tag the AWS resources that you manage through AWS WAF: web ACLs, 3521// rule groups, IP sets, and regex pattern sets. You can't manage or view tags 3522// through the AWS WAF console. 3523// 3524// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3525// with awserr.Error's Code and Message methods to get detailed information about 3526// the error. 3527// 3528// See the AWS API reference guide for AWS WAFV2's 3529// API operation ListTagsForResource for usage and error information. 3530// 3531// Returned Error Types: 3532// * WAFInternalErrorException 3533// Your request is valid, but AWS WAF couldn’t perform the operation because 3534// of a system problem. Retry your request. 3535// 3536// * WAFInvalidParameterException 3537// The operation failed because AWS WAF didn't recognize a parameter in the 3538// request. For example: 3539// 3540// * You specified an invalid parameter name or value. 3541// 3542// * Your nested statement isn't valid. You might have tried to nest a statement 3543// that can’t be nested. 3544// 3545// * You tried to update a WebACL with a DefaultAction that isn't among the 3546// types available at DefaultAction. 3547// 3548// * Your request references an ARN that is malformed, or corresponds to 3549// a resource with which a Web ACL cannot be associated. 3550// 3551// * WAFNonexistentItemException 3552// AWS WAF couldn’t perform the operation because your resource doesn’t 3553// exist. 3554// 3555// * WAFTagOperationException 3556// An error occurred during the tagging operation. Retry your request. 3557// 3558// * WAFTagOperationInternalErrorException 3559// AWS WAF couldn’t perform your tagging operation because of an internal 3560// error. Retry your request. 3561// 3562// * WAFInvalidOperationException 3563// The operation isn't valid. 3564// 3565// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListTagsForResource 3566func (c *WAFV2) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { 3567 req, out := c.ListTagsForResourceRequest(input) 3568 return out, req.Send() 3569} 3570 3571// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of 3572// the ability to pass a context and additional request options. 3573// 3574// See ListTagsForResource for details on how to use this API operation. 3575// 3576// The context must be non-nil and will be used for request cancellation. If 3577// the context is nil a panic will occur. In the future the SDK may create 3578// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3579// for more information on using Contexts. 3580func (c *WAFV2) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { 3581 req, out := c.ListTagsForResourceRequest(input) 3582 req.SetContext(ctx) 3583 req.ApplyOptions(opts...) 3584 return out, req.Send() 3585} 3586 3587const opListWebACLs = "ListWebACLs" 3588 3589// ListWebACLsRequest generates a "aws/request.Request" representing the 3590// client's request for the ListWebACLs operation. The "output" return 3591// value will be populated with the request's response once the request completes 3592// successfully. 3593// 3594// Use "Send" method on the returned Request to send the API call to the service. 3595// the "output" return value is not valid until after Send returns without error. 3596// 3597// See ListWebACLs for more information on using the ListWebACLs 3598// API call, and error handling. 3599// 3600// This method is useful when you want to inject custom logic or configuration 3601// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3602// 3603// 3604// // Example sending a request using the ListWebACLsRequest method. 3605// req, resp := client.ListWebACLsRequest(params) 3606// 3607// err := req.Send() 3608// if err == nil { // resp is now filled 3609// fmt.Println(resp) 3610// } 3611// 3612// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListWebACLs 3613func (c *WAFV2) ListWebACLsRequest(input *ListWebACLsInput) (req *request.Request, output *ListWebACLsOutput) { 3614 op := &request.Operation{ 3615 Name: opListWebACLs, 3616 HTTPMethod: "POST", 3617 HTTPPath: "/", 3618 } 3619 3620 if input == nil { 3621 input = &ListWebACLsInput{} 3622 } 3623 3624 output = &ListWebACLsOutput{} 3625 req = c.newRequest(op, input, output) 3626 return 3627} 3628 3629// ListWebACLs API operation for AWS WAFV2. 3630// 3631// 3632// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3633// 2019. For information, including how to migrate your AWS WAF resources from 3634// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3635// 3636// Retrieves an array of WebACLSummary objects for the web ACLs that you manage. 3637// 3638// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3639// with awserr.Error's Code and Message methods to get detailed information about 3640// the error. 3641// 3642// See the AWS API reference guide for AWS WAFV2's 3643// API operation ListWebACLs for usage and error information. 3644// 3645// Returned Error Types: 3646// * WAFInternalErrorException 3647// Your request is valid, but AWS WAF couldn’t perform the operation because 3648// of a system problem. Retry your request. 3649// 3650// * WAFInvalidParameterException 3651// The operation failed because AWS WAF didn't recognize a parameter in the 3652// request. For example: 3653// 3654// * You specified an invalid parameter name or value. 3655// 3656// * Your nested statement isn't valid. You might have tried to nest a statement 3657// that can’t be nested. 3658// 3659// * You tried to update a WebACL with a DefaultAction that isn't among the 3660// types available at DefaultAction. 3661// 3662// * Your request references an ARN that is malformed, or corresponds to 3663// a resource with which a Web ACL cannot be associated. 3664// 3665// * WAFInvalidOperationException 3666// The operation isn't valid. 3667// 3668// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/ListWebACLs 3669func (c *WAFV2) ListWebACLs(input *ListWebACLsInput) (*ListWebACLsOutput, error) { 3670 req, out := c.ListWebACLsRequest(input) 3671 return out, req.Send() 3672} 3673 3674// ListWebACLsWithContext is the same as ListWebACLs with the addition of 3675// the ability to pass a context and additional request options. 3676// 3677// See ListWebACLs for details on how to use this API operation. 3678// 3679// The context must be non-nil and will be used for request cancellation. If 3680// the context is nil a panic will occur. In the future the SDK may create 3681// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3682// for more information on using Contexts. 3683func (c *WAFV2) ListWebACLsWithContext(ctx aws.Context, input *ListWebACLsInput, opts ...request.Option) (*ListWebACLsOutput, error) { 3684 req, out := c.ListWebACLsRequest(input) 3685 req.SetContext(ctx) 3686 req.ApplyOptions(opts...) 3687 return out, req.Send() 3688} 3689 3690const opPutLoggingConfiguration = "PutLoggingConfiguration" 3691 3692// PutLoggingConfigurationRequest generates a "aws/request.Request" representing the 3693// client's request for the PutLoggingConfiguration operation. The "output" return 3694// value will be populated with the request's response once the request completes 3695// successfully. 3696// 3697// Use "Send" method on the returned Request to send the API call to the service. 3698// the "output" return value is not valid until after Send returns without error. 3699// 3700// See PutLoggingConfiguration for more information on using the PutLoggingConfiguration 3701// API call, and error handling. 3702// 3703// This method is useful when you want to inject custom logic or configuration 3704// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3705// 3706// 3707// // Example sending a request using the PutLoggingConfigurationRequest method. 3708// req, resp := client.PutLoggingConfigurationRequest(params) 3709// 3710// err := req.Send() 3711// if err == nil { // resp is now filled 3712// fmt.Println(resp) 3713// } 3714// 3715// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutLoggingConfiguration 3716func (c *WAFV2) PutLoggingConfigurationRequest(input *PutLoggingConfigurationInput) (req *request.Request, output *PutLoggingConfigurationOutput) { 3717 op := &request.Operation{ 3718 Name: opPutLoggingConfiguration, 3719 HTTPMethod: "POST", 3720 HTTPPath: "/", 3721 } 3722 3723 if input == nil { 3724 input = &PutLoggingConfigurationInput{} 3725 } 3726 3727 output = &PutLoggingConfigurationOutput{} 3728 req = c.newRequest(op, input, output) 3729 return 3730} 3731 3732// PutLoggingConfiguration API operation for AWS WAFV2. 3733// 3734// 3735// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 3736// 2019. For information, including how to migrate your AWS WAF resources from 3737// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 3738// 3739// Enables the specified LoggingConfiguration, to start logging from a web ACL, 3740// according to the configuration provided. 3741// 3742// You can access information about all traffic that AWS WAF inspects using 3743// the following steps: 3744// 3745// Create an Amazon Kinesis Data Firehose. 3746// 3747// Create the data firehose with a PUT source and in the Region that you are 3748// operating. If you are capturing logs for Amazon CloudFront, always create 3749// the firehose in US East (N. Virginia). 3750// 3751// Give the data firehose a name that starts with the prefix aws-waf-logs-. 3752// For example, aws-waf-logs-us-east-2-analytics. 3753// 3754// Do not create the data firehose using a Kinesis stream as your source. 3755// 3756// Associate that firehose to your web ACL using a PutLoggingConfiguration request. 3757// 3758// When you successfully enable logging using a PutLoggingConfiguration request, 3759// AWS WAF will create a service linked role with the necessary permissions 3760// to write logs to the Amazon Kinesis Data Firehose. For more information, 3761// see Logging Web ACL Traffic Information (https://docs.aws.amazon.com/waf/latest/developerguide/logging.html) 3762// in the AWS WAF Developer Guide. 3763// 3764// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3765// with awserr.Error's Code and Message methods to get detailed information about 3766// the error. 3767// 3768// See the AWS API reference guide for AWS WAFV2's 3769// API operation PutLoggingConfiguration for usage and error information. 3770// 3771// Returned Error Types: 3772// * WAFInternalErrorException 3773// Your request is valid, but AWS WAF couldn’t perform the operation because 3774// of a system problem. Retry your request. 3775// 3776// * WAFNonexistentItemException 3777// AWS WAF couldn’t perform the operation because your resource doesn’t 3778// exist. 3779// 3780// * WAFOptimisticLockException 3781// AWS WAF couldn’t save your changes because you tried to update or delete 3782// a resource that has changed since you last retrieved it. Get the resource 3783// again, make any changes you need to make to the new copy, and retry your 3784// operation. 3785// 3786// * WAFServiceLinkedRoleErrorException 3787// AWS WAF is not able to access the service linked role. This can be caused 3788// by a previous PutLoggingConfiguration request, which can lock the service 3789// linked role for about 20 seconds. Please try your request again. The service 3790// linked role can also be locked by a previous DeleteServiceLinkedRole request, 3791// which can lock the role for 15 minutes or more. If you recently made a call 3792// to DeleteServiceLinkedRole, wait at least 15 minutes and try the request 3793// again. If you receive this same exception again, you will have to wait additional 3794// time until the role is unlocked. 3795// 3796// * WAFInvalidParameterException 3797// The operation failed because AWS WAF didn't recognize a parameter in the 3798// request. For example: 3799// 3800// * You specified an invalid parameter name or value. 3801// 3802// * Your nested statement isn't valid. You might have tried to nest a statement 3803// that can’t be nested. 3804// 3805// * You tried to update a WebACL with a DefaultAction that isn't among the 3806// types available at DefaultAction. 3807// 3808// * Your request references an ARN that is malformed, or corresponds to 3809// a resource with which a Web ACL cannot be associated. 3810// 3811// * WAFInvalidOperationException 3812// The operation isn't valid. 3813// 3814// * WAFLimitsExceededException 3815// AWS WAF couldn’t perform the operation because you exceeded your resource 3816// limit. For example, the maximum number of WebACL objects that you can create 3817// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 3818// in the AWS WAF Developer Guide. 3819// 3820// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutLoggingConfiguration 3821func (c *WAFV2) PutLoggingConfiguration(input *PutLoggingConfigurationInput) (*PutLoggingConfigurationOutput, error) { 3822 req, out := c.PutLoggingConfigurationRequest(input) 3823 return out, req.Send() 3824} 3825 3826// PutLoggingConfigurationWithContext is the same as PutLoggingConfiguration with the addition of 3827// the ability to pass a context and additional request options. 3828// 3829// See PutLoggingConfiguration for details on how to use this API operation. 3830// 3831// The context must be non-nil and will be used for request cancellation. If 3832// the context is nil a panic will occur. In the future the SDK may create 3833// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3834// for more information on using Contexts. 3835func (c *WAFV2) PutLoggingConfigurationWithContext(ctx aws.Context, input *PutLoggingConfigurationInput, opts ...request.Option) (*PutLoggingConfigurationOutput, error) { 3836 req, out := c.PutLoggingConfigurationRequest(input) 3837 req.SetContext(ctx) 3838 req.ApplyOptions(opts...) 3839 return out, req.Send() 3840} 3841 3842const opPutPermissionPolicy = "PutPermissionPolicy" 3843 3844// PutPermissionPolicyRequest generates a "aws/request.Request" representing the 3845// client's request for the PutPermissionPolicy operation. The "output" return 3846// value will be populated with the request's response once the request completes 3847// successfully. 3848// 3849// Use "Send" method on the returned Request to send the API call to the service. 3850// the "output" return value is not valid until after Send returns without error. 3851// 3852// See PutPermissionPolicy for more information on using the PutPermissionPolicy 3853// API call, and error handling. 3854// 3855// This method is useful when you want to inject custom logic or configuration 3856// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3857// 3858// 3859// // Example sending a request using the PutPermissionPolicyRequest method. 3860// req, resp := client.PutPermissionPolicyRequest(params) 3861// 3862// err := req.Send() 3863// if err == nil { // resp is now filled 3864// fmt.Println(resp) 3865// } 3866// 3867// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutPermissionPolicy 3868func (c *WAFV2) PutPermissionPolicyRequest(input *PutPermissionPolicyInput) (req *request.Request, output *PutPermissionPolicyOutput) { 3869 op := &request.Operation{ 3870 Name: opPutPermissionPolicy, 3871 HTTPMethod: "POST", 3872 HTTPPath: "/", 3873 } 3874 3875 if input == nil { 3876 input = &PutPermissionPolicyInput{} 3877 } 3878 3879 output = &PutPermissionPolicyOutput{} 3880 req = c.newRequest(op, input, output) 3881 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3882 return 3883} 3884 3885// PutPermissionPolicy API operation for AWS WAFV2. 3886// 3887// Attaches an IAM policy to the specified resource. Use this to share a rule 3888// group across accounts. 3889// 3890// You must be the owner of the rule group to perform this operation. 3891// 3892// This action is subject to the following restrictions: 3893// 3894// * You can attach only one policy with each PutPermissionPolicy request. 3895// 3896// * The ARN in the request must be a valid WAF RuleGroup ARN and the rule 3897// group must exist in the same region. 3898// 3899// * The user making the request must be the owner of the rule group. 3900// 3901// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3902// with awserr.Error's Code and Message methods to get detailed information about 3903// the error. 3904// 3905// See the AWS API reference guide for AWS WAFV2's 3906// API operation PutPermissionPolicy for usage and error information. 3907// 3908// Returned Error Types: 3909// * WAFNonexistentItemException 3910// AWS WAF couldn’t perform the operation because your resource doesn’t 3911// exist. 3912// 3913// * WAFInternalErrorException 3914// Your request is valid, but AWS WAF couldn’t perform the operation because 3915// of a system problem. Retry your request. 3916// 3917// * WAFInvalidParameterException 3918// The operation failed because AWS WAF didn't recognize a parameter in the 3919// request. For example: 3920// 3921// * You specified an invalid parameter name or value. 3922// 3923// * Your nested statement isn't valid. You might have tried to nest a statement 3924// that can’t be nested. 3925// 3926// * You tried to update a WebACL with a DefaultAction that isn't among the 3927// types available at DefaultAction. 3928// 3929// * Your request references an ARN that is malformed, or corresponds to 3930// a resource with which a Web ACL cannot be associated. 3931// 3932// * WAFInvalidPermissionPolicyException 3933// The operation failed because the specified policy isn't in the proper format. 3934// 3935// The policy specifications must conform to the following: 3936// 3937// * The policy must be composed using IAM Policy version 2012-10-17 or version 3938// 2015-01-01. 3939// 3940// * The policy must include specifications for Effect, Action, and Principal. 3941// 3942// * Effect must specify Allow. 3943// 3944// * Action must specify wafv2:CreateWebACL, wafv2:UpdateWebACL, and wafv2:PutFirewallManagerRuleGroups. 3945// AWS WAF rejects any extra actions or wildcard actions in the policy. 3946// 3947// * The policy must not include a Resource parameter. 3948// 3949// For more information, see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html). 3950// 3951// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/PutPermissionPolicy 3952func (c *WAFV2) PutPermissionPolicy(input *PutPermissionPolicyInput) (*PutPermissionPolicyOutput, error) { 3953 req, out := c.PutPermissionPolicyRequest(input) 3954 return out, req.Send() 3955} 3956 3957// PutPermissionPolicyWithContext is the same as PutPermissionPolicy with the addition of 3958// the ability to pass a context and additional request options. 3959// 3960// See PutPermissionPolicy for details on how to use this API operation. 3961// 3962// The context must be non-nil and will be used for request cancellation. If 3963// the context is nil a panic will occur. In the future the SDK may create 3964// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3965// for more information on using Contexts. 3966func (c *WAFV2) PutPermissionPolicyWithContext(ctx aws.Context, input *PutPermissionPolicyInput, opts ...request.Option) (*PutPermissionPolicyOutput, error) { 3967 req, out := c.PutPermissionPolicyRequest(input) 3968 req.SetContext(ctx) 3969 req.ApplyOptions(opts...) 3970 return out, req.Send() 3971} 3972 3973const opTagResource = "TagResource" 3974 3975// TagResourceRequest generates a "aws/request.Request" representing the 3976// client's request for the TagResource operation. The "output" return 3977// value will be populated with the request's response once the request completes 3978// successfully. 3979// 3980// Use "Send" method on the returned Request to send the API call to the service. 3981// the "output" return value is not valid until after Send returns without error. 3982// 3983// See TagResource for more information on using the TagResource 3984// API call, and error handling. 3985// 3986// This method is useful when you want to inject custom logic or configuration 3987// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3988// 3989// 3990// // Example sending a request using the TagResourceRequest method. 3991// req, resp := client.TagResourceRequest(params) 3992// 3993// err := req.Send() 3994// if err == nil { // resp is now filled 3995// fmt.Println(resp) 3996// } 3997// 3998// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/TagResource 3999func (c *WAFV2) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { 4000 op := &request.Operation{ 4001 Name: opTagResource, 4002 HTTPMethod: "POST", 4003 HTTPPath: "/", 4004 } 4005 4006 if input == nil { 4007 input = &TagResourceInput{} 4008 } 4009 4010 output = &TagResourceOutput{} 4011 req = c.newRequest(op, input, output) 4012 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 4013 return 4014} 4015 4016// TagResource API operation for AWS WAFV2. 4017// 4018// 4019// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4020// 2019. For information, including how to migrate your AWS WAF resources from 4021// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4022// 4023// Associates tags with the specified AWS resource. Tags are key:value pairs 4024// that you can use to categorize and manage your resources, for purposes like 4025// billing. For example, you might set the tag key to "customer" and the value 4026// to the customer name or ID. You can specify one or more tags to add to each 4027// AWS resource, up to 50 tags for a resource. 4028// 4029// You can tag the AWS resources that you manage through AWS WAF: web ACLs, 4030// rule groups, IP sets, and regex pattern sets. You can't manage or view tags 4031// through the AWS WAF console. 4032// 4033// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 4034// with awserr.Error's Code and Message methods to get detailed information about 4035// the error. 4036// 4037// See the AWS API reference guide for AWS WAFV2's 4038// API operation TagResource for usage and error information. 4039// 4040// Returned Error Types: 4041// * WAFInternalErrorException 4042// Your request is valid, but AWS WAF couldn’t perform the operation because 4043// of a system problem. Retry your request. 4044// 4045// * WAFInvalidParameterException 4046// The operation failed because AWS WAF didn't recognize a parameter in the 4047// request. For example: 4048// 4049// * You specified an invalid parameter name or value. 4050// 4051// * Your nested statement isn't valid. You might have tried to nest a statement 4052// that can’t be nested. 4053// 4054// * You tried to update a WebACL with a DefaultAction that isn't among the 4055// types available at DefaultAction. 4056// 4057// * Your request references an ARN that is malformed, or corresponds to 4058// a resource with which a Web ACL cannot be associated. 4059// 4060// * WAFLimitsExceededException 4061// AWS WAF couldn’t perform the operation because you exceeded your resource 4062// limit. For example, the maximum number of WebACL objects that you can create 4063// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 4064// in the AWS WAF Developer Guide. 4065// 4066// * WAFNonexistentItemException 4067// AWS WAF couldn’t perform the operation because your resource doesn’t 4068// exist. 4069// 4070// * WAFTagOperationException 4071// An error occurred during the tagging operation. Retry your request. 4072// 4073// * WAFTagOperationInternalErrorException 4074// AWS WAF couldn’t perform your tagging operation because of an internal 4075// error. Retry your request. 4076// 4077// * WAFInvalidOperationException 4078// The operation isn't valid. 4079// 4080// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/TagResource 4081func (c *WAFV2) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { 4082 req, out := c.TagResourceRequest(input) 4083 return out, req.Send() 4084} 4085 4086// TagResourceWithContext is the same as TagResource with the addition of 4087// the ability to pass a context and additional request options. 4088// 4089// See TagResource for details on how to use this API operation. 4090// 4091// The context must be non-nil and will be used for request cancellation. If 4092// the context is nil a panic will occur. In the future the SDK may create 4093// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 4094// for more information on using Contexts. 4095func (c *WAFV2) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { 4096 req, out := c.TagResourceRequest(input) 4097 req.SetContext(ctx) 4098 req.ApplyOptions(opts...) 4099 return out, req.Send() 4100} 4101 4102const opUntagResource = "UntagResource" 4103 4104// UntagResourceRequest generates a "aws/request.Request" representing the 4105// client's request for the UntagResource operation. The "output" return 4106// value will be populated with the request's response once the request completes 4107// successfully. 4108// 4109// Use "Send" method on the returned Request to send the API call to the service. 4110// the "output" return value is not valid until after Send returns without error. 4111// 4112// See UntagResource for more information on using the UntagResource 4113// API call, and error handling. 4114// 4115// This method is useful when you want to inject custom logic or configuration 4116// into the SDK's request lifecycle. Such as custom headers, or retry logic. 4117// 4118// 4119// // Example sending a request using the UntagResourceRequest method. 4120// req, resp := client.UntagResourceRequest(params) 4121// 4122// err := req.Send() 4123// if err == nil { // resp is now filled 4124// fmt.Println(resp) 4125// } 4126// 4127// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UntagResource 4128func (c *WAFV2) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { 4129 op := &request.Operation{ 4130 Name: opUntagResource, 4131 HTTPMethod: "POST", 4132 HTTPPath: "/", 4133 } 4134 4135 if input == nil { 4136 input = &UntagResourceInput{} 4137 } 4138 4139 output = &UntagResourceOutput{} 4140 req = c.newRequest(op, input, output) 4141 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 4142 return 4143} 4144 4145// UntagResource API operation for AWS WAFV2. 4146// 4147// 4148// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4149// 2019. For information, including how to migrate your AWS WAF resources from 4150// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4151// 4152// Disassociates tags from an AWS resource. Tags are key:value pairs that you 4153// can associate with AWS resources. For example, the tag key might be "customer" 4154// and the tag value might be "companyA." You can specify one or more tags to 4155// add to each container. You can add up to 50 tags to each AWS resource. 4156// 4157// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 4158// with awserr.Error's Code and Message methods to get detailed information about 4159// the error. 4160// 4161// See the AWS API reference guide for AWS WAFV2's 4162// API operation UntagResource for usage and error information. 4163// 4164// Returned Error Types: 4165// * WAFInternalErrorException 4166// Your request is valid, but AWS WAF couldn’t perform the operation because 4167// of a system problem. Retry your request. 4168// 4169// * WAFInvalidParameterException 4170// The operation failed because AWS WAF didn't recognize a parameter in the 4171// request. For example: 4172// 4173// * You specified an invalid parameter name or value. 4174// 4175// * Your nested statement isn't valid. You might have tried to nest a statement 4176// that can’t be nested. 4177// 4178// * You tried to update a WebACL with a DefaultAction that isn't among the 4179// types available at DefaultAction. 4180// 4181// * Your request references an ARN that is malformed, or corresponds to 4182// a resource with which a Web ACL cannot be associated. 4183// 4184// * WAFNonexistentItemException 4185// AWS WAF couldn’t perform the operation because your resource doesn’t 4186// exist. 4187// 4188// * WAFTagOperationException 4189// An error occurred during the tagging operation. Retry your request. 4190// 4191// * WAFTagOperationInternalErrorException 4192// AWS WAF couldn’t perform your tagging operation because of an internal 4193// error. Retry your request. 4194// 4195// * WAFInvalidOperationException 4196// The operation isn't valid. 4197// 4198// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UntagResource 4199func (c *WAFV2) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { 4200 req, out := c.UntagResourceRequest(input) 4201 return out, req.Send() 4202} 4203 4204// UntagResourceWithContext is the same as UntagResource with the addition of 4205// the ability to pass a context and additional request options. 4206// 4207// See UntagResource for details on how to use this API operation. 4208// 4209// The context must be non-nil and will be used for request cancellation. If 4210// the context is nil a panic will occur. In the future the SDK may create 4211// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 4212// for more information on using Contexts. 4213func (c *WAFV2) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { 4214 req, out := c.UntagResourceRequest(input) 4215 req.SetContext(ctx) 4216 req.ApplyOptions(opts...) 4217 return out, req.Send() 4218} 4219 4220const opUpdateIPSet = "UpdateIPSet" 4221 4222// UpdateIPSetRequest generates a "aws/request.Request" representing the 4223// client's request for the UpdateIPSet operation. The "output" return 4224// value will be populated with the request's response once the request completes 4225// successfully. 4226// 4227// Use "Send" method on the returned Request to send the API call to the service. 4228// the "output" return value is not valid until after Send returns without error. 4229// 4230// See UpdateIPSet for more information on using the UpdateIPSet 4231// API call, and error handling. 4232// 4233// This method is useful when you want to inject custom logic or configuration 4234// into the SDK's request lifecycle. Such as custom headers, or retry logic. 4235// 4236// 4237// // Example sending a request using the UpdateIPSetRequest method. 4238// req, resp := client.UpdateIPSetRequest(params) 4239// 4240// err := req.Send() 4241// if err == nil { // resp is now filled 4242// fmt.Println(resp) 4243// } 4244// 4245// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateIPSet 4246func (c *WAFV2) UpdateIPSetRequest(input *UpdateIPSetInput) (req *request.Request, output *UpdateIPSetOutput) { 4247 op := &request.Operation{ 4248 Name: opUpdateIPSet, 4249 HTTPMethod: "POST", 4250 HTTPPath: "/", 4251 } 4252 4253 if input == nil { 4254 input = &UpdateIPSetInput{} 4255 } 4256 4257 output = &UpdateIPSetOutput{} 4258 req = c.newRequest(op, input, output) 4259 return 4260} 4261 4262// UpdateIPSet API operation for AWS WAFV2. 4263// 4264// 4265// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4266// 2019. For information, including how to migrate your AWS WAF resources from 4267// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4268// 4269// Updates the specified IPSet. 4270// 4271// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 4272// with awserr.Error's Code and Message methods to get detailed information about 4273// the error. 4274// 4275// See the AWS API reference guide for AWS WAFV2's 4276// API operation UpdateIPSet for usage and error information. 4277// 4278// Returned Error Types: 4279// * WAFInternalErrorException 4280// Your request is valid, but AWS WAF couldn’t perform the operation because 4281// of a system problem. Retry your request. 4282// 4283// * WAFInvalidParameterException 4284// The operation failed because AWS WAF didn't recognize a parameter in the 4285// request. For example: 4286// 4287// * You specified an invalid parameter name or value. 4288// 4289// * Your nested statement isn't valid. You might have tried to nest a statement 4290// that can’t be nested. 4291// 4292// * You tried to update a WebACL with a DefaultAction that isn't among the 4293// types available at DefaultAction. 4294// 4295// * Your request references an ARN that is malformed, or corresponds to 4296// a resource with which a Web ACL cannot be associated. 4297// 4298// * WAFNonexistentItemException 4299// AWS WAF couldn’t perform the operation because your resource doesn’t 4300// exist. 4301// 4302// * WAFDuplicateItemException 4303// AWS WAF couldn’t perform the operation because the resource that you tried 4304// to save is a duplicate of an existing one. 4305// 4306// * WAFOptimisticLockException 4307// AWS WAF couldn’t save your changes because you tried to update or delete 4308// a resource that has changed since you last retrieved it. Get the resource 4309// again, make any changes you need to make to the new copy, and retry your 4310// operation. 4311// 4312// * WAFLimitsExceededException 4313// AWS WAF couldn’t perform the operation because you exceeded your resource 4314// limit. For example, the maximum number of WebACL objects that you can create 4315// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 4316// in the AWS WAF Developer Guide. 4317// 4318// * WAFInvalidOperationException 4319// The operation isn't valid. 4320// 4321// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateIPSet 4322func (c *WAFV2) UpdateIPSet(input *UpdateIPSetInput) (*UpdateIPSetOutput, error) { 4323 req, out := c.UpdateIPSetRequest(input) 4324 return out, req.Send() 4325} 4326 4327// UpdateIPSetWithContext is the same as UpdateIPSet with the addition of 4328// the ability to pass a context and additional request options. 4329// 4330// See UpdateIPSet for details on how to use this API operation. 4331// 4332// The context must be non-nil and will be used for request cancellation. If 4333// the context is nil a panic will occur. In the future the SDK may create 4334// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 4335// for more information on using Contexts. 4336func (c *WAFV2) UpdateIPSetWithContext(ctx aws.Context, input *UpdateIPSetInput, opts ...request.Option) (*UpdateIPSetOutput, error) { 4337 req, out := c.UpdateIPSetRequest(input) 4338 req.SetContext(ctx) 4339 req.ApplyOptions(opts...) 4340 return out, req.Send() 4341} 4342 4343const opUpdateRegexPatternSet = "UpdateRegexPatternSet" 4344 4345// UpdateRegexPatternSetRequest generates a "aws/request.Request" representing the 4346// client's request for the UpdateRegexPatternSet operation. The "output" return 4347// value will be populated with the request's response once the request completes 4348// successfully. 4349// 4350// Use "Send" method on the returned Request to send the API call to the service. 4351// the "output" return value is not valid until after Send returns without error. 4352// 4353// See UpdateRegexPatternSet for more information on using the UpdateRegexPatternSet 4354// API call, and error handling. 4355// 4356// This method is useful when you want to inject custom logic or configuration 4357// into the SDK's request lifecycle. Such as custom headers, or retry logic. 4358// 4359// 4360// // Example sending a request using the UpdateRegexPatternSetRequest method. 4361// req, resp := client.UpdateRegexPatternSetRequest(params) 4362// 4363// err := req.Send() 4364// if err == nil { // resp is now filled 4365// fmt.Println(resp) 4366// } 4367// 4368// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRegexPatternSet 4369func (c *WAFV2) UpdateRegexPatternSetRequest(input *UpdateRegexPatternSetInput) (req *request.Request, output *UpdateRegexPatternSetOutput) { 4370 op := &request.Operation{ 4371 Name: opUpdateRegexPatternSet, 4372 HTTPMethod: "POST", 4373 HTTPPath: "/", 4374 } 4375 4376 if input == nil { 4377 input = &UpdateRegexPatternSetInput{} 4378 } 4379 4380 output = &UpdateRegexPatternSetOutput{} 4381 req = c.newRequest(op, input, output) 4382 return 4383} 4384 4385// UpdateRegexPatternSet API operation for AWS WAFV2. 4386// 4387// 4388// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4389// 2019. For information, including how to migrate your AWS WAF resources from 4390// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4391// 4392// Updates the specified RegexPatternSet. 4393// 4394// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 4395// with awserr.Error's Code and Message methods to get detailed information about 4396// the error. 4397// 4398// See the AWS API reference guide for AWS WAFV2's 4399// API operation UpdateRegexPatternSet for usage and error information. 4400// 4401// Returned Error Types: 4402// * WAFInternalErrorException 4403// Your request is valid, but AWS WAF couldn’t perform the operation because 4404// of a system problem. Retry your request. 4405// 4406// * WAFInvalidParameterException 4407// The operation failed because AWS WAF didn't recognize a parameter in the 4408// request. For example: 4409// 4410// * You specified an invalid parameter name or value. 4411// 4412// * Your nested statement isn't valid. You might have tried to nest a statement 4413// that can’t be nested. 4414// 4415// * You tried to update a WebACL with a DefaultAction that isn't among the 4416// types available at DefaultAction. 4417// 4418// * Your request references an ARN that is malformed, or corresponds to 4419// a resource with which a Web ACL cannot be associated. 4420// 4421// * WAFNonexistentItemException 4422// AWS WAF couldn’t perform the operation because your resource doesn’t 4423// exist. 4424// 4425// * WAFDuplicateItemException 4426// AWS WAF couldn’t perform the operation because the resource that you tried 4427// to save is a duplicate of an existing one. 4428// 4429// * WAFOptimisticLockException 4430// AWS WAF couldn’t save your changes because you tried to update or delete 4431// a resource that has changed since you last retrieved it. Get the resource 4432// again, make any changes you need to make to the new copy, and retry your 4433// operation. 4434// 4435// * WAFLimitsExceededException 4436// AWS WAF couldn’t perform the operation because you exceeded your resource 4437// limit. For example, the maximum number of WebACL objects that you can create 4438// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 4439// in the AWS WAF Developer Guide. 4440// 4441// * WAFInvalidOperationException 4442// The operation isn't valid. 4443// 4444// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRegexPatternSet 4445func (c *WAFV2) UpdateRegexPatternSet(input *UpdateRegexPatternSetInput) (*UpdateRegexPatternSetOutput, error) { 4446 req, out := c.UpdateRegexPatternSetRequest(input) 4447 return out, req.Send() 4448} 4449 4450// UpdateRegexPatternSetWithContext is the same as UpdateRegexPatternSet with the addition of 4451// the ability to pass a context and additional request options. 4452// 4453// See UpdateRegexPatternSet for details on how to use this API operation. 4454// 4455// The context must be non-nil and will be used for request cancellation. If 4456// the context is nil a panic will occur. In the future the SDK may create 4457// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 4458// for more information on using Contexts. 4459func (c *WAFV2) UpdateRegexPatternSetWithContext(ctx aws.Context, input *UpdateRegexPatternSetInput, opts ...request.Option) (*UpdateRegexPatternSetOutput, error) { 4460 req, out := c.UpdateRegexPatternSetRequest(input) 4461 req.SetContext(ctx) 4462 req.ApplyOptions(opts...) 4463 return out, req.Send() 4464} 4465 4466const opUpdateRuleGroup = "UpdateRuleGroup" 4467 4468// UpdateRuleGroupRequest generates a "aws/request.Request" representing the 4469// client's request for the UpdateRuleGroup operation. The "output" return 4470// value will be populated with the request's response once the request completes 4471// successfully. 4472// 4473// Use "Send" method on the returned Request to send the API call to the service. 4474// the "output" return value is not valid until after Send returns without error. 4475// 4476// See UpdateRuleGroup for more information on using the UpdateRuleGroup 4477// API call, and error handling. 4478// 4479// This method is useful when you want to inject custom logic or configuration 4480// into the SDK's request lifecycle. Such as custom headers, or retry logic. 4481// 4482// 4483// // Example sending a request using the UpdateRuleGroupRequest method. 4484// req, resp := client.UpdateRuleGroupRequest(params) 4485// 4486// err := req.Send() 4487// if err == nil { // resp is now filled 4488// fmt.Println(resp) 4489// } 4490// 4491// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRuleGroup 4492func (c *WAFV2) UpdateRuleGroupRequest(input *UpdateRuleGroupInput) (req *request.Request, output *UpdateRuleGroupOutput) { 4493 op := &request.Operation{ 4494 Name: opUpdateRuleGroup, 4495 HTTPMethod: "POST", 4496 HTTPPath: "/", 4497 } 4498 4499 if input == nil { 4500 input = &UpdateRuleGroupInput{} 4501 } 4502 4503 output = &UpdateRuleGroupOutput{} 4504 req = c.newRequest(op, input, output) 4505 return 4506} 4507 4508// UpdateRuleGroup API operation for AWS WAFV2. 4509// 4510// 4511// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4512// 2019. For information, including how to migrate your AWS WAF resources from 4513// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4514// 4515// Updates the specified RuleGroup. 4516// 4517// A rule group defines a collection of rules to inspect and control web requests 4518// that you can use in a WebACL. When you create a rule group, you define an 4519// immutable capacity limit. If you update a rule group, you must stay within 4520// the capacity. This allows others to reuse the rule group with confidence 4521// in its capacity requirements. 4522// 4523// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 4524// with awserr.Error's Code and Message methods to get detailed information about 4525// the error. 4526// 4527// See the AWS API reference guide for AWS WAFV2's 4528// API operation UpdateRuleGroup for usage and error information. 4529// 4530// Returned Error Types: 4531// * WAFInternalErrorException 4532// Your request is valid, but AWS WAF couldn’t perform the operation because 4533// of a system problem. Retry your request. 4534// 4535// * WAFInvalidParameterException 4536// The operation failed because AWS WAF didn't recognize a parameter in the 4537// request. For example: 4538// 4539// * You specified an invalid parameter name or value. 4540// 4541// * Your nested statement isn't valid. You might have tried to nest a statement 4542// that can’t be nested. 4543// 4544// * You tried to update a WebACL with a DefaultAction that isn't among the 4545// types available at DefaultAction. 4546// 4547// * Your request references an ARN that is malformed, or corresponds to 4548// a resource with which a Web ACL cannot be associated. 4549// 4550// * WAFNonexistentItemException 4551// AWS WAF couldn’t perform the operation because your resource doesn’t 4552// exist. 4553// 4554// * WAFDuplicateItemException 4555// AWS WAF couldn’t perform the operation because the resource that you tried 4556// to save is a duplicate of an existing one. 4557// 4558// * WAFOptimisticLockException 4559// AWS WAF couldn’t save your changes because you tried to update or delete 4560// a resource that has changed since you last retrieved it. Get the resource 4561// again, make any changes you need to make to the new copy, and retry your 4562// operation. 4563// 4564// * WAFLimitsExceededException 4565// AWS WAF couldn’t perform the operation because you exceeded your resource 4566// limit. For example, the maximum number of WebACL objects that you can create 4567// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 4568// in the AWS WAF Developer Guide. 4569// 4570// * WAFUnavailableEntityException 4571// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 4572// 4573// * WAFSubscriptionNotFoundException 4574// 4575// * WAFInvalidOperationException 4576// The operation isn't valid. 4577// 4578// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateRuleGroup 4579func (c *WAFV2) UpdateRuleGroup(input *UpdateRuleGroupInput) (*UpdateRuleGroupOutput, error) { 4580 req, out := c.UpdateRuleGroupRequest(input) 4581 return out, req.Send() 4582} 4583 4584// UpdateRuleGroupWithContext is the same as UpdateRuleGroup with the addition of 4585// the ability to pass a context and additional request options. 4586// 4587// See UpdateRuleGroup for details on how to use this API operation. 4588// 4589// The context must be non-nil and will be used for request cancellation. If 4590// the context is nil a panic will occur. In the future the SDK may create 4591// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 4592// for more information on using Contexts. 4593func (c *WAFV2) UpdateRuleGroupWithContext(ctx aws.Context, input *UpdateRuleGroupInput, opts ...request.Option) (*UpdateRuleGroupOutput, error) { 4594 req, out := c.UpdateRuleGroupRequest(input) 4595 req.SetContext(ctx) 4596 req.ApplyOptions(opts...) 4597 return out, req.Send() 4598} 4599 4600const opUpdateWebACL = "UpdateWebACL" 4601 4602// UpdateWebACLRequest generates a "aws/request.Request" representing the 4603// client's request for the UpdateWebACL operation. The "output" return 4604// value will be populated with the request's response once the request completes 4605// successfully. 4606// 4607// Use "Send" method on the returned Request to send the API call to the service. 4608// the "output" return value is not valid until after Send returns without error. 4609// 4610// See UpdateWebACL for more information on using the UpdateWebACL 4611// API call, and error handling. 4612// 4613// This method is useful when you want to inject custom logic or configuration 4614// into the SDK's request lifecycle. Such as custom headers, or retry logic. 4615// 4616// 4617// // Example sending a request using the UpdateWebACLRequest method. 4618// req, resp := client.UpdateWebACLRequest(params) 4619// 4620// err := req.Send() 4621// if err == nil { // resp is now filled 4622// fmt.Println(resp) 4623// } 4624// 4625// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateWebACL 4626func (c *WAFV2) UpdateWebACLRequest(input *UpdateWebACLInput) (req *request.Request, output *UpdateWebACLOutput) { 4627 op := &request.Operation{ 4628 Name: opUpdateWebACL, 4629 HTTPMethod: "POST", 4630 HTTPPath: "/", 4631 } 4632 4633 if input == nil { 4634 input = &UpdateWebACLInput{} 4635 } 4636 4637 output = &UpdateWebACLOutput{} 4638 req = c.newRequest(op, input, output) 4639 return 4640} 4641 4642// UpdateWebACL API operation for AWS WAFV2. 4643// 4644// 4645// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4646// 2019. For information, including how to migrate your AWS WAF resources from 4647// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4648// 4649// Updates the specified WebACL. 4650// 4651// A Web ACL defines a collection of rules to use to inspect and control web 4652// requests. Each rule has an action defined (allow, block, or count) for requests 4653// that match the statement of the rule. In the Web ACL, you assign a default 4654// action to take (allow, block) for any request that does not match any of 4655// the rules. The rules in a Web ACL can be a combination of the types Rule, 4656// RuleGroup, and managed rule group. You can associate a Web ACL with one or 4657// more AWS resources to protect. The resources can be Amazon CloudFront, an 4658// Amazon API Gateway REST API, an Application Load Balancer, or an AWS AppSync 4659// GraphQL API. 4660// 4661// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 4662// with awserr.Error's Code and Message methods to get detailed information about 4663// the error. 4664// 4665// See the AWS API reference guide for AWS WAFV2's 4666// API operation UpdateWebACL for usage and error information. 4667// 4668// Returned Error Types: 4669// * WAFInternalErrorException 4670// Your request is valid, but AWS WAF couldn’t perform the operation because 4671// of a system problem. Retry your request. 4672// 4673// * WAFInvalidParameterException 4674// The operation failed because AWS WAF didn't recognize a parameter in the 4675// request. For example: 4676// 4677// * You specified an invalid parameter name or value. 4678// 4679// * Your nested statement isn't valid. You might have tried to nest a statement 4680// that can’t be nested. 4681// 4682// * You tried to update a WebACL with a DefaultAction that isn't among the 4683// types available at DefaultAction. 4684// 4685// * Your request references an ARN that is malformed, or corresponds to 4686// a resource with which a Web ACL cannot be associated. 4687// 4688// * WAFNonexistentItemException 4689// AWS WAF couldn’t perform the operation because your resource doesn’t 4690// exist. 4691// 4692// * WAFDuplicateItemException 4693// AWS WAF couldn’t perform the operation because the resource that you tried 4694// to save is a duplicate of an existing one. 4695// 4696// * WAFOptimisticLockException 4697// AWS WAF couldn’t save your changes because you tried to update or delete 4698// a resource that has changed since you last retrieved it. Get the resource 4699// again, make any changes you need to make to the new copy, and retry your 4700// operation. 4701// 4702// * WAFLimitsExceededException 4703// AWS WAF couldn’t perform the operation because you exceeded your resource 4704// limit. For example, the maximum number of WebACL objects that you can create 4705// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 4706// in the AWS WAF Developer Guide. 4707// 4708// * WAFInvalidResourceException 4709// AWS WAF couldn’t perform the operation because the resource that you requested 4710// isn’t valid. Check the resource, and try again. 4711// 4712// * WAFUnavailableEntityException 4713// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 4714// 4715// * WAFSubscriptionNotFoundException 4716// 4717// * WAFInvalidOperationException 4718// The operation isn't valid. 4719// 4720// See also, https://docs.aws.amazon.com/goto/WebAPI/wafv2-2019-07-29/UpdateWebACL 4721func (c *WAFV2) UpdateWebACL(input *UpdateWebACLInput) (*UpdateWebACLOutput, error) { 4722 req, out := c.UpdateWebACLRequest(input) 4723 return out, req.Send() 4724} 4725 4726// UpdateWebACLWithContext is the same as UpdateWebACL with the addition of 4727// the ability to pass a context and additional request options. 4728// 4729// See UpdateWebACL for details on how to use this API operation. 4730// 4731// The context must be non-nil and will be used for request cancellation. If 4732// the context is nil a panic will occur. In the future the SDK may create 4733// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 4734// for more information on using Contexts. 4735func (c *WAFV2) UpdateWebACLWithContext(ctx aws.Context, input *UpdateWebACLInput, opts ...request.Option) (*UpdateWebACLOutput, error) { 4736 req, out := c.UpdateWebACLRequest(input) 4737 req.SetContext(ctx) 4738 req.ApplyOptions(opts...) 4739 return out, req.Send() 4740} 4741 4742// 4743// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4744// 2019. For information, including how to migrate your AWS WAF resources from 4745// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4746// 4747// All query arguments of a web request. 4748// 4749// This is used only to indicate the web request component for AWS WAF to inspect, 4750// in the FieldToMatch specification. 4751type AllQueryArguments struct { 4752 _ struct{} `type:"structure"` 4753} 4754 4755// String returns the string representation 4756func (s AllQueryArguments) String() string { 4757 return awsutil.Prettify(s) 4758} 4759 4760// GoString returns the string representation 4761func (s AllQueryArguments) GoString() string { 4762 return s.String() 4763} 4764 4765// 4766// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4767// 2019. For information, including how to migrate your AWS WAF resources from 4768// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4769// 4770// Specifies that AWS WAF should allow requests. 4771// 4772// This is used only in the context of other settings, for example to specify 4773// values for RuleAction and web ACL DefaultAction. 4774type AllowAction struct { 4775 _ struct{} `type:"structure"` 4776} 4777 4778// String returns the string representation 4779func (s AllowAction) String() string { 4780 return awsutil.Prettify(s) 4781} 4782 4783// GoString returns the string representation 4784func (s AllowAction) GoString() string { 4785 return s.String() 4786} 4787 4788// 4789// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4790// 2019. For information, including how to migrate your AWS WAF resources from 4791// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4792// 4793// A logical rule statement used to combine other rule statements with AND logic. 4794// You provide more than one Statement within the AndStatement. 4795type AndStatement struct { 4796 _ struct{} `type:"structure"` 4797 4798 // The statements to combine with AND logic. You can use any statements that 4799 // can be nested. 4800 // 4801 // Statements is a required field 4802 Statements []*Statement `type:"list" required:"true"` 4803} 4804 4805// String returns the string representation 4806func (s AndStatement) String() string { 4807 return awsutil.Prettify(s) 4808} 4809 4810// GoString returns the string representation 4811func (s AndStatement) GoString() string { 4812 return s.String() 4813} 4814 4815// Validate inspects the fields of the type to determine if they are valid. 4816func (s *AndStatement) Validate() error { 4817 invalidParams := request.ErrInvalidParams{Context: "AndStatement"} 4818 if s.Statements == nil { 4819 invalidParams.Add(request.NewErrParamRequired("Statements")) 4820 } 4821 4822 if invalidParams.Len() > 0 { 4823 return invalidParams 4824 } 4825 return nil 4826} 4827 4828// SetStatements sets the Statements field's value. 4829func (s *AndStatement) SetStatements(v []*Statement) *AndStatement { 4830 s.Statements = v 4831 return s 4832} 4833 4834type AssociateWebACLInput struct { 4835 _ struct{} `type:"structure"` 4836 4837 // The Amazon Resource Name (ARN) of the resource to associate with the web 4838 // ACL. 4839 // 4840 // The ARN must be in one of the following formats: 4841 // 4842 // * For an Application Load Balancer: arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id 4843 // 4844 // * For an API Gateway REST API: arn:aws:apigateway:region::/restapis/api-id/stages/stage-name 4845 // 4846 // * For an AppSync GraphQL API: arn:aws:appsync:region:account-id:apis/GraphQLApiId 4847 // 4848 // ResourceArn is a required field 4849 ResourceArn *string `min:"20" type:"string" required:"true"` 4850 4851 // The Amazon Resource Name (ARN) of the Web ACL that you want to associate 4852 // with the resource. 4853 // 4854 // WebACLArn is a required field 4855 WebACLArn *string `min:"20" type:"string" required:"true"` 4856} 4857 4858// String returns the string representation 4859func (s AssociateWebACLInput) String() string { 4860 return awsutil.Prettify(s) 4861} 4862 4863// GoString returns the string representation 4864func (s AssociateWebACLInput) GoString() string { 4865 return s.String() 4866} 4867 4868// Validate inspects the fields of the type to determine if they are valid. 4869func (s *AssociateWebACLInput) Validate() error { 4870 invalidParams := request.ErrInvalidParams{Context: "AssociateWebACLInput"} 4871 if s.ResourceArn == nil { 4872 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 4873 } 4874 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 4875 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 4876 } 4877 if s.WebACLArn == nil { 4878 invalidParams.Add(request.NewErrParamRequired("WebACLArn")) 4879 } 4880 if s.WebACLArn != nil && len(*s.WebACLArn) < 20 { 4881 invalidParams.Add(request.NewErrParamMinLen("WebACLArn", 20)) 4882 } 4883 4884 if invalidParams.Len() > 0 { 4885 return invalidParams 4886 } 4887 return nil 4888} 4889 4890// SetResourceArn sets the ResourceArn field's value. 4891func (s *AssociateWebACLInput) SetResourceArn(v string) *AssociateWebACLInput { 4892 s.ResourceArn = &v 4893 return s 4894} 4895 4896// SetWebACLArn sets the WebACLArn field's value. 4897func (s *AssociateWebACLInput) SetWebACLArn(v string) *AssociateWebACLInput { 4898 s.WebACLArn = &v 4899 return s 4900} 4901 4902type AssociateWebACLOutput struct { 4903 _ struct{} `type:"structure"` 4904} 4905 4906// String returns the string representation 4907func (s AssociateWebACLOutput) String() string { 4908 return awsutil.Prettify(s) 4909} 4910 4911// GoString returns the string representation 4912func (s AssociateWebACLOutput) GoString() string { 4913 return s.String() 4914} 4915 4916// 4917// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4918// 2019. For information, including how to migrate your AWS WAF resources from 4919// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4920// 4921// Specifies that AWS WAF should block requests. 4922// 4923// This is used only in the context of other settings, for example to specify 4924// values for RuleAction and web ACL DefaultAction. 4925type BlockAction struct { 4926 _ struct{} `type:"structure"` 4927} 4928 4929// String returns the string representation 4930func (s BlockAction) String() string { 4931 return awsutil.Prettify(s) 4932} 4933 4934// GoString returns the string representation 4935func (s BlockAction) GoString() string { 4936 return s.String() 4937} 4938 4939// 4940// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4941// 2019. For information, including how to migrate your AWS WAF resources from 4942// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4943// 4944// The body of a web request. This immediately follows the request headers. 4945// 4946// This is used only to indicate the web request component for AWS WAF to inspect, 4947// in the FieldToMatch specification. 4948type Body struct { 4949 _ struct{} `type:"structure"` 4950} 4951 4952// String returns the string representation 4953func (s Body) String() string { 4954 return awsutil.Prettify(s) 4955} 4956 4957// GoString returns the string representation 4958func (s Body) GoString() string { 4959 return s.String() 4960} 4961 4962// 4963// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 4964// 2019. For information, including how to migrate your AWS WAF resources from 4965// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 4966// 4967// A rule statement that defines a string match search for AWS WAF to apply 4968// to web requests. The byte match statement provides the bytes to search for, 4969// the location in requests that you want AWS WAF to search, and other settings. 4970// The bytes to search for are typically a string that corresponds with ASCII 4971// characters. In the AWS WAF console and the developer guide, this is refered 4972// to as a string match statement. 4973type ByteMatchStatement struct { 4974 _ struct{} `type:"structure"` 4975 4976 // The part of a web request that you want AWS WAF to inspect. For more information, 4977 // see FieldToMatch. 4978 // 4979 // FieldToMatch is a required field 4980 FieldToMatch *FieldToMatch `type:"structure" required:"true"` 4981 4982 // The area within the portion of a web request that you want AWS WAF to search 4983 // for SearchString. Valid values include the following: 4984 // 4985 // CONTAINS 4986 // 4987 // The specified part of the web request must include the value of SearchString, 4988 // but the location doesn't matter. 4989 // 4990 // CONTAINS_WORD 4991 // 4992 // The specified part of the web request must include the value of SearchString, 4993 // and SearchString must contain only alphanumeric characters or underscore 4994 // (A-Z, a-z, 0-9, or _). In addition, SearchString must be a word, which means 4995 // that both of the following are true: 4996 // 4997 // * SearchString is at the beginning of the specified part of the web request 4998 // or is preceded by a character other than an alphanumeric character or 4999 // underscore (_). Examples include the value of a header and ;BadBot. 5000 // 5001 // * SearchString is at the end of the specified part of the web request 5002 // or is followed by a character other than an alphanumeric character or 5003 // underscore (_), for example, BadBot; and -BadBot;. 5004 // 5005 // EXACTLY 5006 // 5007 // The value of the specified part of the web request must exactly match the 5008 // value of SearchString. 5009 // 5010 // STARTS_WITH 5011 // 5012 // The value of SearchString must appear at the beginning of the specified part 5013 // of the web request. 5014 // 5015 // ENDS_WITH 5016 // 5017 // The value of SearchString must appear at the end of the specified part of 5018 // the web request. 5019 // 5020 // PositionalConstraint is a required field 5021 PositionalConstraint *string `type:"string" required:"true" enum:"PositionalConstraint"` 5022 5023 // A string value that you want AWS WAF to search for. AWS WAF searches only 5024 // in the part of web requests that you designate for inspection in FieldToMatch. 5025 // The maximum length of the value is 50 bytes. 5026 // 5027 // Valid values depend on the component that you specify for inspection in FieldToMatch: 5028 // 5029 // * Method: The HTTP method that you want AWS WAF to search for. This indicates 5030 // the type of operation specified in the request. 5031 // 5032 // * UriPath: The value that you want AWS WAF to search for in the URI path, 5033 // for example, /images/daily-ad.jpg. 5034 // 5035 // If SearchString includes alphabetic characters A-Z and a-z, note that the 5036 // value is case sensitive. 5037 // 5038 // If you're using the AWS WAF API 5039 // 5040 // Specify a base64-encoded version of the value. The maximum length of the 5041 // value before you base64-encode it is 50 bytes. 5042 // 5043 // For example, suppose the value of Type is HEADER and the value of Data is 5044 // User-Agent. If you want to search the User-Agent header for the value BadBot, 5045 // you base64-encode BadBot using MIME base64-encoding and include the resulting 5046 // value, QmFkQm90, in the value of SearchString. 5047 // 5048 // If you're using the AWS CLI or one of the AWS SDKs 5049 // 5050 // The value that you want AWS WAF to search for. The SDK automatically base64 5051 // encodes the value. 5052 // 5053 // SearchString is automatically base64 encoded/decoded by the SDK. 5054 // 5055 // SearchString is a required field 5056 SearchString []byte `type:"blob" required:"true"` 5057 5058 // Text transformations eliminate some of the unusual formatting that attackers 5059 // use in web requests in an effort to bypass detection. If you specify one 5060 // or more transformations in a rule statement, AWS WAF performs all transformations 5061 // on the content of the request component identified by FieldToMatch, starting 5062 // from the lowest priority setting, before inspecting the content for a match. 5063 // 5064 // TextTransformations is a required field 5065 TextTransformations []*TextTransformation `min:"1" type:"list" required:"true"` 5066} 5067 5068// String returns the string representation 5069func (s ByteMatchStatement) String() string { 5070 return awsutil.Prettify(s) 5071} 5072 5073// GoString returns the string representation 5074func (s ByteMatchStatement) GoString() string { 5075 return s.String() 5076} 5077 5078// Validate inspects the fields of the type to determine if they are valid. 5079func (s *ByteMatchStatement) Validate() error { 5080 invalidParams := request.ErrInvalidParams{Context: "ByteMatchStatement"} 5081 if s.FieldToMatch == nil { 5082 invalidParams.Add(request.NewErrParamRequired("FieldToMatch")) 5083 } 5084 if s.PositionalConstraint == nil { 5085 invalidParams.Add(request.NewErrParamRequired("PositionalConstraint")) 5086 } 5087 if s.SearchString == nil { 5088 invalidParams.Add(request.NewErrParamRequired("SearchString")) 5089 } 5090 if s.TextTransformations == nil { 5091 invalidParams.Add(request.NewErrParamRequired("TextTransformations")) 5092 } 5093 if s.TextTransformations != nil && len(s.TextTransformations) < 1 { 5094 invalidParams.Add(request.NewErrParamMinLen("TextTransformations", 1)) 5095 } 5096 if s.FieldToMatch != nil { 5097 if err := s.FieldToMatch.Validate(); err != nil { 5098 invalidParams.AddNested("FieldToMatch", err.(request.ErrInvalidParams)) 5099 } 5100 } 5101 if s.TextTransformations != nil { 5102 for i, v := range s.TextTransformations { 5103 if v == nil { 5104 continue 5105 } 5106 if err := v.Validate(); err != nil { 5107 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TextTransformations", i), err.(request.ErrInvalidParams)) 5108 } 5109 } 5110 } 5111 5112 if invalidParams.Len() > 0 { 5113 return invalidParams 5114 } 5115 return nil 5116} 5117 5118// SetFieldToMatch sets the FieldToMatch field's value. 5119func (s *ByteMatchStatement) SetFieldToMatch(v *FieldToMatch) *ByteMatchStatement { 5120 s.FieldToMatch = v 5121 return s 5122} 5123 5124// SetPositionalConstraint sets the PositionalConstraint field's value. 5125func (s *ByteMatchStatement) SetPositionalConstraint(v string) *ByteMatchStatement { 5126 s.PositionalConstraint = &v 5127 return s 5128} 5129 5130// SetSearchString sets the SearchString field's value. 5131func (s *ByteMatchStatement) SetSearchString(v []byte) *ByteMatchStatement { 5132 s.SearchString = v 5133 return s 5134} 5135 5136// SetTextTransformations sets the TextTransformations field's value. 5137func (s *ByteMatchStatement) SetTextTransformations(v []*TextTransformation) *ByteMatchStatement { 5138 s.TextTransformations = v 5139 return s 5140} 5141 5142type CheckCapacityInput struct { 5143 _ struct{} `type:"structure"` 5144 5145 // An array of Rule that you're configuring to use in a rule group or web ACL. 5146 // 5147 // Rules is a required field 5148 Rules []*Rule `type:"list" required:"true"` 5149 5150 // Specifies whether this is for an AWS CloudFront distribution or for a regional 5151 // application. A regional application can be an Application Load Balancer (ALB), 5152 // an API Gateway REST API, or an AppSync GraphQL API. 5153 // 5154 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 5155 // as follows: 5156 // 5157 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 5158 // --region=us-east-1. 5159 // 5160 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 5161 // 5162 // Scope is a required field 5163 Scope *string `type:"string" required:"true" enum:"Scope"` 5164} 5165 5166// String returns the string representation 5167func (s CheckCapacityInput) String() string { 5168 return awsutil.Prettify(s) 5169} 5170 5171// GoString returns the string representation 5172func (s CheckCapacityInput) GoString() string { 5173 return s.String() 5174} 5175 5176// Validate inspects the fields of the type to determine if they are valid. 5177func (s *CheckCapacityInput) Validate() error { 5178 invalidParams := request.ErrInvalidParams{Context: "CheckCapacityInput"} 5179 if s.Rules == nil { 5180 invalidParams.Add(request.NewErrParamRequired("Rules")) 5181 } 5182 if s.Scope == nil { 5183 invalidParams.Add(request.NewErrParamRequired("Scope")) 5184 } 5185 if s.Rules != nil { 5186 for i, v := range s.Rules { 5187 if v == nil { 5188 continue 5189 } 5190 if err := v.Validate(); err != nil { 5191 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 5192 } 5193 } 5194 } 5195 5196 if invalidParams.Len() > 0 { 5197 return invalidParams 5198 } 5199 return nil 5200} 5201 5202// SetRules sets the Rules field's value. 5203func (s *CheckCapacityInput) SetRules(v []*Rule) *CheckCapacityInput { 5204 s.Rules = v 5205 return s 5206} 5207 5208// SetScope sets the Scope field's value. 5209func (s *CheckCapacityInput) SetScope(v string) *CheckCapacityInput { 5210 s.Scope = &v 5211 return s 5212} 5213 5214type CheckCapacityOutput struct { 5215 _ struct{} `type:"structure"` 5216 5217 // The capacity required by the rules and scope. 5218 Capacity *int64 `type:"long"` 5219} 5220 5221// String returns the string representation 5222func (s CheckCapacityOutput) String() string { 5223 return awsutil.Prettify(s) 5224} 5225 5226// GoString returns the string representation 5227func (s CheckCapacityOutput) GoString() string { 5228 return s.String() 5229} 5230 5231// SetCapacity sets the Capacity field's value. 5232func (s *CheckCapacityOutput) SetCapacity(v int64) *CheckCapacityOutput { 5233 s.Capacity = &v 5234 return s 5235} 5236 5237// 5238// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 5239// 2019. For information, including how to migrate your AWS WAF resources from 5240// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 5241// 5242// Specifies that AWS WAF should count requests. 5243// 5244// This is used only in the context of other settings, for example to specify 5245// values for RuleAction and web ACL DefaultAction. 5246type CountAction struct { 5247 _ struct{} `type:"structure"` 5248} 5249 5250// String returns the string representation 5251func (s CountAction) String() string { 5252 return awsutil.Prettify(s) 5253} 5254 5255// GoString returns the string representation 5256func (s CountAction) GoString() string { 5257 return s.String() 5258} 5259 5260type CreateIPSetInput struct { 5261 _ struct{} `type:"structure"` 5262 5263 // Contains an array of strings that specify one or more IP addresses or blocks 5264 // of IP addresses in Classless Inter-Domain Routing (CIDR) notation. AWS WAF 5265 // supports all address ranges for IP versions IPv4 and IPv6. 5266 // 5267 // Examples: 5268 // 5269 // * To configure AWS WAF to allow, block, or count requests that originated 5270 // from the IP address 192.0.2.44, specify 192.0.2.44/32. 5271 // 5272 // * To configure AWS WAF to allow, block, or count requests that originated 5273 // from IP addresses from 192.0.2.0 to 192.0.2.255, specify 192.0.2.0/24. 5274 // 5275 // * To configure AWS WAF to allow, block, or count requests that originated 5276 // from the IP address 1111:0000:0000:0000:0000:0000:0000:0111, specify 1111:0000:0000:0000:0000:0000:0000:0111/128. 5277 // 5278 // * To configure AWS WAF to allow, block, or count requests that originated 5279 // from IP addresses 1111:0000:0000:0000:0000:0000:0000:0000 to 1111:0000:0000:0000:ffff:ffff:ffff:ffff, 5280 // specify 1111:0000:0000:0000:0000:0000:0000:0000/64. 5281 // 5282 // For more information about CIDR notation, see the Wikipedia entry Classless 5283 // Inter-Domain Routing (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing). 5284 // 5285 // Addresses is a required field 5286 Addresses []*string `type:"list" required:"true"` 5287 5288 // A description of the IP set that helps with identification. You cannot change 5289 // the description of an IP set after you create it. 5290 Description *string `min:"1" type:"string"` 5291 5292 // Specify IPV4 or IPV6. 5293 // 5294 // IPAddressVersion is a required field 5295 IPAddressVersion *string `type:"string" required:"true" enum:"IPAddressVersion"` 5296 5297 // The name of the IP set. You cannot change the name of an IPSet after you 5298 // create it. 5299 // 5300 // Name is a required field 5301 Name *string `min:"1" type:"string" required:"true"` 5302 5303 // Specifies whether this is for an AWS CloudFront distribution or for a regional 5304 // application. A regional application can be an Application Load Balancer (ALB), 5305 // an API Gateway REST API, or an AppSync GraphQL API. 5306 // 5307 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 5308 // as follows: 5309 // 5310 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 5311 // --region=us-east-1. 5312 // 5313 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 5314 // 5315 // Scope is a required field 5316 Scope *string `type:"string" required:"true" enum:"Scope"` 5317 5318 // An array of key:value pairs to associate with the resource. 5319 Tags []*Tag `min:"1" type:"list"` 5320} 5321 5322// String returns the string representation 5323func (s CreateIPSetInput) String() string { 5324 return awsutil.Prettify(s) 5325} 5326 5327// GoString returns the string representation 5328func (s CreateIPSetInput) GoString() string { 5329 return s.String() 5330} 5331 5332// Validate inspects the fields of the type to determine if they are valid. 5333func (s *CreateIPSetInput) Validate() error { 5334 invalidParams := request.ErrInvalidParams{Context: "CreateIPSetInput"} 5335 if s.Addresses == nil { 5336 invalidParams.Add(request.NewErrParamRequired("Addresses")) 5337 } 5338 if s.Description != nil && len(*s.Description) < 1 { 5339 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 5340 } 5341 if s.IPAddressVersion == nil { 5342 invalidParams.Add(request.NewErrParamRequired("IPAddressVersion")) 5343 } 5344 if s.Name == nil { 5345 invalidParams.Add(request.NewErrParamRequired("Name")) 5346 } 5347 if s.Name != nil && len(*s.Name) < 1 { 5348 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 5349 } 5350 if s.Scope == nil { 5351 invalidParams.Add(request.NewErrParamRequired("Scope")) 5352 } 5353 if s.Tags != nil && len(s.Tags) < 1 { 5354 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 5355 } 5356 if s.Tags != nil { 5357 for i, v := range s.Tags { 5358 if v == nil { 5359 continue 5360 } 5361 if err := v.Validate(); err != nil { 5362 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 5363 } 5364 } 5365 } 5366 5367 if invalidParams.Len() > 0 { 5368 return invalidParams 5369 } 5370 return nil 5371} 5372 5373// SetAddresses sets the Addresses field's value. 5374func (s *CreateIPSetInput) SetAddresses(v []*string) *CreateIPSetInput { 5375 s.Addresses = v 5376 return s 5377} 5378 5379// SetDescription sets the Description field's value. 5380func (s *CreateIPSetInput) SetDescription(v string) *CreateIPSetInput { 5381 s.Description = &v 5382 return s 5383} 5384 5385// SetIPAddressVersion sets the IPAddressVersion field's value. 5386func (s *CreateIPSetInput) SetIPAddressVersion(v string) *CreateIPSetInput { 5387 s.IPAddressVersion = &v 5388 return s 5389} 5390 5391// SetName sets the Name field's value. 5392func (s *CreateIPSetInput) SetName(v string) *CreateIPSetInput { 5393 s.Name = &v 5394 return s 5395} 5396 5397// SetScope sets the Scope field's value. 5398func (s *CreateIPSetInput) SetScope(v string) *CreateIPSetInput { 5399 s.Scope = &v 5400 return s 5401} 5402 5403// SetTags sets the Tags field's value. 5404func (s *CreateIPSetInput) SetTags(v []*Tag) *CreateIPSetInput { 5405 s.Tags = v 5406 return s 5407} 5408 5409type CreateIPSetOutput struct { 5410 _ struct{} `type:"structure"` 5411 5412 // High-level information about an IPSet, returned by operations like create 5413 // and list. This provides information like the ID, that you can use to retrieve 5414 // and manage an IPSet, and the ARN, that you provide to the IPSetReferenceStatement 5415 // to use the address set in a Rule. 5416 Summary *IPSetSummary `type:"structure"` 5417} 5418 5419// String returns the string representation 5420func (s CreateIPSetOutput) String() string { 5421 return awsutil.Prettify(s) 5422} 5423 5424// GoString returns the string representation 5425func (s CreateIPSetOutput) GoString() string { 5426 return s.String() 5427} 5428 5429// SetSummary sets the Summary field's value. 5430func (s *CreateIPSetOutput) SetSummary(v *IPSetSummary) *CreateIPSetOutput { 5431 s.Summary = v 5432 return s 5433} 5434 5435type CreateRegexPatternSetInput struct { 5436 _ struct{} `type:"structure"` 5437 5438 // A description of the set that helps with identification. You cannot change 5439 // the description of a set after you create it. 5440 Description *string `min:"1" type:"string"` 5441 5442 // The name of the set. You cannot change the name after you create the set. 5443 // 5444 // Name is a required field 5445 Name *string `min:"1" type:"string" required:"true"` 5446 5447 // Array of regular expression strings. 5448 // 5449 // RegularExpressionList is a required field 5450 RegularExpressionList []*Regex `type:"list" required:"true"` 5451 5452 // Specifies whether this is for an AWS CloudFront distribution or for a regional 5453 // application. A regional application can be an Application Load Balancer (ALB), 5454 // an API Gateway REST API, or an AppSync GraphQL API. 5455 // 5456 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 5457 // as follows: 5458 // 5459 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 5460 // --region=us-east-1. 5461 // 5462 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 5463 // 5464 // Scope is a required field 5465 Scope *string `type:"string" required:"true" enum:"Scope"` 5466 5467 // An array of key:value pairs to associate with the resource. 5468 Tags []*Tag `min:"1" type:"list"` 5469} 5470 5471// String returns the string representation 5472func (s CreateRegexPatternSetInput) String() string { 5473 return awsutil.Prettify(s) 5474} 5475 5476// GoString returns the string representation 5477func (s CreateRegexPatternSetInput) GoString() string { 5478 return s.String() 5479} 5480 5481// Validate inspects the fields of the type to determine if they are valid. 5482func (s *CreateRegexPatternSetInput) Validate() error { 5483 invalidParams := request.ErrInvalidParams{Context: "CreateRegexPatternSetInput"} 5484 if s.Description != nil && len(*s.Description) < 1 { 5485 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 5486 } 5487 if s.Name == nil { 5488 invalidParams.Add(request.NewErrParamRequired("Name")) 5489 } 5490 if s.Name != nil && len(*s.Name) < 1 { 5491 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 5492 } 5493 if s.RegularExpressionList == nil { 5494 invalidParams.Add(request.NewErrParamRequired("RegularExpressionList")) 5495 } 5496 if s.Scope == nil { 5497 invalidParams.Add(request.NewErrParamRequired("Scope")) 5498 } 5499 if s.Tags != nil && len(s.Tags) < 1 { 5500 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 5501 } 5502 if s.RegularExpressionList != nil { 5503 for i, v := range s.RegularExpressionList { 5504 if v == nil { 5505 continue 5506 } 5507 if err := v.Validate(); err != nil { 5508 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RegularExpressionList", i), err.(request.ErrInvalidParams)) 5509 } 5510 } 5511 } 5512 if s.Tags != nil { 5513 for i, v := range s.Tags { 5514 if v == nil { 5515 continue 5516 } 5517 if err := v.Validate(); err != nil { 5518 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 5519 } 5520 } 5521 } 5522 5523 if invalidParams.Len() > 0 { 5524 return invalidParams 5525 } 5526 return nil 5527} 5528 5529// SetDescription sets the Description field's value. 5530func (s *CreateRegexPatternSetInput) SetDescription(v string) *CreateRegexPatternSetInput { 5531 s.Description = &v 5532 return s 5533} 5534 5535// SetName sets the Name field's value. 5536func (s *CreateRegexPatternSetInput) SetName(v string) *CreateRegexPatternSetInput { 5537 s.Name = &v 5538 return s 5539} 5540 5541// SetRegularExpressionList sets the RegularExpressionList field's value. 5542func (s *CreateRegexPatternSetInput) SetRegularExpressionList(v []*Regex) *CreateRegexPatternSetInput { 5543 s.RegularExpressionList = v 5544 return s 5545} 5546 5547// SetScope sets the Scope field's value. 5548func (s *CreateRegexPatternSetInput) SetScope(v string) *CreateRegexPatternSetInput { 5549 s.Scope = &v 5550 return s 5551} 5552 5553// SetTags sets the Tags field's value. 5554func (s *CreateRegexPatternSetInput) SetTags(v []*Tag) *CreateRegexPatternSetInput { 5555 s.Tags = v 5556 return s 5557} 5558 5559type CreateRegexPatternSetOutput struct { 5560 _ struct{} `type:"structure"` 5561 5562 // High-level information about a RegexPatternSet, returned by operations like 5563 // create and list. This provides information like the ID, that you can use 5564 // to retrieve and manage a RegexPatternSet, and the ARN, that you provide to 5565 // the RegexPatternSetReferenceStatement to use the pattern set in a Rule. 5566 Summary *RegexPatternSetSummary `type:"structure"` 5567} 5568 5569// String returns the string representation 5570func (s CreateRegexPatternSetOutput) String() string { 5571 return awsutil.Prettify(s) 5572} 5573 5574// GoString returns the string representation 5575func (s CreateRegexPatternSetOutput) GoString() string { 5576 return s.String() 5577} 5578 5579// SetSummary sets the Summary field's value. 5580func (s *CreateRegexPatternSetOutput) SetSummary(v *RegexPatternSetSummary) *CreateRegexPatternSetOutput { 5581 s.Summary = v 5582 return s 5583} 5584 5585type CreateRuleGroupInput struct { 5586 _ struct{} `type:"structure"` 5587 5588 // The web ACL capacity units (WCUs) required for this rule group. 5589 // 5590 // When you create your own rule group, you define this, and you cannot change 5591 // it after creation. When you add or modify the rules in a rule group, AWS 5592 // WAF enforces this limit. You can check the capacity for a set of rules using 5593 // CheckCapacity. 5594 // 5595 // AWS WAF uses WCUs to calculate and control the operating resources that are 5596 // used to run your rules, rule groups, and web ACLs. AWS WAF calculates capacity 5597 // differently for each rule type, to reflect the relative cost of each rule. 5598 // Simple rules that cost little to run use fewer WCUs than more complex rules 5599 // that use more processing power. Rule group capacity is fixed at creation, 5600 // which helps users plan their web ACL WCU usage when they use a rule group. 5601 // The WCU limit for web ACLs is 1,500. 5602 // 5603 // Capacity is a required field 5604 Capacity *int64 `min:"1" type:"long" required:"true"` 5605 5606 // A description of the rule group that helps with identification. You cannot 5607 // change the description of a rule group after you create it. 5608 Description *string `min:"1" type:"string"` 5609 5610 // The name of the rule group. You cannot change the name of a rule group after 5611 // you create it. 5612 // 5613 // Name is a required field 5614 Name *string `min:"1" type:"string" required:"true"` 5615 5616 // The Rule statements used to identify the web requests that you want to allow, 5617 // block, or count. Each rule includes one top-level statement that AWS WAF 5618 // uses to identify matching web requests, and parameters that govern how AWS 5619 // WAF handles them. 5620 Rules []*Rule `type:"list"` 5621 5622 // Specifies whether this is for an AWS CloudFront distribution or for a regional 5623 // application. A regional application can be an Application Load Balancer (ALB), 5624 // an API Gateway REST API, or an AppSync GraphQL API. 5625 // 5626 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 5627 // as follows: 5628 // 5629 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 5630 // --region=us-east-1. 5631 // 5632 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 5633 // 5634 // Scope is a required field 5635 Scope *string `type:"string" required:"true" enum:"Scope"` 5636 5637 // An array of key:value pairs to associate with the resource. 5638 Tags []*Tag `min:"1" type:"list"` 5639 5640 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 5641 // 5642 // VisibilityConfig is a required field 5643 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 5644} 5645 5646// String returns the string representation 5647func (s CreateRuleGroupInput) String() string { 5648 return awsutil.Prettify(s) 5649} 5650 5651// GoString returns the string representation 5652func (s CreateRuleGroupInput) GoString() string { 5653 return s.String() 5654} 5655 5656// Validate inspects the fields of the type to determine if they are valid. 5657func (s *CreateRuleGroupInput) Validate() error { 5658 invalidParams := request.ErrInvalidParams{Context: "CreateRuleGroupInput"} 5659 if s.Capacity == nil { 5660 invalidParams.Add(request.NewErrParamRequired("Capacity")) 5661 } 5662 if s.Capacity != nil && *s.Capacity < 1 { 5663 invalidParams.Add(request.NewErrParamMinValue("Capacity", 1)) 5664 } 5665 if s.Description != nil && len(*s.Description) < 1 { 5666 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 5667 } 5668 if s.Name == nil { 5669 invalidParams.Add(request.NewErrParamRequired("Name")) 5670 } 5671 if s.Name != nil && len(*s.Name) < 1 { 5672 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 5673 } 5674 if s.Scope == nil { 5675 invalidParams.Add(request.NewErrParamRequired("Scope")) 5676 } 5677 if s.Tags != nil && len(s.Tags) < 1 { 5678 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 5679 } 5680 if s.VisibilityConfig == nil { 5681 invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) 5682 } 5683 if s.Rules != nil { 5684 for i, v := range s.Rules { 5685 if v == nil { 5686 continue 5687 } 5688 if err := v.Validate(); err != nil { 5689 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 5690 } 5691 } 5692 } 5693 if s.Tags != nil { 5694 for i, v := range s.Tags { 5695 if v == nil { 5696 continue 5697 } 5698 if err := v.Validate(); err != nil { 5699 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 5700 } 5701 } 5702 } 5703 if s.VisibilityConfig != nil { 5704 if err := s.VisibilityConfig.Validate(); err != nil { 5705 invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) 5706 } 5707 } 5708 5709 if invalidParams.Len() > 0 { 5710 return invalidParams 5711 } 5712 return nil 5713} 5714 5715// SetCapacity sets the Capacity field's value. 5716func (s *CreateRuleGroupInput) SetCapacity(v int64) *CreateRuleGroupInput { 5717 s.Capacity = &v 5718 return s 5719} 5720 5721// SetDescription sets the Description field's value. 5722func (s *CreateRuleGroupInput) SetDescription(v string) *CreateRuleGroupInput { 5723 s.Description = &v 5724 return s 5725} 5726 5727// SetName sets the Name field's value. 5728func (s *CreateRuleGroupInput) SetName(v string) *CreateRuleGroupInput { 5729 s.Name = &v 5730 return s 5731} 5732 5733// SetRules sets the Rules field's value. 5734func (s *CreateRuleGroupInput) SetRules(v []*Rule) *CreateRuleGroupInput { 5735 s.Rules = v 5736 return s 5737} 5738 5739// SetScope sets the Scope field's value. 5740func (s *CreateRuleGroupInput) SetScope(v string) *CreateRuleGroupInput { 5741 s.Scope = &v 5742 return s 5743} 5744 5745// SetTags sets the Tags field's value. 5746func (s *CreateRuleGroupInput) SetTags(v []*Tag) *CreateRuleGroupInput { 5747 s.Tags = v 5748 return s 5749} 5750 5751// SetVisibilityConfig sets the VisibilityConfig field's value. 5752func (s *CreateRuleGroupInput) SetVisibilityConfig(v *VisibilityConfig) *CreateRuleGroupInput { 5753 s.VisibilityConfig = v 5754 return s 5755} 5756 5757type CreateRuleGroupOutput struct { 5758 _ struct{} `type:"structure"` 5759 5760 // High-level information about a RuleGroup, returned by operations like create 5761 // and list. This provides information like the ID, that you can use to retrieve 5762 // and manage a RuleGroup, and the ARN, that you provide to the RuleGroupReferenceStatement 5763 // to use the rule group in a Rule. 5764 Summary *RuleGroupSummary `type:"structure"` 5765} 5766 5767// String returns the string representation 5768func (s CreateRuleGroupOutput) String() string { 5769 return awsutil.Prettify(s) 5770} 5771 5772// GoString returns the string representation 5773func (s CreateRuleGroupOutput) GoString() string { 5774 return s.String() 5775} 5776 5777// SetSummary sets the Summary field's value. 5778func (s *CreateRuleGroupOutput) SetSummary(v *RuleGroupSummary) *CreateRuleGroupOutput { 5779 s.Summary = v 5780 return s 5781} 5782 5783type CreateWebACLInput struct { 5784 _ struct{} `type:"structure"` 5785 5786 // The action to perform if none of the Rules contained in the WebACL match. 5787 // 5788 // DefaultAction is a required field 5789 DefaultAction *DefaultAction `type:"structure" required:"true"` 5790 5791 // A description of the Web ACL that helps with identification. You cannot change 5792 // the description of a Web ACL after you create it. 5793 Description *string `min:"1" type:"string"` 5794 5795 // The name of the Web ACL. You cannot change the name of a Web ACL after you 5796 // create it. 5797 // 5798 // Name is a required field 5799 Name *string `min:"1" type:"string" required:"true"` 5800 5801 // The Rule statements used to identify the web requests that you want to allow, 5802 // block, or count. Each rule includes one top-level statement that AWS WAF 5803 // uses to identify matching web requests, and parameters that govern how AWS 5804 // WAF handles them. 5805 Rules []*Rule `type:"list"` 5806 5807 // Specifies whether this is for an AWS CloudFront distribution or for a regional 5808 // application. A regional application can be an Application Load Balancer (ALB), 5809 // an API Gateway REST API, or an AppSync GraphQL API. 5810 // 5811 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 5812 // as follows: 5813 // 5814 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 5815 // --region=us-east-1. 5816 // 5817 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 5818 // 5819 // Scope is a required field 5820 Scope *string `type:"string" required:"true" enum:"Scope"` 5821 5822 // An array of key:value pairs to associate with the resource. 5823 Tags []*Tag `min:"1" type:"list"` 5824 5825 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 5826 // 5827 // VisibilityConfig is a required field 5828 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 5829} 5830 5831// String returns the string representation 5832func (s CreateWebACLInput) String() string { 5833 return awsutil.Prettify(s) 5834} 5835 5836// GoString returns the string representation 5837func (s CreateWebACLInput) GoString() string { 5838 return s.String() 5839} 5840 5841// Validate inspects the fields of the type to determine if they are valid. 5842func (s *CreateWebACLInput) Validate() error { 5843 invalidParams := request.ErrInvalidParams{Context: "CreateWebACLInput"} 5844 if s.DefaultAction == nil { 5845 invalidParams.Add(request.NewErrParamRequired("DefaultAction")) 5846 } 5847 if s.Description != nil && len(*s.Description) < 1 { 5848 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 5849 } 5850 if s.Name == nil { 5851 invalidParams.Add(request.NewErrParamRequired("Name")) 5852 } 5853 if s.Name != nil && len(*s.Name) < 1 { 5854 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 5855 } 5856 if s.Scope == nil { 5857 invalidParams.Add(request.NewErrParamRequired("Scope")) 5858 } 5859 if s.Tags != nil && len(s.Tags) < 1 { 5860 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 5861 } 5862 if s.VisibilityConfig == nil { 5863 invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) 5864 } 5865 if s.Rules != nil { 5866 for i, v := range s.Rules { 5867 if v == nil { 5868 continue 5869 } 5870 if err := v.Validate(); err != nil { 5871 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 5872 } 5873 } 5874 } 5875 if s.Tags != nil { 5876 for i, v := range s.Tags { 5877 if v == nil { 5878 continue 5879 } 5880 if err := v.Validate(); err != nil { 5881 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 5882 } 5883 } 5884 } 5885 if s.VisibilityConfig != nil { 5886 if err := s.VisibilityConfig.Validate(); err != nil { 5887 invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) 5888 } 5889 } 5890 5891 if invalidParams.Len() > 0 { 5892 return invalidParams 5893 } 5894 return nil 5895} 5896 5897// SetDefaultAction sets the DefaultAction field's value. 5898func (s *CreateWebACLInput) SetDefaultAction(v *DefaultAction) *CreateWebACLInput { 5899 s.DefaultAction = v 5900 return s 5901} 5902 5903// SetDescription sets the Description field's value. 5904func (s *CreateWebACLInput) SetDescription(v string) *CreateWebACLInput { 5905 s.Description = &v 5906 return s 5907} 5908 5909// SetName sets the Name field's value. 5910func (s *CreateWebACLInput) SetName(v string) *CreateWebACLInput { 5911 s.Name = &v 5912 return s 5913} 5914 5915// SetRules sets the Rules field's value. 5916func (s *CreateWebACLInput) SetRules(v []*Rule) *CreateWebACLInput { 5917 s.Rules = v 5918 return s 5919} 5920 5921// SetScope sets the Scope field's value. 5922func (s *CreateWebACLInput) SetScope(v string) *CreateWebACLInput { 5923 s.Scope = &v 5924 return s 5925} 5926 5927// SetTags sets the Tags field's value. 5928func (s *CreateWebACLInput) SetTags(v []*Tag) *CreateWebACLInput { 5929 s.Tags = v 5930 return s 5931} 5932 5933// SetVisibilityConfig sets the VisibilityConfig field's value. 5934func (s *CreateWebACLInput) SetVisibilityConfig(v *VisibilityConfig) *CreateWebACLInput { 5935 s.VisibilityConfig = v 5936 return s 5937} 5938 5939type CreateWebACLOutput struct { 5940 _ struct{} `type:"structure"` 5941 5942 // High-level information about a WebACL, returned by operations like create 5943 // and list. This provides information like the ID, that you can use to retrieve 5944 // and manage a WebACL, and the ARN, that you provide to operations like AssociateWebACL. 5945 Summary *WebACLSummary `type:"structure"` 5946} 5947 5948// String returns the string representation 5949func (s CreateWebACLOutput) String() string { 5950 return awsutil.Prettify(s) 5951} 5952 5953// GoString returns the string representation 5954func (s CreateWebACLOutput) GoString() string { 5955 return s.String() 5956} 5957 5958// SetSummary sets the Summary field's value. 5959func (s *CreateWebACLOutput) SetSummary(v *WebACLSummary) *CreateWebACLOutput { 5960 s.Summary = v 5961 return s 5962} 5963 5964// 5965// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 5966// 2019. For information, including how to migrate your AWS WAF resources from 5967// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 5968// 5969// In a WebACL, this is the action that you want AWS WAF to perform when a web 5970// request doesn't match any of the rules in the WebACL. The default action 5971// must be a terminating action, so count is not allowed. 5972type DefaultAction struct { 5973 _ struct{} `type:"structure"` 5974 5975 // Specifies that AWS WAF should allow requests by default. 5976 Allow *AllowAction `type:"structure"` 5977 5978 // Specifies that AWS WAF should block requests by default. 5979 Block *BlockAction `type:"structure"` 5980} 5981 5982// String returns the string representation 5983func (s DefaultAction) String() string { 5984 return awsutil.Prettify(s) 5985} 5986 5987// GoString returns the string representation 5988func (s DefaultAction) GoString() string { 5989 return s.String() 5990} 5991 5992// SetAllow sets the Allow field's value. 5993func (s *DefaultAction) SetAllow(v *AllowAction) *DefaultAction { 5994 s.Allow = v 5995 return s 5996} 5997 5998// SetBlock sets the Block field's value. 5999func (s *DefaultAction) SetBlock(v *BlockAction) *DefaultAction { 6000 s.Block = v 6001 return s 6002} 6003 6004type DeleteFirewallManagerRuleGroupsInput struct { 6005 _ struct{} `type:"structure"` 6006 6007 // The Amazon Resource Name (ARN) of the web ACL. 6008 // 6009 // WebACLArn is a required field 6010 WebACLArn *string `min:"20" type:"string" required:"true"` 6011 6012 // A token used for optimistic locking. AWS WAF returns a token to your get 6013 // and list requests, to mark the state of the entity at the time of the request. 6014 // To make changes to the entity associated with the token, you provide the 6015 // token to operations like update and delete. AWS WAF uses the token to ensure 6016 // that no changes have been made to the entity since you last retrieved it. 6017 // If a change has been made, the update fails with a WAFOptimisticLockException. 6018 // If this happens, perform another get, and use the new token returned by that 6019 // operation. 6020 // 6021 // WebACLLockToken is a required field 6022 WebACLLockToken *string `min:"1" type:"string" required:"true"` 6023} 6024 6025// String returns the string representation 6026func (s DeleteFirewallManagerRuleGroupsInput) String() string { 6027 return awsutil.Prettify(s) 6028} 6029 6030// GoString returns the string representation 6031func (s DeleteFirewallManagerRuleGroupsInput) GoString() string { 6032 return s.String() 6033} 6034 6035// Validate inspects the fields of the type to determine if they are valid. 6036func (s *DeleteFirewallManagerRuleGroupsInput) Validate() error { 6037 invalidParams := request.ErrInvalidParams{Context: "DeleteFirewallManagerRuleGroupsInput"} 6038 if s.WebACLArn == nil { 6039 invalidParams.Add(request.NewErrParamRequired("WebACLArn")) 6040 } 6041 if s.WebACLArn != nil && len(*s.WebACLArn) < 20 { 6042 invalidParams.Add(request.NewErrParamMinLen("WebACLArn", 20)) 6043 } 6044 if s.WebACLLockToken == nil { 6045 invalidParams.Add(request.NewErrParamRequired("WebACLLockToken")) 6046 } 6047 if s.WebACLLockToken != nil && len(*s.WebACLLockToken) < 1 { 6048 invalidParams.Add(request.NewErrParamMinLen("WebACLLockToken", 1)) 6049 } 6050 6051 if invalidParams.Len() > 0 { 6052 return invalidParams 6053 } 6054 return nil 6055} 6056 6057// SetWebACLArn sets the WebACLArn field's value. 6058func (s *DeleteFirewallManagerRuleGroupsInput) SetWebACLArn(v string) *DeleteFirewallManagerRuleGroupsInput { 6059 s.WebACLArn = &v 6060 return s 6061} 6062 6063// SetWebACLLockToken sets the WebACLLockToken field's value. 6064func (s *DeleteFirewallManagerRuleGroupsInput) SetWebACLLockToken(v string) *DeleteFirewallManagerRuleGroupsInput { 6065 s.WebACLLockToken = &v 6066 return s 6067} 6068 6069type DeleteFirewallManagerRuleGroupsOutput struct { 6070 _ struct{} `type:"structure"` 6071 6072 // A token used for optimistic locking. AWS WAF returns a token to your get 6073 // and list requests, to mark the state of the entity at the time of the request. 6074 // To make changes to the entity associated with the token, you provide the 6075 // token to operations like update and delete. AWS WAF uses the token to ensure 6076 // that no changes have been made to the entity since you last retrieved it. 6077 // If a change has been made, the update fails with a WAFOptimisticLockException. 6078 // If this happens, perform another get, and use the new token returned by that 6079 // operation. 6080 NextWebACLLockToken *string `min:"1" type:"string"` 6081} 6082 6083// String returns the string representation 6084func (s DeleteFirewallManagerRuleGroupsOutput) String() string { 6085 return awsutil.Prettify(s) 6086} 6087 6088// GoString returns the string representation 6089func (s DeleteFirewallManagerRuleGroupsOutput) GoString() string { 6090 return s.String() 6091} 6092 6093// SetNextWebACLLockToken sets the NextWebACLLockToken field's value. 6094func (s *DeleteFirewallManagerRuleGroupsOutput) SetNextWebACLLockToken(v string) *DeleteFirewallManagerRuleGroupsOutput { 6095 s.NextWebACLLockToken = &v 6096 return s 6097} 6098 6099type DeleteIPSetInput struct { 6100 _ struct{} `type:"structure"` 6101 6102 // A unique identifier for the set. This ID is returned in the responses to 6103 // create and list commands. You provide it to operations like update and delete. 6104 // 6105 // Id is a required field 6106 Id *string `min:"1" type:"string" required:"true"` 6107 6108 // A token used for optimistic locking. AWS WAF returns a token to your get 6109 // and list requests, to mark the state of the entity at the time of the request. 6110 // To make changes to the entity associated with the token, you provide the 6111 // token to operations like update and delete. AWS WAF uses the token to ensure 6112 // that no changes have been made to the entity since you last retrieved it. 6113 // If a change has been made, the update fails with a WAFOptimisticLockException. 6114 // If this happens, perform another get, and use the new token returned by that 6115 // operation. 6116 // 6117 // LockToken is a required field 6118 LockToken *string `min:"1" type:"string" required:"true"` 6119 6120 // The name of the IP set. You cannot change the name of an IPSet after you 6121 // create it. 6122 // 6123 // Name is a required field 6124 Name *string `min:"1" type:"string" required:"true"` 6125 6126 // Specifies whether this is for an AWS CloudFront distribution or for a regional 6127 // application. A regional application can be an Application Load Balancer (ALB), 6128 // an API Gateway REST API, or an AppSync GraphQL API. 6129 // 6130 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 6131 // as follows: 6132 // 6133 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 6134 // --region=us-east-1. 6135 // 6136 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 6137 // 6138 // Scope is a required field 6139 Scope *string `type:"string" required:"true" enum:"Scope"` 6140} 6141 6142// String returns the string representation 6143func (s DeleteIPSetInput) String() string { 6144 return awsutil.Prettify(s) 6145} 6146 6147// GoString returns the string representation 6148func (s DeleteIPSetInput) GoString() string { 6149 return s.String() 6150} 6151 6152// Validate inspects the fields of the type to determine if they are valid. 6153func (s *DeleteIPSetInput) Validate() error { 6154 invalidParams := request.ErrInvalidParams{Context: "DeleteIPSetInput"} 6155 if s.Id == nil { 6156 invalidParams.Add(request.NewErrParamRequired("Id")) 6157 } 6158 if s.Id != nil && len(*s.Id) < 1 { 6159 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 6160 } 6161 if s.LockToken == nil { 6162 invalidParams.Add(request.NewErrParamRequired("LockToken")) 6163 } 6164 if s.LockToken != nil && len(*s.LockToken) < 1 { 6165 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 6166 } 6167 if s.Name == nil { 6168 invalidParams.Add(request.NewErrParamRequired("Name")) 6169 } 6170 if s.Name != nil && len(*s.Name) < 1 { 6171 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6172 } 6173 if s.Scope == nil { 6174 invalidParams.Add(request.NewErrParamRequired("Scope")) 6175 } 6176 6177 if invalidParams.Len() > 0 { 6178 return invalidParams 6179 } 6180 return nil 6181} 6182 6183// SetId sets the Id field's value. 6184func (s *DeleteIPSetInput) SetId(v string) *DeleteIPSetInput { 6185 s.Id = &v 6186 return s 6187} 6188 6189// SetLockToken sets the LockToken field's value. 6190func (s *DeleteIPSetInput) SetLockToken(v string) *DeleteIPSetInput { 6191 s.LockToken = &v 6192 return s 6193} 6194 6195// SetName sets the Name field's value. 6196func (s *DeleteIPSetInput) SetName(v string) *DeleteIPSetInput { 6197 s.Name = &v 6198 return s 6199} 6200 6201// SetScope sets the Scope field's value. 6202func (s *DeleteIPSetInput) SetScope(v string) *DeleteIPSetInput { 6203 s.Scope = &v 6204 return s 6205} 6206 6207type DeleteIPSetOutput struct { 6208 _ struct{} `type:"structure"` 6209} 6210 6211// String returns the string representation 6212func (s DeleteIPSetOutput) String() string { 6213 return awsutil.Prettify(s) 6214} 6215 6216// GoString returns the string representation 6217func (s DeleteIPSetOutput) GoString() string { 6218 return s.String() 6219} 6220 6221type DeleteLoggingConfigurationInput struct { 6222 _ struct{} `type:"structure"` 6223 6224 // The Amazon Resource Name (ARN) of the web ACL from which you want to delete 6225 // the LoggingConfiguration. 6226 // 6227 // ResourceArn is a required field 6228 ResourceArn *string `min:"20" type:"string" required:"true"` 6229} 6230 6231// String returns the string representation 6232func (s DeleteLoggingConfigurationInput) String() string { 6233 return awsutil.Prettify(s) 6234} 6235 6236// GoString returns the string representation 6237func (s DeleteLoggingConfigurationInput) GoString() string { 6238 return s.String() 6239} 6240 6241// Validate inspects the fields of the type to determine if they are valid. 6242func (s *DeleteLoggingConfigurationInput) Validate() error { 6243 invalidParams := request.ErrInvalidParams{Context: "DeleteLoggingConfigurationInput"} 6244 if s.ResourceArn == nil { 6245 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 6246 } 6247 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 6248 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 6249 } 6250 6251 if invalidParams.Len() > 0 { 6252 return invalidParams 6253 } 6254 return nil 6255} 6256 6257// SetResourceArn sets the ResourceArn field's value. 6258func (s *DeleteLoggingConfigurationInput) SetResourceArn(v string) *DeleteLoggingConfigurationInput { 6259 s.ResourceArn = &v 6260 return s 6261} 6262 6263type DeleteLoggingConfigurationOutput struct { 6264 _ struct{} `type:"structure"` 6265} 6266 6267// String returns the string representation 6268func (s DeleteLoggingConfigurationOutput) String() string { 6269 return awsutil.Prettify(s) 6270} 6271 6272// GoString returns the string representation 6273func (s DeleteLoggingConfigurationOutput) GoString() string { 6274 return s.String() 6275} 6276 6277type DeletePermissionPolicyInput struct { 6278 _ struct{} `type:"structure"` 6279 6280 // The Amazon Resource Name (ARN) of the rule group from which you want to delete 6281 // the policy. 6282 // 6283 // You must be the owner of the rule group to perform this operation. 6284 // 6285 // ResourceArn is a required field 6286 ResourceArn *string `min:"20" type:"string" required:"true"` 6287} 6288 6289// String returns the string representation 6290func (s DeletePermissionPolicyInput) String() string { 6291 return awsutil.Prettify(s) 6292} 6293 6294// GoString returns the string representation 6295func (s DeletePermissionPolicyInput) GoString() string { 6296 return s.String() 6297} 6298 6299// Validate inspects the fields of the type to determine if they are valid. 6300func (s *DeletePermissionPolicyInput) Validate() error { 6301 invalidParams := request.ErrInvalidParams{Context: "DeletePermissionPolicyInput"} 6302 if s.ResourceArn == nil { 6303 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 6304 } 6305 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 6306 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 6307 } 6308 6309 if invalidParams.Len() > 0 { 6310 return invalidParams 6311 } 6312 return nil 6313} 6314 6315// SetResourceArn sets the ResourceArn field's value. 6316func (s *DeletePermissionPolicyInput) SetResourceArn(v string) *DeletePermissionPolicyInput { 6317 s.ResourceArn = &v 6318 return s 6319} 6320 6321type DeletePermissionPolicyOutput struct { 6322 _ struct{} `type:"structure"` 6323} 6324 6325// String returns the string representation 6326func (s DeletePermissionPolicyOutput) String() string { 6327 return awsutil.Prettify(s) 6328} 6329 6330// GoString returns the string representation 6331func (s DeletePermissionPolicyOutput) GoString() string { 6332 return s.String() 6333} 6334 6335type DeleteRegexPatternSetInput struct { 6336 _ struct{} `type:"structure"` 6337 6338 // A unique identifier for the set. This ID is returned in the responses to 6339 // create and list commands. You provide it to operations like update and delete. 6340 // 6341 // Id is a required field 6342 Id *string `min:"1" type:"string" required:"true"` 6343 6344 // A token used for optimistic locking. AWS WAF returns a token to your get 6345 // and list requests, to mark the state of the entity at the time of the request. 6346 // To make changes to the entity associated with the token, you provide the 6347 // token to operations like update and delete. AWS WAF uses the token to ensure 6348 // that no changes have been made to the entity since you last retrieved it. 6349 // If a change has been made, the update fails with a WAFOptimisticLockException. 6350 // If this happens, perform another get, and use the new token returned by that 6351 // operation. 6352 // 6353 // LockToken is a required field 6354 LockToken *string `min:"1" type:"string" required:"true"` 6355 6356 // The name of the set. You cannot change the name after you create the set. 6357 // 6358 // Name is a required field 6359 Name *string `min:"1" type:"string" required:"true"` 6360 6361 // Specifies whether this is for an AWS CloudFront distribution or for a regional 6362 // application. A regional application can be an Application Load Balancer (ALB), 6363 // an API Gateway REST API, or an AppSync GraphQL API. 6364 // 6365 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 6366 // as follows: 6367 // 6368 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 6369 // --region=us-east-1. 6370 // 6371 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 6372 // 6373 // Scope is a required field 6374 Scope *string `type:"string" required:"true" enum:"Scope"` 6375} 6376 6377// String returns the string representation 6378func (s DeleteRegexPatternSetInput) String() string { 6379 return awsutil.Prettify(s) 6380} 6381 6382// GoString returns the string representation 6383func (s DeleteRegexPatternSetInput) GoString() string { 6384 return s.String() 6385} 6386 6387// Validate inspects the fields of the type to determine if they are valid. 6388func (s *DeleteRegexPatternSetInput) Validate() error { 6389 invalidParams := request.ErrInvalidParams{Context: "DeleteRegexPatternSetInput"} 6390 if s.Id == nil { 6391 invalidParams.Add(request.NewErrParamRequired("Id")) 6392 } 6393 if s.Id != nil && len(*s.Id) < 1 { 6394 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 6395 } 6396 if s.LockToken == nil { 6397 invalidParams.Add(request.NewErrParamRequired("LockToken")) 6398 } 6399 if s.LockToken != nil && len(*s.LockToken) < 1 { 6400 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 6401 } 6402 if s.Name == nil { 6403 invalidParams.Add(request.NewErrParamRequired("Name")) 6404 } 6405 if s.Name != nil && len(*s.Name) < 1 { 6406 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6407 } 6408 if s.Scope == nil { 6409 invalidParams.Add(request.NewErrParamRequired("Scope")) 6410 } 6411 6412 if invalidParams.Len() > 0 { 6413 return invalidParams 6414 } 6415 return nil 6416} 6417 6418// SetId sets the Id field's value. 6419func (s *DeleteRegexPatternSetInput) SetId(v string) *DeleteRegexPatternSetInput { 6420 s.Id = &v 6421 return s 6422} 6423 6424// SetLockToken sets the LockToken field's value. 6425func (s *DeleteRegexPatternSetInput) SetLockToken(v string) *DeleteRegexPatternSetInput { 6426 s.LockToken = &v 6427 return s 6428} 6429 6430// SetName sets the Name field's value. 6431func (s *DeleteRegexPatternSetInput) SetName(v string) *DeleteRegexPatternSetInput { 6432 s.Name = &v 6433 return s 6434} 6435 6436// SetScope sets the Scope field's value. 6437func (s *DeleteRegexPatternSetInput) SetScope(v string) *DeleteRegexPatternSetInput { 6438 s.Scope = &v 6439 return s 6440} 6441 6442type DeleteRegexPatternSetOutput struct { 6443 _ struct{} `type:"structure"` 6444} 6445 6446// String returns the string representation 6447func (s DeleteRegexPatternSetOutput) String() string { 6448 return awsutil.Prettify(s) 6449} 6450 6451// GoString returns the string representation 6452func (s DeleteRegexPatternSetOutput) GoString() string { 6453 return s.String() 6454} 6455 6456type DeleteRuleGroupInput struct { 6457 _ struct{} `type:"structure"` 6458 6459 // A unique identifier for the rule group. This ID is returned in the responses 6460 // to create and list commands. You provide it to operations like update and 6461 // delete. 6462 // 6463 // Id is a required field 6464 Id *string `min:"1" type:"string" required:"true"` 6465 6466 // A token used for optimistic locking. AWS WAF returns a token to your get 6467 // and list requests, to mark the state of the entity at the time of the request. 6468 // To make changes to the entity associated with the token, you provide the 6469 // token to operations like update and delete. AWS WAF uses the token to ensure 6470 // that no changes have been made to the entity since you last retrieved it. 6471 // If a change has been made, the update fails with a WAFOptimisticLockException. 6472 // If this happens, perform another get, and use the new token returned by that 6473 // operation. 6474 // 6475 // LockToken is a required field 6476 LockToken *string `min:"1" type:"string" required:"true"` 6477 6478 // The name of the rule group. You cannot change the name of a rule group after 6479 // you create it. 6480 // 6481 // Name is a required field 6482 Name *string `min:"1" type:"string" required:"true"` 6483 6484 // Specifies whether this is for an AWS CloudFront distribution or for a regional 6485 // application. A regional application can be an Application Load Balancer (ALB), 6486 // an API Gateway REST API, or an AppSync GraphQL API. 6487 // 6488 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 6489 // as follows: 6490 // 6491 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 6492 // --region=us-east-1. 6493 // 6494 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 6495 // 6496 // Scope is a required field 6497 Scope *string `type:"string" required:"true" enum:"Scope"` 6498} 6499 6500// String returns the string representation 6501func (s DeleteRuleGroupInput) String() string { 6502 return awsutil.Prettify(s) 6503} 6504 6505// GoString returns the string representation 6506func (s DeleteRuleGroupInput) GoString() string { 6507 return s.String() 6508} 6509 6510// Validate inspects the fields of the type to determine if they are valid. 6511func (s *DeleteRuleGroupInput) Validate() error { 6512 invalidParams := request.ErrInvalidParams{Context: "DeleteRuleGroupInput"} 6513 if s.Id == nil { 6514 invalidParams.Add(request.NewErrParamRequired("Id")) 6515 } 6516 if s.Id != nil && len(*s.Id) < 1 { 6517 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 6518 } 6519 if s.LockToken == nil { 6520 invalidParams.Add(request.NewErrParamRequired("LockToken")) 6521 } 6522 if s.LockToken != nil && len(*s.LockToken) < 1 { 6523 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 6524 } 6525 if s.Name == nil { 6526 invalidParams.Add(request.NewErrParamRequired("Name")) 6527 } 6528 if s.Name != nil && len(*s.Name) < 1 { 6529 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6530 } 6531 if s.Scope == nil { 6532 invalidParams.Add(request.NewErrParamRequired("Scope")) 6533 } 6534 6535 if invalidParams.Len() > 0 { 6536 return invalidParams 6537 } 6538 return nil 6539} 6540 6541// SetId sets the Id field's value. 6542func (s *DeleteRuleGroupInput) SetId(v string) *DeleteRuleGroupInput { 6543 s.Id = &v 6544 return s 6545} 6546 6547// SetLockToken sets the LockToken field's value. 6548func (s *DeleteRuleGroupInput) SetLockToken(v string) *DeleteRuleGroupInput { 6549 s.LockToken = &v 6550 return s 6551} 6552 6553// SetName sets the Name field's value. 6554func (s *DeleteRuleGroupInput) SetName(v string) *DeleteRuleGroupInput { 6555 s.Name = &v 6556 return s 6557} 6558 6559// SetScope sets the Scope field's value. 6560func (s *DeleteRuleGroupInput) SetScope(v string) *DeleteRuleGroupInput { 6561 s.Scope = &v 6562 return s 6563} 6564 6565type DeleteRuleGroupOutput struct { 6566 _ struct{} `type:"structure"` 6567} 6568 6569// String returns the string representation 6570func (s DeleteRuleGroupOutput) String() string { 6571 return awsutil.Prettify(s) 6572} 6573 6574// GoString returns the string representation 6575func (s DeleteRuleGroupOutput) GoString() string { 6576 return s.String() 6577} 6578 6579type DeleteWebACLInput struct { 6580 _ struct{} `type:"structure"` 6581 6582 // The unique identifier for the Web ACL. This ID is returned in the responses 6583 // to create and list commands. You provide it to operations like update and 6584 // delete. 6585 // 6586 // Id is a required field 6587 Id *string `min:"1" type:"string" required:"true"` 6588 6589 // A token used for optimistic locking. AWS WAF returns a token to your get 6590 // and list requests, to mark the state of the entity at the time of the request. 6591 // To make changes to the entity associated with the token, you provide the 6592 // token to operations like update and delete. AWS WAF uses the token to ensure 6593 // that no changes have been made to the entity since you last retrieved it. 6594 // If a change has been made, the update fails with a WAFOptimisticLockException. 6595 // If this happens, perform another get, and use the new token returned by that 6596 // operation. 6597 // 6598 // LockToken is a required field 6599 LockToken *string `min:"1" type:"string" required:"true"` 6600 6601 // The name of the Web ACL. You cannot change the name of a Web ACL after you 6602 // create it. 6603 // 6604 // Name is a required field 6605 Name *string `min:"1" type:"string" required:"true"` 6606 6607 // Specifies whether this is for an AWS CloudFront distribution or for a regional 6608 // application. A regional application can be an Application Load Balancer (ALB), 6609 // an API Gateway REST API, or an AppSync GraphQL API. 6610 // 6611 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 6612 // as follows: 6613 // 6614 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 6615 // --region=us-east-1. 6616 // 6617 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 6618 // 6619 // Scope is a required field 6620 Scope *string `type:"string" required:"true" enum:"Scope"` 6621} 6622 6623// String returns the string representation 6624func (s DeleteWebACLInput) String() string { 6625 return awsutil.Prettify(s) 6626} 6627 6628// GoString returns the string representation 6629func (s DeleteWebACLInput) GoString() string { 6630 return s.String() 6631} 6632 6633// Validate inspects the fields of the type to determine if they are valid. 6634func (s *DeleteWebACLInput) Validate() error { 6635 invalidParams := request.ErrInvalidParams{Context: "DeleteWebACLInput"} 6636 if s.Id == nil { 6637 invalidParams.Add(request.NewErrParamRequired("Id")) 6638 } 6639 if s.Id != nil && len(*s.Id) < 1 { 6640 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 6641 } 6642 if s.LockToken == nil { 6643 invalidParams.Add(request.NewErrParamRequired("LockToken")) 6644 } 6645 if s.LockToken != nil && len(*s.LockToken) < 1 { 6646 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 6647 } 6648 if s.Name == nil { 6649 invalidParams.Add(request.NewErrParamRequired("Name")) 6650 } 6651 if s.Name != nil && len(*s.Name) < 1 { 6652 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6653 } 6654 if s.Scope == nil { 6655 invalidParams.Add(request.NewErrParamRequired("Scope")) 6656 } 6657 6658 if invalidParams.Len() > 0 { 6659 return invalidParams 6660 } 6661 return nil 6662} 6663 6664// SetId sets the Id field's value. 6665func (s *DeleteWebACLInput) SetId(v string) *DeleteWebACLInput { 6666 s.Id = &v 6667 return s 6668} 6669 6670// SetLockToken sets the LockToken field's value. 6671func (s *DeleteWebACLInput) SetLockToken(v string) *DeleteWebACLInput { 6672 s.LockToken = &v 6673 return s 6674} 6675 6676// SetName sets the Name field's value. 6677func (s *DeleteWebACLInput) SetName(v string) *DeleteWebACLInput { 6678 s.Name = &v 6679 return s 6680} 6681 6682// SetScope sets the Scope field's value. 6683func (s *DeleteWebACLInput) SetScope(v string) *DeleteWebACLInput { 6684 s.Scope = &v 6685 return s 6686} 6687 6688type DeleteWebACLOutput struct { 6689 _ struct{} `type:"structure"` 6690} 6691 6692// String returns the string representation 6693func (s DeleteWebACLOutput) String() string { 6694 return awsutil.Prettify(s) 6695} 6696 6697// GoString returns the string representation 6698func (s DeleteWebACLOutput) GoString() string { 6699 return s.String() 6700} 6701 6702type DescribeManagedRuleGroupInput struct { 6703 _ struct{} `type:"structure"` 6704 6705 // The name of the managed rule group. You use this, along with the vendor name, 6706 // to identify the rule group. 6707 // 6708 // Name is a required field 6709 Name *string `min:"1" type:"string" required:"true"` 6710 6711 // Specifies whether this is for an AWS CloudFront distribution or for a regional 6712 // application. A regional application can be an Application Load Balancer (ALB), 6713 // an API Gateway REST API, or an AppSync GraphQL API. 6714 // 6715 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 6716 // as follows: 6717 // 6718 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 6719 // --region=us-east-1. 6720 // 6721 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 6722 // 6723 // Scope is a required field 6724 Scope *string `type:"string" required:"true" enum:"Scope"` 6725 6726 // The name of the managed rule group vendor. You use this, along with the rule 6727 // group name, to identify the rule group. 6728 // 6729 // VendorName is a required field 6730 VendorName *string `min:"1" type:"string" required:"true"` 6731} 6732 6733// String returns the string representation 6734func (s DescribeManagedRuleGroupInput) String() string { 6735 return awsutil.Prettify(s) 6736} 6737 6738// GoString returns the string representation 6739func (s DescribeManagedRuleGroupInput) GoString() string { 6740 return s.String() 6741} 6742 6743// Validate inspects the fields of the type to determine if they are valid. 6744func (s *DescribeManagedRuleGroupInput) Validate() error { 6745 invalidParams := request.ErrInvalidParams{Context: "DescribeManagedRuleGroupInput"} 6746 if s.Name == nil { 6747 invalidParams.Add(request.NewErrParamRequired("Name")) 6748 } 6749 if s.Name != nil && len(*s.Name) < 1 { 6750 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6751 } 6752 if s.Scope == nil { 6753 invalidParams.Add(request.NewErrParamRequired("Scope")) 6754 } 6755 if s.VendorName == nil { 6756 invalidParams.Add(request.NewErrParamRequired("VendorName")) 6757 } 6758 if s.VendorName != nil && len(*s.VendorName) < 1 { 6759 invalidParams.Add(request.NewErrParamMinLen("VendorName", 1)) 6760 } 6761 6762 if invalidParams.Len() > 0 { 6763 return invalidParams 6764 } 6765 return nil 6766} 6767 6768// SetName sets the Name field's value. 6769func (s *DescribeManagedRuleGroupInput) SetName(v string) *DescribeManagedRuleGroupInput { 6770 s.Name = &v 6771 return s 6772} 6773 6774// SetScope sets the Scope field's value. 6775func (s *DescribeManagedRuleGroupInput) SetScope(v string) *DescribeManagedRuleGroupInput { 6776 s.Scope = &v 6777 return s 6778} 6779 6780// SetVendorName sets the VendorName field's value. 6781func (s *DescribeManagedRuleGroupInput) SetVendorName(v string) *DescribeManagedRuleGroupInput { 6782 s.VendorName = &v 6783 return s 6784} 6785 6786type DescribeManagedRuleGroupOutput struct { 6787 _ struct{} `type:"structure"` 6788 6789 // The web ACL capacity units (WCUs) required for this rule group. AWS WAF uses 6790 // web ACL capacity units (WCU) to calculate and control the operating resources 6791 // that are used to run your rules, rule groups, and web ACLs. AWS WAF calculates 6792 // capacity differently for each rule type, to reflect each rule's relative 6793 // cost. Rule group capacity is fixed at creation, so users can plan their web 6794 // ACL WCU usage when they use a rule group. The WCU limit for web ACLs is 1,500. 6795 Capacity *int64 `min:"1" type:"long"` 6796 6797 Rules []*RuleSummary `type:"list"` 6798} 6799 6800// String returns the string representation 6801func (s DescribeManagedRuleGroupOutput) String() string { 6802 return awsutil.Prettify(s) 6803} 6804 6805// GoString returns the string representation 6806func (s DescribeManagedRuleGroupOutput) GoString() string { 6807 return s.String() 6808} 6809 6810// SetCapacity sets the Capacity field's value. 6811func (s *DescribeManagedRuleGroupOutput) SetCapacity(v int64) *DescribeManagedRuleGroupOutput { 6812 s.Capacity = &v 6813 return s 6814} 6815 6816// SetRules sets the Rules field's value. 6817func (s *DescribeManagedRuleGroupOutput) SetRules(v []*RuleSummary) *DescribeManagedRuleGroupOutput { 6818 s.Rules = v 6819 return s 6820} 6821 6822type DisassociateWebACLInput struct { 6823 _ struct{} `type:"structure"` 6824 6825 // The Amazon Resource Name (ARN) of the resource to disassociate from the web 6826 // ACL. 6827 // 6828 // The ARN must be in one of the following formats: 6829 // 6830 // * For an Application Load Balancer: arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id 6831 // 6832 // * For an API Gateway REST API: arn:aws:apigateway:region::/restapis/api-id/stages/stage-name 6833 // 6834 // * For an AppSync GraphQL API: arn:aws:appsync:region:account-id:apis/GraphQLApiId 6835 // 6836 // ResourceArn is a required field 6837 ResourceArn *string `min:"20" type:"string" required:"true"` 6838} 6839 6840// String returns the string representation 6841func (s DisassociateWebACLInput) String() string { 6842 return awsutil.Prettify(s) 6843} 6844 6845// GoString returns the string representation 6846func (s DisassociateWebACLInput) GoString() string { 6847 return s.String() 6848} 6849 6850// Validate inspects the fields of the type to determine if they are valid. 6851func (s *DisassociateWebACLInput) Validate() error { 6852 invalidParams := request.ErrInvalidParams{Context: "DisassociateWebACLInput"} 6853 if s.ResourceArn == nil { 6854 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 6855 } 6856 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 6857 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 6858 } 6859 6860 if invalidParams.Len() > 0 { 6861 return invalidParams 6862 } 6863 return nil 6864} 6865 6866// SetResourceArn sets the ResourceArn field's value. 6867func (s *DisassociateWebACLInput) SetResourceArn(v string) *DisassociateWebACLInput { 6868 s.ResourceArn = &v 6869 return s 6870} 6871 6872type DisassociateWebACLOutput struct { 6873 _ struct{} `type:"structure"` 6874} 6875 6876// String returns the string representation 6877func (s DisassociateWebACLOutput) String() string { 6878 return awsutil.Prettify(s) 6879} 6880 6881// GoString returns the string representation 6882func (s DisassociateWebACLOutput) GoString() string { 6883 return s.String() 6884} 6885 6886// 6887// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 6888// 2019. For information, including how to migrate your AWS WAF resources from 6889// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 6890// 6891// Specifies a single rule to exclude from the rule group. Excluding a rule 6892// overrides its action setting for the rule group in the web ACL, setting it 6893// to COUNT. This effectively excludes the rule from acting on web requests. 6894type ExcludedRule struct { 6895 _ struct{} `type:"structure"` 6896 6897 // The name of the rule to exclude. 6898 // 6899 // Name is a required field 6900 Name *string `min:"1" type:"string" required:"true"` 6901} 6902 6903// String returns the string representation 6904func (s ExcludedRule) String() string { 6905 return awsutil.Prettify(s) 6906} 6907 6908// GoString returns the string representation 6909func (s ExcludedRule) GoString() string { 6910 return s.String() 6911} 6912 6913// Validate inspects the fields of the type to determine if they are valid. 6914func (s *ExcludedRule) Validate() error { 6915 invalidParams := request.ErrInvalidParams{Context: "ExcludedRule"} 6916 if s.Name == nil { 6917 invalidParams.Add(request.NewErrParamRequired("Name")) 6918 } 6919 if s.Name != nil && len(*s.Name) < 1 { 6920 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6921 } 6922 6923 if invalidParams.Len() > 0 { 6924 return invalidParams 6925 } 6926 return nil 6927} 6928 6929// SetName sets the Name field's value. 6930func (s *ExcludedRule) SetName(v string) *ExcludedRule { 6931 s.Name = &v 6932 return s 6933} 6934 6935// 6936// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 6937// 2019. For information, including how to migrate your AWS WAF resources from 6938// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 6939// 6940// The part of a web request that you want AWS WAF to inspect. Include the single 6941// FieldToMatch type that you want to inspect, with additional specifications 6942// as needed, according to the type. You specify a single request component 6943// in FieldToMatch for each rule statement that requires it. To inspect more 6944// than one component of a web request, create a separate rule statement for 6945// each component. 6946type FieldToMatch struct { 6947 _ struct{} `type:"structure"` 6948 6949 // Inspect all query arguments. 6950 AllQueryArguments *AllQueryArguments `type:"structure"` 6951 6952 // Inspect the request body, which immediately follows the request headers. 6953 // This is the part of a request that contains any additional data that you 6954 // want to send to your web server as the HTTP request body, such as data from 6955 // a form. 6956 // 6957 // Note that only the first 8 KB (8192 bytes) of the request body are forwarded 6958 // to AWS WAF for inspection by the underlying host service. If you don't need 6959 // to inspect more than 8 KB, you can guarantee that you don't allow additional 6960 // bytes in by combining a statement that inspects the body of the web request, 6961 // such as ByteMatchStatement or RegexPatternSetReferenceStatement, with a SizeConstraintStatement 6962 // that enforces an 8 KB size limit on the body of the request. AWS WAF doesn't 6963 // support inspecting the entire contents of web requests whose bodies exceed 6964 // the 8 KB limit. 6965 Body *Body `type:"structure"` 6966 6967 // Inspect the HTTP method. The method indicates the type of operation that 6968 // the request is asking the origin to perform. 6969 Method *Method `type:"structure"` 6970 6971 // Inspect the query string. This is the part of a URL that appears after a 6972 // ? character, if any. 6973 QueryString *QueryString `type:"structure"` 6974 6975 // Inspect a single header. Provide the name of the header to inspect, for example, 6976 // User-Agent or Referer. This setting isn't case sensitive. 6977 SingleHeader *SingleHeader `type:"structure"` 6978 6979 // Inspect a single query argument. Provide the name of the query argument to 6980 // inspect, such as UserName or SalesRegion. The name can be up to 30 characters 6981 // long and isn't case sensitive. 6982 // 6983 // This is used only to indicate the web request component for AWS WAF to inspect, 6984 // in the FieldToMatch specification. 6985 SingleQueryArgument *SingleQueryArgument `type:"structure"` 6986 6987 // Inspect the request URI path. This is the part of a web request that identifies 6988 // a resource, for example, /images/daily-ad.jpg. 6989 UriPath *UriPath `type:"structure"` 6990} 6991 6992// String returns the string representation 6993func (s FieldToMatch) String() string { 6994 return awsutil.Prettify(s) 6995} 6996 6997// GoString returns the string representation 6998func (s FieldToMatch) GoString() string { 6999 return s.String() 7000} 7001 7002// Validate inspects the fields of the type to determine if they are valid. 7003func (s *FieldToMatch) Validate() error { 7004 invalidParams := request.ErrInvalidParams{Context: "FieldToMatch"} 7005 if s.SingleHeader != nil { 7006 if err := s.SingleHeader.Validate(); err != nil { 7007 invalidParams.AddNested("SingleHeader", err.(request.ErrInvalidParams)) 7008 } 7009 } 7010 if s.SingleQueryArgument != nil { 7011 if err := s.SingleQueryArgument.Validate(); err != nil { 7012 invalidParams.AddNested("SingleQueryArgument", err.(request.ErrInvalidParams)) 7013 } 7014 } 7015 7016 if invalidParams.Len() > 0 { 7017 return invalidParams 7018 } 7019 return nil 7020} 7021 7022// SetAllQueryArguments sets the AllQueryArguments field's value. 7023func (s *FieldToMatch) SetAllQueryArguments(v *AllQueryArguments) *FieldToMatch { 7024 s.AllQueryArguments = v 7025 return s 7026} 7027 7028// SetBody sets the Body field's value. 7029func (s *FieldToMatch) SetBody(v *Body) *FieldToMatch { 7030 s.Body = v 7031 return s 7032} 7033 7034// SetMethod sets the Method field's value. 7035func (s *FieldToMatch) SetMethod(v *Method) *FieldToMatch { 7036 s.Method = v 7037 return s 7038} 7039 7040// SetQueryString sets the QueryString field's value. 7041func (s *FieldToMatch) SetQueryString(v *QueryString) *FieldToMatch { 7042 s.QueryString = v 7043 return s 7044} 7045 7046// SetSingleHeader sets the SingleHeader field's value. 7047func (s *FieldToMatch) SetSingleHeader(v *SingleHeader) *FieldToMatch { 7048 s.SingleHeader = v 7049 return s 7050} 7051 7052// SetSingleQueryArgument sets the SingleQueryArgument field's value. 7053func (s *FieldToMatch) SetSingleQueryArgument(v *SingleQueryArgument) *FieldToMatch { 7054 s.SingleQueryArgument = v 7055 return s 7056} 7057 7058// SetUriPath sets the UriPath field's value. 7059func (s *FieldToMatch) SetUriPath(v *UriPath) *FieldToMatch { 7060 s.UriPath = v 7061 return s 7062} 7063 7064// A rule group that's defined for an AWS Firewall Manager WAF policy. 7065type FirewallManagerRuleGroup struct { 7066 _ struct{} `type:"structure"` 7067 7068 // The processing guidance for an AWS Firewall Manager rule. This is like a 7069 // regular rule Statement, but it can only contain a rule group reference. 7070 // 7071 // FirewallManagerStatement is a required field 7072 FirewallManagerStatement *FirewallManagerStatement `type:"structure" required:"true"` 7073 7074 // The name of the rule group. You cannot change the name of a rule group after 7075 // you create it. 7076 // 7077 // Name is a required field 7078 Name *string `min:"1" type:"string" required:"true"` 7079 7080 // The override action to apply to the rules in a rule group. Used only for 7081 // rule statements that reference a rule group, like RuleGroupReferenceStatement 7082 // and ManagedRuleGroupStatement. 7083 // 7084 // Set the override action to none to leave the rule actions in effect. Set 7085 // it to count to only count matches, regardless of the rule action settings. 7086 // 7087 // In a Rule, you must specify either this OverrideAction setting or the rule 7088 // Action setting, but not both: 7089 // 7090 // * If the rule statement references a rule group, use this override action 7091 // setting and not the action setting. 7092 // 7093 // * If the rule statement does not reference a rule group, use the rule 7094 // action setting and not this rule override action setting. 7095 // 7096 // OverrideAction is a required field 7097 OverrideAction *OverrideAction `type:"structure" required:"true"` 7098 7099 // If you define more than one rule group in the first or last Firewall Manager 7100 // rule groups, AWS WAF evaluates each request against the rule groups in order, 7101 // starting from the lowest priority setting. The priorities don't need to be 7102 // consecutive, but they must all be different. 7103 // 7104 // Priority is a required field 7105 Priority *int64 `type:"integer" required:"true"` 7106 7107 // 7108 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7109 // 2019. For information, including how to migrate your AWS WAF resources from 7110 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7111 // 7112 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 7113 // 7114 // VisibilityConfig is a required field 7115 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 7116} 7117 7118// String returns the string representation 7119func (s FirewallManagerRuleGroup) String() string { 7120 return awsutil.Prettify(s) 7121} 7122 7123// GoString returns the string representation 7124func (s FirewallManagerRuleGroup) GoString() string { 7125 return s.String() 7126} 7127 7128// SetFirewallManagerStatement sets the FirewallManagerStatement field's value. 7129func (s *FirewallManagerRuleGroup) SetFirewallManagerStatement(v *FirewallManagerStatement) *FirewallManagerRuleGroup { 7130 s.FirewallManagerStatement = v 7131 return s 7132} 7133 7134// SetName sets the Name field's value. 7135func (s *FirewallManagerRuleGroup) SetName(v string) *FirewallManagerRuleGroup { 7136 s.Name = &v 7137 return s 7138} 7139 7140// SetOverrideAction sets the OverrideAction field's value. 7141func (s *FirewallManagerRuleGroup) SetOverrideAction(v *OverrideAction) *FirewallManagerRuleGroup { 7142 s.OverrideAction = v 7143 return s 7144} 7145 7146// SetPriority sets the Priority field's value. 7147func (s *FirewallManagerRuleGroup) SetPriority(v int64) *FirewallManagerRuleGroup { 7148 s.Priority = &v 7149 return s 7150} 7151 7152// SetVisibilityConfig sets the VisibilityConfig field's value. 7153func (s *FirewallManagerRuleGroup) SetVisibilityConfig(v *VisibilityConfig) *FirewallManagerRuleGroup { 7154 s.VisibilityConfig = v 7155 return s 7156} 7157 7158// The processing guidance for an AWS Firewall Manager rule. This is like a 7159// regular rule Statement, but it can only contain a rule group reference. 7160type FirewallManagerStatement struct { 7161 _ struct{} `type:"structure"` 7162 7163 // 7164 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7165 // 2019. For information, including how to migrate your AWS WAF resources from 7166 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7167 // 7168 // A rule statement used to run the rules that are defined in a managed rule 7169 // group. To use this, provide the vendor name and the name of the rule group 7170 // in this statement. You can retrieve the required names by calling ListAvailableManagedRuleGroups. 7171 // 7172 // You can't nest a ManagedRuleGroupStatement, for example for use inside a 7173 // NotStatement or OrStatement. It can only be referenced as a top-level statement 7174 // within a rule. 7175 ManagedRuleGroupStatement *ManagedRuleGroupStatement `type:"structure"` 7176 7177 // 7178 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7179 // 2019. For information, including how to migrate your AWS WAF resources from 7180 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7181 // 7182 // A rule statement used to run the rules that are defined in a RuleGroup. To 7183 // use this, create a rule group with your rules, then provide the ARN of the 7184 // rule group in this statement. 7185 // 7186 // You cannot nest a RuleGroupReferenceStatement, for example for use inside 7187 // a NotStatement or OrStatement. It can only be referenced as a top-level statement 7188 // within a rule. 7189 RuleGroupReferenceStatement *RuleGroupReferenceStatement `type:"structure"` 7190} 7191 7192// String returns the string representation 7193func (s FirewallManagerStatement) String() string { 7194 return awsutil.Prettify(s) 7195} 7196 7197// GoString returns the string representation 7198func (s FirewallManagerStatement) GoString() string { 7199 return s.String() 7200} 7201 7202// SetManagedRuleGroupStatement sets the ManagedRuleGroupStatement field's value. 7203func (s *FirewallManagerStatement) SetManagedRuleGroupStatement(v *ManagedRuleGroupStatement) *FirewallManagerStatement { 7204 s.ManagedRuleGroupStatement = v 7205 return s 7206} 7207 7208// SetRuleGroupReferenceStatement sets the RuleGroupReferenceStatement field's value. 7209func (s *FirewallManagerStatement) SetRuleGroupReferenceStatement(v *RuleGroupReferenceStatement) *FirewallManagerStatement { 7210 s.RuleGroupReferenceStatement = v 7211 return s 7212} 7213 7214// The configuration for inspecting IP addresses in an HTTP header that you 7215// specify, instead of using the IP address that's reported by the web request 7216// origin. Commonly, this is the X-Forwarded-For (XFF) header, but you can specify 7217// any header name. 7218// 7219// If the specified header isn't present in the request, AWS WAF doesn't apply 7220// the rule to the web request at all. 7221// 7222// This configuration is used for GeoMatchStatement and RateBasedStatement. 7223// For IPSetReferenceStatement, use IPSetForwardedIPConfig instead. 7224// 7225// AWS WAF only evaluates the first IP address found in the specified HTTP header. 7226type ForwardedIPConfig struct { 7227 _ struct{} `type:"structure"` 7228 7229 // The match status to assign to the web request if the request doesn't have 7230 // a valid IP address in the specified position. 7231 // 7232 // If the specified header isn't present in the request, AWS WAF doesn't apply 7233 // the rule to the web request at all. 7234 // 7235 // You can specify the following fallback behaviors: 7236 // 7237 // * MATCH - Treat the web request as matching the rule statement. AWS WAF 7238 // applies the rule action to the request. 7239 // 7240 // * NO_MATCH - Treat the web request as not matching the rule statement. 7241 // 7242 // FallbackBehavior is a required field 7243 FallbackBehavior *string `type:"string" required:"true" enum:"FallbackBehavior"` 7244 7245 // The name of the HTTP header to use for the IP address. For example, to use 7246 // the X-Forwarded-For (XFF) header, set this to X-Forwarded-For. 7247 // 7248 // If the specified header isn't present in the request, AWS WAF doesn't apply 7249 // the rule to the web request at all. 7250 // 7251 // HeaderName is a required field 7252 HeaderName *string `min:"1" type:"string" required:"true"` 7253} 7254 7255// String returns the string representation 7256func (s ForwardedIPConfig) String() string { 7257 return awsutil.Prettify(s) 7258} 7259 7260// GoString returns the string representation 7261func (s ForwardedIPConfig) GoString() string { 7262 return s.String() 7263} 7264 7265// Validate inspects the fields of the type to determine if they are valid. 7266func (s *ForwardedIPConfig) Validate() error { 7267 invalidParams := request.ErrInvalidParams{Context: "ForwardedIPConfig"} 7268 if s.FallbackBehavior == nil { 7269 invalidParams.Add(request.NewErrParamRequired("FallbackBehavior")) 7270 } 7271 if s.HeaderName == nil { 7272 invalidParams.Add(request.NewErrParamRequired("HeaderName")) 7273 } 7274 if s.HeaderName != nil && len(*s.HeaderName) < 1 { 7275 invalidParams.Add(request.NewErrParamMinLen("HeaderName", 1)) 7276 } 7277 7278 if invalidParams.Len() > 0 { 7279 return invalidParams 7280 } 7281 return nil 7282} 7283 7284// SetFallbackBehavior sets the FallbackBehavior field's value. 7285func (s *ForwardedIPConfig) SetFallbackBehavior(v string) *ForwardedIPConfig { 7286 s.FallbackBehavior = &v 7287 return s 7288} 7289 7290// SetHeaderName sets the HeaderName field's value. 7291func (s *ForwardedIPConfig) SetHeaderName(v string) *ForwardedIPConfig { 7292 s.HeaderName = &v 7293 return s 7294} 7295 7296// 7297// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7298// 2019. For information, including how to migrate your AWS WAF resources from 7299// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7300// 7301// A rule statement used to identify web requests based on country of origin. 7302type GeoMatchStatement struct { 7303 _ struct{} `type:"structure"` 7304 7305 // An array of two-character country codes, for example, [ "US", "CN" ], from 7306 // the alpha-2 country ISO codes of the ISO 3166 international standard. 7307 CountryCodes []*string `min:"1" type:"list"` 7308 7309 // The configuration for inspecting IP addresses in an HTTP header that you 7310 // specify, instead of using the IP address that's reported by the web request 7311 // origin. Commonly, this is the X-Forwarded-For (XFF) header, but you can specify 7312 // any header name. 7313 // 7314 // If the specified header isn't present in the request, AWS WAF doesn't apply 7315 // the rule to the web request at all. 7316 ForwardedIPConfig *ForwardedIPConfig `type:"structure"` 7317} 7318 7319// String returns the string representation 7320func (s GeoMatchStatement) String() string { 7321 return awsutil.Prettify(s) 7322} 7323 7324// GoString returns the string representation 7325func (s GeoMatchStatement) GoString() string { 7326 return s.String() 7327} 7328 7329// Validate inspects the fields of the type to determine if they are valid. 7330func (s *GeoMatchStatement) Validate() error { 7331 invalidParams := request.ErrInvalidParams{Context: "GeoMatchStatement"} 7332 if s.CountryCodes != nil && len(s.CountryCodes) < 1 { 7333 invalidParams.Add(request.NewErrParamMinLen("CountryCodes", 1)) 7334 } 7335 if s.ForwardedIPConfig != nil { 7336 if err := s.ForwardedIPConfig.Validate(); err != nil { 7337 invalidParams.AddNested("ForwardedIPConfig", err.(request.ErrInvalidParams)) 7338 } 7339 } 7340 7341 if invalidParams.Len() > 0 { 7342 return invalidParams 7343 } 7344 return nil 7345} 7346 7347// SetCountryCodes sets the CountryCodes field's value. 7348func (s *GeoMatchStatement) SetCountryCodes(v []*string) *GeoMatchStatement { 7349 s.CountryCodes = v 7350 return s 7351} 7352 7353// SetForwardedIPConfig sets the ForwardedIPConfig field's value. 7354func (s *GeoMatchStatement) SetForwardedIPConfig(v *ForwardedIPConfig) *GeoMatchStatement { 7355 s.ForwardedIPConfig = v 7356 return s 7357} 7358 7359type GetIPSetInput struct { 7360 _ struct{} `type:"structure"` 7361 7362 // A unique identifier for the set. This ID is returned in the responses to 7363 // create and list commands. You provide it to operations like update and delete. 7364 // 7365 // Id is a required field 7366 Id *string `min:"1" type:"string" required:"true"` 7367 7368 // The name of the IP set. You cannot change the name of an IPSet after you 7369 // create it. 7370 // 7371 // Name is a required field 7372 Name *string `min:"1" type:"string" required:"true"` 7373 7374 // Specifies whether this is for an AWS CloudFront distribution or for a regional 7375 // application. A regional application can be an Application Load Balancer (ALB), 7376 // an API Gateway REST API, or an AppSync GraphQL API. 7377 // 7378 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 7379 // as follows: 7380 // 7381 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 7382 // --region=us-east-1. 7383 // 7384 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 7385 // 7386 // Scope is a required field 7387 Scope *string `type:"string" required:"true" enum:"Scope"` 7388} 7389 7390// String returns the string representation 7391func (s GetIPSetInput) String() string { 7392 return awsutil.Prettify(s) 7393} 7394 7395// GoString returns the string representation 7396func (s GetIPSetInput) GoString() string { 7397 return s.String() 7398} 7399 7400// Validate inspects the fields of the type to determine if they are valid. 7401func (s *GetIPSetInput) Validate() error { 7402 invalidParams := request.ErrInvalidParams{Context: "GetIPSetInput"} 7403 if s.Id == nil { 7404 invalidParams.Add(request.NewErrParamRequired("Id")) 7405 } 7406 if s.Id != nil && len(*s.Id) < 1 { 7407 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 7408 } 7409 if s.Name == nil { 7410 invalidParams.Add(request.NewErrParamRequired("Name")) 7411 } 7412 if s.Name != nil && len(*s.Name) < 1 { 7413 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 7414 } 7415 if s.Scope == nil { 7416 invalidParams.Add(request.NewErrParamRequired("Scope")) 7417 } 7418 7419 if invalidParams.Len() > 0 { 7420 return invalidParams 7421 } 7422 return nil 7423} 7424 7425// SetId sets the Id field's value. 7426func (s *GetIPSetInput) SetId(v string) *GetIPSetInput { 7427 s.Id = &v 7428 return s 7429} 7430 7431// SetName sets the Name field's value. 7432func (s *GetIPSetInput) SetName(v string) *GetIPSetInput { 7433 s.Name = &v 7434 return s 7435} 7436 7437// SetScope sets the Scope field's value. 7438func (s *GetIPSetInput) SetScope(v string) *GetIPSetInput { 7439 s.Scope = &v 7440 return s 7441} 7442 7443type GetIPSetOutput struct { 7444 _ struct{} `type:"structure"` 7445 7446 // 7447 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7448 // 2019. For information, including how to migrate your AWS WAF resources from 7449 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7450 // 7451 // Contains one or more IP addresses or blocks of IP addresses specified in 7452 // Classless Inter-Domain Routing (CIDR) notation. AWS WAF supports any CIDR 7453 // range. For information about CIDR notation, see the Wikipedia entry Classless 7454 // Inter-Domain Routing (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing). 7455 // 7456 // AWS WAF assigns an ARN to each IPSet that you create. To use an IP set in 7457 // a rule, you provide the ARN to the Rule statement IPSetReferenceStatement. 7458 IPSet *IPSet `type:"structure"` 7459 7460 // A token used for optimistic locking. AWS WAF returns a token to your get 7461 // and list requests, to mark the state of the entity at the time of the request. 7462 // To make changes to the entity associated with the token, you provide the 7463 // token to operations like update and delete. AWS WAF uses the token to ensure 7464 // that no changes have been made to the entity since you last retrieved it. 7465 // If a change has been made, the update fails with a WAFOptimisticLockException. 7466 // If this happens, perform another get, and use the new token returned by that 7467 // operation. 7468 LockToken *string `min:"1" type:"string"` 7469} 7470 7471// String returns the string representation 7472func (s GetIPSetOutput) String() string { 7473 return awsutil.Prettify(s) 7474} 7475 7476// GoString returns the string representation 7477func (s GetIPSetOutput) GoString() string { 7478 return s.String() 7479} 7480 7481// SetIPSet sets the IPSet field's value. 7482func (s *GetIPSetOutput) SetIPSet(v *IPSet) *GetIPSetOutput { 7483 s.IPSet = v 7484 return s 7485} 7486 7487// SetLockToken sets the LockToken field's value. 7488func (s *GetIPSetOutput) SetLockToken(v string) *GetIPSetOutput { 7489 s.LockToken = &v 7490 return s 7491} 7492 7493type GetLoggingConfigurationInput struct { 7494 _ struct{} `type:"structure"` 7495 7496 // The Amazon Resource Name (ARN) of the web ACL for which you want to get the 7497 // LoggingConfiguration. 7498 // 7499 // ResourceArn is a required field 7500 ResourceArn *string `min:"20" type:"string" required:"true"` 7501} 7502 7503// String returns the string representation 7504func (s GetLoggingConfigurationInput) String() string { 7505 return awsutil.Prettify(s) 7506} 7507 7508// GoString returns the string representation 7509func (s GetLoggingConfigurationInput) GoString() string { 7510 return s.String() 7511} 7512 7513// Validate inspects the fields of the type to determine if they are valid. 7514func (s *GetLoggingConfigurationInput) Validate() error { 7515 invalidParams := request.ErrInvalidParams{Context: "GetLoggingConfigurationInput"} 7516 if s.ResourceArn == nil { 7517 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 7518 } 7519 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 7520 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 7521 } 7522 7523 if invalidParams.Len() > 0 { 7524 return invalidParams 7525 } 7526 return nil 7527} 7528 7529// SetResourceArn sets the ResourceArn field's value. 7530func (s *GetLoggingConfigurationInput) SetResourceArn(v string) *GetLoggingConfigurationInput { 7531 s.ResourceArn = &v 7532 return s 7533} 7534 7535type GetLoggingConfigurationOutput struct { 7536 _ struct{} `type:"structure"` 7537 7538 // The LoggingConfiguration for the specified web ACL. 7539 LoggingConfiguration *LoggingConfiguration `type:"structure"` 7540} 7541 7542// String returns the string representation 7543func (s GetLoggingConfigurationOutput) String() string { 7544 return awsutil.Prettify(s) 7545} 7546 7547// GoString returns the string representation 7548func (s GetLoggingConfigurationOutput) GoString() string { 7549 return s.String() 7550} 7551 7552// SetLoggingConfiguration sets the LoggingConfiguration field's value. 7553func (s *GetLoggingConfigurationOutput) SetLoggingConfiguration(v *LoggingConfiguration) *GetLoggingConfigurationOutput { 7554 s.LoggingConfiguration = v 7555 return s 7556} 7557 7558type GetPermissionPolicyInput struct { 7559 _ struct{} `type:"structure"` 7560 7561 // The Amazon Resource Name (ARN) of the rule group for which you want to get 7562 // the policy. 7563 // 7564 // ResourceArn is a required field 7565 ResourceArn *string `min:"20" type:"string" required:"true"` 7566} 7567 7568// String returns the string representation 7569func (s GetPermissionPolicyInput) String() string { 7570 return awsutil.Prettify(s) 7571} 7572 7573// GoString returns the string representation 7574func (s GetPermissionPolicyInput) GoString() string { 7575 return s.String() 7576} 7577 7578// Validate inspects the fields of the type to determine if they are valid. 7579func (s *GetPermissionPolicyInput) Validate() error { 7580 invalidParams := request.ErrInvalidParams{Context: "GetPermissionPolicyInput"} 7581 if s.ResourceArn == nil { 7582 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 7583 } 7584 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 7585 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 7586 } 7587 7588 if invalidParams.Len() > 0 { 7589 return invalidParams 7590 } 7591 return nil 7592} 7593 7594// SetResourceArn sets the ResourceArn field's value. 7595func (s *GetPermissionPolicyInput) SetResourceArn(v string) *GetPermissionPolicyInput { 7596 s.ResourceArn = &v 7597 return s 7598} 7599 7600type GetPermissionPolicyOutput struct { 7601 _ struct{} `type:"structure"` 7602 7603 // The IAM policy that is attached to the specified rule group. 7604 Policy *string `min:"1" type:"string"` 7605} 7606 7607// String returns the string representation 7608func (s GetPermissionPolicyOutput) String() string { 7609 return awsutil.Prettify(s) 7610} 7611 7612// GoString returns the string representation 7613func (s GetPermissionPolicyOutput) GoString() string { 7614 return s.String() 7615} 7616 7617// SetPolicy sets the Policy field's value. 7618func (s *GetPermissionPolicyOutput) SetPolicy(v string) *GetPermissionPolicyOutput { 7619 s.Policy = &v 7620 return s 7621} 7622 7623type GetRateBasedStatementManagedKeysInput struct { 7624 _ struct{} `type:"structure"` 7625 7626 // The name of the rate-based rule to get the keys for. 7627 // 7628 // RuleName is a required field 7629 RuleName *string `min:"1" type:"string" required:"true"` 7630 7631 // Specifies whether this is for an AWS CloudFront distribution or for a regional 7632 // application. A regional application can be an Application Load Balancer (ALB), 7633 // an API Gateway REST API, or an AppSync GraphQL API. 7634 // 7635 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 7636 // as follows: 7637 // 7638 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 7639 // --region=us-east-1. 7640 // 7641 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 7642 // 7643 // Scope is a required field 7644 Scope *string `type:"string" required:"true" enum:"Scope"` 7645 7646 // The unique identifier for the Web ACL. This ID is returned in the responses 7647 // to create and list commands. You provide it to operations like update and 7648 // delete. 7649 // 7650 // WebACLId is a required field 7651 WebACLId *string `min:"1" type:"string" required:"true"` 7652 7653 // The name of the Web ACL. You cannot change the name of a Web ACL after you 7654 // create it. 7655 // 7656 // WebACLName is a required field 7657 WebACLName *string `min:"1" type:"string" required:"true"` 7658} 7659 7660// String returns the string representation 7661func (s GetRateBasedStatementManagedKeysInput) String() string { 7662 return awsutil.Prettify(s) 7663} 7664 7665// GoString returns the string representation 7666func (s GetRateBasedStatementManagedKeysInput) GoString() string { 7667 return s.String() 7668} 7669 7670// Validate inspects the fields of the type to determine if they are valid. 7671func (s *GetRateBasedStatementManagedKeysInput) Validate() error { 7672 invalidParams := request.ErrInvalidParams{Context: "GetRateBasedStatementManagedKeysInput"} 7673 if s.RuleName == nil { 7674 invalidParams.Add(request.NewErrParamRequired("RuleName")) 7675 } 7676 if s.RuleName != nil && len(*s.RuleName) < 1 { 7677 invalidParams.Add(request.NewErrParamMinLen("RuleName", 1)) 7678 } 7679 if s.Scope == nil { 7680 invalidParams.Add(request.NewErrParamRequired("Scope")) 7681 } 7682 if s.WebACLId == nil { 7683 invalidParams.Add(request.NewErrParamRequired("WebACLId")) 7684 } 7685 if s.WebACLId != nil && len(*s.WebACLId) < 1 { 7686 invalidParams.Add(request.NewErrParamMinLen("WebACLId", 1)) 7687 } 7688 if s.WebACLName == nil { 7689 invalidParams.Add(request.NewErrParamRequired("WebACLName")) 7690 } 7691 if s.WebACLName != nil && len(*s.WebACLName) < 1 { 7692 invalidParams.Add(request.NewErrParamMinLen("WebACLName", 1)) 7693 } 7694 7695 if invalidParams.Len() > 0 { 7696 return invalidParams 7697 } 7698 return nil 7699} 7700 7701// SetRuleName sets the RuleName field's value. 7702func (s *GetRateBasedStatementManagedKeysInput) SetRuleName(v string) *GetRateBasedStatementManagedKeysInput { 7703 s.RuleName = &v 7704 return s 7705} 7706 7707// SetScope sets the Scope field's value. 7708func (s *GetRateBasedStatementManagedKeysInput) SetScope(v string) *GetRateBasedStatementManagedKeysInput { 7709 s.Scope = &v 7710 return s 7711} 7712 7713// SetWebACLId sets the WebACLId field's value. 7714func (s *GetRateBasedStatementManagedKeysInput) SetWebACLId(v string) *GetRateBasedStatementManagedKeysInput { 7715 s.WebACLId = &v 7716 return s 7717} 7718 7719// SetWebACLName sets the WebACLName field's value. 7720func (s *GetRateBasedStatementManagedKeysInput) SetWebACLName(v string) *GetRateBasedStatementManagedKeysInput { 7721 s.WebACLName = &v 7722 return s 7723} 7724 7725type GetRateBasedStatementManagedKeysOutput struct { 7726 _ struct{} `type:"structure"` 7727 7728 // The keys that are of Internet Protocol version 4 (IPv4). 7729 ManagedKeysIPV4 *RateBasedStatementManagedKeysIPSet `type:"structure"` 7730 7731 // The keys that are of Internet Protocol version 6 (IPv6). 7732 ManagedKeysIPV6 *RateBasedStatementManagedKeysIPSet `type:"structure"` 7733} 7734 7735// String returns the string representation 7736func (s GetRateBasedStatementManagedKeysOutput) String() string { 7737 return awsutil.Prettify(s) 7738} 7739 7740// GoString returns the string representation 7741func (s GetRateBasedStatementManagedKeysOutput) GoString() string { 7742 return s.String() 7743} 7744 7745// SetManagedKeysIPV4 sets the ManagedKeysIPV4 field's value. 7746func (s *GetRateBasedStatementManagedKeysOutput) SetManagedKeysIPV4(v *RateBasedStatementManagedKeysIPSet) *GetRateBasedStatementManagedKeysOutput { 7747 s.ManagedKeysIPV4 = v 7748 return s 7749} 7750 7751// SetManagedKeysIPV6 sets the ManagedKeysIPV6 field's value. 7752func (s *GetRateBasedStatementManagedKeysOutput) SetManagedKeysIPV6(v *RateBasedStatementManagedKeysIPSet) *GetRateBasedStatementManagedKeysOutput { 7753 s.ManagedKeysIPV6 = v 7754 return s 7755} 7756 7757type GetRegexPatternSetInput struct { 7758 _ struct{} `type:"structure"` 7759 7760 // A unique identifier for the set. This ID is returned in the responses to 7761 // create and list commands. You provide it to operations like update and delete. 7762 // 7763 // Id is a required field 7764 Id *string `min:"1" type:"string" required:"true"` 7765 7766 // The name of the set. You cannot change the name after you create the set. 7767 // 7768 // Name is a required field 7769 Name *string `min:"1" type:"string" required:"true"` 7770 7771 // Specifies whether this is for an AWS CloudFront distribution or for a regional 7772 // application. A regional application can be an Application Load Balancer (ALB), 7773 // an API Gateway REST API, or an AppSync GraphQL API. 7774 // 7775 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 7776 // as follows: 7777 // 7778 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 7779 // --region=us-east-1. 7780 // 7781 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 7782 // 7783 // Scope is a required field 7784 Scope *string `type:"string" required:"true" enum:"Scope"` 7785} 7786 7787// String returns the string representation 7788func (s GetRegexPatternSetInput) String() string { 7789 return awsutil.Prettify(s) 7790} 7791 7792// GoString returns the string representation 7793func (s GetRegexPatternSetInput) GoString() string { 7794 return s.String() 7795} 7796 7797// Validate inspects the fields of the type to determine if they are valid. 7798func (s *GetRegexPatternSetInput) Validate() error { 7799 invalidParams := request.ErrInvalidParams{Context: "GetRegexPatternSetInput"} 7800 if s.Id == nil { 7801 invalidParams.Add(request.NewErrParamRequired("Id")) 7802 } 7803 if s.Id != nil && len(*s.Id) < 1 { 7804 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 7805 } 7806 if s.Name == nil { 7807 invalidParams.Add(request.NewErrParamRequired("Name")) 7808 } 7809 if s.Name != nil && len(*s.Name) < 1 { 7810 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 7811 } 7812 if s.Scope == nil { 7813 invalidParams.Add(request.NewErrParamRequired("Scope")) 7814 } 7815 7816 if invalidParams.Len() > 0 { 7817 return invalidParams 7818 } 7819 return nil 7820} 7821 7822// SetId sets the Id field's value. 7823func (s *GetRegexPatternSetInput) SetId(v string) *GetRegexPatternSetInput { 7824 s.Id = &v 7825 return s 7826} 7827 7828// SetName sets the Name field's value. 7829func (s *GetRegexPatternSetInput) SetName(v string) *GetRegexPatternSetInput { 7830 s.Name = &v 7831 return s 7832} 7833 7834// SetScope sets the Scope field's value. 7835func (s *GetRegexPatternSetInput) SetScope(v string) *GetRegexPatternSetInput { 7836 s.Scope = &v 7837 return s 7838} 7839 7840type GetRegexPatternSetOutput struct { 7841 _ struct{} `type:"structure"` 7842 7843 // A token used for optimistic locking. AWS WAF returns a token to your get 7844 // and list requests, to mark the state of the entity at the time of the request. 7845 // To make changes to the entity associated with the token, you provide the 7846 // token to operations like update and delete. AWS WAF uses the token to ensure 7847 // that no changes have been made to the entity since you last retrieved it. 7848 // If a change has been made, the update fails with a WAFOptimisticLockException. 7849 // If this happens, perform another get, and use the new token returned by that 7850 // operation. 7851 LockToken *string `min:"1" type:"string"` 7852 7853 // 7854 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7855 // 2019. For information, including how to migrate your AWS WAF resources from 7856 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7857 // 7858 // Contains one or more regular expressions. 7859 // 7860 // AWS WAF assigns an ARN to each RegexPatternSet that you create. To use a 7861 // set in a rule, you provide the ARN to the Rule statement RegexPatternSetReferenceStatement. 7862 RegexPatternSet *RegexPatternSet `type:"structure"` 7863} 7864 7865// String returns the string representation 7866func (s GetRegexPatternSetOutput) String() string { 7867 return awsutil.Prettify(s) 7868} 7869 7870// GoString returns the string representation 7871func (s GetRegexPatternSetOutput) GoString() string { 7872 return s.String() 7873} 7874 7875// SetLockToken sets the LockToken field's value. 7876func (s *GetRegexPatternSetOutput) SetLockToken(v string) *GetRegexPatternSetOutput { 7877 s.LockToken = &v 7878 return s 7879} 7880 7881// SetRegexPatternSet sets the RegexPatternSet field's value. 7882func (s *GetRegexPatternSetOutput) SetRegexPatternSet(v *RegexPatternSet) *GetRegexPatternSetOutput { 7883 s.RegexPatternSet = v 7884 return s 7885} 7886 7887type GetRuleGroupInput struct { 7888 _ struct{} `type:"structure"` 7889 7890 // A unique identifier for the rule group. This ID is returned in the responses 7891 // to create and list commands. You provide it to operations like update and 7892 // delete. 7893 // 7894 // Id is a required field 7895 Id *string `min:"1" type:"string" required:"true"` 7896 7897 // The name of the rule group. You cannot change the name of a rule group after 7898 // you create it. 7899 // 7900 // Name is a required field 7901 Name *string `min:"1" type:"string" required:"true"` 7902 7903 // Specifies whether this is for an AWS CloudFront distribution or for a regional 7904 // application. A regional application can be an Application Load Balancer (ALB), 7905 // an API Gateway REST API, or an AppSync GraphQL API. 7906 // 7907 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 7908 // as follows: 7909 // 7910 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 7911 // --region=us-east-1. 7912 // 7913 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 7914 // 7915 // Scope is a required field 7916 Scope *string `type:"string" required:"true" enum:"Scope"` 7917} 7918 7919// String returns the string representation 7920func (s GetRuleGroupInput) String() string { 7921 return awsutil.Prettify(s) 7922} 7923 7924// GoString returns the string representation 7925func (s GetRuleGroupInput) GoString() string { 7926 return s.String() 7927} 7928 7929// Validate inspects the fields of the type to determine if they are valid. 7930func (s *GetRuleGroupInput) Validate() error { 7931 invalidParams := request.ErrInvalidParams{Context: "GetRuleGroupInput"} 7932 if s.Id == nil { 7933 invalidParams.Add(request.NewErrParamRequired("Id")) 7934 } 7935 if s.Id != nil && len(*s.Id) < 1 { 7936 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 7937 } 7938 if s.Name == nil { 7939 invalidParams.Add(request.NewErrParamRequired("Name")) 7940 } 7941 if s.Name != nil && len(*s.Name) < 1 { 7942 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 7943 } 7944 if s.Scope == nil { 7945 invalidParams.Add(request.NewErrParamRequired("Scope")) 7946 } 7947 7948 if invalidParams.Len() > 0 { 7949 return invalidParams 7950 } 7951 return nil 7952} 7953 7954// SetId sets the Id field's value. 7955func (s *GetRuleGroupInput) SetId(v string) *GetRuleGroupInput { 7956 s.Id = &v 7957 return s 7958} 7959 7960// SetName sets the Name field's value. 7961func (s *GetRuleGroupInput) SetName(v string) *GetRuleGroupInput { 7962 s.Name = &v 7963 return s 7964} 7965 7966// SetScope sets the Scope field's value. 7967func (s *GetRuleGroupInput) SetScope(v string) *GetRuleGroupInput { 7968 s.Scope = &v 7969 return s 7970} 7971 7972type GetRuleGroupOutput struct { 7973 _ struct{} `type:"structure"` 7974 7975 // A token used for optimistic locking. AWS WAF returns a token to your get 7976 // and list requests, to mark the state of the entity at the time of the request. 7977 // To make changes to the entity associated with the token, you provide the 7978 // token to operations like update and delete. AWS WAF uses the token to ensure 7979 // that no changes have been made to the entity since you last retrieved it. 7980 // If a change has been made, the update fails with a WAFOptimisticLockException. 7981 // If this happens, perform another get, and use the new token returned by that 7982 // operation. 7983 LockToken *string `min:"1" type:"string"` 7984 7985 // 7986 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 7987 // 2019. For information, including how to migrate your AWS WAF resources from 7988 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 7989 // 7990 // A rule group defines a collection of rules to inspect and control web requests 7991 // that you can use in a WebACL. When you create a rule group, you define an 7992 // immutable capacity limit. If you update a rule group, you must stay within 7993 // the capacity. This allows others to reuse the rule group with confidence 7994 // in its capacity requirements. 7995 RuleGroup *RuleGroup `type:"structure"` 7996} 7997 7998// String returns the string representation 7999func (s GetRuleGroupOutput) String() string { 8000 return awsutil.Prettify(s) 8001} 8002 8003// GoString returns the string representation 8004func (s GetRuleGroupOutput) GoString() string { 8005 return s.String() 8006} 8007 8008// SetLockToken sets the LockToken field's value. 8009func (s *GetRuleGroupOutput) SetLockToken(v string) *GetRuleGroupOutput { 8010 s.LockToken = &v 8011 return s 8012} 8013 8014// SetRuleGroup sets the RuleGroup field's value. 8015func (s *GetRuleGroupOutput) SetRuleGroup(v *RuleGroup) *GetRuleGroupOutput { 8016 s.RuleGroup = v 8017 return s 8018} 8019 8020type GetSampledRequestsInput struct { 8021 _ struct{} `type:"structure"` 8022 8023 // The number of requests that you want AWS WAF to return from among the first 8024 // 5,000 requests that your AWS resource received during the time range. If 8025 // your resource received fewer requests than the value of MaxItems, GetSampledRequests 8026 // returns information about all of them. 8027 // 8028 // MaxItems is a required field 8029 MaxItems *int64 `min:"1" type:"long" required:"true"` 8030 8031 // The metric name assigned to the Rule or RuleGroup for which you want a sample 8032 // of requests. 8033 // 8034 // RuleMetricName is a required field 8035 RuleMetricName *string `min:"1" type:"string" required:"true"` 8036 8037 // Specifies whether this is for an AWS CloudFront distribution or for a regional 8038 // application. A regional application can be an Application Load Balancer (ALB), 8039 // an API Gateway REST API, or an AppSync GraphQL API. 8040 // 8041 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 8042 // as follows: 8043 // 8044 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 8045 // --region=us-east-1. 8046 // 8047 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 8048 // 8049 // Scope is a required field 8050 Scope *string `type:"string" required:"true" enum:"Scope"` 8051 8052 // The start date and time and the end date and time of the range for which 8053 // you want GetSampledRequests to return a sample of requests. You must specify 8054 // the times in Coordinated Universal Time (UTC) format. UTC format includes 8055 // the special designator, Z. For example, "2016-09-27T14:50Z". You can specify 8056 // any time range in the previous three hours. 8057 // 8058 // TimeWindow is a required field 8059 TimeWindow *TimeWindow `type:"structure" required:"true"` 8060 8061 // The Amazon resource name (ARN) of the WebACL for which you want a sample 8062 // of requests. 8063 // 8064 // WebAclArn is a required field 8065 WebAclArn *string `min:"20" type:"string" required:"true"` 8066} 8067 8068// String returns the string representation 8069func (s GetSampledRequestsInput) String() string { 8070 return awsutil.Prettify(s) 8071} 8072 8073// GoString returns the string representation 8074func (s GetSampledRequestsInput) GoString() string { 8075 return s.String() 8076} 8077 8078// Validate inspects the fields of the type to determine if they are valid. 8079func (s *GetSampledRequestsInput) Validate() error { 8080 invalidParams := request.ErrInvalidParams{Context: "GetSampledRequestsInput"} 8081 if s.MaxItems == nil { 8082 invalidParams.Add(request.NewErrParamRequired("MaxItems")) 8083 } 8084 if s.MaxItems != nil && *s.MaxItems < 1 { 8085 invalidParams.Add(request.NewErrParamMinValue("MaxItems", 1)) 8086 } 8087 if s.RuleMetricName == nil { 8088 invalidParams.Add(request.NewErrParamRequired("RuleMetricName")) 8089 } 8090 if s.RuleMetricName != nil && len(*s.RuleMetricName) < 1 { 8091 invalidParams.Add(request.NewErrParamMinLen("RuleMetricName", 1)) 8092 } 8093 if s.Scope == nil { 8094 invalidParams.Add(request.NewErrParamRequired("Scope")) 8095 } 8096 if s.TimeWindow == nil { 8097 invalidParams.Add(request.NewErrParamRequired("TimeWindow")) 8098 } 8099 if s.WebAclArn == nil { 8100 invalidParams.Add(request.NewErrParamRequired("WebAclArn")) 8101 } 8102 if s.WebAclArn != nil && len(*s.WebAclArn) < 20 { 8103 invalidParams.Add(request.NewErrParamMinLen("WebAclArn", 20)) 8104 } 8105 if s.TimeWindow != nil { 8106 if err := s.TimeWindow.Validate(); err != nil { 8107 invalidParams.AddNested("TimeWindow", err.(request.ErrInvalidParams)) 8108 } 8109 } 8110 8111 if invalidParams.Len() > 0 { 8112 return invalidParams 8113 } 8114 return nil 8115} 8116 8117// SetMaxItems sets the MaxItems field's value. 8118func (s *GetSampledRequestsInput) SetMaxItems(v int64) *GetSampledRequestsInput { 8119 s.MaxItems = &v 8120 return s 8121} 8122 8123// SetRuleMetricName sets the RuleMetricName field's value. 8124func (s *GetSampledRequestsInput) SetRuleMetricName(v string) *GetSampledRequestsInput { 8125 s.RuleMetricName = &v 8126 return s 8127} 8128 8129// SetScope sets the Scope field's value. 8130func (s *GetSampledRequestsInput) SetScope(v string) *GetSampledRequestsInput { 8131 s.Scope = &v 8132 return s 8133} 8134 8135// SetTimeWindow sets the TimeWindow field's value. 8136func (s *GetSampledRequestsInput) SetTimeWindow(v *TimeWindow) *GetSampledRequestsInput { 8137 s.TimeWindow = v 8138 return s 8139} 8140 8141// SetWebAclArn sets the WebAclArn field's value. 8142func (s *GetSampledRequestsInput) SetWebAclArn(v string) *GetSampledRequestsInput { 8143 s.WebAclArn = &v 8144 return s 8145} 8146 8147type GetSampledRequestsOutput struct { 8148 _ struct{} `type:"structure"` 8149 8150 // The total number of requests from which GetSampledRequests got a sample of 8151 // MaxItems requests. If PopulationSize is less than MaxItems, the sample includes 8152 // every request that your AWS resource received during the specified time range. 8153 PopulationSize *int64 `type:"long"` 8154 8155 // A complex type that contains detailed information about each of the requests 8156 // in the sample. 8157 SampledRequests []*SampledHTTPRequest `type:"list"` 8158 8159 // Usually, TimeWindow is the time range that you specified in the GetSampledRequests 8160 // request. However, if your AWS resource received more than 5,000 requests 8161 // during the time range that you specified in the request, GetSampledRequests 8162 // returns the time range for the first 5,000 requests. Times are in Coordinated 8163 // Universal Time (UTC) format. 8164 TimeWindow *TimeWindow `type:"structure"` 8165} 8166 8167// String returns the string representation 8168func (s GetSampledRequestsOutput) String() string { 8169 return awsutil.Prettify(s) 8170} 8171 8172// GoString returns the string representation 8173func (s GetSampledRequestsOutput) GoString() string { 8174 return s.String() 8175} 8176 8177// SetPopulationSize sets the PopulationSize field's value. 8178func (s *GetSampledRequestsOutput) SetPopulationSize(v int64) *GetSampledRequestsOutput { 8179 s.PopulationSize = &v 8180 return s 8181} 8182 8183// SetSampledRequests sets the SampledRequests field's value. 8184func (s *GetSampledRequestsOutput) SetSampledRequests(v []*SampledHTTPRequest) *GetSampledRequestsOutput { 8185 s.SampledRequests = v 8186 return s 8187} 8188 8189// SetTimeWindow sets the TimeWindow field's value. 8190func (s *GetSampledRequestsOutput) SetTimeWindow(v *TimeWindow) *GetSampledRequestsOutput { 8191 s.TimeWindow = v 8192 return s 8193} 8194 8195type GetWebACLForResourceInput struct { 8196 _ struct{} `type:"structure"` 8197 8198 // The ARN (Amazon Resource Name) of the resource. 8199 // 8200 // ResourceArn is a required field 8201 ResourceArn *string `min:"20" type:"string" required:"true"` 8202} 8203 8204// String returns the string representation 8205func (s GetWebACLForResourceInput) String() string { 8206 return awsutil.Prettify(s) 8207} 8208 8209// GoString returns the string representation 8210func (s GetWebACLForResourceInput) GoString() string { 8211 return s.String() 8212} 8213 8214// Validate inspects the fields of the type to determine if they are valid. 8215func (s *GetWebACLForResourceInput) Validate() error { 8216 invalidParams := request.ErrInvalidParams{Context: "GetWebACLForResourceInput"} 8217 if s.ResourceArn == nil { 8218 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 8219 } 8220 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 8221 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 8222 } 8223 8224 if invalidParams.Len() > 0 { 8225 return invalidParams 8226 } 8227 return nil 8228} 8229 8230// SetResourceArn sets the ResourceArn field's value. 8231func (s *GetWebACLForResourceInput) SetResourceArn(v string) *GetWebACLForResourceInput { 8232 s.ResourceArn = &v 8233 return s 8234} 8235 8236type GetWebACLForResourceOutput struct { 8237 _ struct{} `type:"structure"` 8238 8239 // The Web ACL that is associated with the resource. If there is no associated 8240 // resource, AWS WAF returns a null Web ACL. 8241 WebACL *WebACL `type:"structure"` 8242} 8243 8244// String returns the string representation 8245func (s GetWebACLForResourceOutput) String() string { 8246 return awsutil.Prettify(s) 8247} 8248 8249// GoString returns the string representation 8250func (s GetWebACLForResourceOutput) GoString() string { 8251 return s.String() 8252} 8253 8254// SetWebACL sets the WebACL field's value. 8255func (s *GetWebACLForResourceOutput) SetWebACL(v *WebACL) *GetWebACLForResourceOutput { 8256 s.WebACL = v 8257 return s 8258} 8259 8260type GetWebACLInput struct { 8261 _ struct{} `type:"structure"` 8262 8263 // The unique identifier for the Web ACL. This ID is returned in the responses 8264 // to create and list commands. You provide it to operations like update and 8265 // delete. 8266 // 8267 // Id is a required field 8268 Id *string `min:"1" type:"string" required:"true"` 8269 8270 // The name of the Web ACL. You cannot change the name of a Web ACL after you 8271 // create it. 8272 // 8273 // Name is a required field 8274 Name *string `min:"1" type:"string" required:"true"` 8275 8276 // Specifies whether this is for an AWS CloudFront distribution or for a regional 8277 // application. A regional application can be an Application Load Balancer (ALB), 8278 // an API Gateway REST API, or an AppSync GraphQL API. 8279 // 8280 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 8281 // as follows: 8282 // 8283 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 8284 // --region=us-east-1. 8285 // 8286 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 8287 // 8288 // Scope is a required field 8289 Scope *string `type:"string" required:"true" enum:"Scope"` 8290} 8291 8292// String returns the string representation 8293func (s GetWebACLInput) String() string { 8294 return awsutil.Prettify(s) 8295} 8296 8297// GoString returns the string representation 8298func (s GetWebACLInput) GoString() string { 8299 return s.String() 8300} 8301 8302// Validate inspects the fields of the type to determine if they are valid. 8303func (s *GetWebACLInput) Validate() error { 8304 invalidParams := request.ErrInvalidParams{Context: "GetWebACLInput"} 8305 if s.Id == nil { 8306 invalidParams.Add(request.NewErrParamRequired("Id")) 8307 } 8308 if s.Id != nil && len(*s.Id) < 1 { 8309 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 8310 } 8311 if s.Name == nil { 8312 invalidParams.Add(request.NewErrParamRequired("Name")) 8313 } 8314 if s.Name != nil && len(*s.Name) < 1 { 8315 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 8316 } 8317 if s.Scope == nil { 8318 invalidParams.Add(request.NewErrParamRequired("Scope")) 8319 } 8320 8321 if invalidParams.Len() > 0 { 8322 return invalidParams 8323 } 8324 return nil 8325} 8326 8327// SetId sets the Id field's value. 8328func (s *GetWebACLInput) SetId(v string) *GetWebACLInput { 8329 s.Id = &v 8330 return s 8331} 8332 8333// SetName sets the Name field's value. 8334func (s *GetWebACLInput) SetName(v string) *GetWebACLInput { 8335 s.Name = &v 8336 return s 8337} 8338 8339// SetScope sets the Scope field's value. 8340func (s *GetWebACLInput) SetScope(v string) *GetWebACLInput { 8341 s.Scope = &v 8342 return s 8343} 8344 8345type GetWebACLOutput struct { 8346 _ struct{} `type:"structure"` 8347 8348 // A token used for optimistic locking. AWS WAF returns a token to your get 8349 // and list requests, to mark the state of the entity at the time of the request. 8350 // To make changes to the entity associated with the token, you provide the 8351 // token to operations like update and delete. AWS WAF uses the token to ensure 8352 // that no changes have been made to the entity since you last retrieved it. 8353 // If a change has been made, the update fails with a WAFOptimisticLockException. 8354 // If this happens, perform another get, and use the new token returned by that 8355 // operation. 8356 LockToken *string `min:"1" type:"string"` 8357 8358 // The Web ACL specification. You can modify the settings in this Web ACL and 8359 // use it to update this Web ACL or create a new one. 8360 WebACL *WebACL `type:"structure"` 8361} 8362 8363// String returns the string representation 8364func (s GetWebACLOutput) String() string { 8365 return awsutil.Prettify(s) 8366} 8367 8368// GoString returns the string representation 8369func (s GetWebACLOutput) GoString() string { 8370 return s.String() 8371} 8372 8373// SetLockToken sets the LockToken field's value. 8374func (s *GetWebACLOutput) SetLockToken(v string) *GetWebACLOutput { 8375 s.LockToken = &v 8376 return s 8377} 8378 8379// SetWebACL sets the WebACL field's value. 8380func (s *GetWebACLOutput) SetWebACL(v *WebACL) *GetWebACLOutput { 8381 s.WebACL = v 8382 return s 8383} 8384 8385// 8386// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 8387// 2019. For information, including how to migrate your AWS WAF resources from 8388// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 8389// 8390// Part of the response from GetSampledRequests. This is a complex type that 8391// appears as Headers in the response syntax. HTTPHeader contains the names 8392// and values of all of the headers that appear in one of the web requests. 8393type HTTPHeader struct { 8394 _ struct{} `type:"structure"` 8395 8396 // The name of the HTTP header. 8397 Name *string `type:"string"` 8398 8399 // The value of the HTTP header. 8400 Value *string `type:"string"` 8401} 8402 8403// String returns the string representation 8404func (s HTTPHeader) String() string { 8405 return awsutil.Prettify(s) 8406} 8407 8408// GoString returns the string representation 8409func (s HTTPHeader) GoString() string { 8410 return s.String() 8411} 8412 8413// SetName sets the Name field's value. 8414func (s *HTTPHeader) SetName(v string) *HTTPHeader { 8415 s.Name = &v 8416 return s 8417} 8418 8419// SetValue sets the Value field's value. 8420func (s *HTTPHeader) SetValue(v string) *HTTPHeader { 8421 s.Value = &v 8422 return s 8423} 8424 8425// 8426// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 8427// 2019. For information, including how to migrate your AWS WAF resources from 8428// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 8429// 8430// Part of the response from GetSampledRequests. This is a complex type that 8431// appears as Request in the response syntax. HTTPRequest contains information 8432// about one of the web requests. 8433type HTTPRequest struct { 8434 _ struct{} `type:"structure"` 8435 8436 // The IP address that the request originated from. If the web ACL is associated 8437 // with a CloudFront distribution, this is the value of one of the following 8438 // fields in CloudFront access logs: 8439 // 8440 // * c-ip, if the viewer did not use an HTTP proxy or a load balancer to 8441 // send the request 8442 // 8443 // * x-forwarded-for, if the viewer did use an HTTP proxy or a load balancer 8444 // to send the request 8445 ClientIP *string `type:"string"` 8446 8447 // The two-letter country code for the country that the request originated from. 8448 // For a current list of country codes, see the Wikipedia entry ISO 3166-1 alpha-2 8449 // (https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2). 8450 Country *string `type:"string"` 8451 8452 // The HTTP version specified in the sampled web request, for example, HTTP/1.1. 8453 HTTPVersion *string `type:"string"` 8454 8455 // A complex type that contains the name and value for each header in the sampled 8456 // web request. 8457 Headers []*HTTPHeader `type:"list"` 8458 8459 // The HTTP method specified in the sampled web request. 8460 Method *string `type:"string"` 8461 8462 // The URI path of the request, which identifies the resource, for example, 8463 // /images/daily-ad.jpg. 8464 URI *string `type:"string"` 8465} 8466 8467// String returns the string representation 8468func (s HTTPRequest) String() string { 8469 return awsutil.Prettify(s) 8470} 8471 8472// GoString returns the string representation 8473func (s HTTPRequest) GoString() string { 8474 return s.String() 8475} 8476 8477// SetClientIP sets the ClientIP field's value. 8478func (s *HTTPRequest) SetClientIP(v string) *HTTPRequest { 8479 s.ClientIP = &v 8480 return s 8481} 8482 8483// SetCountry sets the Country field's value. 8484func (s *HTTPRequest) SetCountry(v string) *HTTPRequest { 8485 s.Country = &v 8486 return s 8487} 8488 8489// SetHTTPVersion sets the HTTPVersion field's value. 8490func (s *HTTPRequest) SetHTTPVersion(v string) *HTTPRequest { 8491 s.HTTPVersion = &v 8492 return s 8493} 8494 8495// SetHeaders sets the Headers field's value. 8496func (s *HTTPRequest) SetHeaders(v []*HTTPHeader) *HTTPRequest { 8497 s.Headers = v 8498 return s 8499} 8500 8501// SetMethod sets the Method field's value. 8502func (s *HTTPRequest) SetMethod(v string) *HTTPRequest { 8503 s.Method = &v 8504 return s 8505} 8506 8507// SetURI sets the URI field's value. 8508func (s *HTTPRequest) SetURI(v string) *HTTPRequest { 8509 s.URI = &v 8510 return s 8511} 8512 8513// 8514// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 8515// 2019. For information, including how to migrate your AWS WAF resources from 8516// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 8517// 8518// Contains one or more IP addresses or blocks of IP addresses specified in 8519// Classless Inter-Domain Routing (CIDR) notation. AWS WAF supports any CIDR 8520// range. For information about CIDR notation, see the Wikipedia entry Classless 8521// Inter-Domain Routing (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing). 8522// 8523// AWS WAF assigns an ARN to each IPSet that you create. To use an IP set in 8524// a rule, you provide the ARN to the Rule statement IPSetReferenceStatement. 8525type IPSet struct { 8526 _ struct{} `type:"structure"` 8527 8528 // The Amazon Resource Name (ARN) of the entity. 8529 // 8530 // ARN is a required field 8531 ARN *string `min:"20" type:"string" required:"true"` 8532 8533 // Contains an array of strings that specify one or more IP addresses or blocks 8534 // of IP addresses in Classless Inter-Domain Routing (CIDR) notation. AWS WAF 8535 // supports all address ranges for IP versions IPv4 and IPv6. 8536 // 8537 // Examples: 8538 // 8539 // * To configure AWS WAF to allow, block, or count requests that originated 8540 // from the IP address 192.0.2.44, specify 192.0.2.44/32. 8541 // 8542 // * To configure AWS WAF to allow, block, or count requests that originated 8543 // from IP addresses from 192.0.2.0 to 192.0.2.255, specify 192.0.2.0/24. 8544 // 8545 // * To configure AWS WAF to allow, block, or count requests that originated 8546 // from the IP address 1111:0000:0000:0000:0000:0000:0000:0111, specify 1111:0000:0000:0000:0000:0000:0000:0111/128. 8547 // 8548 // * To configure AWS WAF to allow, block, or count requests that originated 8549 // from IP addresses 1111:0000:0000:0000:0000:0000:0000:0000 to 1111:0000:0000:0000:ffff:ffff:ffff:ffff, 8550 // specify 1111:0000:0000:0000:0000:0000:0000:0000/64. 8551 // 8552 // For more information about CIDR notation, see the Wikipedia entry Classless 8553 // Inter-Domain Routing (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing). 8554 // 8555 // Addresses is a required field 8556 Addresses []*string `type:"list" required:"true"` 8557 8558 // A description of the IP set that helps with identification. You cannot change 8559 // the description of an IP set after you create it. 8560 Description *string `min:"1" type:"string"` 8561 8562 // Specify IPV4 or IPV6. 8563 // 8564 // IPAddressVersion is a required field 8565 IPAddressVersion *string `type:"string" required:"true" enum:"IPAddressVersion"` 8566 8567 // A unique identifier for the set. This ID is returned in the responses to 8568 // create and list commands. You provide it to operations like update and delete. 8569 // 8570 // Id is a required field 8571 Id *string `min:"1" type:"string" required:"true"` 8572 8573 // The name of the IP set. You cannot change the name of an IPSet after you 8574 // create it. 8575 // 8576 // Name is a required field 8577 Name *string `min:"1" type:"string" required:"true"` 8578} 8579 8580// String returns the string representation 8581func (s IPSet) String() string { 8582 return awsutil.Prettify(s) 8583} 8584 8585// GoString returns the string representation 8586func (s IPSet) GoString() string { 8587 return s.String() 8588} 8589 8590// SetARN sets the ARN field's value. 8591func (s *IPSet) SetARN(v string) *IPSet { 8592 s.ARN = &v 8593 return s 8594} 8595 8596// SetAddresses sets the Addresses field's value. 8597func (s *IPSet) SetAddresses(v []*string) *IPSet { 8598 s.Addresses = v 8599 return s 8600} 8601 8602// SetDescription sets the Description field's value. 8603func (s *IPSet) SetDescription(v string) *IPSet { 8604 s.Description = &v 8605 return s 8606} 8607 8608// SetIPAddressVersion sets the IPAddressVersion field's value. 8609func (s *IPSet) SetIPAddressVersion(v string) *IPSet { 8610 s.IPAddressVersion = &v 8611 return s 8612} 8613 8614// SetId sets the Id field's value. 8615func (s *IPSet) SetId(v string) *IPSet { 8616 s.Id = &v 8617 return s 8618} 8619 8620// SetName sets the Name field's value. 8621func (s *IPSet) SetName(v string) *IPSet { 8622 s.Name = &v 8623 return s 8624} 8625 8626// The configuration for inspecting IP addresses in an HTTP header that you 8627// specify, instead of using the IP address that's reported by the web request 8628// origin. Commonly, this is the X-Forwarded-For (XFF) header, but you can specify 8629// any header name. 8630// 8631// If the specified header isn't present in the request, AWS WAF doesn't apply 8632// the rule to the web request at all. 8633// 8634// This configuration is used only for IPSetReferenceStatement. For GeoMatchStatement 8635// and RateBasedStatement, use ForwardedIPConfig instead. 8636type IPSetForwardedIPConfig struct { 8637 _ struct{} `type:"structure"` 8638 8639 // The match status to assign to the web request if the request doesn't have 8640 // a valid IP address in the specified position. 8641 // 8642 // If the specified header isn't present in the request, AWS WAF doesn't apply 8643 // the rule to the web request at all. 8644 // 8645 // You can specify the following fallback behaviors: 8646 // 8647 // * MATCH - Treat the web request as matching the rule statement. AWS WAF 8648 // applies the rule action to the request. 8649 // 8650 // * NO_MATCH - Treat the web request as not matching the rule statement. 8651 // 8652 // FallbackBehavior is a required field 8653 FallbackBehavior *string `type:"string" required:"true" enum:"FallbackBehavior"` 8654 8655 // The name of the HTTP header to use for the IP address. For example, to use 8656 // the X-Forwarded-For (XFF) header, set this to X-Forwarded-For. 8657 // 8658 // If the specified header isn't present in the request, AWS WAF doesn't apply 8659 // the rule to the web request at all. 8660 // 8661 // HeaderName is a required field 8662 HeaderName *string `min:"1" type:"string" required:"true"` 8663 8664 // The position in the header to search for the IP address. The header can contain 8665 // IP addresses of the original client and also of proxies. For example, the 8666 // header value could be 10.1.1.1, 127.0.0.0, 10.10.10.10 where the first IP 8667 // address identifies the original client and the rest identify proxies that 8668 // the request went through. 8669 // 8670 // The options for this setting are the following: 8671 // 8672 // * FIRST - Inspect the first IP address in the list of IP addresses in 8673 // the header. This is usually the client's original IP. 8674 // 8675 // * LAST - Inspect the last IP address in the list of IP addresses in the 8676 // header. 8677 // 8678 // * ANY - Inspect all IP addresses in the header for a match. If the header 8679 // contains more than 10 IP addresses, AWS WAF inspects the last 10. 8680 // 8681 // Position is a required field 8682 Position *string `type:"string" required:"true" enum:"ForwardedIPPosition"` 8683} 8684 8685// String returns the string representation 8686func (s IPSetForwardedIPConfig) String() string { 8687 return awsutil.Prettify(s) 8688} 8689 8690// GoString returns the string representation 8691func (s IPSetForwardedIPConfig) GoString() string { 8692 return s.String() 8693} 8694 8695// Validate inspects the fields of the type to determine if they are valid. 8696func (s *IPSetForwardedIPConfig) Validate() error { 8697 invalidParams := request.ErrInvalidParams{Context: "IPSetForwardedIPConfig"} 8698 if s.FallbackBehavior == nil { 8699 invalidParams.Add(request.NewErrParamRequired("FallbackBehavior")) 8700 } 8701 if s.HeaderName == nil { 8702 invalidParams.Add(request.NewErrParamRequired("HeaderName")) 8703 } 8704 if s.HeaderName != nil && len(*s.HeaderName) < 1 { 8705 invalidParams.Add(request.NewErrParamMinLen("HeaderName", 1)) 8706 } 8707 if s.Position == nil { 8708 invalidParams.Add(request.NewErrParamRequired("Position")) 8709 } 8710 8711 if invalidParams.Len() > 0 { 8712 return invalidParams 8713 } 8714 return nil 8715} 8716 8717// SetFallbackBehavior sets the FallbackBehavior field's value. 8718func (s *IPSetForwardedIPConfig) SetFallbackBehavior(v string) *IPSetForwardedIPConfig { 8719 s.FallbackBehavior = &v 8720 return s 8721} 8722 8723// SetHeaderName sets the HeaderName field's value. 8724func (s *IPSetForwardedIPConfig) SetHeaderName(v string) *IPSetForwardedIPConfig { 8725 s.HeaderName = &v 8726 return s 8727} 8728 8729// SetPosition sets the Position field's value. 8730func (s *IPSetForwardedIPConfig) SetPosition(v string) *IPSetForwardedIPConfig { 8731 s.Position = &v 8732 return s 8733} 8734 8735// 8736// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 8737// 2019. For information, including how to migrate your AWS WAF resources from 8738// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 8739// 8740// A rule statement used to detect web requests coming from particular IP addresses 8741// or address ranges. To use this, create an IPSet that specifies the addresses 8742// you want to detect, then use the ARN of that set in this statement. To create 8743// an IP set, see CreateIPSet. 8744// 8745// Each IP set rule statement references an IP set. You create and maintain 8746// the set independent of your rules. This allows you to use the single set 8747// in multiple rules. When you update the referenced set, AWS WAF automatically 8748// updates all rules that reference it. 8749type IPSetReferenceStatement struct { 8750 _ struct{} `type:"structure"` 8751 8752 // The Amazon Resource Name (ARN) of the IPSet that this statement references. 8753 // 8754 // ARN is a required field 8755 ARN *string `min:"20" type:"string" required:"true"` 8756 8757 // The configuration for inspecting IP addresses in an HTTP header that you 8758 // specify, instead of using the IP address that's reported by the web request 8759 // origin. Commonly, this is the X-Forwarded-For (XFF) header, but you can specify 8760 // any header name. 8761 // 8762 // If the specified header isn't present in the request, AWS WAF doesn't apply 8763 // the rule to the web request at all. 8764 IPSetForwardedIPConfig *IPSetForwardedIPConfig `type:"structure"` 8765} 8766 8767// String returns the string representation 8768func (s IPSetReferenceStatement) String() string { 8769 return awsutil.Prettify(s) 8770} 8771 8772// GoString returns the string representation 8773func (s IPSetReferenceStatement) GoString() string { 8774 return s.String() 8775} 8776 8777// Validate inspects the fields of the type to determine if they are valid. 8778func (s *IPSetReferenceStatement) Validate() error { 8779 invalidParams := request.ErrInvalidParams{Context: "IPSetReferenceStatement"} 8780 if s.ARN == nil { 8781 invalidParams.Add(request.NewErrParamRequired("ARN")) 8782 } 8783 if s.ARN != nil && len(*s.ARN) < 20 { 8784 invalidParams.Add(request.NewErrParamMinLen("ARN", 20)) 8785 } 8786 if s.IPSetForwardedIPConfig != nil { 8787 if err := s.IPSetForwardedIPConfig.Validate(); err != nil { 8788 invalidParams.AddNested("IPSetForwardedIPConfig", err.(request.ErrInvalidParams)) 8789 } 8790 } 8791 8792 if invalidParams.Len() > 0 { 8793 return invalidParams 8794 } 8795 return nil 8796} 8797 8798// SetARN sets the ARN field's value. 8799func (s *IPSetReferenceStatement) SetARN(v string) *IPSetReferenceStatement { 8800 s.ARN = &v 8801 return s 8802} 8803 8804// SetIPSetForwardedIPConfig sets the IPSetForwardedIPConfig field's value. 8805func (s *IPSetReferenceStatement) SetIPSetForwardedIPConfig(v *IPSetForwardedIPConfig) *IPSetReferenceStatement { 8806 s.IPSetForwardedIPConfig = v 8807 return s 8808} 8809 8810// 8811// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 8812// 2019. For information, including how to migrate your AWS WAF resources from 8813// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 8814// 8815// High-level information about an IPSet, returned by operations like create 8816// and list. This provides information like the ID, that you can use to retrieve 8817// and manage an IPSet, and the ARN, that you provide to the IPSetReferenceStatement 8818// to use the address set in a Rule. 8819type IPSetSummary struct { 8820 _ struct{} `type:"structure"` 8821 8822 // The Amazon Resource Name (ARN) of the entity. 8823 ARN *string `min:"20" type:"string"` 8824 8825 // A description of the IP set that helps with identification. You cannot change 8826 // the description of an IP set after you create it. 8827 Description *string `min:"1" type:"string"` 8828 8829 // A unique identifier for the set. This ID is returned in the responses to 8830 // create and list commands. You provide it to operations like update and delete. 8831 Id *string `min:"1" type:"string"` 8832 8833 // A token used for optimistic locking. AWS WAF returns a token to your get 8834 // and list requests, to mark the state of the entity at the time of the request. 8835 // To make changes to the entity associated with the token, you provide the 8836 // token to operations like update and delete. AWS WAF uses the token to ensure 8837 // that no changes have been made to the entity since you last retrieved it. 8838 // If a change has been made, the update fails with a WAFOptimisticLockException. 8839 // If this happens, perform another get, and use the new token returned by that 8840 // operation. 8841 LockToken *string `min:"1" type:"string"` 8842 8843 // The name of the IP set. You cannot change the name of an IPSet after you 8844 // create it. 8845 Name *string `min:"1" type:"string"` 8846} 8847 8848// String returns the string representation 8849func (s IPSetSummary) String() string { 8850 return awsutil.Prettify(s) 8851} 8852 8853// GoString returns the string representation 8854func (s IPSetSummary) GoString() string { 8855 return s.String() 8856} 8857 8858// SetARN sets the ARN field's value. 8859func (s *IPSetSummary) SetARN(v string) *IPSetSummary { 8860 s.ARN = &v 8861 return s 8862} 8863 8864// SetDescription sets the Description field's value. 8865func (s *IPSetSummary) SetDescription(v string) *IPSetSummary { 8866 s.Description = &v 8867 return s 8868} 8869 8870// SetId sets the Id field's value. 8871func (s *IPSetSummary) SetId(v string) *IPSetSummary { 8872 s.Id = &v 8873 return s 8874} 8875 8876// SetLockToken sets the LockToken field's value. 8877func (s *IPSetSummary) SetLockToken(v string) *IPSetSummary { 8878 s.LockToken = &v 8879 return s 8880} 8881 8882// SetName sets the Name field's value. 8883func (s *IPSetSummary) SetName(v string) *IPSetSummary { 8884 s.Name = &v 8885 return s 8886} 8887 8888type ListAvailableManagedRuleGroupsInput struct { 8889 _ struct{} `type:"structure"` 8890 8891 // The maximum number of objects that you want AWS WAF to return for this request. 8892 // If more objects are available, in the response, AWS WAF provides a NextMarker 8893 // value that you can use in a subsequent call to get the next batch of objects. 8894 Limit *int64 `min:"1" type:"integer"` 8895 8896 // When you request a list of objects with a Limit setting, if the number of 8897 // objects that are still available for retrieval exceeds the limit, AWS WAF 8898 // returns a NextMarker value in the response. To retrieve the next batch of 8899 // objects, provide the marker from the prior call in your next request. 8900 NextMarker *string `min:"1" type:"string"` 8901 8902 // Specifies whether this is for an AWS CloudFront distribution or for a regional 8903 // application. A regional application can be an Application Load Balancer (ALB), 8904 // an API Gateway REST API, or an AppSync GraphQL API. 8905 // 8906 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 8907 // as follows: 8908 // 8909 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 8910 // --region=us-east-1. 8911 // 8912 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 8913 // 8914 // Scope is a required field 8915 Scope *string `type:"string" required:"true" enum:"Scope"` 8916} 8917 8918// String returns the string representation 8919func (s ListAvailableManagedRuleGroupsInput) String() string { 8920 return awsutil.Prettify(s) 8921} 8922 8923// GoString returns the string representation 8924func (s ListAvailableManagedRuleGroupsInput) GoString() string { 8925 return s.String() 8926} 8927 8928// Validate inspects the fields of the type to determine if they are valid. 8929func (s *ListAvailableManagedRuleGroupsInput) Validate() error { 8930 invalidParams := request.ErrInvalidParams{Context: "ListAvailableManagedRuleGroupsInput"} 8931 if s.Limit != nil && *s.Limit < 1 { 8932 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 8933 } 8934 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 8935 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 8936 } 8937 if s.Scope == nil { 8938 invalidParams.Add(request.NewErrParamRequired("Scope")) 8939 } 8940 8941 if invalidParams.Len() > 0 { 8942 return invalidParams 8943 } 8944 return nil 8945} 8946 8947// SetLimit sets the Limit field's value. 8948func (s *ListAvailableManagedRuleGroupsInput) SetLimit(v int64) *ListAvailableManagedRuleGroupsInput { 8949 s.Limit = &v 8950 return s 8951} 8952 8953// SetNextMarker sets the NextMarker field's value. 8954func (s *ListAvailableManagedRuleGroupsInput) SetNextMarker(v string) *ListAvailableManagedRuleGroupsInput { 8955 s.NextMarker = &v 8956 return s 8957} 8958 8959// SetScope sets the Scope field's value. 8960func (s *ListAvailableManagedRuleGroupsInput) SetScope(v string) *ListAvailableManagedRuleGroupsInput { 8961 s.Scope = &v 8962 return s 8963} 8964 8965type ListAvailableManagedRuleGroupsOutput struct { 8966 _ struct{} `type:"structure"` 8967 8968 ManagedRuleGroups []*ManagedRuleGroupSummary `type:"list"` 8969 8970 // When you request a list of objects with a Limit setting, if the number of 8971 // objects that are still available for retrieval exceeds the limit, AWS WAF 8972 // returns a NextMarker value in the response. To retrieve the next batch of 8973 // objects, provide the marker from the prior call in your next request. 8974 NextMarker *string `min:"1" type:"string"` 8975} 8976 8977// String returns the string representation 8978func (s ListAvailableManagedRuleGroupsOutput) String() string { 8979 return awsutil.Prettify(s) 8980} 8981 8982// GoString returns the string representation 8983func (s ListAvailableManagedRuleGroupsOutput) GoString() string { 8984 return s.String() 8985} 8986 8987// SetManagedRuleGroups sets the ManagedRuleGroups field's value. 8988func (s *ListAvailableManagedRuleGroupsOutput) SetManagedRuleGroups(v []*ManagedRuleGroupSummary) *ListAvailableManagedRuleGroupsOutput { 8989 s.ManagedRuleGroups = v 8990 return s 8991} 8992 8993// SetNextMarker sets the NextMarker field's value. 8994func (s *ListAvailableManagedRuleGroupsOutput) SetNextMarker(v string) *ListAvailableManagedRuleGroupsOutput { 8995 s.NextMarker = &v 8996 return s 8997} 8998 8999type ListIPSetsInput struct { 9000 _ struct{} `type:"structure"` 9001 9002 // The maximum number of objects that you want AWS WAF to return for this request. 9003 // If more objects are available, in the response, AWS WAF provides a NextMarker 9004 // value that you can use in a subsequent call to get the next batch of objects. 9005 Limit *int64 `min:"1" type:"integer"` 9006 9007 // When you request a list of objects with a Limit setting, if the number of 9008 // objects that are still available for retrieval exceeds the limit, AWS WAF 9009 // returns a NextMarker value in the response. To retrieve the next batch of 9010 // objects, provide the marker from the prior call in your next request. 9011 NextMarker *string `min:"1" type:"string"` 9012 9013 // Specifies whether this is for an AWS CloudFront distribution or for a regional 9014 // application. A regional application can be an Application Load Balancer (ALB), 9015 // an API Gateway REST API, or an AppSync GraphQL API. 9016 // 9017 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 9018 // as follows: 9019 // 9020 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 9021 // --region=us-east-1. 9022 // 9023 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 9024 // 9025 // Scope is a required field 9026 Scope *string `type:"string" required:"true" enum:"Scope"` 9027} 9028 9029// String returns the string representation 9030func (s ListIPSetsInput) String() string { 9031 return awsutil.Prettify(s) 9032} 9033 9034// GoString returns the string representation 9035func (s ListIPSetsInput) GoString() string { 9036 return s.String() 9037} 9038 9039// Validate inspects the fields of the type to determine if they are valid. 9040func (s *ListIPSetsInput) Validate() error { 9041 invalidParams := request.ErrInvalidParams{Context: "ListIPSetsInput"} 9042 if s.Limit != nil && *s.Limit < 1 { 9043 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 9044 } 9045 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 9046 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 9047 } 9048 if s.Scope == nil { 9049 invalidParams.Add(request.NewErrParamRequired("Scope")) 9050 } 9051 9052 if invalidParams.Len() > 0 { 9053 return invalidParams 9054 } 9055 return nil 9056} 9057 9058// SetLimit sets the Limit field's value. 9059func (s *ListIPSetsInput) SetLimit(v int64) *ListIPSetsInput { 9060 s.Limit = &v 9061 return s 9062} 9063 9064// SetNextMarker sets the NextMarker field's value. 9065func (s *ListIPSetsInput) SetNextMarker(v string) *ListIPSetsInput { 9066 s.NextMarker = &v 9067 return s 9068} 9069 9070// SetScope sets the Scope field's value. 9071func (s *ListIPSetsInput) SetScope(v string) *ListIPSetsInput { 9072 s.Scope = &v 9073 return s 9074} 9075 9076type ListIPSetsOutput struct { 9077 _ struct{} `type:"structure"` 9078 9079 // Array of IPSets. This may not be the full list of IPSets that you have defined. 9080 // See the Limit specification for this request. 9081 IPSets []*IPSetSummary `type:"list"` 9082 9083 // When you request a list of objects with a Limit setting, if the number of 9084 // objects that are still available for retrieval exceeds the limit, AWS WAF 9085 // returns a NextMarker value in the response. To retrieve the next batch of 9086 // objects, provide the marker from the prior call in your next request. 9087 NextMarker *string `min:"1" type:"string"` 9088} 9089 9090// String returns the string representation 9091func (s ListIPSetsOutput) String() string { 9092 return awsutil.Prettify(s) 9093} 9094 9095// GoString returns the string representation 9096func (s ListIPSetsOutput) GoString() string { 9097 return s.String() 9098} 9099 9100// SetIPSets sets the IPSets field's value. 9101func (s *ListIPSetsOutput) SetIPSets(v []*IPSetSummary) *ListIPSetsOutput { 9102 s.IPSets = v 9103 return s 9104} 9105 9106// SetNextMarker sets the NextMarker field's value. 9107func (s *ListIPSetsOutput) SetNextMarker(v string) *ListIPSetsOutput { 9108 s.NextMarker = &v 9109 return s 9110} 9111 9112type ListLoggingConfigurationsInput struct { 9113 _ struct{} `type:"structure"` 9114 9115 // The maximum number of objects that you want AWS WAF to return for this request. 9116 // If more objects are available, in the response, AWS WAF provides a NextMarker 9117 // value that you can use in a subsequent call to get the next batch of objects. 9118 Limit *int64 `min:"1" type:"integer"` 9119 9120 // When you request a list of objects with a Limit setting, if the number of 9121 // objects that are still available for retrieval exceeds the limit, AWS WAF 9122 // returns a NextMarker value in the response. To retrieve the next batch of 9123 // objects, provide the marker from the prior call in your next request. 9124 NextMarker *string `min:"1" type:"string"` 9125 9126 // Specifies whether this is for an AWS CloudFront distribution or for a regional 9127 // application. A regional application can be an Application Load Balancer (ALB), 9128 // an API Gateway REST API, or an AppSync GraphQL API. 9129 // 9130 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 9131 // as follows: 9132 // 9133 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 9134 // --region=us-east-1. 9135 // 9136 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 9137 Scope *string `type:"string" enum:"Scope"` 9138} 9139 9140// String returns the string representation 9141func (s ListLoggingConfigurationsInput) String() string { 9142 return awsutil.Prettify(s) 9143} 9144 9145// GoString returns the string representation 9146func (s ListLoggingConfigurationsInput) GoString() string { 9147 return s.String() 9148} 9149 9150// Validate inspects the fields of the type to determine if they are valid. 9151func (s *ListLoggingConfigurationsInput) Validate() error { 9152 invalidParams := request.ErrInvalidParams{Context: "ListLoggingConfigurationsInput"} 9153 if s.Limit != nil && *s.Limit < 1 { 9154 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 9155 } 9156 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 9157 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 9158 } 9159 9160 if invalidParams.Len() > 0 { 9161 return invalidParams 9162 } 9163 return nil 9164} 9165 9166// SetLimit sets the Limit field's value. 9167func (s *ListLoggingConfigurationsInput) SetLimit(v int64) *ListLoggingConfigurationsInput { 9168 s.Limit = &v 9169 return s 9170} 9171 9172// SetNextMarker sets the NextMarker field's value. 9173func (s *ListLoggingConfigurationsInput) SetNextMarker(v string) *ListLoggingConfigurationsInput { 9174 s.NextMarker = &v 9175 return s 9176} 9177 9178// SetScope sets the Scope field's value. 9179func (s *ListLoggingConfigurationsInput) SetScope(v string) *ListLoggingConfigurationsInput { 9180 s.Scope = &v 9181 return s 9182} 9183 9184type ListLoggingConfigurationsOutput struct { 9185 _ struct{} `type:"structure"` 9186 9187 LoggingConfigurations []*LoggingConfiguration `type:"list"` 9188 9189 // When you request a list of objects with a Limit setting, if the number of 9190 // objects that are still available for retrieval exceeds the limit, AWS WAF 9191 // returns a NextMarker value in the response. To retrieve the next batch of 9192 // objects, provide the marker from the prior call in your next request. 9193 NextMarker *string `min:"1" type:"string"` 9194} 9195 9196// String returns the string representation 9197func (s ListLoggingConfigurationsOutput) String() string { 9198 return awsutil.Prettify(s) 9199} 9200 9201// GoString returns the string representation 9202func (s ListLoggingConfigurationsOutput) GoString() string { 9203 return s.String() 9204} 9205 9206// SetLoggingConfigurations sets the LoggingConfigurations field's value. 9207func (s *ListLoggingConfigurationsOutput) SetLoggingConfigurations(v []*LoggingConfiguration) *ListLoggingConfigurationsOutput { 9208 s.LoggingConfigurations = v 9209 return s 9210} 9211 9212// SetNextMarker sets the NextMarker field's value. 9213func (s *ListLoggingConfigurationsOutput) SetNextMarker(v string) *ListLoggingConfigurationsOutput { 9214 s.NextMarker = &v 9215 return s 9216} 9217 9218type ListRegexPatternSetsInput struct { 9219 _ struct{} `type:"structure"` 9220 9221 // The maximum number of objects that you want AWS WAF to return for this request. 9222 // If more objects are available, in the response, AWS WAF provides a NextMarker 9223 // value that you can use in a subsequent call to get the next batch of objects. 9224 Limit *int64 `min:"1" type:"integer"` 9225 9226 // When you request a list of objects with a Limit setting, if the number of 9227 // objects that are still available for retrieval exceeds the limit, AWS WAF 9228 // returns a NextMarker value in the response. To retrieve the next batch of 9229 // objects, provide the marker from the prior call in your next request. 9230 NextMarker *string `min:"1" type:"string"` 9231 9232 // Specifies whether this is for an AWS CloudFront distribution or for a regional 9233 // application. A regional application can be an Application Load Balancer (ALB), 9234 // an API Gateway REST API, or an AppSync GraphQL API. 9235 // 9236 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 9237 // as follows: 9238 // 9239 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 9240 // --region=us-east-1. 9241 // 9242 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 9243 // 9244 // Scope is a required field 9245 Scope *string `type:"string" required:"true" enum:"Scope"` 9246} 9247 9248// String returns the string representation 9249func (s ListRegexPatternSetsInput) String() string { 9250 return awsutil.Prettify(s) 9251} 9252 9253// GoString returns the string representation 9254func (s ListRegexPatternSetsInput) GoString() string { 9255 return s.String() 9256} 9257 9258// Validate inspects the fields of the type to determine if they are valid. 9259func (s *ListRegexPatternSetsInput) Validate() error { 9260 invalidParams := request.ErrInvalidParams{Context: "ListRegexPatternSetsInput"} 9261 if s.Limit != nil && *s.Limit < 1 { 9262 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 9263 } 9264 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 9265 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 9266 } 9267 if s.Scope == nil { 9268 invalidParams.Add(request.NewErrParamRequired("Scope")) 9269 } 9270 9271 if invalidParams.Len() > 0 { 9272 return invalidParams 9273 } 9274 return nil 9275} 9276 9277// SetLimit sets the Limit field's value. 9278func (s *ListRegexPatternSetsInput) SetLimit(v int64) *ListRegexPatternSetsInput { 9279 s.Limit = &v 9280 return s 9281} 9282 9283// SetNextMarker sets the NextMarker field's value. 9284func (s *ListRegexPatternSetsInput) SetNextMarker(v string) *ListRegexPatternSetsInput { 9285 s.NextMarker = &v 9286 return s 9287} 9288 9289// SetScope sets the Scope field's value. 9290func (s *ListRegexPatternSetsInput) SetScope(v string) *ListRegexPatternSetsInput { 9291 s.Scope = &v 9292 return s 9293} 9294 9295type ListRegexPatternSetsOutput struct { 9296 _ struct{} `type:"structure"` 9297 9298 // When you request a list of objects with a Limit setting, if the number of 9299 // objects that are still available for retrieval exceeds the limit, AWS WAF 9300 // returns a NextMarker value in the response. To retrieve the next batch of 9301 // objects, provide the marker from the prior call in your next request. 9302 NextMarker *string `min:"1" type:"string"` 9303 9304 RegexPatternSets []*RegexPatternSetSummary `type:"list"` 9305} 9306 9307// String returns the string representation 9308func (s ListRegexPatternSetsOutput) String() string { 9309 return awsutil.Prettify(s) 9310} 9311 9312// GoString returns the string representation 9313func (s ListRegexPatternSetsOutput) GoString() string { 9314 return s.String() 9315} 9316 9317// SetNextMarker sets the NextMarker field's value. 9318func (s *ListRegexPatternSetsOutput) SetNextMarker(v string) *ListRegexPatternSetsOutput { 9319 s.NextMarker = &v 9320 return s 9321} 9322 9323// SetRegexPatternSets sets the RegexPatternSets field's value. 9324func (s *ListRegexPatternSetsOutput) SetRegexPatternSets(v []*RegexPatternSetSummary) *ListRegexPatternSetsOutput { 9325 s.RegexPatternSets = v 9326 return s 9327} 9328 9329type ListResourcesForWebACLInput struct { 9330 _ struct{} `type:"structure"` 9331 9332 // Used for web ACLs that are scoped for regional applications. A regional application 9333 // can be an Application Load Balancer (ALB), an API Gateway REST API, or an 9334 // AppSync GraphQL API. 9335 ResourceType *string `type:"string" enum:"ResourceType"` 9336 9337 // The Amazon Resource Name (ARN) of the Web ACL. 9338 // 9339 // WebACLArn is a required field 9340 WebACLArn *string `min:"20" type:"string" required:"true"` 9341} 9342 9343// String returns the string representation 9344func (s ListResourcesForWebACLInput) String() string { 9345 return awsutil.Prettify(s) 9346} 9347 9348// GoString returns the string representation 9349func (s ListResourcesForWebACLInput) GoString() string { 9350 return s.String() 9351} 9352 9353// Validate inspects the fields of the type to determine if they are valid. 9354func (s *ListResourcesForWebACLInput) Validate() error { 9355 invalidParams := request.ErrInvalidParams{Context: "ListResourcesForWebACLInput"} 9356 if s.WebACLArn == nil { 9357 invalidParams.Add(request.NewErrParamRequired("WebACLArn")) 9358 } 9359 if s.WebACLArn != nil && len(*s.WebACLArn) < 20 { 9360 invalidParams.Add(request.NewErrParamMinLen("WebACLArn", 20)) 9361 } 9362 9363 if invalidParams.Len() > 0 { 9364 return invalidParams 9365 } 9366 return nil 9367} 9368 9369// SetResourceType sets the ResourceType field's value. 9370func (s *ListResourcesForWebACLInput) SetResourceType(v string) *ListResourcesForWebACLInput { 9371 s.ResourceType = &v 9372 return s 9373} 9374 9375// SetWebACLArn sets the WebACLArn field's value. 9376func (s *ListResourcesForWebACLInput) SetWebACLArn(v string) *ListResourcesForWebACLInput { 9377 s.WebACLArn = &v 9378 return s 9379} 9380 9381type ListResourcesForWebACLOutput struct { 9382 _ struct{} `type:"structure"` 9383 9384 // The array of Amazon Resource Names (ARNs) of the associated resources. 9385 ResourceArns []*string `type:"list"` 9386} 9387 9388// String returns the string representation 9389func (s ListResourcesForWebACLOutput) String() string { 9390 return awsutil.Prettify(s) 9391} 9392 9393// GoString returns the string representation 9394func (s ListResourcesForWebACLOutput) GoString() string { 9395 return s.String() 9396} 9397 9398// SetResourceArns sets the ResourceArns field's value. 9399func (s *ListResourcesForWebACLOutput) SetResourceArns(v []*string) *ListResourcesForWebACLOutput { 9400 s.ResourceArns = v 9401 return s 9402} 9403 9404type ListRuleGroupsInput struct { 9405 _ struct{} `type:"structure"` 9406 9407 // The maximum number of objects that you want AWS WAF to return for this request. 9408 // If more objects are available, in the response, AWS WAF provides a NextMarker 9409 // value that you can use in a subsequent call to get the next batch of objects. 9410 Limit *int64 `min:"1" type:"integer"` 9411 9412 // When you request a list of objects with a Limit setting, if the number of 9413 // objects that are still available for retrieval exceeds the limit, AWS WAF 9414 // returns a NextMarker value in the response. To retrieve the next batch of 9415 // objects, provide the marker from the prior call in your next request. 9416 NextMarker *string `min:"1" type:"string"` 9417 9418 // Specifies whether this is for an AWS CloudFront distribution or for a regional 9419 // application. A regional application can be an Application Load Balancer (ALB), 9420 // an API Gateway REST API, or an AppSync GraphQL API. 9421 // 9422 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 9423 // as follows: 9424 // 9425 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 9426 // --region=us-east-1. 9427 // 9428 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 9429 // 9430 // Scope is a required field 9431 Scope *string `type:"string" required:"true" enum:"Scope"` 9432} 9433 9434// String returns the string representation 9435func (s ListRuleGroupsInput) String() string { 9436 return awsutil.Prettify(s) 9437} 9438 9439// GoString returns the string representation 9440func (s ListRuleGroupsInput) GoString() string { 9441 return s.String() 9442} 9443 9444// Validate inspects the fields of the type to determine if they are valid. 9445func (s *ListRuleGroupsInput) Validate() error { 9446 invalidParams := request.ErrInvalidParams{Context: "ListRuleGroupsInput"} 9447 if s.Limit != nil && *s.Limit < 1 { 9448 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 9449 } 9450 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 9451 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 9452 } 9453 if s.Scope == nil { 9454 invalidParams.Add(request.NewErrParamRequired("Scope")) 9455 } 9456 9457 if invalidParams.Len() > 0 { 9458 return invalidParams 9459 } 9460 return nil 9461} 9462 9463// SetLimit sets the Limit field's value. 9464func (s *ListRuleGroupsInput) SetLimit(v int64) *ListRuleGroupsInput { 9465 s.Limit = &v 9466 return s 9467} 9468 9469// SetNextMarker sets the NextMarker field's value. 9470func (s *ListRuleGroupsInput) SetNextMarker(v string) *ListRuleGroupsInput { 9471 s.NextMarker = &v 9472 return s 9473} 9474 9475// SetScope sets the Scope field's value. 9476func (s *ListRuleGroupsInput) SetScope(v string) *ListRuleGroupsInput { 9477 s.Scope = &v 9478 return s 9479} 9480 9481type ListRuleGroupsOutput struct { 9482 _ struct{} `type:"structure"` 9483 9484 // When you request a list of objects with a Limit setting, if the number of 9485 // objects that are still available for retrieval exceeds the limit, AWS WAF 9486 // returns a NextMarker value in the response. To retrieve the next batch of 9487 // objects, provide the marker from the prior call in your next request. 9488 NextMarker *string `min:"1" type:"string"` 9489 9490 RuleGroups []*RuleGroupSummary `type:"list"` 9491} 9492 9493// String returns the string representation 9494func (s ListRuleGroupsOutput) String() string { 9495 return awsutil.Prettify(s) 9496} 9497 9498// GoString returns the string representation 9499func (s ListRuleGroupsOutput) GoString() string { 9500 return s.String() 9501} 9502 9503// SetNextMarker sets the NextMarker field's value. 9504func (s *ListRuleGroupsOutput) SetNextMarker(v string) *ListRuleGroupsOutput { 9505 s.NextMarker = &v 9506 return s 9507} 9508 9509// SetRuleGroups sets the RuleGroups field's value. 9510func (s *ListRuleGroupsOutput) SetRuleGroups(v []*RuleGroupSummary) *ListRuleGroupsOutput { 9511 s.RuleGroups = v 9512 return s 9513} 9514 9515type ListTagsForResourceInput struct { 9516 _ struct{} `type:"structure"` 9517 9518 // The maximum number of objects that you want AWS WAF to return for this request. 9519 // If more objects are available, in the response, AWS WAF provides a NextMarker 9520 // value that you can use in a subsequent call to get the next batch of objects. 9521 Limit *int64 `min:"1" type:"integer"` 9522 9523 // When you request a list of objects with a Limit setting, if the number of 9524 // objects that are still available for retrieval exceeds the limit, AWS WAF 9525 // returns a NextMarker value in the response. To retrieve the next batch of 9526 // objects, provide the marker from the prior call in your next request. 9527 NextMarker *string `min:"1" type:"string"` 9528 9529 // The Amazon Resource Name (ARN) of the resource. 9530 // 9531 // ResourceARN is a required field 9532 ResourceARN *string `min:"20" type:"string" required:"true"` 9533} 9534 9535// String returns the string representation 9536func (s ListTagsForResourceInput) String() string { 9537 return awsutil.Prettify(s) 9538} 9539 9540// GoString returns the string representation 9541func (s ListTagsForResourceInput) GoString() string { 9542 return s.String() 9543} 9544 9545// Validate inspects the fields of the type to determine if they are valid. 9546func (s *ListTagsForResourceInput) Validate() error { 9547 invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} 9548 if s.Limit != nil && *s.Limit < 1 { 9549 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 9550 } 9551 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 9552 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 9553 } 9554 if s.ResourceARN == nil { 9555 invalidParams.Add(request.NewErrParamRequired("ResourceARN")) 9556 } 9557 if s.ResourceARN != nil && len(*s.ResourceARN) < 20 { 9558 invalidParams.Add(request.NewErrParamMinLen("ResourceARN", 20)) 9559 } 9560 9561 if invalidParams.Len() > 0 { 9562 return invalidParams 9563 } 9564 return nil 9565} 9566 9567// SetLimit sets the Limit field's value. 9568func (s *ListTagsForResourceInput) SetLimit(v int64) *ListTagsForResourceInput { 9569 s.Limit = &v 9570 return s 9571} 9572 9573// SetNextMarker sets the NextMarker field's value. 9574func (s *ListTagsForResourceInput) SetNextMarker(v string) *ListTagsForResourceInput { 9575 s.NextMarker = &v 9576 return s 9577} 9578 9579// SetResourceARN sets the ResourceARN field's value. 9580func (s *ListTagsForResourceInput) SetResourceARN(v string) *ListTagsForResourceInput { 9581 s.ResourceARN = &v 9582 return s 9583} 9584 9585type ListTagsForResourceOutput struct { 9586 _ struct{} `type:"structure"` 9587 9588 // When you request a list of objects with a Limit setting, if the number of 9589 // objects that are still available for retrieval exceeds the limit, AWS WAF 9590 // returns a NextMarker value in the response. To retrieve the next batch of 9591 // objects, provide the marker from the prior call in your next request. 9592 NextMarker *string `min:"1" type:"string"` 9593 9594 // The collection of tagging definitions for the resource. 9595 TagInfoForResource *TagInfoForResource `type:"structure"` 9596} 9597 9598// String returns the string representation 9599func (s ListTagsForResourceOutput) String() string { 9600 return awsutil.Prettify(s) 9601} 9602 9603// GoString returns the string representation 9604func (s ListTagsForResourceOutput) GoString() string { 9605 return s.String() 9606} 9607 9608// SetNextMarker sets the NextMarker field's value. 9609func (s *ListTagsForResourceOutput) SetNextMarker(v string) *ListTagsForResourceOutput { 9610 s.NextMarker = &v 9611 return s 9612} 9613 9614// SetTagInfoForResource sets the TagInfoForResource field's value. 9615func (s *ListTagsForResourceOutput) SetTagInfoForResource(v *TagInfoForResource) *ListTagsForResourceOutput { 9616 s.TagInfoForResource = v 9617 return s 9618} 9619 9620type ListWebACLsInput struct { 9621 _ struct{} `type:"structure"` 9622 9623 // The maximum number of objects that you want AWS WAF to return for this request. 9624 // If more objects are available, in the response, AWS WAF provides a NextMarker 9625 // value that you can use in a subsequent call to get the next batch of objects. 9626 Limit *int64 `min:"1" type:"integer"` 9627 9628 // When you request a list of objects with a Limit setting, if the number of 9629 // objects that are still available for retrieval exceeds the limit, AWS WAF 9630 // returns a NextMarker value in the response. To retrieve the next batch of 9631 // objects, provide the marker from the prior call in your next request. 9632 NextMarker *string `min:"1" type:"string"` 9633 9634 // Specifies whether this is for an AWS CloudFront distribution or for a regional 9635 // application. A regional application can be an Application Load Balancer (ALB), 9636 // an API Gateway REST API, or an AppSync GraphQL API. 9637 // 9638 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 9639 // as follows: 9640 // 9641 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 9642 // --region=us-east-1. 9643 // 9644 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 9645 // 9646 // Scope is a required field 9647 Scope *string `type:"string" required:"true" enum:"Scope"` 9648} 9649 9650// String returns the string representation 9651func (s ListWebACLsInput) String() string { 9652 return awsutil.Prettify(s) 9653} 9654 9655// GoString returns the string representation 9656func (s ListWebACLsInput) GoString() string { 9657 return s.String() 9658} 9659 9660// Validate inspects the fields of the type to determine if they are valid. 9661func (s *ListWebACLsInput) Validate() error { 9662 invalidParams := request.ErrInvalidParams{Context: "ListWebACLsInput"} 9663 if s.Limit != nil && *s.Limit < 1 { 9664 invalidParams.Add(request.NewErrParamMinValue("Limit", 1)) 9665 } 9666 if s.NextMarker != nil && len(*s.NextMarker) < 1 { 9667 invalidParams.Add(request.NewErrParamMinLen("NextMarker", 1)) 9668 } 9669 if s.Scope == nil { 9670 invalidParams.Add(request.NewErrParamRequired("Scope")) 9671 } 9672 9673 if invalidParams.Len() > 0 { 9674 return invalidParams 9675 } 9676 return nil 9677} 9678 9679// SetLimit sets the Limit field's value. 9680func (s *ListWebACLsInput) SetLimit(v int64) *ListWebACLsInput { 9681 s.Limit = &v 9682 return s 9683} 9684 9685// SetNextMarker sets the NextMarker field's value. 9686func (s *ListWebACLsInput) SetNextMarker(v string) *ListWebACLsInput { 9687 s.NextMarker = &v 9688 return s 9689} 9690 9691// SetScope sets the Scope field's value. 9692func (s *ListWebACLsInput) SetScope(v string) *ListWebACLsInput { 9693 s.Scope = &v 9694 return s 9695} 9696 9697type ListWebACLsOutput struct { 9698 _ struct{} `type:"structure"` 9699 9700 // When you request a list of objects with a Limit setting, if the number of 9701 // objects that are still available for retrieval exceeds the limit, AWS WAF 9702 // returns a NextMarker value in the response. To retrieve the next batch of 9703 // objects, provide the marker from the prior call in your next request. 9704 NextMarker *string `min:"1" type:"string"` 9705 9706 WebACLs []*WebACLSummary `type:"list"` 9707} 9708 9709// String returns the string representation 9710func (s ListWebACLsOutput) String() string { 9711 return awsutil.Prettify(s) 9712} 9713 9714// GoString returns the string representation 9715func (s ListWebACLsOutput) GoString() string { 9716 return s.String() 9717} 9718 9719// SetNextMarker sets the NextMarker field's value. 9720func (s *ListWebACLsOutput) SetNextMarker(v string) *ListWebACLsOutput { 9721 s.NextMarker = &v 9722 return s 9723} 9724 9725// SetWebACLs sets the WebACLs field's value. 9726func (s *ListWebACLsOutput) SetWebACLs(v []*WebACLSummary) *ListWebACLsOutput { 9727 s.WebACLs = v 9728 return s 9729} 9730 9731// 9732// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 9733// 2019. For information, including how to migrate your AWS WAF resources from 9734// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 9735// 9736// Defines an association between Amazon Kinesis Data Firehose destinations 9737// and a web ACL resource, for logging from AWS WAF. As part of the association, 9738// you can specify parts of the standard logging fields to keep out of the logs. 9739type LoggingConfiguration struct { 9740 _ struct{} `type:"structure"` 9741 9742 // The Amazon Kinesis Data Firehose Amazon Resource Name (ARNs) that you want 9743 // to associate with the web ACL. 9744 // 9745 // LogDestinationConfigs is a required field 9746 LogDestinationConfigs []*string `min:"1" type:"list" required:"true"` 9747 9748 // Indicates whether the logging configuration was created by AWS Firewall Manager, 9749 // as part of an AWS WAF policy configuration. If true, only Firewall Manager 9750 // can modify or delete the configuration. 9751 ManagedByFirewallManager *bool `type:"boolean"` 9752 9753 // The parts of the request that you want to keep out of the logs. For example, 9754 // if you redact the HEADER field, the HEADER field in the firehose will be 9755 // xxx. 9756 // 9757 // You must use one of the following values: URI, QUERY_STRING, HEADER, or METHOD. 9758 RedactedFields []*FieldToMatch `type:"list"` 9759 9760 // The Amazon Resource Name (ARN) of the web ACL that you want to associate 9761 // with LogDestinationConfigs. 9762 // 9763 // ResourceArn is a required field 9764 ResourceArn *string `min:"20" type:"string" required:"true"` 9765} 9766 9767// String returns the string representation 9768func (s LoggingConfiguration) String() string { 9769 return awsutil.Prettify(s) 9770} 9771 9772// GoString returns the string representation 9773func (s LoggingConfiguration) GoString() string { 9774 return s.String() 9775} 9776 9777// Validate inspects the fields of the type to determine if they are valid. 9778func (s *LoggingConfiguration) Validate() error { 9779 invalidParams := request.ErrInvalidParams{Context: "LoggingConfiguration"} 9780 if s.LogDestinationConfigs == nil { 9781 invalidParams.Add(request.NewErrParamRequired("LogDestinationConfigs")) 9782 } 9783 if s.LogDestinationConfigs != nil && len(s.LogDestinationConfigs) < 1 { 9784 invalidParams.Add(request.NewErrParamMinLen("LogDestinationConfigs", 1)) 9785 } 9786 if s.ResourceArn == nil { 9787 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 9788 } 9789 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 9790 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 9791 } 9792 if s.RedactedFields != nil { 9793 for i, v := range s.RedactedFields { 9794 if v == nil { 9795 continue 9796 } 9797 if err := v.Validate(); err != nil { 9798 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RedactedFields", i), err.(request.ErrInvalidParams)) 9799 } 9800 } 9801 } 9802 9803 if invalidParams.Len() > 0 { 9804 return invalidParams 9805 } 9806 return nil 9807} 9808 9809// SetLogDestinationConfigs sets the LogDestinationConfigs field's value. 9810func (s *LoggingConfiguration) SetLogDestinationConfigs(v []*string) *LoggingConfiguration { 9811 s.LogDestinationConfigs = v 9812 return s 9813} 9814 9815// SetManagedByFirewallManager sets the ManagedByFirewallManager field's value. 9816func (s *LoggingConfiguration) SetManagedByFirewallManager(v bool) *LoggingConfiguration { 9817 s.ManagedByFirewallManager = &v 9818 return s 9819} 9820 9821// SetRedactedFields sets the RedactedFields field's value. 9822func (s *LoggingConfiguration) SetRedactedFields(v []*FieldToMatch) *LoggingConfiguration { 9823 s.RedactedFields = v 9824 return s 9825} 9826 9827// SetResourceArn sets the ResourceArn field's value. 9828func (s *LoggingConfiguration) SetResourceArn(v string) *LoggingConfiguration { 9829 s.ResourceArn = &v 9830 return s 9831} 9832 9833// 9834// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 9835// 2019. For information, including how to migrate your AWS WAF resources from 9836// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 9837// 9838// A rule statement used to run the rules that are defined in a managed rule 9839// group. To use this, provide the vendor name and the name of the rule group 9840// in this statement. You can retrieve the required names by calling ListAvailableManagedRuleGroups. 9841// 9842// You can't nest a ManagedRuleGroupStatement, for example for use inside a 9843// NotStatement or OrStatement. It can only be referenced as a top-level statement 9844// within a rule. 9845type ManagedRuleGroupStatement struct { 9846 _ struct{} `type:"structure"` 9847 9848 // The rules whose actions are set to COUNT by the web ACL, regardless of the 9849 // action that is set on the rule. This effectively excludes the rule from acting 9850 // on web requests. 9851 ExcludedRules []*ExcludedRule `type:"list"` 9852 9853 // The name of the managed rule group. You use this, along with the vendor name, 9854 // to identify the rule group. 9855 // 9856 // Name is a required field 9857 Name *string `min:"1" type:"string" required:"true"` 9858 9859 // The name of the managed rule group vendor. You use this, along with the rule 9860 // group name, to identify the rule group. 9861 // 9862 // VendorName is a required field 9863 VendorName *string `min:"1" type:"string" required:"true"` 9864} 9865 9866// String returns the string representation 9867func (s ManagedRuleGroupStatement) String() string { 9868 return awsutil.Prettify(s) 9869} 9870 9871// GoString returns the string representation 9872func (s ManagedRuleGroupStatement) GoString() string { 9873 return s.String() 9874} 9875 9876// Validate inspects the fields of the type to determine if they are valid. 9877func (s *ManagedRuleGroupStatement) Validate() error { 9878 invalidParams := request.ErrInvalidParams{Context: "ManagedRuleGroupStatement"} 9879 if s.Name == nil { 9880 invalidParams.Add(request.NewErrParamRequired("Name")) 9881 } 9882 if s.Name != nil && len(*s.Name) < 1 { 9883 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 9884 } 9885 if s.VendorName == nil { 9886 invalidParams.Add(request.NewErrParamRequired("VendorName")) 9887 } 9888 if s.VendorName != nil && len(*s.VendorName) < 1 { 9889 invalidParams.Add(request.NewErrParamMinLen("VendorName", 1)) 9890 } 9891 if s.ExcludedRules != nil { 9892 for i, v := range s.ExcludedRules { 9893 if v == nil { 9894 continue 9895 } 9896 if err := v.Validate(); err != nil { 9897 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ExcludedRules", i), err.(request.ErrInvalidParams)) 9898 } 9899 } 9900 } 9901 9902 if invalidParams.Len() > 0 { 9903 return invalidParams 9904 } 9905 return nil 9906} 9907 9908// SetExcludedRules sets the ExcludedRules field's value. 9909func (s *ManagedRuleGroupStatement) SetExcludedRules(v []*ExcludedRule) *ManagedRuleGroupStatement { 9910 s.ExcludedRules = v 9911 return s 9912} 9913 9914// SetName sets the Name field's value. 9915func (s *ManagedRuleGroupStatement) SetName(v string) *ManagedRuleGroupStatement { 9916 s.Name = &v 9917 return s 9918} 9919 9920// SetVendorName sets the VendorName field's value. 9921func (s *ManagedRuleGroupStatement) SetVendorName(v string) *ManagedRuleGroupStatement { 9922 s.VendorName = &v 9923 return s 9924} 9925 9926// 9927// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 9928// 2019. For information, including how to migrate your AWS WAF resources from 9929// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 9930// 9931// High-level information about a managed rule group, returned by ListAvailableManagedRuleGroups. 9932// This provides information like the name and vendor name, that you provide 9933// when you add a ManagedRuleGroupStatement to a web ACL. Managed rule groups 9934// include AWS Managed Rules rule groups, which are free of charge to AWS WAF 9935// customers, and AWS Marketplace managed rule groups, which you can subscribe 9936// to through AWS Marketplace. 9937type ManagedRuleGroupSummary struct { 9938 _ struct{} `type:"structure"` 9939 9940 // The description of the managed rule group, provided by AWS Managed Rules 9941 // or the AWS Marketplace seller who manages it. 9942 Description *string `min:"1" type:"string"` 9943 9944 // The name of the managed rule group. You use this, along with the vendor name, 9945 // to identify the rule group. 9946 Name *string `min:"1" type:"string"` 9947 9948 // The name of the managed rule group vendor. You use this, along with the rule 9949 // group name, to identify the rule group. 9950 VendorName *string `min:"1" type:"string"` 9951} 9952 9953// String returns the string representation 9954func (s ManagedRuleGroupSummary) String() string { 9955 return awsutil.Prettify(s) 9956} 9957 9958// GoString returns the string representation 9959func (s ManagedRuleGroupSummary) GoString() string { 9960 return s.String() 9961} 9962 9963// SetDescription sets the Description field's value. 9964func (s *ManagedRuleGroupSummary) SetDescription(v string) *ManagedRuleGroupSummary { 9965 s.Description = &v 9966 return s 9967} 9968 9969// SetName sets the Name field's value. 9970func (s *ManagedRuleGroupSummary) SetName(v string) *ManagedRuleGroupSummary { 9971 s.Name = &v 9972 return s 9973} 9974 9975// SetVendorName sets the VendorName field's value. 9976func (s *ManagedRuleGroupSummary) SetVendorName(v string) *ManagedRuleGroupSummary { 9977 s.VendorName = &v 9978 return s 9979} 9980 9981// 9982// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 9983// 2019. For information, including how to migrate your AWS WAF resources from 9984// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 9985// 9986// The HTTP method of a web request. The method indicates the type of operation 9987// that the request is asking the origin to perform. 9988// 9989// This is used only to indicate the web request component for AWS WAF to inspect, 9990// in the FieldToMatch specification. 9991type Method struct { 9992 _ struct{} `type:"structure"` 9993} 9994 9995// String returns the string representation 9996func (s Method) String() string { 9997 return awsutil.Prettify(s) 9998} 9999 10000// GoString returns the string representation 10001func (s Method) GoString() string { 10002 return s.String() 10003} 10004 10005// 10006// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10007// 2019. For information, including how to migrate your AWS WAF resources from 10008// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10009// 10010// Specifies that AWS WAF should do nothing. This is generally used to try out 10011// a rule without performing any actions. You set the OverrideAction on the 10012// Rule. 10013// 10014// This is used only in the context of other settings, for example to specify 10015// values for RuleAction and web ACL DefaultAction. 10016type NoneAction struct { 10017 _ struct{} `type:"structure"` 10018} 10019 10020// String returns the string representation 10021func (s NoneAction) String() string { 10022 return awsutil.Prettify(s) 10023} 10024 10025// GoString returns the string representation 10026func (s NoneAction) GoString() string { 10027 return s.String() 10028} 10029 10030// 10031// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10032// 2019. For information, including how to migrate your AWS WAF resources from 10033// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10034// 10035// A logical rule statement used to negate the results of another rule statement. 10036// You provide one Statement within the NotStatement. 10037type NotStatement struct { 10038 _ struct{} `type:"structure"` 10039 10040 // The statement to negate. You can use any statement that can be nested. 10041 // 10042 // Statement is a required field 10043 Statement *Statement `type:"structure" required:"true"` 10044} 10045 10046// String returns the string representation 10047func (s NotStatement) String() string { 10048 return awsutil.Prettify(s) 10049} 10050 10051// GoString returns the string representation 10052func (s NotStatement) GoString() string { 10053 return s.String() 10054} 10055 10056// Validate inspects the fields of the type to determine if they are valid. 10057func (s *NotStatement) Validate() error { 10058 invalidParams := request.ErrInvalidParams{Context: "NotStatement"} 10059 if s.Statement == nil { 10060 invalidParams.Add(request.NewErrParamRequired("Statement")) 10061 } 10062 if s.Statement != nil { 10063 if err := s.Statement.Validate(); err != nil { 10064 invalidParams.AddNested("Statement", err.(request.ErrInvalidParams)) 10065 } 10066 } 10067 10068 if invalidParams.Len() > 0 { 10069 return invalidParams 10070 } 10071 return nil 10072} 10073 10074// SetStatement sets the Statement field's value. 10075func (s *NotStatement) SetStatement(v *Statement) *NotStatement { 10076 s.Statement = v 10077 return s 10078} 10079 10080// 10081// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10082// 2019. For information, including how to migrate your AWS WAF resources from 10083// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10084// 10085// A logical rule statement used to combine other rule statements with OR logic. 10086// You provide more than one Statement within the OrStatement. 10087type OrStatement struct { 10088 _ struct{} `type:"structure"` 10089 10090 // The statements to combine with OR logic. You can use any statements that 10091 // can be nested. 10092 // 10093 // Statements is a required field 10094 Statements []*Statement `type:"list" required:"true"` 10095} 10096 10097// String returns the string representation 10098func (s OrStatement) String() string { 10099 return awsutil.Prettify(s) 10100} 10101 10102// GoString returns the string representation 10103func (s OrStatement) GoString() string { 10104 return s.String() 10105} 10106 10107// Validate inspects the fields of the type to determine if they are valid. 10108func (s *OrStatement) Validate() error { 10109 invalidParams := request.ErrInvalidParams{Context: "OrStatement"} 10110 if s.Statements == nil { 10111 invalidParams.Add(request.NewErrParamRequired("Statements")) 10112 } 10113 if s.Statements != nil { 10114 for i, v := range s.Statements { 10115 if v == nil { 10116 continue 10117 } 10118 if err := v.Validate(); err != nil { 10119 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Statements", i), err.(request.ErrInvalidParams)) 10120 } 10121 } 10122 } 10123 10124 if invalidParams.Len() > 0 { 10125 return invalidParams 10126 } 10127 return nil 10128} 10129 10130// SetStatements sets the Statements field's value. 10131func (s *OrStatement) SetStatements(v []*Statement) *OrStatement { 10132 s.Statements = v 10133 return s 10134} 10135 10136// The override action to apply to the rules in a rule group. Used only for 10137// rule statements that reference a rule group, like RuleGroupReferenceStatement 10138// and ManagedRuleGroupStatement. 10139// 10140// Set the override action to none to leave the rule actions in effect. Set 10141// it to count to only count matches, regardless of the rule action settings. 10142// 10143// In a Rule, you must specify either this OverrideAction setting or the rule 10144// Action setting, but not both: 10145// 10146// * If the rule statement references a rule group, use this override action 10147// setting and not the action setting. 10148// 10149// * If the rule statement does not reference a rule group, use the rule 10150// action setting and not this rule override action setting. 10151type OverrideAction struct { 10152 _ struct{} `type:"structure"` 10153 10154 // Override the rule action setting to count. 10155 Count *CountAction `type:"structure"` 10156 10157 // Don't override the rule action setting. 10158 None *NoneAction `type:"structure"` 10159} 10160 10161// String returns the string representation 10162func (s OverrideAction) String() string { 10163 return awsutil.Prettify(s) 10164} 10165 10166// GoString returns the string representation 10167func (s OverrideAction) GoString() string { 10168 return s.String() 10169} 10170 10171// SetCount sets the Count field's value. 10172func (s *OverrideAction) SetCount(v *CountAction) *OverrideAction { 10173 s.Count = v 10174 return s 10175} 10176 10177// SetNone sets the None field's value. 10178func (s *OverrideAction) SetNone(v *NoneAction) *OverrideAction { 10179 s.None = v 10180 return s 10181} 10182 10183type PutLoggingConfigurationInput struct { 10184 _ struct{} `type:"structure"` 10185 10186 // 10187 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10188 // 2019. For information, including how to migrate your AWS WAF resources from 10189 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10190 // 10191 // Defines an association between Amazon Kinesis Data Firehose destinations 10192 // and a web ACL resource, for logging from AWS WAF. As part of the association, 10193 // you can specify parts of the standard logging fields to keep out of the logs. 10194 // 10195 // LoggingConfiguration is a required field 10196 LoggingConfiguration *LoggingConfiguration `type:"structure" required:"true"` 10197} 10198 10199// String returns the string representation 10200func (s PutLoggingConfigurationInput) String() string { 10201 return awsutil.Prettify(s) 10202} 10203 10204// GoString returns the string representation 10205func (s PutLoggingConfigurationInput) GoString() string { 10206 return s.String() 10207} 10208 10209// Validate inspects the fields of the type to determine if they are valid. 10210func (s *PutLoggingConfigurationInput) Validate() error { 10211 invalidParams := request.ErrInvalidParams{Context: "PutLoggingConfigurationInput"} 10212 if s.LoggingConfiguration == nil { 10213 invalidParams.Add(request.NewErrParamRequired("LoggingConfiguration")) 10214 } 10215 if s.LoggingConfiguration != nil { 10216 if err := s.LoggingConfiguration.Validate(); err != nil { 10217 invalidParams.AddNested("LoggingConfiguration", err.(request.ErrInvalidParams)) 10218 } 10219 } 10220 10221 if invalidParams.Len() > 0 { 10222 return invalidParams 10223 } 10224 return nil 10225} 10226 10227// SetLoggingConfiguration sets the LoggingConfiguration field's value. 10228func (s *PutLoggingConfigurationInput) SetLoggingConfiguration(v *LoggingConfiguration) *PutLoggingConfigurationInput { 10229 s.LoggingConfiguration = v 10230 return s 10231} 10232 10233type PutLoggingConfigurationOutput struct { 10234 _ struct{} `type:"structure"` 10235 10236 // 10237 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10238 // 2019. For information, including how to migrate your AWS WAF resources from 10239 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10240 // 10241 // Defines an association between Amazon Kinesis Data Firehose destinations 10242 // and a web ACL resource, for logging from AWS WAF. As part of the association, 10243 // you can specify parts of the standard logging fields to keep out of the logs. 10244 LoggingConfiguration *LoggingConfiguration `type:"structure"` 10245} 10246 10247// String returns the string representation 10248func (s PutLoggingConfigurationOutput) String() string { 10249 return awsutil.Prettify(s) 10250} 10251 10252// GoString returns the string representation 10253func (s PutLoggingConfigurationOutput) GoString() string { 10254 return s.String() 10255} 10256 10257// SetLoggingConfiguration sets the LoggingConfiguration field's value. 10258func (s *PutLoggingConfigurationOutput) SetLoggingConfiguration(v *LoggingConfiguration) *PutLoggingConfigurationOutput { 10259 s.LoggingConfiguration = v 10260 return s 10261} 10262 10263type PutPermissionPolicyInput struct { 10264 _ struct{} `type:"structure"` 10265 10266 // The policy to attach to the specified rule group. 10267 // 10268 // The policy specifications must conform to the following: 10269 // 10270 // * The policy must be composed using IAM Policy version 2012-10-17 or version 10271 // 2015-01-01. 10272 // 10273 // * The policy must include specifications for Effect, Action, and Principal. 10274 // 10275 // * Effect must specify Allow. 10276 // 10277 // * Action must specify wafv2:CreateWebACL, wafv2:UpdateWebACL, and wafv2:PutFirewallManagerRuleGroups. 10278 // AWS WAF rejects any extra actions or wildcard actions in the policy. 10279 // 10280 // * The policy must not include a Resource parameter. 10281 // 10282 // For more information, see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html). 10283 // 10284 // Policy is a required field 10285 Policy *string `min:"1" type:"string" required:"true"` 10286 10287 // The Amazon Resource Name (ARN) of the RuleGroup to which you want to attach 10288 // the policy. 10289 // 10290 // ResourceArn is a required field 10291 ResourceArn *string `min:"20" type:"string" required:"true"` 10292} 10293 10294// String returns the string representation 10295func (s PutPermissionPolicyInput) String() string { 10296 return awsutil.Prettify(s) 10297} 10298 10299// GoString returns the string representation 10300func (s PutPermissionPolicyInput) GoString() string { 10301 return s.String() 10302} 10303 10304// Validate inspects the fields of the type to determine if they are valid. 10305func (s *PutPermissionPolicyInput) Validate() error { 10306 invalidParams := request.ErrInvalidParams{Context: "PutPermissionPolicyInput"} 10307 if s.Policy == nil { 10308 invalidParams.Add(request.NewErrParamRequired("Policy")) 10309 } 10310 if s.Policy != nil && len(*s.Policy) < 1 { 10311 invalidParams.Add(request.NewErrParamMinLen("Policy", 1)) 10312 } 10313 if s.ResourceArn == nil { 10314 invalidParams.Add(request.NewErrParamRequired("ResourceArn")) 10315 } 10316 if s.ResourceArn != nil && len(*s.ResourceArn) < 20 { 10317 invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 20)) 10318 } 10319 10320 if invalidParams.Len() > 0 { 10321 return invalidParams 10322 } 10323 return nil 10324} 10325 10326// SetPolicy sets the Policy field's value. 10327func (s *PutPermissionPolicyInput) SetPolicy(v string) *PutPermissionPolicyInput { 10328 s.Policy = &v 10329 return s 10330} 10331 10332// SetResourceArn sets the ResourceArn field's value. 10333func (s *PutPermissionPolicyInput) SetResourceArn(v string) *PutPermissionPolicyInput { 10334 s.ResourceArn = &v 10335 return s 10336} 10337 10338type PutPermissionPolicyOutput struct { 10339 _ struct{} `type:"structure"` 10340} 10341 10342// String returns the string representation 10343func (s PutPermissionPolicyOutput) String() string { 10344 return awsutil.Prettify(s) 10345} 10346 10347// GoString returns the string representation 10348func (s PutPermissionPolicyOutput) GoString() string { 10349 return s.String() 10350} 10351 10352// 10353// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10354// 2019. For information, including how to migrate your AWS WAF resources from 10355// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10356// 10357// The query string of a web request. This is the part of a URL that appears 10358// after a ? character, if any. 10359// 10360// This is used only to indicate the web request component for AWS WAF to inspect, 10361// in the FieldToMatch specification. 10362type QueryString struct { 10363 _ struct{} `type:"structure"` 10364} 10365 10366// String returns the string representation 10367func (s QueryString) String() string { 10368 return awsutil.Prettify(s) 10369} 10370 10371// GoString returns the string representation 10372func (s QueryString) GoString() string { 10373 return s.String() 10374} 10375 10376// 10377// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10378// 2019. For information, including how to migrate your AWS WAF resources from 10379// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10380// 10381// A rate-based rule tracks the rate of requests for each originating IP address, 10382// and triggers the rule action when the rate exceeds a limit that you specify 10383// on the number of requests in any 5-minute time span. You can use this to 10384// put a temporary block on requests from an IP address that is sending excessive 10385// requests. 10386// 10387// When the rule action triggers, AWS WAF blocks additional requests from the 10388// IP address until the request rate falls below the limit. 10389// 10390// You can optionally nest another statement inside the rate-based statement, 10391// to narrow the scope of the rule so that it only counts requests that match 10392// the nested statement. For example, based on recent requests that you have 10393// seen from an attacker, you might create a rate-based rule with a nested AND 10394// rule statement that contains the following nested statements: 10395// 10396// * An IP match statement with an IP set that specified the address 192.0.2.44. 10397// 10398// * A string match statement that searches in the User-Agent header for 10399// the string BadBot. 10400// 10401// In this rate-based rule, you also define a rate limit. For this example, 10402// the rate limit is 1,000. Requests that meet both of the conditions in the 10403// statements are counted. If the count exceeds 1,000 requests per five minutes, 10404// the rule action triggers. Requests that do not meet both conditions are not 10405// counted towards the rate limit and are not affected by this rule. 10406// 10407// You cannot nest a RateBasedStatement, for example for use inside a NotStatement 10408// or OrStatement. It can only be referenced as a top-level statement within 10409// a rule. 10410type RateBasedStatement struct { 10411 _ struct{} `type:"structure"` 10412 10413 // Setting that indicates how to aggregate the request counts. The options are 10414 // the following: 10415 // 10416 // * IP - Aggregate the request counts on the IP address from the web request 10417 // origin. 10418 // 10419 // * FORWARDED_IP - Aggregate the request counts on the first IP address 10420 // in an HTTP header. If you use this, configure the ForwardedIPConfig, to 10421 // specify the header to use. 10422 // 10423 // AggregateKeyType is a required field 10424 AggregateKeyType *string `type:"string" required:"true" enum:"RateBasedStatementAggregateKeyType"` 10425 10426 // The configuration for inspecting IP addresses in an HTTP header that you 10427 // specify, instead of using the IP address that's reported by the web request 10428 // origin. Commonly, this is the X-Forwarded-For (XFF) header, but you can specify 10429 // any header name. 10430 // 10431 // If the specified header isn't present in the request, AWS WAF doesn't apply 10432 // the rule to the web request at all. 10433 // 10434 // This is required if AggregateKeyType is set to FORWARDED_IP. 10435 ForwardedIPConfig *ForwardedIPConfig `type:"structure"` 10436 10437 // The limit on requests per 5-minute period for a single originating IP address. 10438 // If the statement includes a ScopeDownStatement, this limit is applied only 10439 // to the requests that match the statement. 10440 // 10441 // Limit is a required field 10442 Limit *int64 `min:"100" type:"long" required:"true"` 10443 10444 // An optional nested statement that narrows the scope of the rate-based statement 10445 // to matching web requests. This can be any nestable statement, and you can 10446 // nest statements at any level below this scope-down statement. 10447 ScopeDownStatement *Statement `type:"structure"` 10448} 10449 10450// String returns the string representation 10451func (s RateBasedStatement) String() string { 10452 return awsutil.Prettify(s) 10453} 10454 10455// GoString returns the string representation 10456func (s RateBasedStatement) GoString() string { 10457 return s.String() 10458} 10459 10460// Validate inspects the fields of the type to determine if they are valid. 10461func (s *RateBasedStatement) Validate() error { 10462 invalidParams := request.ErrInvalidParams{Context: "RateBasedStatement"} 10463 if s.AggregateKeyType == nil { 10464 invalidParams.Add(request.NewErrParamRequired("AggregateKeyType")) 10465 } 10466 if s.Limit == nil { 10467 invalidParams.Add(request.NewErrParamRequired("Limit")) 10468 } 10469 if s.Limit != nil && *s.Limit < 100 { 10470 invalidParams.Add(request.NewErrParamMinValue("Limit", 100)) 10471 } 10472 if s.ForwardedIPConfig != nil { 10473 if err := s.ForwardedIPConfig.Validate(); err != nil { 10474 invalidParams.AddNested("ForwardedIPConfig", err.(request.ErrInvalidParams)) 10475 } 10476 } 10477 if s.ScopeDownStatement != nil { 10478 if err := s.ScopeDownStatement.Validate(); err != nil { 10479 invalidParams.AddNested("ScopeDownStatement", err.(request.ErrInvalidParams)) 10480 } 10481 } 10482 10483 if invalidParams.Len() > 0 { 10484 return invalidParams 10485 } 10486 return nil 10487} 10488 10489// SetAggregateKeyType sets the AggregateKeyType field's value. 10490func (s *RateBasedStatement) SetAggregateKeyType(v string) *RateBasedStatement { 10491 s.AggregateKeyType = &v 10492 return s 10493} 10494 10495// SetForwardedIPConfig sets the ForwardedIPConfig field's value. 10496func (s *RateBasedStatement) SetForwardedIPConfig(v *ForwardedIPConfig) *RateBasedStatement { 10497 s.ForwardedIPConfig = v 10498 return s 10499} 10500 10501// SetLimit sets the Limit field's value. 10502func (s *RateBasedStatement) SetLimit(v int64) *RateBasedStatement { 10503 s.Limit = &v 10504 return s 10505} 10506 10507// SetScopeDownStatement sets the ScopeDownStatement field's value. 10508func (s *RateBasedStatement) SetScopeDownStatement(v *Statement) *RateBasedStatement { 10509 s.ScopeDownStatement = v 10510 return s 10511} 10512 10513// 10514// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10515// 2019. For information, including how to migrate your AWS WAF resources from 10516// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10517// 10518// The set of IP addresses that are currently blocked for a rate-based statement. 10519type RateBasedStatementManagedKeysIPSet struct { 10520 _ struct{} `type:"structure"` 10521 10522 // The IP addresses that are currently blocked. 10523 Addresses []*string `type:"list"` 10524 10525 IPAddressVersion *string `type:"string" enum:"IPAddressVersion"` 10526} 10527 10528// String returns the string representation 10529func (s RateBasedStatementManagedKeysIPSet) String() string { 10530 return awsutil.Prettify(s) 10531} 10532 10533// GoString returns the string representation 10534func (s RateBasedStatementManagedKeysIPSet) GoString() string { 10535 return s.String() 10536} 10537 10538// SetAddresses sets the Addresses field's value. 10539func (s *RateBasedStatementManagedKeysIPSet) SetAddresses(v []*string) *RateBasedStatementManagedKeysIPSet { 10540 s.Addresses = v 10541 return s 10542} 10543 10544// SetIPAddressVersion sets the IPAddressVersion field's value. 10545func (s *RateBasedStatementManagedKeysIPSet) SetIPAddressVersion(v string) *RateBasedStatementManagedKeysIPSet { 10546 s.IPAddressVersion = &v 10547 return s 10548} 10549 10550// 10551// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10552// 2019. For information, including how to migrate your AWS WAF resources from 10553// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10554// 10555// A single regular expression. This is used in a RegexPatternSet. 10556type Regex struct { 10557 _ struct{} `type:"structure"` 10558 10559 // The string representing the regular expression. 10560 RegexString *string `min:"1" type:"string"` 10561} 10562 10563// String returns the string representation 10564func (s Regex) String() string { 10565 return awsutil.Prettify(s) 10566} 10567 10568// GoString returns the string representation 10569func (s Regex) GoString() string { 10570 return s.String() 10571} 10572 10573// Validate inspects the fields of the type to determine if they are valid. 10574func (s *Regex) Validate() error { 10575 invalidParams := request.ErrInvalidParams{Context: "Regex"} 10576 if s.RegexString != nil && len(*s.RegexString) < 1 { 10577 invalidParams.Add(request.NewErrParamMinLen("RegexString", 1)) 10578 } 10579 10580 if invalidParams.Len() > 0 { 10581 return invalidParams 10582 } 10583 return nil 10584} 10585 10586// SetRegexString sets the RegexString field's value. 10587func (s *Regex) SetRegexString(v string) *Regex { 10588 s.RegexString = &v 10589 return s 10590} 10591 10592// 10593// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10594// 2019. For information, including how to migrate your AWS WAF resources from 10595// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10596// 10597// Contains one or more regular expressions. 10598// 10599// AWS WAF assigns an ARN to each RegexPatternSet that you create. To use a 10600// set in a rule, you provide the ARN to the Rule statement RegexPatternSetReferenceStatement. 10601type RegexPatternSet struct { 10602 _ struct{} `type:"structure"` 10603 10604 // The Amazon Resource Name (ARN) of the entity. 10605 ARN *string `min:"20" type:"string"` 10606 10607 // A description of the set that helps with identification. You cannot change 10608 // the description of a set after you create it. 10609 Description *string `min:"1" type:"string"` 10610 10611 // A unique identifier for the set. This ID is returned in the responses to 10612 // create and list commands. You provide it to operations like update and delete. 10613 Id *string `min:"1" type:"string"` 10614 10615 // The name of the set. You cannot change the name after you create the set. 10616 Name *string `min:"1" type:"string"` 10617 10618 // The regular expression patterns in the set. 10619 RegularExpressionList []*Regex `type:"list"` 10620} 10621 10622// String returns the string representation 10623func (s RegexPatternSet) String() string { 10624 return awsutil.Prettify(s) 10625} 10626 10627// GoString returns the string representation 10628func (s RegexPatternSet) GoString() string { 10629 return s.String() 10630} 10631 10632// SetARN sets the ARN field's value. 10633func (s *RegexPatternSet) SetARN(v string) *RegexPatternSet { 10634 s.ARN = &v 10635 return s 10636} 10637 10638// SetDescription sets the Description field's value. 10639func (s *RegexPatternSet) SetDescription(v string) *RegexPatternSet { 10640 s.Description = &v 10641 return s 10642} 10643 10644// SetId sets the Id field's value. 10645func (s *RegexPatternSet) SetId(v string) *RegexPatternSet { 10646 s.Id = &v 10647 return s 10648} 10649 10650// SetName sets the Name field's value. 10651func (s *RegexPatternSet) SetName(v string) *RegexPatternSet { 10652 s.Name = &v 10653 return s 10654} 10655 10656// SetRegularExpressionList sets the RegularExpressionList field's value. 10657func (s *RegexPatternSet) SetRegularExpressionList(v []*Regex) *RegexPatternSet { 10658 s.RegularExpressionList = v 10659 return s 10660} 10661 10662// 10663// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10664// 2019. For information, including how to migrate your AWS WAF resources from 10665// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10666// 10667// A rule statement used to search web request components for matches with regular 10668// expressions. To use this, create a RegexPatternSet that specifies the expressions 10669// that you want to detect, then use the ARN of that set in this statement. 10670// A web request matches the pattern set rule statement if the request component 10671// matches any of the patterns in the set. To create a regex pattern set, see 10672// CreateRegexPatternSet. 10673// 10674// Each regex pattern set rule statement references a regex pattern set. You 10675// create and maintain the set independent of your rules. This allows you to 10676// use the single set in multiple rules. When you update the referenced set, 10677// AWS WAF automatically updates all rules that reference it. 10678type RegexPatternSetReferenceStatement struct { 10679 _ struct{} `type:"structure"` 10680 10681 // The Amazon Resource Name (ARN) of the RegexPatternSet that this statement 10682 // references. 10683 // 10684 // ARN is a required field 10685 ARN *string `min:"20" type:"string" required:"true"` 10686 10687 // The part of a web request that you want AWS WAF to inspect. For more information, 10688 // see FieldToMatch. 10689 // 10690 // FieldToMatch is a required field 10691 FieldToMatch *FieldToMatch `type:"structure" required:"true"` 10692 10693 // Text transformations eliminate some of the unusual formatting that attackers 10694 // use in web requests in an effort to bypass detection. If you specify one 10695 // or more transformations in a rule statement, AWS WAF performs all transformations 10696 // on the content of the request component identified by FieldToMatch, starting 10697 // from the lowest priority setting, before inspecting the content for a match. 10698 // 10699 // TextTransformations is a required field 10700 TextTransformations []*TextTransformation `min:"1" type:"list" required:"true"` 10701} 10702 10703// String returns the string representation 10704func (s RegexPatternSetReferenceStatement) String() string { 10705 return awsutil.Prettify(s) 10706} 10707 10708// GoString returns the string representation 10709func (s RegexPatternSetReferenceStatement) GoString() string { 10710 return s.String() 10711} 10712 10713// Validate inspects the fields of the type to determine if they are valid. 10714func (s *RegexPatternSetReferenceStatement) Validate() error { 10715 invalidParams := request.ErrInvalidParams{Context: "RegexPatternSetReferenceStatement"} 10716 if s.ARN == nil { 10717 invalidParams.Add(request.NewErrParamRequired("ARN")) 10718 } 10719 if s.ARN != nil && len(*s.ARN) < 20 { 10720 invalidParams.Add(request.NewErrParamMinLen("ARN", 20)) 10721 } 10722 if s.FieldToMatch == nil { 10723 invalidParams.Add(request.NewErrParamRequired("FieldToMatch")) 10724 } 10725 if s.TextTransformations == nil { 10726 invalidParams.Add(request.NewErrParamRequired("TextTransformations")) 10727 } 10728 if s.TextTransformations != nil && len(s.TextTransformations) < 1 { 10729 invalidParams.Add(request.NewErrParamMinLen("TextTransformations", 1)) 10730 } 10731 if s.FieldToMatch != nil { 10732 if err := s.FieldToMatch.Validate(); err != nil { 10733 invalidParams.AddNested("FieldToMatch", err.(request.ErrInvalidParams)) 10734 } 10735 } 10736 if s.TextTransformations != nil { 10737 for i, v := range s.TextTransformations { 10738 if v == nil { 10739 continue 10740 } 10741 if err := v.Validate(); err != nil { 10742 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TextTransformations", i), err.(request.ErrInvalidParams)) 10743 } 10744 } 10745 } 10746 10747 if invalidParams.Len() > 0 { 10748 return invalidParams 10749 } 10750 return nil 10751} 10752 10753// SetARN sets the ARN field's value. 10754func (s *RegexPatternSetReferenceStatement) SetARN(v string) *RegexPatternSetReferenceStatement { 10755 s.ARN = &v 10756 return s 10757} 10758 10759// SetFieldToMatch sets the FieldToMatch field's value. 10760func (s *RegexPatternSetReferenceStatement) SetFieldToMatch(v *FieldToMatch) *RegexPatternSetReferenceStatement { 10761 s.FieldToMatch = v 10762 return s 10763} 10764 10765// SetTextTransformations sets the TextTransformations field's value. 10766func (s *RegexPatternSetReferenceStatement) SetTextTransformations(v []*TextTransformation) *RegexPatternSetReferenceStatement { 10767 s.TextTransformations = v 10768 return s 10769} 10770 10771// 10772// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10773// 2019. For information, including how to migrate your AWS WAF resources from 10774// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10775// 10776// High-level information about a RegexPatternSet, returned by operations like 10777// create and list. This provides information like the ID, that you can use 10778// to retrieve and manage a RegexPatternSet, and the ARN, that you provide to 10779// the RegexPatternSetReferenceStatement to use the pattern set in a Rule. 10780type RegexPatternSetSummary struct { 10781 _ struct{} `type:"structure"` 10782 10783 // The Amazon Resource Name (ARN) of the entity. 10784 ARN *string `min:"20" type:"string"` 10785 10786 // A description of the set that helps with identification. You cannot change 10787 // the description of a set after you create it. 10788 Description *string `min:"1" type:"string"` 10789 10790 // A unique identifier for the set. This ID is returned in the responses to 10791 // create and list commands. You provide it to operations like update and delete. 10792 Id *string `min:"1" type:"string"` 10793 10794 // A token used for optimistic locking. AWS WAF returns a token to your get 10795 // and list requests, to mark the state of the entity at the time of the request. 10796 // To make changes to the entity associated with the token, you provide the 10797 // token to operations like update and delete. AWS WAF uses the token to ensure 10798 // that no changes have been made to the entity since you last retrieved it. 10799 // If a change has been made, the update fails with a WAFOptimisticLockException. 10800 // If this happens, perform another get, and use the new token returned by that 10801 // operation. 10802 LockToken *string `min:"1" type:"string"` 10803 10804 // The name of the data type instance. You cannot change the name after you 10805 // create the instance. 10806 Name *string `min:"1" type:"string"` 10807} 10808 10809// String returns the string representation 10810func (s RegexPatternSetSummary) String() string { 10811 return awsutil.Prettify(s) 10812} 10813 10814// GoString returns the string representation 10815func (s RegexPatternSetSummary) GoString() string { 10816 return s.String() 10817} 10818 10819// SetARN sets the ARN field's value. 10820func (s *RegexPatternSetSummary) SetARN(v string) *RegexPatternSetSummary { 10821 s.ARN = &v 10822 return s 10823} 10824 10825// SetDescription sets the Description field's value. 10826func (s *RegexPatternSetSummary) SetDescription(v string) *RegexPatternSetSummary { 10827 s.Description = &v 10828 return s 10829} 10830 10831// SetId sets the Id field's value. 10832func (s *RegexPatternSetSummary) SetId(v string) *RegexPatternSetSummary { 10833 s.Id = &v 10834 return s 10835} 10836 10837// SetLockToken sets the LockToken field's value. 10838func (s *RegexPatternSetSummary) SetLockToken(v string) *RegexPatternSetSummary { 10839 s.LockToken = &v 10840 return s 10841} 10842 10843// SetName sets the Name field's value. 10844func (s *RegexPatternSetSummary) SetName(v string) *RegexPatternSetSummary { 10845 s.Name = &v 10846 return s 10847} 10848 10849// 10850// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 10851// 2019. For information, including how to migrate your AWS WAF resources from 10852// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 10853// 10854// A single rule, which you can use in a WebACL or RuleGroup to identify web 10855// requests that you want to allow, block, or count. Each rule includes one 10856// top-level Statement that AWS WAF uses to identify matching web requests, 10857// and parameters that govern how AWS WAF handles them. 10858type Rule struct { 10859 _ struct{} `type:"structure"` 10860 10861 // The action that AWS WAF should take on a web request when it matches the 10862 // rule statement. Settings at the web ACL level can override the rule action 10863 // setting. 10864 // 10865 // This is used only for rules whose statements do not reference a rule group. 10866 // Rule statements that reference a rule group include RuleGroupReferenceStatement 10867 // and ManagedRuleGroupStatement. 10868 // 10869 // You must specify either this Action setting or the rule OverrideAction setting, 10870 // but not both: 10871 // 10872 // * If the rule statement does not reference a rule group, use this rule 10873 // action setting and not the rule override action setting. 10874 // 10875 // * If the rule statement references a rule group, use the override action 10876 // setting and not this action setting. 10877 Action *RuleAction `type:"structure"` 10878 10879 // The name of the rule. You can't change the name of a Rule after you create 10880 // it. 10881 // 10882 // Name is a required field 10883 Name *string `min:"1" type:"string" required:"true"` 10884 10885 // The override action to apply to the rules in a rule group. Used only for 10886 // rule statements that reference a rule group, like RuleGroupReferenceStatement 10887 // and ManagedRuleGroupStatement. 10888 // 10889 // Set the override action to none to leave the rule actions in effect. Set 10890 // it to count to only count matches, regardless of the rule action settings. 10891 // 10892 // In a Rule, you must specify either this OverrideAction setting or the rule 10893 // Action setting, but not both: 10894 // 10895 // * If the rule statement references a rule group, use this override action 10896 // setting and not the action setting. 10897 // 10898 // * If the rule statement does not reference a rule group, use the rule 10899 // action setting and not this rule override action setting. 10900 OverrideAction *OverrideAction `type:"structure"` 10901 10902 // If you define more than one Rule in a WebACL, AWS WAF evaluates each request 10903 // against the Rules in order based on the value of Priority. AWS WAF processes 10904 // rules with lower priority first. The priorities don't need to be consecutive, 10905 // but they must all be different. 10906 // 10907 // Priority is a required field 10908 Priority *int64 `type:"integer" required:"true"` 10909 10910 // The AWS WAF processing statement for the rule, for example ByteMatchStatement 10911 // or SizeConstraintStatement. 10912 // 10913 // Statement is a required field 10914 Statement *Statement `type:"structure" required:"true"` 10915 10916 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 10917 // 10918 // VisibilityConfig is a required field 10919 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 10920} 10921 10922// String returns the string representation 10923func (s Rule) String() string { 10924 return awsutil.Prettify(s) 10925} 10926 10927// GoString returns the string representation 10928func (s Rule) GoString() string { 10929 return s.String() 10930} 10931 10932// Validate inspects the fields of the type to determine if they are valid. 10933func (s *Rule) Validate() error { 10934 invalidParams := request.ErrInvalidParams{Context: "Rule"} 10935 if s.Name == nil { 10936 invalidParams.Add(request.NewErrParamRequired("Name")) 10937 } 10938 if s.Name != nil && len(*s.Name) < 1 { 10939 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 10940 } 10941 if s.Priority == nil { 10942 invalidParams.Add(request.NewErrParamRequired("Priority")) 10943 } 10944 if s.Statement == nil { 10945 invalidParams.Add(request.NewErrParamRequired("Statement")) 10946 } 10947 if s.VisibilityConfig == nil { 10948 invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) 10949 } 10950 if s.Statement != nil { 10951 if err := s.Statement.Validate(); err != nil { 10952 invalidParams.AddNested("Statement", err.(request.ErrInvalidParams)) 10953 } 10954 } 10955 if s.VisibilityConfig != nil { 10956 if err := s.VisibilityConfig.Validate(); err != nil { 10957 invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) 10958 } 10959 } 10960 10961 if invalidParams.Len() > 0 { 10962 return invalidParams 10963 } 10964 return nil 10965} 10966 10967// SetAction sets the Action field's value. 10968func (s *Rule) SetAction(v *RuleAction) *Rule { 10969 s.Action = v 10970 return s 10971} 10972 10973// SetName sets the Name field's value. 10974func (s *Rule) SetName(v string) *Rule { 10975 s.Name = &v 10976 return s 10977} 10978 10979// SetOverrideAction sets the OverrideAction field's value. 10980func (s *Rule) SetOverrideAction(v *OverrideAction) *Rule { 10981 s.OverrideAction = v 10982 return s 10983} 10984 10985// SetPriority sets the Priority field's value. 10986func (s *Rule) SetPriority(v int64) *Rule { 10987 s.Priority = &v 10988 return s 10989} 10990 10991// SetStatement sets the Statement field's value. 10992func (s *Rule) SetStatement(v *Statement) *Rule { 10993 s.Statement = v 10994 return s 10995} 10996 10997// SetVisibilityConfig sets the VisibilityConfig field's value. 10998func (s *Rule) SetVisibilityConfig(v *VisibilityConfig) *Rule { 10999 s.VisibilityConfig = v 11000 return s 11001} 11002 11003// 11004// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11005// 2019. For information, including how to migrate your AWS WAF resources from 11006// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11007// 11008// The action that AWS WAF should take on a web request when it matches a rule's 11009// statement. Settings at the web ACL level can override the rule action setting. 11010type RuleAction struct { 11011 _ struct{} `type:"structure"` 11012 11013 // Instructs AWS WAF to allow the web request. 11014 Allow *AllowAction `type:"structure"` 11015 11016 // Instructs AWS WAF to block the web request. 11017 Block *BlockAction `type:"structure"` 11018 11019 // Instructs AWS WAF to count the web request and allow it. 11020 Count *CountAction `type:"structure"` 11021} 11022 11023// String returns the string representation 11024func (s RuleAction) String() string { 11025 return awsutil.Prettify(s) 11026} 11027 11028// GoString returns the string representation 11029func (s RuleAction) GoString() string { 11030 return s.String() 11031} 11032 11033// SetAllow sets the Allow field's value. 11034func (s *RuleAction) SetAllow(v *AllowAction) *RuleAction { 11035 s.Allow = v 11036 return s 11037} 11038 11039// SetBlock sets the Block field's value. 11040func (s *RuleAction) SetBlock(v *BlockAction) *RuleAction { 11041 s.Block = v 11042 return s 11043} 11044 11045// SetCount sets the Count field's value. 11046func (s *RuleAction) SetCount(v *CountAction) *RuleAction { 11047 s.Count = v 11048 return s 11049} 11050 11051// 11052// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11053// 2019. For information, including how to migrate your AWS WAF resources from 11054// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11055// 11056// A rule group defines a collection of rules to inspect and control web requests 11057// that you can use in a WebACL. When you create a rule group, you define an 11058// immutable capacity limit. If you update a rule group, you must stay within 11059// the capacity. This allows others to reuse the rule group with confidence 11060// in its capacity requirements. 11061type RuleGroup struct { 11062 _ struct{} `type:"structure"` 11063 11064 // The Amazon Resource Name (ARN) of the entity. 11065 // 11066 // ARN is a required field 11067 ARN *string `min:"20" type:"string" required:"true"` 11068 11069 // The web ACL capacity units (WCUs) required for this rule group. 11070 // 11071 // When you create your own rule group, you define this, and you cannot change 11072 // it after creation. When you add or modify the rules in a rule group, AWS 11073 // WAF enforces this limit. You can check the capacity for a set of rules using 11074 // CheckCapacity. 11075 // 11076 // AWS WAF uses WCUs to calculate and control the operating resources that are 11077 // used to run your rules, rule groups, and web ACLs. AWS WAF calculates capacity 11078 // differently for each rule type, to reflect the relative cost of each rule. 11079 // Simple rules that cost little to run use fewer WCUs than more complex rules 11080 // that use more processing power. Rule group capacity is fixed at creation, 11081 // which helps users plan their web ACL WCU usage when they use a rule group. 11082 // The WCU limit for web ACLs is 1,500. 11083 // 11084 // Capacity is a required field 11085 Capacity *int64 `min:"1" type:"long" required:"true"` 11086 11087 // A description of the rule group that helps with identification. You cannot 11088 // change the description of a rule group after you create it. 11089 Description *string `min:"1" type:"string"` 11090 11091 // A unique identifier for the rule group. This ID is returned in the responses 11092 // to create and list commands. You provide it to operations like update and 11093 // delete. 11094 // 11095 // Id is a required field 11096 Id *string `min:"1" type:"string" required:"true"` 11097 11098 // The name of the rule group. You cannot change the name of a rule group after 11099 // you create it. 11100 // 11101 // Name is a required field 11102 Name *string `min:"1" type:"string" required:"true"` 11103 11104 // The Rule statements used to identify the web requests that you want to allow, 11105 // block, or count. Each rule includes one top-level statement that AWS WAF 11106 // uses to identify matching web requests, and parameters that govern how AWS 11107 // WAF handles them. 11108 Rules []*Rule `type:"list"` 11109 11110 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 11111 // 11112 // VisibilityConfig is a required field 11113 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 11114} 11115 11116// String returns the string representation 11117func (s RuleGroup) String() string { 11118 return awsutil.Prettify(s) 11119} 11120 11121// GoString returns the string representation 11122func (s RuleGroup) GoString() string { 11123 return s.String() 11124} 11125 11126// SetARN sets the ARN field's value. 11127func (s *RuleGroup) SetARN(v string) *RuleGroup { 11128 s.ARN = &v 11129 return s 11130} 11131 11132// SetCapacity sets the Capacity field's value. 11133func (s *RuleGroup) SetCapacity(v int64) *RuleGroup { 11134 s.Capacity = &v 11135 return s 11136} 11137 11138// SetDescription sets the Description field's value. 11139func (s *RuleGroup) SetDescription(v string) *RuleGroup { 11140 s.Description = &v 11141 return s 11142} 11143 11144// SetId sets the Id field's value. 11145func (s *RuleGroup) SetId(v string) *RuleGroup { 11146 s.Id = &v 11147 return s 11148} 11149 11150// SetName sets the Name field's value. 11151func (s *RuleGroup) SetName(v string) *RuleGroup { 11152 s.Name = &v 11153 return s 11154} 11155 11156// SetRules sets the Rules field's value. 11157func (s *RuleGroup) SetRules(v []*Rule) *RuleGroup { 11158 s.Rules = v 11159 return s 11160} 11161 11162// SetVisibilityConfig sets the VisibilityConfig field's value. 11163func (s *RuleGroup) SetVisibilityConfig(v *VisibilityConfig) *RuleGroup { 11164 s.VisibilityConfig = v 11165 return s 11166} 11167 11168// 11169// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11170// 2019. For information, including how to migrate your AWS WAF resources from 11171// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11172// 11173// A rule statement used to run the rules that are defined in a RuleGroup. To 11174// use this, create a rule group with your rules, then provide the ARN of the 11175// rule group in this statement. 11176// 11177// You cannot nest a RuleGroupReferenceStatement, for example for use inside 11178// a NotStatement or OrStatement. It can only be referenced as a top-level statement 11179// within a rule. 11180type RuleGroupReferenceStatement struct { 11181 _ struct{} `type:"structure"` 11182 11183 // The Amazon Resource Name (ARN) of the entity. 11184 // 11185 // ARN is a required field 11186 ARN *string `min:"20" type:"string" required:"true"` 11187 11188 // The names of rules that are in the referenced rule group, but that you want 11189 // AWS WAF to exclude from processing for this rule statement. 11190 ExcludedRules []*ExcludedRule `type:"list"` 11191} 11192 11193// String returns the string representation 11194func (s RuleGroupReferenceStatement) String() string { 11195 return awsutil.Prettify(s) 11196} 11197 11198// GoString returns the string representation 11199func (s RuleGroupReferenceStatement) GoString() string { 11200 return s.String() 11201} 11202 11203// Validate inspects the fields of the type to determine if they are valid. 11204func (s *RuleGroupReferenceStatement) Validate() error { 11205 invalidParams := request.ErrInvalidParams{Context: "RuleGroupReferenceStatement"} 11206 if s.ARN == nil { 11207 invalidParams.Add(request.NewErrParamRequired("ARN")) 11208 } 11209 if s.ARN != nil && len(*s.ARN) < 20 { 11210 invalidParams.Add(request.NewErrParamMinLen("ARN", 20)) 11211 } 11212 if s.ExcludedRules != nil { 11213 for i, v := range s.ExcludedRules { 11214 if v == nil { 11215 continue 11216 } 11217 if err := v.Validate(); err != nil { 11218 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ExcludedRules", i), err.(request.ErrInvalidParams)) 11219 } 11220 } 11221 } 11222 11223 if invalidParams.Len() > 0 { 11224 return invalidParams 11225 } 11226 return nil 11227} 11228 11229// SetARN sets the ARN field's value. 11230func (s *RuleGroupReferenceStatement) SetARN(v string) *RuleGroupReferenceStatement { 11231 s.ARN = &v 11232 return s 11233} 11234 11235// SetExcludedRules sets the ExcludedRules field's value. 11236func (s *RuleGroupReferenceStatement) SetExcludedRules(v []*ExcludedRule) *RuleGroupReferenceStatement { 11237 s.ExcludedRules = v 11238 return s 11239} 11240 11241// 11242// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11243// 2019. For information, including how to migrate your AWS WAF resources from 11244// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11245// 11246// High-level information about a RuleGroup, returned by operations like create 11247// and list. This provides information like the ID, that you can use to retrieve 11248// and manage a RuleGroup, and the ARN, that you provide to the RuleGroupReferenceStatement 11249// to use the rule group in a Rule. 11250type RuleGroupSummary struct { 11251 _ struct{} `type:"structure"` 11252 11253 // The Amazon Resource Name (ARN) of the entity. 11254 ARN *string `min:"20" type:"string"` 11255 11256 // A description of the rule group that helps with identification. You cannot 11257 // change the description of a rule group after you create it. 11258 Description *string `min:"1" type:"string"` 11259 11260 // A unique identifier for the rule group. This ID is returned in the responses 11261 // to create and list commands. You provide it to operations like update and 11262 // delete. 11263 Id *string `min:"1" type:"string"` 11264 11265 // A token used for optimistic locking. AWS WAF returns a token to your get 11266 // and list requests, to mark the state of the entity at the time of the request. 11267 // To make changes to the entity associated with the token, you provide the 11268 // token to operations like update and delete. AWS WAF uses the token to ensure 11269 // that no changes have been made to the entity since you last retrieved it. 11270 // If a change has been made, the update fails with a WAFOptimisticLockException. 11271 // If this happens, perform another get, and use the new token returned by that 11272 // operation. 11273 LockToken *string `min:"1" type:"string"` 11274 11275 // The name of the data type instance. You cannot change the name after you 11276 // create the instance. 11277 Name *string `min:"1" type:"string"` 11278} 11279 11280// String returns the string representation 11281func (s RuleGroupSummary) String() string { 11282 return awsutil.Prettify(s) 11283} 11284 11285// GoString returns the string representation 11286func (s RuleGroupSummary) GoString() string { 11287 return s.String() 11288} 11289 11290// SetARN sets the ARN field's value. 11291func (s *RuleGroupSummary) SetARN(v string) *RuleGroupSummary { 11292 s.ARN = &v 11293 return s 11294} 11295 11296// SetDescription sets the Description field's value. 11297func (s *RuleGroupSummary) SetDescription(v string) *RuleGroupSummary { 11298 s.Description = &v 11299 return s 11300} 11301 11302// SetId sets the Id field's value. 11303func (s *RuleGroupSummary) SetId(v string) *RuleGroupSummary { 11304 s.Id = &v 11305 return s 11306} 11307 11308// SetLockToken sets the LockToken field's value. 11309func (s *RuleGroupSummary) SetLockToken(v string) *RuleGroupSummary { 11310 s.LockToken = &v 11311 return s 11312} 11313 11314// SetName sets the Name field's value. 11315func (s *RuleGroupSummary) SetName(v string) *RuleGroupSummary { 11316 s.Name = &v 11317 return s 11318} 11319 11320// 11321// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11322// 2019. For information, including how to migrate your AWS WAF resources from 11323// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11324// 11325// High-level information about a Rule, returned by operations like DescribeManagedRuleGroup. 11326// This provides information like the ID, that you can use to retrieve and manage 11327// a RuleGroup, and the ARN, that you provide to the RuleGroupReferenceStatement 11328// to use the rule group in a Rule. 11329type RuleSummary struct { 11330 _ struct{} `type:"structure"` 11331 11332 // 11333 // This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11334 // 2019. For information, including how to migrate your AWS WAF resources from 11335 // the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11336 // 11337 // The action that AWS WAF should take on a web request when it matches a rule's 11338 // statement. Settings at the web ACL level can override the rule action setting. 11339 Action *RuleAction `type:"structure"` 11340 11341 // The name of the rule. 11342 Name *string `min:"1" type:"string"` 11343} 11344 11345// String returns the string representation 11346func (s RuleSummary) String() string { 11347 return awsutil.Prettify(s) 11348} 11349 11350// GoString returns the string representation 11351func (s RuleSummary) GoString() string { 11352 return s.String() 11353} 11354 11355// SetAction sets the Action field's value. 11356func (s *RuleSummary) SetAction(v *RuleAction) *RuleSummary { 11357 s.Action = v 11358 return s 11359} 11360 11361// SetName sets the Name field's value. 11362func (s *RuleSummary) SetName(v string) *RuleSummary { 11363 s.Name = &v 11364 return s 11365} 11366 11367// 11368// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11369// 2019. For information, including how to migrate your AWS WAF resources from 11370// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11371// 11372// Represents a single sampled web request. The response from GetSampledRequests 11373// includes a SampledHTTPRequests complex type that appears as SampledRequests 11374// in the response syntax. SampledHTTPRequests contains an array of SampledHTTPRequest 11375// objects. 11376type SampledHTTPRequest struct { 11377 _ struct{} `type:"structure"` 11378 11379 // The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT. 11380 Action *string `type:"string"` 11381 11382 // A complex type that contains detailed information about the request. 11383 // 11384 // Request is a required field 11385 Request *HTTPRequest `type:"structure" required:"true"` 11386 11387 // The name of the Rule that the request matched. For managed rule groups, the 11388 // format for this name is <vendor name>#<managed rule group name>#<rule name>. 11389 // For your own rule groups, the format for this name is <rule group name>#<rule 11390 // name>. If the rule is not in a rule group, this field is absent. 11391 RuleNameWithinRuleGroup *string `min:"1" type:"string"` 11392 11393 // The time at which AWS WAF received the request from your AWS resource, in 11394 // Unix time format (in seconds). 11395 Timestamp *time.Time `type:"timestamp"` 11396 11397 // A value that indicates how one result in the response relates proportionally 11398 // to other results in the response. For example, a result that has a weight 11399 // of 2 represents roughly twice as many web requests as a result that has a 11400 // weight of 1. 11401 // 11402 // Weight is a required field 11403 Weight *int64 `type:"long" required:"true"` 11404} 11405 11406// String returns the string representation 11407func (s SampledHTTPRequest) String() string { 11408 return awsutil.Prettify(s) 11409} 11410 11411// GoString returns the string representation 11412func (s SampledHTTPRequest) GoString() string { 11413 return s.String() 11414} 11415 11416// SetAction sets the Action field's value. 11417func (s *SampledHTTPRequest) SetAction(v string) *SampledHTTPRequest { 11418 s.Action = &v 11419 return s 11420} 11421 11422// SetRequest sets the Request field's value. 11423func (s *SampledHTTPRequest) SetRequest(v *HTTPRequest) *SampledHTTPRequest { 11424 s.Request = v 11425 return s 11426} 11427 11428// SetRuleNameWithinRuleGroup sets the RuleNameWithinRuleGroup field's value. 11429func (s *SampledHTTPRequest) SetRuleNameWithinRuleGroup(v string) *SampledHTTPRequest { 11430 s.RuleNameWithinRuleGroup = &v 11431 return s 11432} 11433 11434// SetTimestamp sets the Timestamp field's value. 11435func (s *SampledHTTPRequest) SetTimestamp(v time.Time) *SampledHTTPRequest { 11436 s.Timestamp = &v 11437 return s 11438} 11439 11440// SetWeight sets the Weight field's value. 11441func (s *SampledHTTPRequest) SetWeight(v int64) *SampledHTTPRequest { 11442 s.Weight = &v 11443 return s 11444} 11445 11446// 11447// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11448// 2019. For information, including how to migrate your AWS WAF resources from 11449// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11450// 11451// One of the headers in a web request, identified by name, for example, User-Agent 11452// or Referer. This setting isn't case sensitive. 11453// 11454// This is used only to indicate the web request component for AWS WAF to inspect, 11455// in the FieldToMatch specification. 11456type SingleHeader struct { 11457 _ struct{} `type:"structure"` 11458 11459 // The name of the query header to inspect. 11460 // 11461 // Name is a required field 11462 Name *string `min:"1" type:"string" required:"true"` 11463} 11464 11465// String returns the string representation 11466func (s SingleHeader) String() string { 11467 return awsutil.Prettify(s) 11468} 11469 11470// GoString returns the string representation 11471func (s SingleHeader) GoString() string { 11472 return s.String() 11473} 11474 11475// Validate inspects the fields of the type to determine if they are valid. 11476func (s *SingleHeader) Validate() error { 11477 invalidParams := request.ErrInvalidParams{Context: "SingleHeader"} 11478 if s.Name == nil { 11479 invalidParams.Add(request.NewErrParamRequired("Name")) 11480 } 11481 if s.Name != nil && len(*s.Name) < 1 { 11482 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 11483 } 11484 11485 if invalidParams.Len() > 0 { 11486 return invalidParams 11487 } 11488 return nil 11489} 11490 11491// SetName sets the Name field's value. 11492func (s *SingleHeader) SetName(v string) *SingleHeader { 11493 s.Name = &v 11494 return s 11495} 11496 11497// 11498// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11499// 2019. For information, including how to migrate your AWS WAF resources from 11500// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11501// 11502// One query argument in a web request, identified by name, for example UserName 11503// or SalesRegion. The name can be up to 30 characters long and isn't case sensitive. 11504type SingleQueryArgument struct { 11505 _ struct{} `type:"structure"` 11506 11507 // The name of the query argument to inspect. 11508 // 11509 // Name is a required field 11510 Name *string `min:"1" type:"string" required:"true"` 11511} 11512 11513// String returns the string representation 11514func (s SingleQueryArgument) String() string { 11515 return awsutil.Prettify(s) 11516} 11517 11518// GoString returns the string representation 11519func (s SingleQueryArgument) GoString() string { 11520 return s.String() 11521} 11522 11523// Validate inspects the fields of the type to determine if they are valid. 11524func (s *SingleQueryArgument) Validate() error { 11525 invalidParams := request.ErrInvalidParams{Context: "SingleQueryArgument"} 11526 if s.Name == nil { 11527 invalidParams.Add(request.NewErrParamRequired("Name")) 11528 } 11529 if s.Name != nil && len(*s.Name) < 1 { 11530 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 11531 } 11532 11533 if invalidParams.Len() > 0 { 11534 return invalidParams 11535 } 11536 return nil 11537} 11538 11539// SetName sets the Name field's value. 11540func (s *SingleQueryArgument) SetName(v string) *SingleQueryArgument { 11541 s.Name = &v 11542 return s 11543} 11544 11545// 11546// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11547// 2019. For information, including how to migrate your AWS WAF resources from 11548// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11549// 11550// A rule statement that compares a number of bytes against the size of a request 11551// component, using a comparison operator, such as greater than (>) or less 11552// than (<). For example, you can use a size constraint statement to look for 11553// query strings that are longer than 100 bytes. 11554// 11555// If you configure AWS WAF to inspect the request body, AWS WAF inspects only 11556// the first 8192 bytes (8 KB). If the request body for your web requests never 11557// exceeds 8192 bytes, you can create a size constraint condition and block 11558// requests that have a request body greater than 8192 bytes. 11559// 11560// If you choose URI for the value of Part of the request to filter on, the 11561// slash (/) in the URI counts as one character. For example, the URI /logo.jpg 11562// is nine characters long. 11563type SizeConstraintStatement struct { 11564 _ struct{} `type:"structure"` 11565 11566 // The operator to use to compare the request part to the size setting. 11567 // 11568 // ComparisonOperator is a required field 11569 ComparisonOperator *string `type:"string" required:"true" enum:"ComparisonOperator"` 11570 11571 // The part of a web request that you want AWS WAF to inspect. For more information, 11572 // see FieldToMatch. 11573 // 11574 // FieldToMatch is a required field 11575 FieldToMatch *FieldToMatch `type:"structure" required:"true"` 11576 11577 // The size, in byte, to compare to the request part, after any transformations. 11578 // 11579 // Size is a required field 11580 Size *int64 `type:"long" required:"true"` 11581 11582 // Text transformations eliminate some of the unusual formatting that attackers 11583 // use in web requests in an effort to bypass detection. If you specify one 11584 // or more transformations in a rule statement, AWS WAF performs all transformations 11585 // on the content of the request component identified by FieldToMatch, starting 11586 // from the lowest priority setting, before inspecting the content for a match. 11587 // 11588 // TextTransformations is a required field 11589 TextTransformations []*TextTransformation `min:"1" type:"list" required:"true"` 11590} 11591 11592// String returns the string representation 11593func (s SizeConstraintStatement) String() string { 11594 return awsutil.Prettify(s) 11595} 11596 11597// GoString returns the string representation 11598func (s SizeConstraintStatement) GoString() string { 11599 return s.String() 11600} 11601 11602// Validate inspects the fields of the type to determine if they are valid. 11603func (s *SizeConstraintStatement) Validate() error { 11604 invalidParams := request.ErrInvalidParams{Context: "SizeConstraintStatement"} 11605 if s.ComparisonOperator == nil { 11606 invalidParams.Add(request.NewErrParamRequired("ComparisonOperator")) 11607 } 11608 if s.FieldToMatch == nil { 11609 invalidParams.Add(request.NewErrParamRequired("FieldToMatch")) 11610 } 11611 if s.Size == nil { 11612 invalidParams.Add(request.NewErrParamRequired("Size")) 11613 } 11614 if s.TextTransformations == nil { 11615 invalidParams.Add(request.NewErrParamRequired("TextTransformations")) 11616 } 11617 if s.TextTransformations != nil && len(s.TextTransformations) < 1 { 11618 invalidParams.Add(request.NewErrParamMinLen("TextTransformations", 1)) 11619 } 11620 if s.FieldToMatch != nil { 11621 if err := s.FieldToMatch.Validate(); err != nil { 11622 invalidParams.AddNested("FieldToMatch", err.(request.ErrInvalidParams)) 11623 } 11624 } 11625 if s.TextTransformations != nil { 11626 for i, v := range s.TextTransformations { 11627 if v == nil { 11628 continue 11629 } 11630 if err := v.Validate(); err != nil { 11631 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TextTransformations", i), err.(request.ErrInvalidParams)) 11632 } 11633 } 11634 } 11635 11636 if invalidParams.Len() > 0 { 11637 return invalidParams 11638 } 11639 return nil 11640} 11641 11642// SetComparisonOperator sets the ComparisonOperator field's value. 11643func (s *SizeConstraintStatement) SetComparisonOperator(v string) *SizeConstraintStatement { 11644 s.ComparisonOperator = &v 11645 return s 11646} 11647 11648// SetFieldToMatch sets the FieldToMatch field's value. 11649func (s *SizeConstraintStatement) SetFieldToMatch(v *FieldToMatch) *SizeConstraintStatement { 11650 s.FieldToMatch = v 11651 return s 11652} 11653 11654// SetSize sets the Size field's value. 11655func (s *SizeConstraintStatement) SetSize(v int64) *SizeConstraintStatement { 11656 s.Size = &v 11657 return s 11658} 11659 11660// SetTextTransformations sets the TextTransformations field's value. 11661func (s *SizeConstraintStatement) SetTextTransformations(v []*TextTransformation) *SizeConstraintStatement { 11662 s.TextTransformations = v 11663 return s 11664} 11665 11666// 11667// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11668// 2019. For information, including how to migrate your AWS WAF resources from 11669// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11670// 11671// Attackers sometimes insert malicious SQL code into web requests in an effort 11672// to extract data from your database. To allow or block web requests that appear 11673// to contain malicious SQL code, create one or more SQL injection match conditions. 11674// An SQL injection match condition identifies the part of web requests, such 11675// as the URI or the query string, that you want AWS WAF to inspect. Later in 11676// the process, when you create a web ACL, you specify whether to allow or block 11677// requests that appear to contain malicious SQL code. 11678type SqliMatchStatement struct { 11679 _ struct{} `type:"structure"` 11680 11681 // The part of a web request that you want AWS WAF to inspect. For more information, 11682 // see FieldToMatch. 11683 // 11684 // FieldToMatch is a required field 11685 FieldToMatch *FieldToMatch `type:"structure" required:"true"` 11686 11687 // Text transformations eliminate some of the unusual formatting that attackers 11688 // use in web requests in an effort to bypass detection. If you specify one 11689 // or more transformations in a rule statement, AWS WAF performs all transformations 11690 // on the content of the request component identified by FieldToMatch, starting 11691 // from the lowest priority setting, before inspecting the content for a match. 11692 // 11693 // TextTransformations is a required field 11694 TextTransformations []*TextTransformation `min:"1" type:"list" required:"true"` 11695} 11696 11697// String returns the string representation 11698func (s SqliMatchStatement) String() string { 11699 return awsutil.Prettify(s) 11700} 11701 11702// GoString returns the string representation 11703func (s SqliMatchStatement) GoString() string { 11704 return s.String() 11705} 11706 11707// Validate inspects the fields of the type to determine if they are valid. 11708func (s *SqliMatchStatement) Validate() error { 11709 invalidParams := request.ErrInvalidParams{Context: "SqliMatchStatement"} 11710 if s.FieldToMatch == nil { 11711 invalidParams.Add(request.NewErrParamRequired("FieldToMatch")) 11712 } 11713 if s.TextTransformations == nil { 11714 invalidParams.Add(request.NewErrParamRequired("TextTransformations")) 11715 } 11716 if s.TextTransformations != nil && len(s.TextTransformations) < 1 { 11717 invalidParams.Add(request.NewErrParamMinLen("TextTransformations", 1)) 11718 } 11719 if s.FieldToMatch != nil { 11720 if err := s.FieldToMatch.Validate(); err != nil { 11721 invalidParams.AddNested("FieldToMatch", err.(request.ErrInvalidParams)) 11722 } 11723 } 11724 if s.TextTransformations != nil { 11725 for i, v := range s.TextTransformations { 11726 if v == nil { 11727 continue 11728 } 11729 if err := v.Validate(); err != nil { 11730 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TextTransformations", i), err.(request.ErrInvalidParams)) 11731 } 11732 } 11733 } 11734 11735 if invalidParams.Len() > 0 { 11736 return invalidParams 11737 } 11738 return nil 11739} 11740 11741// SetFieldToMatch sets the FieldToMatch field's value. 11742func (s *SqliMatchStatement) SetFieldToMatch(v *FieldToMatch) *SqliMatchStatement { 11743 s.FieldToMatch = v 11744 return s 11745} 11746 11747// SetTextTransformations sets the TextTransformations field's value. 11748func (s *SqliMatchStatement) SetTextTransformations(v []*TextTransformation) *SqliMatchStatement { 11749 s.TextTransformations = v 11750 return s 11751} 11752 11753// 11754// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 11755// 2019. For information, including how to migrate your AWS WAF resources from 11756// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 11757// 11758// The processing guidance for a Rule, used by AWS WAF to determine whether 11759// a web request matches the rule. 11760type Statement struct { 11761 _ struct{} `type:"structure"` 11762 11763 // A logical rule statement used to combine other rule statements with AND logic. 11764 // You provide more than one Statement within the AndStatement. 11765 AndStatement *AndStatement `type:"structure"` 11766 11767 // A rule statement that defines a string match search for AWS WAF to apply 11768 // to web requests. The byte match statement provides the bytes to search for, 11769 // the location in requests that you want AWS WAF to search, and other settings. 11770 // The bytes to search for are typically a string that corresponds with ASCII 11771 // characters. In the AWS WAF console and the developer guide, this is refered 11772 // to as a string match statement. 11773 ByteMatchStatement *ByteMatchStatement `type:"structure"` 11774 11775 // A rule statement used to identify web requests based on country of origin. 11776 GeoMatchStatement *GeoMatchStatement `type:"structure"` 11777 11778 // A rule statement used to detect web requests coming from particular IP addresses 11779 // or address ranges. To use this, create an IPSet that specifies the addresses 11780 // you want to detect, then use the ARN of that set in this statement. To create 11781 // an IP set, see CreateIPSet. 11782 // 11783 // Each IP set rule statement references an IP set. You create and maintain 11784 // the set independent of your rules. This allows you to use the single set 11785 // in multiple rules. When you update the referenced set, AWS WAF automatically 11786 // updates all rules that reference it. 11787 IPSetReferenceStatement *IPSetReferenceStatement `type:"structure"` 11788 11789 // A rule statement used to run the rules that are defined in a managed rule 11790 // group. To use this, provide the vendor name and the name of the rule group 11791 // in this statement. You can retrieve the required names by calling ListAvailableManagedRuleGroups. 11792 // 11793 // You can't nest a ManagedRuleGroupStatement, for example for use inside a 11794 // NotStatement or OrStatement. It can only be referenced as a top-level statement 11795 // within a rule. 11796 ManagedRuleGroupStatement *ManagedRuleGroupStatement `type:"structure"` 11797 11798 // A logical rule statement used to negate the results of another rule statement. 11799 // You provide one Statement within the NotStatement. 11800 NotStatement *NotStatement `type:"structure"` 11801 11802 // A logical rule statement used to combine other rule statements with OR logic. 11803 // You provide more than one Statement within the OrStatement. 11804 OrStatement *OrStatement `type:"structure"` 11805 11806 // A rate-based rule tracks the rate of requests for each originating IP address, 11807 // and triggers the rule action when the rate exceeds a limit that you specify 11808 // on the number of requests in any 5-minute time span. You can use this to 11809 // put a temporary block on requests from an IP address that is sending excessive 11810 // requests. 11811 // 11812 // When the rule action triggers, AWS WAF blocks additional requests from the 11813 // IP address until the request rate falls below the limit. 11814 // 11815 // You can optionally nest another statement inside the rate-based statement, 11816 // to narrow the scope of the rule so that it only counts requests that match 11817 // the nested statement. For example, based on recent requests that you have 11818 // seen from an attacker, you might create a rate-based rule with a nested AND 11819 // rule statement that contains the following nested statements: 11820 // 11821 // * An IP match statement with an IP set that specified the address 192.0.2.44. 11822 // 11823 // * A string match statement that searches in the User-Agent header for 11824 // the string BadBot. 11825 // 11826 // In this rate-based rule, you also define a rate limit. For this example, 11827 // the rate limit is 1,000. Requests that meet both of the conditions in the 11828 // statements are counted. If the count exceeds 1,000 requests per five minutes, 11829 // the rule action triggers. Requests that do not meet both conditions are not 11830 // counted towards the rate limit and are not affected by this rule. 11831 // 11832 // You cannot nest a RateBasedStatement, for example for use inside a NotStatement 11833 // or OrStatement. It can only be referenced as a top-level statement within 11834 // a rule. 11835 RateBasedStatement *RateBasedStatement `type:"structure"` 11836 11837 // A rule statement used to search web request components for matches with regular 11838 // expressions. To use this, create a RegexPatternSet that specifies the expressions 11839 // that you want to detect, then use the ARN of that set in this statement. 11840 // A web request matches the pattern set rule statement if the request component 11841 // matches any of the patterns in the set. To create a regex pattern set, see 11842 // CreateRegexPatternSet. 11843 // 11844 // Each regex pattern set rule statement references a regex pattern set. You 11845 // create and maintain the set independent of your rules. This allows you to 11846 // use the single set in multiple rules. When you update the referenced set, 11847 // AWS WAF automatically updates all rules that reference it. 11848 RegexPatternSetReferenceStatement *RegexPatternSetReferenceStatement `type:"structure"` 11849 11850 // A rule statement used to run the rules that are defined in a RuleGroup. To 11851 // use this, create a rule group with your rules, then provide the ARN of the 11852 // rule group in this statement. 11853 // 11854 // You cannot nest a RuleGroupReferenceStatement, for example for use inside 11855 // a NotStatement or OrStatement. It can only be referenced as a top-level statement 11856 // within a rule. 11857 RuleGroupReferenceStatement *RuleGroupReferenceStatement `type:"structure"` 11858 11859 // A rule statement that compares a number of bytes against the size of a request 11860 // component, using a comparison operator, such as greater than (>) or less 11861 // than (<). For example, you can use a size constraint statement to look for 11862 // query strings that are longer than 100 bytes. 11863 // 11864 // If you configure AWS WAF to inspect the request body, AWS WAF inspects only 11865 // the first 8192 bytes (8 KB). If the request body for your web requests never 11866 // exceeds 8192 bytes, you can create a size constraint condition and block 11867 // requests that have a request body greater than 8192 bytes. 11868 // 11869 // If you choose URI for the value of Part of the request to filter on, the 11870 // slash (/) in the URI counts as one character. For example, the URI /logo.jpg 11871 // is nine characters long. 11872 SizeConstraintStatement *SizeConstraintStatement `type:"structure"` 11873 11874 // Attackers sometimes insert malicious SQL code into web requests in an effort 11875 // to extract data from your database. To allow or block web requests that appear 11876 // to contain malicious SQL code, create one or more SQL injection match conditions. 11877 // An SQL injection match condition identifies the part of web requests, such 11878 // as the URI or the query string, that you want AWS WAF to inspect. Later in 11879 // the process, when you create a web ACL, you specify whether to allow or block 11880 // requests that appear to contain malicious SQL code. 11881 SqliMatchStatement *SqliMatchStatement `type:"structure"` 11882 11883 // A rule statement that defines a cross-site scripting (XSS) match search for 11884 // AWS WAF to apply to web requests. XSS attacks are those where the attacker 11885 // uses vulnerabilities in a benign website as a vehicle to inject malicious 11886 // client-site scripts into other legitimate web browsers. The XSS match statement 11887 // provides the location in requests that you want AWS WAF to search and text 11888 // transformations to use on the search area before AWS WAF searches for character 11889 // sequences that are likely to be malicious strings. 11890 XssMatchStatement *XssMatchStatement `type:"structure"` 11891} 11892 11893// String returns the string representation 11894func (s Statement) String() string { 11895 return awsutil.Prettify(s) 11896} 11897 11898// GoString returns the string representation 11899func (s Statement) GoString() string { 11900 return s.String() 11901} 11902 11903// Validate inspects the fields of the type to determine if they are valid. 11904func (s *Statement) Validate() error { 11905 invalidParams := request.ErrInvalidParams{Context: "Statement"} 11906 if s.AndStatement != nil { 11907 if err := s.AndStatement.Validate(); err != nil { 11908 invalidParams.AddNested("AndStatement", err.(request.ErrInvalidParams)) 11909 } 11910 } 11911 if s.ByteMatchStatement != nil { 11912 if err := s.ByteMatchStatement.Validate(); err != nil { 11913 invalidParams.AddNested("ByteMatchStatement", err.(request.ErrInvalidParams)) 11914 } 11915 } 11916 if s.GeoMatchStatement != nil { 11917 if err := s.GeoMatchStatement.Validate(); err != nil { 11918 invalidParams.AddNested("GeoMatchStatement", err.(request.ErrInvalidParams)) 11919 } 11920 } 11921 if s.IPSetReferenceStatement != nil { 11922 if err := s.IPSetReferenceStatement.Validate(); err != nil { 11923 invalidParams.AddNested("IPSetReferenceStatement", err.(request.ErrInvalidParams)) 11924 } 11925 } 11926 if s.ManagedRuleGroupStatement != nil { 11927 if err := s.ManagedRuleGroupStatement.Validate(); err != nil { 11928 invalidParams.AddNested("ManagedRuleGroupStatement", err.(request.ErrInvalidParams)) 11929 } 11930 } 11931 if s.NotStatement != nil { 11932 if err := s.NotStatement.Validate(); err != nil { 11933 invalidParams.AddNested("NotStatement", err.(request.ErrInvalidParams)) 11934 } 11935 } 11936 if s.OrStatement != nil { 11937 if err := s.OrStatement.Validate(); err != nil { 11938 invalidParams.AddNested("OrStatement", err.(request.ErrInvalidParams)) 11939 } 11940 } 11941 if s.RateBasedStatement != nil { 11942 if err := s.RateBasedStatement.Validate(); err != nil { 11943 invalidParams.AddNested("RateBasedStatement", err.(request.ErrInvalidParams)) 11944 } 11945 } 11946 if s.RegexPatternSetReferenceStatement != nil { 11947 if err := s.RegexPatternSetReferenceStatement.Validate(); err != nil { 11948 invalidParams.AddNested("RegexPatternSetReferenceStatement", err.(request.ErrInvalidParams)) 11949 } 11950 } 11951 if s.RuleGroupReferenceStatement != nil { 11952 if err := s.RuleGroupReferenceStatement.Validate(); err != nil { 11953 invalidParams.AddNested("RuleGroupReferenceStatement", err.(request.ErrInvalidParams)) 11954 } 11955 } 11956 if s.SizeConstraintStatement != nil { 11957 if err := s.SizeConstraintStatement.Validate(); err != nil { 11958 invalidParams.AddNested("SizeConstraintStatement", err.(request.ErrInvalidParams)) 11959 } 11960 } 11961 if s.SqliMatchStatement != nil { 11962 if err := s.SqliMatchStatement.Validate(); err != nil { 11963 invalidParams.AddNested("SqliMatchStatement", err.(request.ErrInvalidParams)) 11964 } 11965 } 11966 if s.XssMatchStatement != nil { 11967 if err := s.XssMatchStatement.Validate(); err != nil { 11968 invalidParams.AddNested("XssMatchStatement", err.(request.ErrInvalidParams)) 11969 } 11970 } 11971 11972 if invalidParams.Len() > 0 { 11973 return invalidParams 11974 } 11975 return nil 11976} 11977 11978// SetAndStatement sets the AndStatement field's value. 11979func (s *Statement) SetAndStatement(v *AndStatement) *Statement { 11980 s.AndStatement = v 11981 return s 11982} 11983 11984// SetByteMatchStatement sets the ByteMatchStatement field's value. 11985func (s *Statement) SetByteMatchStatement(v *ByteMatchStatement) *Statement { 11986 s.ByteMatchStatement = v 11987 return s 11988} 11989 11990// SetGeoMatchStatement sets the GeoMatchStatement field's value. 11991func (s *Statement) SetGeoMatchStatement(v *GeoMatchStatement) *Statement { 11992 s.GeoMatchStatement = v 11993 return s 11994} 11995 11996// SetIPSetReferenceStatement sets the IPSetReferenceStatement field's value. 11997func (s *Statement) SetIPSetReferenceStatement(v *IPSetReferenceStatement) *Statement { 11998 s.IPSetReferenceStatement = v 11999 return s 12000} 12001 12002// SetManagedRuleGroupStatement sets the ManagedRuleGroupStatement field's value. 12003func (s *Statement) SetManagedRuleGroupStatement(v *ManagedRuleGroupStatement) *Statement { 12004 s.ManagedRuleGroupStatement = v 12005 return s 12006} 12007 12008// SetNotStatement sets the NotStatement field's value. 12009func (s *Statement) SetNotStatement(v *NotStatement) *Statement { 12010 s.NotStatement = v 12011 return s 12012} 12013 12014// SetOrStatement sets the OrStatement field's value. 12015func (s *Statement) SetOrStatement(v *OrStatement) *Statement { 12016 s.OrStatement = v 12017 return s 12018} 12019 12020// SetRateBasedStatement sets the RateBasedStatement field's value. 12021func (s *Statement) SetRateBasedStatement(v *RateBasedStatement) *Statement { 12022 s.RateBasedStatement = v 12023 return s 12024} 12025 12026// SetRegexPatternSetReferenceStatement sets the RegexPatternSetReferenceStatement field's value. 12027func (s *Statement) SetRegexPatternSetReferenceStatement(v *RegexPatternSetReferenceStatement) *Statement { 12028 s.RegexPatternSetReferenceStatement = v 12029 return s 12030} 12031 12032// SetRuleGroupReferenceStatement sets the RuleGroupReferenceStatement field's value. 12033func (s *Statement) SetRuleGroupReferenceStatement(v *RuleGroupReferenceStatement) *Statement { 12034 s.RuleGroupReferenceStatement = v 12035 return s 12036} 12037 12038// SetSizeConstraintStatement sets the SizeConstraintStatement field's value. 12039func (s *Statement) SetSizeConstraintStatement(v *SizeConstraintStatement) *Statement { 12040 s.SizeConstraintStatement = v 12041 return s 12042} 12043 12044// SetSqliMatchStatement sets the SqliMatchStatement field's value. 12045func (s *Statement) SetSqliMatchStatement(v *SqliMatchStatement) *Statement { 12046 s.SqliMatchStatement = v 12047 return s 12048} 12049 12050// SetXssMatchStatement sets the XssMatchStatement field's value. 12051func (s *Statement) SetXssMatchStatement(v *XssMatchStatement) *Statement { 12052 s.XssMatchStatement = v 12053 return s 12054} 12055 12056// 12057// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 12058// 2019. For information, including how to migrate your AWS WAF resources from 12059// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 12060// 12061// A tag associated with an AWS resource. Tags are key:value pairs that you 12062// can use to categorize and manage your resources, for purposes like billing 12063// or other management. Typically, the tag key represents a category, such as 12064// "environment", and the tag value represents a specific value within that 12065// category, such as "test," "development," or "production". Or you might set 12066// the tag key to "customer" and the value to the customer name or ID. You can 12067// specify one or more tags to add to each AWS resource, up to 50 tags for a 12068// resource. 12069// 12070// You can tag the AWS resources that you manage through AWS WAF: web ACLs, 12071// rule groups, IP sets, and regex pattern sets. You can't manage or view tags 12072// through the AWS WAF console. 12073type Tag struct { 12074 _ struct{} `type:"structure"` 12075 12076 // Part of the key:value pair that defines a tag. You can use a tag key to describe 12077 // a category of information, such as "customer." Tag keys are case-sensitive. 12078 // 12079 // Key is a required field 12080 Key *string `min:"1" type:"string" required:"true"` 12081 12082 // Part of the key:value pair that defines a tag. You can use a tag value to 12083 // describe a specific value within a category, such as "companyA" or "companyB." 12084 // Tag values are case-sensitive. 12085 // 12086 // Value is a required field 12087 Value *string `type:"string" required:"true"` 12088} 12089 12090// String returns the string representation 12091func (s Tag) String() string { 12092 return awsutil.Prettify(s) 12093} 12094 12095// GoString returns the string representation 12096func (s Tag) GoString() string { 12097 return s.String() 12098} 12099 12100// Validate inspects the fields of the type to determine if they are valid. 12101func (s *Tag) Validate() error { 12102 invalidParams := request.ErrInvalidParams{Context: "Tag"} 12103 if s.Key == nil { 12104 invalidParams.Add(request.NewErrParamRequired("Key")) 12105 } 12106 if s.Key != nil && len(*s.Key) < 1 { 12107 invalidParams.Add(request.NewErrParamMinLen("Key", 1)) 12108 } 12109 if s.Value == nil { 12110 invalidParams.Add(request.NewErrParamRequired("Value")) 12111 } 12112 12113 if invalidParams.Len() > 0 { 12114 return invalidParams 12115 } 12116 return nil 12117} 12118 12119// SetKey sets the Key field's value. 12120func (s *Tag) SetKey(v string) *Tag { 12121 s.Key = &v 12122 return s 12123} 12124 12125// SetValue sets the Value field's value. 12126func (s *Tag) SetValue(v string) *Tag { 12127 s.Value = &v 12128 return s 12129} 12130 12131// 12132// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 12133// 2019. For information, including how to migrate your AWS WAF resources from 12134// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 12135// 12136// The collection of tagging definitions for an AWS resource. Tags are key:value 12137// pairs that you can use to categorize and manage your resources, for purposes 12138// like billing or other management. Typically, the tag key represents a category, 12139// such as "environment", and the tag value represents a specific value within 12140// that category, such as "test," "development," or "production". Or you might 12141// set the tag key to "customer" and the value to the customer name or ID. You 12142// can specify one or more tags to add to each AWS resource, up to 50 tags for 12143// a resource. 12144// 12145// You can tag the AWS resources that you manage through AWS WAF: web ACLs, 12146// rule groups, IP sets, and regex pattern sets. You can't manage or view tags 12147// through the AWS WAF console. 12148type TagInfoForResource struct { 12149 _ struct{} `type:"structure"` 12150 12151 // The Amazon Resource Name (ARN) of the resource. 12152 ResourceARN *string `min:"20" type:"string"` 12153 12154 // The array of Tag objects defined for the resource. 12155 TagList []*Tag `min:"1" type:"list"` 12156} 12157 12158// String returns the string representation 12159func (s TagInfoForResource) String() string { 12160 return awsutil.Prettify(s) 12161} 12162 12163// GoString returns the string representation 12164func (s TagInfoForResource) GoString() string { 12165 return s.String() 12166} 12167 12168// SetResourceARN sets the ResourceARN field's value. 12169func (s *TagInfoForResource) SetResourceARN(v string) *TagInfoForResource { 12170 s.ResourceARN = &v 12171 return s 12172} 12173 12174// SetTagList sets the TagList field's value. 12175func (s *TagInfoForResource) SetTagList(v []*Tag) *TagInfoForResource { 12176 s.TagList = v 12177 return s 12178} 12179 12180type TagResourceInput struct { 12181 _ struct{} `type:"structure"` 12182 12183 // The Amazon Resource Name (ARN) of the resource. 12184 // 12185 // ResourceARN is a required field 12186 ResourceARN *string `min:"20" type:"string" required:"true"` 12187 12188 // An array of key:value pairs to associate with the resource. 12189 // 12190 // Tags is a required field 12191 Tags []*Tag `min:"1" type:"list" required:"true"` 12192} 12193 12194// String returns the string representation 12195func (s TagResourceInput) String() string { 12196 return awsutil.Prettify(s) 12197} 12198 12199// GoString returns the string representation 12200func (s TagResourceInput) GoString() string { 12201 return s.String() 12202} 12203 12204// Validate inspects the fields of the type to determine if they are valid. 12205func (s *TagResourceInput) Validate() error { 12206 invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} 12207 if s.ResourceARN == nil { 12208 invalidParams.Add(request.NewErrParamRequired("ResourceARN")) 12209 } 12210 if s.ResourceARN != nil && len(*s.ResourceARN) < 20 { 12211 invalidParams.Add(request.NewErrParamMinLen("ResourceARN", 20)) 12212 } 12213 if s.Tags == nil { 12214 invalidParams.Add(request.NewErrParamRequired("Tags")) 12215 } 12216 if s.Tags != nil && len(s.Tags) < 1 { 12217 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 12218 } 12219 if s.Tags != nil { 12220 for i, v := range s.Tags { 12221 if v == nil { 12222 continue 12223 } 12224 if err := v.Validate(); err != nil { 12225 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 12226 } 12227 } 12228 } 12229 12230 if invalidParams.Len() > 0 { 12231 return invalidParams 12232 } 12233 return nil 12234} 12235 12236// SetResourceARN sets the ResourceARN field's value. 12237func (s *TagResourceInput) SetResourceARN(v string) *TagResourceInput { 12238 s.ResourceARN = &v 12239 return s 12240} 12241 12242// SetTags sets the Tags field's value. 12243func (s *TagResourceInput) SetTags(v []*Tag) *TagResourceInput { 12244 s.Tags = v 12245 return s 12246} 12247 12248type TagResourceOutput struct { 12249 _ struct{} `type:"structure"` 12250} 12251 12252// String returns the string representation 12253func (s TagResourceOutput) String() string { 12254 return awsutil.Prettify(s) 12255} 12256 12257// GoString returns the string representation 12258func (s TagResourceOutput) GoString() string { 12259 return s.String() 12260} 12261 12262// 12263// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 12264// 2019. For information, including how to migrate your AWS WAF resources from 12265// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 12266// 12267// Text transformations eliminate some of the unusual formatting that attackers 12268// use in web requests in an effort to bypass detection. 12269type TextTransformation struct { 12270 _ struct{} `type:"structure"` 12271 12272 // Sets the relative processing order for multiple transformations that are 12273 // defined for a rule statement. AWS WAF processes all transformations, from 12274 // lowest priority to highest, before inspecting the transformed content. The 12275 // priorities don't need to be consecutive, but they must all be different. 12276 // 12277 // Priority is a required field 12278 Priority *int64 `type:"integer" required:"true"` 12279 12280 // You can specify the following transformation types: 12281 // 12282 // CMD_LINE 12283 // 12284 // When you're concerned that attackers are injecting an operating system command 12285 // line command and using unusual formatting to disguise some or all of the 12286 // command, use this option to perform the following transformations: 12287 // 12288 // * Delete the following characters: \ " ' ^ 12289 // 12290 // * Delete spaces before the following characters: / ( 12291 // 12292 // * Replace the following characters with a space: , ; 12293 // 12294 // * Replace multiple spaces with one space 12295 // 12296 // * Convert uppercase letters (A-Z) to lowercase (a-z) 12297 // 12298 // COMPRESS_WHITE_SPACE 12299 // 12300 // Use this option to replace the following characters with a space character 12301 // (decimal 32): 12302 // 12303 // * \f, formfeed, decimal 12 12304 // 12305 // * \t, tab, decimal 9 12306 // 12307 // * \n, newline, decimal 10 12308 // 12309 // * \r, carriage return, decimal 13 12310 // 12311 // * \v, vertical tab, decimal 11 12312 // 12313 // * non-breaking space, decimal 160 12314 // 12315 // COMPRESS_WHITE_SPACE also replaces multiple spaces with one space. 12316 // 12317 // HTML_ENTITY_DECODE 12318 // 12319 // Use this option to replace HTML-encoded characters with unencoded characters. 12320 // HTML_ENTITY_DECODE performs the following operations: 12321 // 12322 // * Replaces (ampersand)quot; with " 12323 // 12324 // * Replaces (ampersand)nbsp; with a non-breaking space, decimal 160 12325 // 12326 // * Replaces (ampersand)lt; with a "less than" symbol 12327 // 12328 // * Replaces (ampersand)gt; with > 12329 // 12330 // * Replaces characters that are represented in hexadecimal format, (ampersand)#xhhhh;, 12331 // with the corresponding characters 12332 // 12333 // * Replaces characters that are represented in decimal format, (ampersand)#nnnn;, 12334 // with the corresponding characters 12335 // 12336 // LOWERCASE 12337 // 12338 // Use this option to convert uppercase letters (A-Z) to lowercase (a-z). 12339 // 12340 // URL_DECODE 12341 // 12342 // Use this option to decode a URL-encoded value. 12343 // 12344 // NONE 12345 // 12346 // Specify NONE if you don't want any text transformations. 12347 // 12348 // Type is a required field 12349 Type *string `type:"string" required:"true" enum:"TextTransformationType"` 12350} 12351 12352// String returns the string representation 12353func (s TextTransformation) String() string { 12354 return awsutil.Prettify(s) 12355} 12356 12357// GoString returns the string representation 12358func (s TextTransformation) GoString() string { 12359 return s.String() 12360} 12361 12362// Validate inspects the fields of the type to determine if they are valid. 12363func (s *TextTransformation) Validate() error { 12364 invalidParams := request.ErrInvalidParams{Context: "TextTransformation"} 12365 if s.Priority == nil { 12366 invalidParams.Add(request.NewErrParamRequired("Priority")) 12367 } 12368 if s.Type == nil { 12369 invalidParams.Add(request.NewErrParamRequired("Type")) 12370 } 12371 12372 if invalidParams.Len() > 0 { 12373 return invalidParams 12374 } 12375 return nil 12376} 12377 12378// SetPriority sets the Priority field's value. 12379func (s *TextTransformation) SetPriority(v int64) *TextTransformation { 12380 s.Priority = &v 12381 return s 12382} 12383 12384// SetType sets the Type field's value. 12385func (s *TextTransformation) SetType(v string) *TextTransformation { 12386 s.Type = &v 12387 return s 12388} 12389 12390// 12391// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 12392// 2019. For information, including how to migrate your AWS WAF resources from 12393// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 12394// 12395// In a GetSampledRequests request, the StartTime and EndTime objects specify 12396// the time range for which you want AWS WAF to return a sample of web requests. 12397// 12398// You must specify the times in Coordinated Universal Time (UTC) format. UTC 12399// format includes the special designator, Z. For example, "2016-09-27T14:50Z". 12400// You can specify any time range in the previous three hours. 12401// 12402// In a GetSampledRequests response, the StartTime and EndTime objects specify 12403// the time range for which AWS WAF actually returned a sample of web requests. 12404// AWS WAF gets the specified number of requests from among the first 5,000 12405// requests that your AWS resource receives during the specified time period. 12406// If your resource receives more than 5,000 requests during that period, AWS 12407// WAF stops sampling after the 5,000th request. In that case, EndTime is the 12408// time that AWS WAF received the 5,000th request. 12409type TimeWindow struct { 12410 _ struct{} `type:"structure"` 12411 12412 // The end of the time range from which you want GetSampledRequests to return 12413 // a sample of the requests that your AWS resource received. You must specify 12414 // the times in Coordinated Universal Time (UTC) format. UTC format includes 12415 // the special designator, Z. For example, "2016-09-27T14:50Z". You can specify 12416 // any time range in the previous three hours. 12417 // 12418 // EndTime is a required field 12419 EndTime *time.Time `type:"timestamp" required:"true"` 12420 12421 // The beginning of the time range from which you want GetSampledRequests to 12422 // return a sample of the requests that your AWS resource received. You must 12423 // specify the times in Coordinated Universal Time (UTC) format. UTC format 12424 // includes the special designator, Z. For example, "2016-09-27T14:50Z". You 12425 // can specify any time range in the previous three hours. 12426 // 12427 // StartTime is a required field 12428 StartTime *time.Time `type:"timestamp" required:"true"` 12429} 12430 12431// String returns the string representation 12432func (s TimeWindow) String() string { 12433 return awsutil.Prettify(s) 12434} 12435 12436// GoString returns the string representation 12437func (s TimeWindow) GoString() string { 12438 return s.String() 12439} 12440 12441// Validate inspects the fields of the type to determine if they are valid. 12442func (s *TimeWindow) Validate() error { 12443 invalidParams := request.ErrInvalidParams{Context: "TimeWindow"} 12444 if s.EndTime == nil { 12445 invalidParams.Add(request.NewErrParamRequired("EndTime")) 12446 } 12447 if s.StartTime == nil { 12448 invalidParams.Add(request.NewErrParamRequired("StartTime")) 12449 } 12450 12451 if invalidParams.Len() > 0 { 12452 return invalidParams 12453 } 12454 return nil 12455} 12456 12457// SetEndTime sets the EndTime field's value. 12458func (s *TimeWindow) SetEndTime(v time.Time) *TimeWindow { 12459 s.EndTime = &v 12460 return s 12461} 12462 12463// SetStartTime sets the StartTime field's value. 12464func (s *TimeWindow) SetStartTime(v time.Time) *TimeWindow { 12465 s.StartTime = &v 12466 return s 12467} 12468 12469type UntagResourceInput struct { 12470 _ struct{} `type:"structure"` 12471 12472 // The Amazon Resource Name (ARN) of the resource. 12473 // 12474 // ResourceARN is a required field 12475 ResourceARN *string `min:"20" type:"string" required:"true"` 12476 12477 // An array of keys identifying the tags to disassociate from the resource. 12478 // 12479 // TagKeys is a required field 12480 TagKeys []*string `min:"1" type:"list" required:"true"` 12481} 12482 12483// String returns the string representation 12484func (s UntagResourceInput) String() string { 12485 return awsutil.Prettify(s) 12486} 12487 12488// GoString returns the string representation 12489func (s UntagResourceInput) GoString() string { 12490 return s.String() 12491} 12492 12493// Validate inspects the fields of the type to determine if they are valid. 12494func (s *UntagResourceInput) Validate() error { 12495 invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} 12496 if s.ResourceARN == nil { 12497 invalidParams.Add(request.NewErrParamRequired("ResourceARN")) 12498 } 12499 if s.ResourceARN != nil && len(*s.ResourceARN) < 20 { 12500 invalidParams.Add(request.NewErrParamMinLen("ResourceARN", 20)) 12501 } 12502 if s.TagKeys == nil { 12503 invalidParams.Add(request.NewErrParamRequired("TagKeys")) 12504 } 12505 if s.TagKeys != nil && len(s.TagKeys) < 1 { 12506 invalidParams.Add(request.NewErrParamMinLen("TagKeys", 1)) 12507 } 12508 12509 if invalidParams.Len() > 0 { 12510 return invalidParams 12511 } 12512 return nil 12513} 12514 12515// SetResourceARN sets the ResourceARN field's value. 12516func (s *UntagResourceInput) SetResourceARN(v string) *UntagResourceInput { 12517 s.ResourceARN = &v 12518 return s 12519} 12520 12521// SetTagKeys sets the TagKeys field's value. 12522func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { 12523 s.TagKeys = v 12524 return s 12525} 12526 12527type UntagResourceOutput struct { 12528 _ struct{} `type:"structure"` 12529} 12530 12531// String returns the string representation 12532func (s UntagResourceOutput) String() string { 12533 return awsutil.Prettify(s) 12534} 12535 12536// GoString returns the string representation 12537func (s UntagResourceOutput) GoString() string { 12538 return s.String() 12539} 12540 12541type UpdateIPSetInput struct { 12542 _ struct{} `type:"structure"` 12543 12544 // Contains an array of strings that specify one or more IP addresses or blocks 12545 // of IP addresses in Classless Inter-Domain Routing (CIDR) notation. AWS WAF 12546 // supports all address ranges for IP versions IPv4 and IPv6. 12547 // 12548 // Examples: 12549 // 12550 // * To configure AWS WAF to allow, block, or count requests that originated 12551 // from the IP address 192.0.2.44, specify 192.0.2.44/32. 12552 // 12553 // * To configure AWS WAF to allow, block, or count requests that originated 12554 // from IP addresses from 192.0.2.0 to 192.0.2.255, specify 192.0.2.0/24. 12555 // 12556 // * To configure AWS WAF to allow, block, or count requests that originated 12557 // from the IP address 1111:0000:0000:0000:0000:0000:0000:0111, specify 1111:0000:0000:0000:0000:0000:0000:0111/128. 12558 // 12559 // * To configure AWS WAF to allow, block, or count requests that originated 12560 // from IP addresses 1111:0000:0000:0000:0000:0000:0000:0000 to 1111:0000:0000:0000:ffff:ffff:ffff:ffff, 12561 // specify 1111:0000:0000:0000:0000:0000:0000:0000/64. 12562 // 12563 // For more information about CIDR notation, see the Wikipedia entry Classless 12564 // Inter-Domain Routing (https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing). 12565 // 12566 // Addresses is a required field 12567 Addresses []*string `type:"list" required:"true"` 12568 12569 // A description of the IP set that helps with identification. You cannot change 12570 // the description of an IP set after you create it. 12571 Description *string `min:"1" type:"string"` 12572 12573 // A unique identifier for the set. This ID is returned in the responses to 12574 // create and list commands. You provide it to operations like update and delete. 12575 // 12576 // Id is a required field 12577 Id *string `min:"1" type:"string" required:"true"` 12578 12579 // A token used for optimistic locking. AWS WAF returns a token to your get 12580 // and list requests, to mark the state of the entity at the time of the request. 12581 // To make changes to the entity associated with the token, you provide the 12582 // token to operations like update and delete. AWS WAF uses the token to ensure 12583 // that no changes have been made to the entity since you last retrieved it. 12584 // If a change has been made, the update fails with a WAFOptimisticLockException. 12585 // If this happens, perform another get, and use the new token returned by that 12586 // operation. 12587 // 12588 // LockToken is a required field 12589 LockToken *string `min:"1" type:"string" required:"true"` 12590 12591 // The name of the IP set. You cannot change the name of an IPSet after you 12592 // create it. 12593 // 12594 // Name is a required field 12595 Name *string `min:"1" type:"string" required:"true"` 12596 12597 // Specifies whether this is for an AWS CloudFront distribution or for a regional 12598 // application. A regional application can be an Application Load Balancer (ALB), 12599 // an API Gateway REST API, or an AppSync GraphQL API. 12600 // 12601 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 12602 // as follows: 12603 // 12604 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 12605 // --region=us-east-1. 12606 // 12607 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 12608 // 12609 // Scope is a required field 12610 Scope *string `type:"string" required:"true" enum:"Scope"` 12611} 12612 12613// String returns the string representation 12614func (s UpdateIPSetInput) String() string { 12615 return awsutil.Prettify(s) 12616} 12617 12618// GoString returns the string representation 12619func (s UpdateIPSetInput) GoString() string { 12620 return s.String() 12621} 12622 12623// Validate inspects the fields of the type to determine if they are valid. 12624func (s *UpdateIPSetInput) Validate() error { 12625 invalidParams := request.ErrInvalidParams{Context: "UpdateIPSetInput"} 12626 if s.Addresses == nil { 12627 invalidParams.Add(request.NewErrParamRequired("Addresses")) 12628 } 12629 if s.Description != nil && len(*s.Description) < 1 { 12630 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 12631 } 12632 if s.Id == nil { 12633 invalidParams.Add(request.NewErrParamRequired("Id")) 12634 } 12635 if s.Id != nil && len(*s.Id) < 1 { 12636 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 12637 } 12638 if s.LockToken == nil { 12639 invalidParams.Add(request.NewErrParamRequired("LockToken")) 12640 } 12641 if s.LockToken != nil && len(*s.LockToken) < 1 { 12642 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 12643 } 12644 if s.Name == nil { 12645 invalidParams.Add(request.NewErrParamRequired("Name")) 12646 } 12647 if s.Name != nil && len(*s.Name) < 1 { 12648 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 12649 } 12650 if s.Scope == nil { 12651 invalidParams.Add(request.NewErrParamRequired("Scope")) 12652 } 12653 12654 if invalidParams.Len() > 0 { 12655 return invalidParams 12656 } 12657 return nil 12658} 12659 12660// SetAddresses sets the Addresses field's value. 12661func (s *UpdateIPSetInput) SetAddresses(v []*string) *UpdateIPSetInput { 12662 s.Addresses = v 12663 return s 12664} 12665 12666// SetDescription sets the Description field's value. 12667func (s *UpdateIPSetInput) SetDescription(v string) *UpdateIPSetInput { 12668 s.Description = &v 12669 return s 12670} 12671 12672// SetId sets the Id field's value. 12673func (s *UpdateIPSetInput) SetId(v string) *UpdateIPSetInput { 12674 s.Id = &v 12675 return s 12676} 12677 12678// SetLockToken sets the LockToken field's value. 12679func (s *UpdateIPSetInput) SetLockToken(v string) *UpdateIPSetInput { 12680 s.LockToken = &v 12681 return s 12682} 12683 12684// SetName sets the Name field's value. 12685func (s *UpdateIPSetInput) SetName(v string) *UpdateIPSetInput { 12686 s.Name = &v 12687 return s 12688} 12689 12690// SetScope sets the Scope field's value. 12691func (s *UpdateIPSetInput) SetScope(v string) *UpdateIPSetInput { 12692 s.Scope = &v 12693 return s 12694} 12695 12696type UpdateIPSetOutput struct { 12697 _ struct{} `type:"structure"` 12698 12699 // A token used for optimistic locking. AWS WAF returns this token to your update 12700 // requests. You use NextLockToken in the same manner as you use LockToken. 12701 NextLockToken *string `min:"1" type:"string"` 12702} 12703 12704// String returns the string representation 12705func (s UpdateIPSetOutput) String() string { 12706 return awsutil.Prettify(s) 12707} 12708 12709// GoString returns the string representation 12710func (s UpdateIPSetOutput) GoString() string { 12711 return s.String() 12712} 12713 12714// SetNextLockToken sets the NextLockToken field's value. 12715func (s *UpdateIPSetOutput) SetNextLockToken(v string) *UpdateIPSetOutput { 12716 s.NextLockToken = &v 12717 return s 12718} 12719 12720type UpdateRegexPatternSetInput struct { 12721 _ struct{} `type:"structure"` 12722 12723 // A description of the set that helps with identification. You cannot change 12724 // the description of a set after you create it. 12725 Description *string `min:"1" type:"string"` 12726 12727 // A unique identifier for the set. This ID is returned in the responses to 12728 // create and list commands. You provide it to operations like update and delete. 12729 // 12730 // Id is a required field 12731 Id *string `min:"1" type:"string" required:"true"` 12732 12733 // A token used for optimistic locking. AWS WAF returns a token to your get 12734 // and list requests, to mark the state of the entity at the time of the request. 12735 // To make changes to the entity associated with the token, you provide the 12736 // token to operations like update and delete. AWS WAF uses the token to ensure 12737 // that no changes have been made to the entity since you last retrieved it. 12738 // If a change has been made, the update fails with a WAFOptimisticLockException. 12739 // If this happens, perform another get, and use the new token returned by that 12740 // operation. 12741 // 12742 // LockToken is a required field 12743 LockToken *string `min:"1" type:"string" required:"true"` 12744 12745 // The name of the set. You cannot change the name after you create the set. 12746 // 12747 // Name is a required field 12748 Name *string `min:"1" type:"string" required:"true"` 12749 12750 // RegularExpressionList is a required field 12751 RegularExpressionList []*Regex `type:"list" required:"true"` 12752 12753 // Specifies whether this is for an AWS CloudFront distribution or for a regional 12754 // application. A regional application can be an Application Load Balancer (ALB), 12755 // an API Gateway REST API, or an AppSync GraphQL API. 12756 // 12757 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 12758 // as follows: 12759 // 12760 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 12761 // --region=us-east-1. 12762 // 12763 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 12764 // 12765 // Scope is a required field 12766 Scope *string `type:"string" required:"true" enum:"Scope"` 12767} 12768 12769// String returns the string representation 12770func (s UpdateRegexPatternSetInput) String() string { 12771 return awsutil.Prettify(s) 12772} 12773 12774// GoString returns the string representation 12775func (s UpdateRegexPatternSetInput) GoString() string { 12776 return s.String() 12777} 12778 12779// Validate inspects the fields of the type to determine if they are valid. 12780func (s *UpdateRegexPatternSetInput) Validate() error { 12781 invalidParams := request.ErrInvalidParams{Context: "UpdateRegexPatternSetInput"} 12782 if s.Description != nil && len(*s.Description) < 1 { 12783 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 12784 } 12785 if s.Id == nil { 12786 invalidParams.Add(request.NewErrParamRequired("Id")) 12787 } 12788 if s.Id != nil && len(*s.Id) < 1 { 12789 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 12790 } 12791 if s.LockToken == nil { 12792 invalidParams.Add(request.NewErrParamRequired("LockToken")) 12793 } 12794 if s.LockToken != nil && len(*s.LockToken) < 1 { 12795 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 12796 } 12797 if s.Name == nil { 12798 invalidParams.Add(request.NewErrParamRequired("Name")) 12799 } 12800 if s.Name != nil && len(*s.Name) < 1 { 12801 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 12802 } 12803 if s.RegularExpressionList == nil { 12804 invalidParams.Add(request.NewErrParamRequired("RegularExpressionList")) 12805 } 12806 if s.Scope == nil { 12807 invalidParams.Add(request.NewErrParamRequired("Scope")) 12808 } 12809 if s.RegularExpressionList != nil { 12810 for i, v := range s.RegularExpressionList { 12811 if v == nil { 12812 continue 12813 } 12814 if err := v.Validate(); err != nil { 12815 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RegularExpressionList", i), err.(request.ErrInvalidParams)) 12816 } 12817 } 12818 } 12819 12820 if invalidParams.Len() > 0 { 12821 return invalidParams 12822 } 12823 return nil 12824} 12825 12826// SetDescription sets the Description field's value. 12827func (s *UpdateRegexPatternSetInput) SetDescription(v string) *UpdateRegexPatternSetInput { 12828 s.Description = &v 12829 return s 12830} 12831 12832// SetId sets the Id field's value. 12833func (s *UpdateRegexPatternSetInput) SetId(v string) *UpdateRegexPatternSetInput { 12834 s.Id = &v 12835 return s 12836} 12837 12838// SetLockToken sets the LockToken field's value. 12839func (s *UpdateRegexPatternSetInput) SetLockToken(v string) *UpdateRegexPatternSetInput { 12840 s.LockToken = &v 12841 return s 12842} 12843 12844// SetName sets the Name field's value. 12845func (s *UpdateRegexPatternSetInput) SetName(v string) *UpdateRegexPatternSetInput { 12846 s.Name = &v 12847 return s 12848} 12849 12850// SetRegularExpressionList sets the RegularExpressionList field's value. 12851func (s *UpdateRegexPatternSetInput) SetRegularExpressionList(v []*Regex) *UpdateRegexPatternSetInput { 12852 s.RegularExpressionList = v 12853 return s 12854} 12855 12856// SetScope sets the Scope field's value. 12857func (s *UpdateRegexPatternSetInput) SetScope(v string) *UpdateRegexPatternSetInput { 12858 s.Scope = &v 12859 return s 12860} 12861 12862type UpdateRegexPatternSetOutput struct { 12863 _ struct{} `type:"structure"` 12864 12865 // A token used for optimistic locking. AWS WAF returns this token to your update 12866 // requests. You use NextLockToken in the same manner as you use LockToken. 12867 NextLockToken *string `min:"1" type:"string"` 12868} 12869 12870// String returns the string representation 12871func (s UpdateRegexPatternSetOutput) String() string { 12872 return awsutil.Prettify(s) 12873} 12874 12875// GoString returns the string representation 12876func (s UpdateRegexPatternSetOutput) GoString() string { 12877 return s.String() 12878} 12879 12880// SetNextLockToken sets the NextLockToken field's value. 12881func (s *UpdateRegexPatternSetOutput) SetNextLockToken(v string) *UpdateRegexPatternSetOutput { 12882 s.NextLockToken = &v 12883 return s 12884} 12885 12886type UpdateRuleGroupInput struct { 12887 _ struct{} `type:"structure"` 12888 12889 // A description of the rule group that helps with identification. You cannot 12890 // change the description of a rule group after you create it. 12891 Description *string `min:"1" type:"string"` 12892 12893 // A unique identifier for the rule group. This ID is returned in the responses 12894 // to create and list commands. You provide it to operations like update and 12895 // delete. 12896 // 12897 // Id is a required field 12898 Id *string `min:"1" type:"string" required:"true"` 12899 12900 // A token used for optimistic locking. AWS WAF returns a token to your get 12901 // and list requests, to mark the state of the entity at the time of the request. 12902 // To make changes to the entity associated with the token, you provide the 12903 // token to operations like update and delete. AWS WAF uses the token to ensure 12904 // that no changes have been made to the entity since you last retrieved it. 12905 // If a change has been made, the update fails with a WAFOptimisticLockException. 12906 // If this happens, perform another get, and use the new token returned by that 12907 // operation. 12908 // 12909 // LockToken is a required field 12910 LockToken *string `min:"1" type:"string" required:"true"` 12911 12912 // The name of the rule group. You cannot change the name of a rule group after 12913 // you create it. 12914 // 12915 // Name is a required field 12916 Name *string `min:"1" type:"string" required:"true"` 12917 12918 // The Rule statements used to identify the web requests that you want to allow, 12919 // block, or count. Each rule includes one top-level statement that AWS WAF 12920 // uses to identify matching web requests, and parameters that govern how AWS 12921 // WAF handles them. 12922 Rules []*Rule `type:"list"` 12923 12924 // Specifies whether this is for an AWS CloudFront distribution or for a regional 12925 // application. A regional application can be an Application Load Balancer (ALB), 12926 // an API Gateway REST API, or an AppSync GraphQL API. 12927 // 12928 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 12929 // as follows: 12930 // 12931 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 12932 // --region=us-east-1. 12933 // 12934 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 12935 // 12936 // Scope is a required field 12937 Scope *string `type:"string" required:"true" enum:"Scope"` 12938 12939 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 12940 // 12941 // VisibilityConfig is a required field 12942 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 12943} 12944 12945// String returns the string representation 12946func (s UpdateRuleGroupInput) String() string { 12947 return awsutil.Prettify(s) 12948} 12949 12950// GoString returns the string representation 12951func (s UpdateRuleGroupInput) GoString() string { 12952 return s.String() 12953} 12954 12955// Validate inspects the fields of the type to determine if they are valid. 12956func (s *UpdateRuleGroupInput) Validate() error { 12957 invalidParams := request.ErrInvalidParams{Context: "UpdateRuleGroupInput"} 12958 if s.Description != nil && len(*s.Description) < 1 { 12959 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 12960 } 12961 if s.Id == nil { 12962 invalidParams.Add(request.NewErrParamRequired("Id")) 12963 } 12964 if s.Id != nil && len(*s.Id) < 1 { 12965 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 12966 } 12967 if s.LockToken == nil { 12968 invalidParams.Add(request.NewErrParamRequired("LockToken")) 12969 } 12970 if s.LockToken != nil && len(*s.LockToken) < 1 { 12971 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 12972 } 12973 if s.Name == nil { 12974 invalidParams.Add(request.NewErrParamRequired("Name")) 12975 } 12976 if s.Name != nil && len(*s.Name) < 1 { 12977 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 12978 } 12979 if s.Scope == nil { 12980 invalidParams.Add(request.NewErrParamRequired("Scope")) 12981 } 12982 if s.VisibilityConfig == nil { 12983 invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) 12984 } 12985 if s.Rules != nil { 12986 for i, v := range s.Rules { 12987 if v == nil { 12988 continue 12989 } 12990 if err := v.Validate(); err != nil { 12991 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 12992 } 12993 } 12994 } 12995 if s.VisibilityConfig != nil { 12996 if err := s.VisibilityConfig.Validate(); err != nil { 12997 invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) 12998 } 12999 } 13000 13001 if invalidParams.Len() > 0 { 13002 return invalidParams 13003 } 13004 return nil 13005} 13006 13007// SetDescription sets the Description field's value. 13008func (s *UpdateRuleGroupInput) SetDescription(v string) *UpdateRuleGroupInput { 13009 s.Description = &v 13010 return s 13011} 13012 13013// SetId sets the Id field's value. 13014func (s *UpdateRuleGroupInput) SetId(v string) *UpdateRuleGroupInput { 13015 s.Id = &v 13016 return s 13017} 13018 13019// SetLockToken sets the LockToken field's value. 13020func (s *UpdateRuleGroupInput) SetLockToken(v string) *UpdateRuleGroupInput { 13021 s.LockToken = &v 13022 return s 13023} 13024 13025// SetName sets the Name field's value. 13026func (s *UpdateRuleGroupInput) SetName(v string) *UpdateRuleGroupInput { 13027 s.Name = &v 13028 return s 13029} 13030 13031// SetRules sets the Rules field's value. 13032func (s *UpdateRuleGroupInput) SetRules(v []*Rule) *UpdateRuleGroupInput { 13033 s.Rules = v 13034 return s 13035} 13036 13037// SetScope sets the Scope field's value. 13038func (s *UpdateRuleGroupInput) SetScope(v string) *UpdateRuleGroupInput { 13039 s.Scope = &v 13040 return s 13041} 13042 13043// SetVisibilityConfig sets the VisibilityConfig field's value. 13044func (s *UpdateRuleGroupInput) SetVisibilityConfig(v *VisibilityConfig) *UpdateRuleGroupInput { 13045 s.VisibilityConfig = v 13046 return s 13047} 13048 13049type UpdateRuleGroupOutput struct { 13050 _ struct{} `type:"structure"` 13051 13052 // A token used for optimistic locking. AWS WAF returns this token to your update 13053 // requests. You use NextLockToken in the same manner as you use LockToken. 13054 NextLockToken *string `min:"1" type:"string"` 13055} 13056 13057// String returns the string representation 13058func (s UpdateRuleGroupOutput) String() string { 13059 return awsutil.Prettify(s) 13060} 13061 13062// GoString returns the string representation 13063func (s UpdateRuleGroupOutput) GoString() string { 13064 return s.String() 13065} 13066 13067// SetNextLockToken sets the NextLockToken field's value. 13068func (s *UpdateRuleGroupOutput) SetNextLockToken(v string) *UpdateRuleGroupOutput { 13069 s.NextLockToken = &v 13070 return s 13071} 13072 13073type UpdateWebACLInput struct { 13074 _ struct{} `type:"structure"` 13075 13076 // The action to perform if none of the Rules contained in the WebACL match. 13077 // 13078 // DefaultAction is a required field 13079 DefaultAction *DefaultAction `type:"structure" required:"true"` 13080 13081 // A description of the Web ACL that helps with identification. You cannot change 13082 // the description of a Web ACL after you create it. 13083 Description *string `min:"1" type:"string"` 13084 13085 // The unique identifier for the Web ACL. This ID is returned in the responses 13086 // to create and list commands. You provide it to operations like update and 13087 // delete. 13088 // 13089 // Id is a required field 13090 Id *string `min:"1" type:"string" required:"true"` 13091 13092 // A token used for optimistic locking. AWS WAF returns a token to your get 13093 // and list requests, to mark the state of the entity at the time of the request. 13094 // To make changes to the entity associated with the token, you provide the 13095 // token to operations like update and delete. AWS WAF uses the token to ensure 13096 // that no changes have been made to the entity since you last retrieved it. 13097 // If a change has been made, the update fails with a WAFOptimisticLockException. 13098 // If this happens, perform another get, and use the new token returned by that 13099 // operation. 13100 // 13101 // LockToken is a required field 13102 LockToken *string `min:"1" type:"string" required:"true"` 13103 13104 // The name of the Web ACL. You cannot change the name of a Web ACL after you 13105 // create it. 13106 // 13107 // Name is a required field 13108 Name *string `min:"1" type:"string" required:"true"` 13109 13110 // The Rule statements used to identify the web requests that you want to allow, 13111 // block, or count. Each rule includes one top-level statement that AWS WAF 13112 // uses to identify matching web requests, and parameters that govern how AWS 13113 // WAF handles them. 13114 Rules []*Rule `type:"list"` 13115 13116 // Specifies whether this is for an AWS CloudFront distribution or for a regional 13117 // application. A regional application can be an Application Load Balancer (ALB), 13118 // an API Gateway REST API, or an AppSync GraphQL API. 13119 // 13120 // To work with CloudFront, you must also specify the Region US East (N. Virginia) 13121 // as follows: 13122 // 13123 // * CLI - Specify the Region when you use the CloudFront scope: --scope=CLOUDFRONT 13124 // --region=us-east-1. 13125 // 13126 // * API and SDKs - For all calls, use the Region endpoint us-east-1. 13127 // 13128 // Scope is a required field 13129 Scope *string `type:"string" required:"true" enum:"Scope"` 13130 13131 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 13132 // 13133 // VisibilityConfig is a required field 13134 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 13135} 13136 13137// String returns the string representation 13138func (s UpdateWebACLInput) String() string { 13139 return awsutil.Prettify(s) 13140} 13141 13142// GoString returns the string representation 13143func (s UpdateWebACLInput) GoString() string { 13144 return s.String() 13145} 13146 13147// Validate inspects the fields of the type to determine if they are valid. 13148func (s *UpdateWebACLInput) Validate() error { 13149 invalidParams := request.ErrInvalidParams{Context: "UpdateWebACLInput"} 13150 if s.DefaultAction == nil { 13151 invalidParams.Add(request.NewErrParamRequired("DefaultAction")) 13152 } 13153 if s.Description != nil && len(*s.Description) < 1 { 13154 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 13155 } 13156 if s.Id == nil { 13157 invalidParams.Add(request.NewErrParamRequired("Id")) 13158 } 13159 if s.Id != nil && len(*s.Id) < 1 { 13160 invalidParams.Add(request.NewErrParamMinLen("Id", 1)) 13161 } 13162 if s.LockToken == nil { 13163 invalidParams.Add(request.NewErrParamRequired("LockToken")) 13164 } 13165 if s.LockToken != nil && len(*s.LockToken) < 1 { 13166 invalidParams.Add(request.NewErrParamMinLen("LockToken", 1)) 13167 } 13168 if s.Name == nil { 13169 invalidParams.Add(request.NewErrParamRequired("Name")) 13170 } 13171 if s.Name != nil && len(*s.Name) < 1 { 13172 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 13173 } 13174 if s.Scope == nil { 13175 invalidParams.Add(request.NewErrParamRequired("Scope")) 13176 } 13177 if s.VisibilityConfig == nil { 13178 invalidParams.Add(request.NewErrParamRequired("VisibilityConfig")) 13179 } 13180 if s.Rules != nil { 13181 for i, v := range s.Rules { 13182 if v == nil { 13183 continue 13184 } 13185 if err := v.Validate(); err != nil { 13186 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 13187 } 13188 } 13189 } 13190 if s.VisibilityConfig != nil { 13191 if err := s.VisibilityConfig.Validate(); err != nil { 13192 invalidParams.AddNested("VisibilityConfig", err.(request.ErrInvalidParams)) 13193 } 13194 } 13195 13196 if invalidParams.Len() > 0 { 13197 return invalidParams 13198 } 13199 return nil 13200} 13201 13202// SetDefaultAction sets the DefaultAction field's value. 13203func (s *UpdateWebACLInput) SetDefaultAction(v *DefaultAction) *UpdateWebACLInput { 13204 s.DefaultAction = v 13205 return s 13206} 13207 13208// SetDescription sets the Description field's value. 13209func (s *UpdateWebACLInput) SetDescription(v string) *UpdateWebACLInput { 13210 s.Description = &v 13211 return s 13212} 13213 13214// SetId sets the Id field's value. 13215func (s *UpdateWebACLInput) SetId(v string) *UpdateWebACLInput { 13216 s.Id = &v 13217 return s 13218} 13219 13220// SetLockToken sets the LockToken field's value. 13221func (s *UpdateWebACLInput) SetLockToken(v string) *UpdateWebACLInput { 13222 s.LockToken = &v 13223 return s 13224} 13225 13226// SetName sets the Name field's value. 13227func (s *UpdateWebACLInput) SetName(v string) *UpdateWebACLInput { 13228 s.Name = &v 13229 return s 13230} 13231 13232// SetRules sets the Rules field's value. 13233func (s *UpdateWebACLInput) SetRules(v []*Rule) *UpdateWebACLInput { 13234 s.Rules = v 13235 return s 13236} 13237 13238// SetScope sets the Scope field's value. 13239func (s *UpdateWebACLInput) SetScope(v string) *UpdateWebACLInput { 13240 s.Scope = &v 13241 return s 13242} 13243 13244// SetVisibilityConfig sets the VisibilityConfig field's value. 13245func (s *UpdateWebACLInput) SetVisibilityConfig(v *VisibilityConfig) *UpdateWebACLInput { 13246 s.VisibilityConfig = v 13247 return s 13248} 13249 13250type UpdateWebACLOutput struct { 13251 _ struct{} `type:"structure"` 13252 13253 // A token used for optimistic locking. AWS WAF returns this token to your update 13254 // requests. You use NextLockToken in the same manner as you use LockToken. 13255 NextLockToken *string `min:"1" type:"string"` 13256} 13257 13258// String returns the string representation 13259func (s UpdateWebACLOutput) String() string { 13260 return awsutil.Prettify(s) 13261} 13262 13263// GoString returns the string representation 13264func (s UpdateWebACLOutput) GoString() string { 13265 return s.String() 13266} 13267 13268// SetNextLockToken sets the NextLockToken field's value. 13269func (s *UpdateWebACLOutput) SetNextLockToken(v string) *UpdateWebACLOutput { 13270 s.NextLockToken = &v 13271 return s 13272} 13273 13274// 13275// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 13276// 2019. For information, including how to migrate your AWS WAF resources from 13277// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 13278// 13279// The path component of the URI of a web request. This is the part of a web 13280// request that identifies a resource, for example, /images/daily-ad.jpg. 13281// 13282// This is used only to indicate the web request component for AWS WAF to inspect, 13283// in the FieldToMatch specification. 13284type UriPath struct { 13285 _ struct{} `type:"structure"` 13286} 13287 13288// String returns the string representation 13289func (s UriPath) String() string { 13290 return awsutil.Prettify(s) 13291} 13292 13293// GoString returns the string representation 13294func (s UriPath) GoString() string { 13295 return s.String() 13296} 13297 13298// 13299// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 13300// 2019. For information, including how to migrate your AWS WAF resources from 13301// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 13302// 13303// Defines and enables Amazon CloudWatch metrics and web request sample collection. 13304type VisibilityConfig struct { 13305 _ struct{} `type:"structure"` 13306 13307 // A boolean indicating whether the associated resource sends metrics to CloudWatch. 13308 // For the list of available metrics, see AWS WAF Metrics (https://docs.aws.amazon.com/waf/latest/developerguide/monitoring-cloudwatch.html#waf-metrics). 13309 // 13310 // CloudWatchMetricsEnabled is a required field 13311 CloudWatchMetricsEnabled *bool `type:"boolean" required:"true"` 13312 13313 // A name of the CloudWatch metric. The name can contain only the characters: 13314 // A-Z, a-z, 0-9, - (hyphen), and _ (underscore). The name can be from one to 13315 // 128 characters long. It can't contain whitespace or metric names reserved 13316 // for AWS WAF, for example "All" and "Default_Action." 13317 // 13318 // MetricName is a required field 13319 MetricName *string `min:"1" type:"string" required:"true"` 13320 13321 // A boolean indicating whether AWS WAF should store a sampling of the web requests 13322 // that match the rules. You can view the sampled requests through the AWS WAF 13323 // console. 13324 // 13325 // SampledRequestsEnabled is a required field 13326 SampledRequestsEnabled *bool `type:"boolean" required:"true"` 13327} 13328 13329// String returns the string representation 13330func (s VisibilityConfig) String() string { 13331 return awsutil.Prettify(s) 13332} 13333 13334// GoString returns the string representation 13335func (s VisibilityConfig) GoString() string { 13336 return s.String() 13337} 13338 13339// Validate inspects the fields of the type to determine if they are valid. 13340func (s *VisibilityConfig) Validate() error { 13341 invalidParams := request.ErrInvalidParams{Context: "VisibilityConfig"} 13342 if s.CloudWatchMetricsEnabled == nil { 13343 invalidParams.Add(request.NewErrParamRequired("CloudWatchMetricsEnabled")) 13344 } 13345 if s.MetricName == nil { 13346 invalidParams.Add(request.NewErrParamRequired("MetricName")) 13347 } 13348 if s.MetricName != nil && len(*s.MetricName) < 1 { 13349 invalidParams.Add(request.NewErrParamMinLen("MetricName", 1)) 13350 } 13351 if s.SampledRequestsEnabled == nil { 13352 invalidParams.Add(request.NewErrParamRequired("SampledRequestsEnabled")) 13353 } 13354 13355 if invalidParams.Len() > 0 { 13356 return invalidParams 13357 } 13358 return nil 13359} 13360 13361// SetCloudWatchMetricsEnabled sets the CloudWatchMetricsEnabled field's value. 13362func (s *VisibilityConfig) SetCloudWatchMetricsEnabled(v bool) *VisibilityConfig { 13363 s.CloudWatchMetricsEnabled = &v 13364 return s 13365} 13366 13367// SetMetricName sets the MetricName field's value. 13368func (s *VisibilityConfig) SetMetricName(v string) *VisibilityConfig { 13369 s.MetricName = &v 13370 return s 13371} 13372 13373// SetSampledRequestsEnabled sets the SampledRequestsEnabled field's value. 13374func (s *VisibilityConfig) SetSampledRequestsEnabled(v bool) *VisibilityConfig { 13375 s.SampledRequestsEnabled = &v 13376 return s 13377} 13378 13379// AWS WAF couldn’t perform the operation because your resource is being used 13380// by another resource or it’s associated with another resource. 13381type WAFAssociatedItemException struct { 13382 _ struct{} `type:"structure"` 13383 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13384 13385 Message_ *string `locationName:"Message" type:"string"` 13386} 13387 13388// String returns the string representation 13389func (s WAFAssociatedItemException) String() string { 13390 return awsutil.Prettify(s) 13391} 13392 13393// GoString returns the string representation 13394func (s WAFAssociatedItemException) GoString() string { 13395 return s.String() 13396} 13397 13398func newErrorWAFAssociatedItemException(v protocol.ResponseMetadata) error { 13399 return &WAFAssociatedItemException{ 13400 RespMetadata: v, 13401 } 13402} 13403 13404// Code returns the exception type name. 13405func (s *WAFAssociatedItemException) Code() string { 13406 return "WAFAssociatedItemException" 13407} 13408 13409// Message returns the exception's message. 13410func (s *WAFAssociatedItemException) Message() string { 13411 if s.Message_ != nil { 13412 return *s.Message_ 13413 } 13414 return "" 13415} 13416 13417// OrigErr always returns nil, satisfies awserr.Error interface. 13418func (s *WAFAssociatedItemException) OrigErr() error { 13419 return nil 13420} 13421 13422func (s *WAFAssociatedItemException) Error() string { 13423 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13424} 13425 13426// Status code returns the HTTP status code for the request's response error. 13427func (s *WAFAssociatedItemException) StatusCode() int { 13428 return s.RespMetadata.StatusCode 13429} 13430 13431// RequestID returns the service's response RequestID for request. 13432func (s *WAFAssociatedItemException) RequestID() string { 13433 return s.RespMetadata.RequestID 13434} 13435 13436// AWS WAF couldn’t perform the operation because the resource that you tried 13437// to save is a duplicate of an existing one. 13438type WAFDuplicateItemException struct { 13439 _ struct{} `type:"structure"` 13440 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13441 13442 Message_ *string `locationName:"Message" type:"string"` 13443} 13444 13445// String returns the string representation 13446func (s WAFDuplicateItemException) String() string { 13447 return awsutil.Prettify(s) 13448} 13449 13450// GoString returns the string representation 13451func (s WAFDuplicateItemException) GoString() string { 13452 return s.String() 13453} 13454 13455func newErrorWAFDuplicateItemException(v protocol.ResponseMetadata) error { 13456 return &WAFDuplicateItemException{ 13457 RespMetadata: v, 13458 } 13459} 13460 13461// Code returns the exception type name. 13462func (s *WAFDuplicateItemException) Code() string { 13463 return "WAFDuplicateItemException" 13464} 13465 13466// Message returns the exception's message. 13467func (s *WAFDuplicateItemException) Message() string { 13468 if s.Message_ != nil { 13469 return *s.Message_ 13470 } 13471 return "" 13472} 13473 13474// OrigErr always returns nil, satisfies awserr.Error interface. 13475func (s *WAFDuplicateItemException) OrigErr() error { 13476 return nil 13477} 13478 13479func (s *WAFDuplicateItemException) Error() string { 13480 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13481} 13482 13483// Status code returns the HTTP status code for the request's response error. 13484func (s *WAFDuplicateItemException) StatusCode() int { 13485 return s.RespMetadata.StatusCode 13486} 13487 13488// RequestID returns the service's response RequestID for request. 13489func (s *WAFDuplicateItemException) RequestID() string { 13490 return s.RespMetadata.RequestID 13491} 13492 13493// Your request is valid, but AWS WAF couldn’t perform the operation because 13494// of a system problem. Retry your request. 13495type WAFInternalErrorException struct { 13496 _ struct{} `type:"structure"` 13497 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13498 13499 Message_ *string `locationName:"Message" type:"string"` 13500} 13501 13502// String returns the string representation 13503func (s WAFInternalErrorException) String() string { 13504 return awsutil.Prettify(s) 13505} 13506 13507// GoString returns the string representation 13508func (s WAFInternalErrorException) GoString() string { 13509 return s.String() 13510} 13511 13512func newErrorWAFInternalErrorException(v protocol.ResponseMetadata) error { 13513 return &WAFInternalErrorException{ 13514 RespMetadata: v, 13515 } 13516} 13517 13518// Code returns the exception type name. 13519func (s *WAFInternalErrorException) Code() string { 13520 return "WAFInternalErrorException" 13521} 13522 13523// Message returns the exception's message. 13524func (s *WAFInternalErrorException) Message() string { 13525 if s.Message_ != nil { 13526 return *s.Message_ 13527 } 13528 return "" 13529} 13530 13531// OrigErr always returns nil, satisfies awserr.Error interface. 13532func (s *WAFInternalErrorException) OrigErr() error { 13533 return nil 13534} 13535 13536func (s *WAFInternalErrorException) Error() string { 13537 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13538} 13539 13540// Status code returns the HTTP status code for the request's response error. 13541func (s *WAFInternalErrorException) StatusCode() int { 13542 return s.RespMetadata.StatusCode 13543} 13544 13545// RequestID returns the service's response RequestID for request. 13546func (s *WAFInternalErrorException) RequestID() string { 13547 return s.RespMetadata.RequestID 13548} 13549 13550// The operation isn't valid. 13551type WAFInvalidOperationException struct { 13552 _ struct{} `type:"structure"` 13553 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13554 13555 Message_ *string `locationName:"Message" type:"string"` 13556} 13557 13558// String returns the string representation 13559func (s WAFInvalidOperationException) String() string { 13560 return awsutil.Prettify(s) 13561} 13562 13563// GoString returns the string representation 13564func (s WAFInvalidOperationException) GoString() string { 13565 return s.String() 13566} 13567 13568func newErrorWAFInvalidOperationException(v protocol.ResponseMetadata) error { 13569 return &WAFInvalidOperationException{ 13570 RespMetadata: v, 13571 } 13572} 13573 13574// Code returns the exception type name. 13575func (s *WAFInvalidOperationException) Code() string { 13576 return "WAFInvalidOperationException" 13577} 13578 13579// Message returns the exception's message. 13580func (s *WAFInvalidOperationException) Message() string { 13581 if s.Message_ != nil { 13582 return *s.Message_ 13583 } 13584 return "" 13585} 13586 13587// OrigErr always returns nil, satisfies awserr.Error interface. 13588func (s *WAFInvalidOperationException) OrigErr() error { 13589 return nil 13590} 13591 13592func (s *WAFInvalidOperationException) Error() string { 13593 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13594} 13595 13596// Status code returns the HTTP status code for the request's response error. 13597func (s *WAFInvalidOperationException) StatusCode() int { 13598 return s.RespMetadata.StatusCode 13599} 13600 13601// RequestID returns the service's response RequestID for request. 13602func (s *WAFInvalidOperationException) RequestID() string { 13603 return s.RespMetadata.RequestID 13604} 13605 13606// The operation failed because AWS WAF didn't recognize a parameter in the 13607// request. For example: 13608// 13609// * You specified an invalid parameter name or value. 13610// 13611// * Your nested statement isn't valid. You might have tried to nest a statement 13612// that can’t be nested. 13613// 13614// * You tried to update a WebACL with a DefaultAction that isn't among the 13615// types available at DefaultAction. 13616// 13617// * Your request references an ARN that is malformed, or corresponds to 13618// a resource with which a Web ACL cannot be associated. 13619type WAFInvalidParameterException struct { 13620 _ struct{} `type:"structure"` 13621 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13622 13623 Field *string `type:"string" enum:"ParameterExceptionField"` 13624 13625 Message_ *string `locationName:"message" type:"string"` 13626 13627 Parameter *string `min:"1" type:"string"` 13628 13629 Reason *string `type:"string"` 13630} 13631 13632// String returns the string representation 13633func (s WAFInvalidParameterException) String() string { 13634 return awsutil.Prettify(s) 13635} 13636 13637// GoString returns the string representation 13638func (s WAFInvalidParameterException) GoString() string { 13639 return s.String() 13640} 13641 13642func newErrorWAFInvalidParameterException(v protocol.ResponseMetadata) error { 13643 return &WAFInvalidParameterException{ 13644 RespMetadata: v, 13645 } 13646} 13647 13648// Code returns the exception type name. 13649func (s *WAFInvalidParameterException) Code() string { 13650 return "WAFInvalidParameterException" 13651} 13652 13653// Message returns the exception's message. 13654func (s *WAFInvalidParameterException) Message() string { 13655 if s.Message_ != nil { 13656 return *s.Message_ 13657 } 13658 return "" 13659} 13660 13661// OrigErr always returns nil, satisfies awserr.Error interface. 13662func (s *WAFInvalidParameterException) OrigErr() error { 13663 return nil 13664} 13665 13666func (s *WAFInvalidParameterException) Error() string { 13667 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 13668} 13669 13670// Status code returns the HTTP status code for the request's response error. 13671func (s *WAFInvalidParameterException) StatusCode() int { 13672 return s.RespMetadata.StatusCode 13673} 13674 13675// RequestID returns the service's response RequestID for request. 13676func (s *WAFInvalidParameterException) RequestID() string { 13677 return s.RespMetadata.RequestID 13678} 13679 13680// The operation failed because the specified policy isn't in the proper format. 13681// 13682// The policy specifications must conform to the following: 13683// 13684// * The policy must be composed using IAM Policy version 2012-10-17 or version 13685// 2015-01-01. 13686// 13687// * The policy must include specifications for Effect, Action, and Principal. 13688// 13689// * Effect must specify Allow. 13690// 13691// * Action must specify wafv2:CreateWebACL, wafv2:UpdateWebACL, and wafv2:PutFirewallManagerRuleGroups. 13692// AWS WAF rejects any extra actions or wildcard actions in the policy. 13693// 13694// * The policy must not include a Resource parameter. 13695// 13696// For more information, see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html). 13697type WAFInvalidPermissionPolicyException struct { 13698 _ struct{} `type:"structure"` 13699 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13700 13701 Message_ *string `locationName:"Message" type:"string"` 13702} 13703 13704// String returns the string representation 13705func (s WAFInvalidPermissionPolicyException) String() string { 13706 return awsutil.Prettify(s) 13707} 13708 13709// GoString returns the string representation 13710func (s WAFInvalidPermissionPolicyException) GoString() string { 13711 return s.String() 13712} 13713 13714func newErrorWAFInvalidPermissionPolicyException(v protocol.ResponseMetadata) error { 13715 return &WAFInvalidPermissionPolicyException{ 13716 RespMetadata: v, 13717 } 13718} 13719 13720// Code returns the exception type name. 13721func (s *WAFInvalidPermissionPolicyException) Code() string { 13722 return "WAFInvalidPermissionPolicyException" 13723} 13724 13725// Message returns the exception's message. 13726func (s *WAFInvalidPermissionPolicyException) Message() string { 13727 if s.Message_ != nil { 13728 return *s.Message_ 13729 } 13730 return "" 13731} 13732 13733// OrigErr always returns nil, satisfies awserr.Error interface. 13734func (s *WAFInvalidPermissionPolicyException) OrigErr() error { 13735 return nil 13736} 13737 13738func (s *WAFInvalidPermissionPolicyException) Error() string { 13739 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13740} 13741 13742// Status code returns the HTTP status code for the request's response error. 13743func (s *WAFInvalidPermissionPolicyException) StatusCode() int { 13744 return s.RespMetadata.StatusCode 13745} 13746 13747// RequestID returns the service's response RequestID for request. 13748func (s *WAFInvalidPermissionPolicyException) RequestID() string { 13749 return s.RespMetadata.RequestID 13750} 13751 13752// AWS WAF couldn’t perform the operation because the resource that you requested 13753// isn’t valid. Check the resource, and try again. 13754type WAFInvalidResourceException struct { 13755 _ struct{} `type:"structure"` 13756 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13757 13758 Message_ *string `locationName:"Message" type:"string"` 13759} 13760 13761// String returns the string representation 13762func (s WAFInvalidResourceException) String() string { 13763 return awsutil.Prettify(s) 13764} 13765 13766// GoString returns the string representation 13767func (s WAFInvalidResourceException) GoString() string { 13768 return s.String() 13769} 13770 13771func newErrorWAFInvalidResourceException(v protocol.ResponseMetadata) error { 13772 return &WAFInvalidResourceException{ 13773 RespMetadata: v, 13774 } 13775} 13776 13777// Code returns the exception type name. 13778func (s *WAFInvalidResourceException) Code() string { 13779 return "WAFInvalidResourceException" 13780} 13781 13782// Message returns the exception's message. 13783func (s *WAFInvalidResourceException) Message() string { 13784 if s.Message_ != nil { 13785 return *s.Message_ 13786 } 13787 return "" 13788} 13789 13790// OrigErr always returns nil, satisfies awserr.Error interface. 13791func (s *WAFInvalidResourceException) OrigErr() error { 13792 return nil 13793} 13794 13795func (s *WAFInvalidResourceException) Error() string { 13796 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13797} 13798 13799// Status code returns the HTTP status code for the request's response error. 13800func (s *WAFInvalidResourceException) StatusCode() int { 13801 return s.RespMetadata.StatusCode 13802} 13803 13804// RequestID returns the service's response RequestID for request. 13805func (s *WAFInvalidResourceException) RequestID() string { 13806 return s.RespMetadata.RequestID 13807} 13808 13809// AWS WAF couldn’t perform the operation because you exceeded your resource 13810// limit. For example, the maximum number of WebACL objects that you can create 13811// for an AWS account. For more information, see Limits (https://docs.aws.amazon.com/waf/latest/developerguide/limits.html) 13812// in the AWS WAF Developer Guide. 13813type WAFLimitsExceededException struct { 13814 _ struct{} `type:"structure"` 13815 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13816 13817 Message_ *string `locationName:"Message" type:"string"` 13818} 13819 13820// String returns the string representation 13821func (s WAFLimitsExceededException) String() string { 13822 return awsutil.Prettify(s) 13823} 13824 13825// GoString returns the string representation 13826func (s WAFLimitsExceededException) GoString() string { 13827 return s.String() 13828} 13829 13830func newErrorWAFLimitsExceededException(v protocol.ResponseMetadata) error { 13831 return &WAFLimitsExceededException{ 13832 RespMetadata: v, 13833 } 13834} 13835 13836// Code returns the exception type name. 13837func (s *WAFLimitsExceededException) Code() string { 13838 return "WAFLimitsExceededException" 13839} 13840 13841// Message returns the exception's message. 13842func (s *WAFLimitsExceededException) Message() string { 13843 if s.Message_ != nil { 13844 return *s.Message_ 13845 } 13846 return "" 13847} 13848 13849// OrigErr always returns nil, satisfies awserr.Error interface. 13850func (s *WAFLimitsExceededException) OrigErr() error { 13851 return nil 13852} 13853 13854func (s *WAFLimitsExceededException) Error() string { 13855 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13856} 13857 13858// Status code returns the HTTP status code for the request's response error. 13859func (s *WAFLimitsExceededException) StatusCode() int { 13860 return s.RespMetadata.StatusCode 13861} 13862 13863// RequestID returns the service's response RequestID for request. 13864func (s *WAFLimitsExceededException) RequestID() string { 13865 return s.RespMetadata.RequestID 13866} 13867 13868// AWS WAF couldn’t perform the operation because your resource doesn’t 13869// exist. 13870type WAFNonexistentItemException struct { 13871 _ struct{} `type:"structure"` 13872 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13873 13874 Message_ *string `locationName:"Message" type:"string"` 13875} 13876 13877// String returns the string representation 13878func (s WAFNonexistentItemException) String() string { 13879 return awsutil.Prettify(s) 13880} 13881 13882// GoString returns the string representation 13883func (s WAFNonexistentItemException) GoString() string { 13884 return s.String() 13885} 13886 13887func newErrorWAFNonexistentItemException(v protocol.ResponseMetadata) error { 13888 return &WAFNonexistentItemException{ 13889 RespMetadata: v, 13890 } 13891} 13892 13893// Code returns the exception type name. 13894func (s *WAFNonexistentItemException) Code() string { 13895 return "WAFNonexistentItemException" 13896} 13897 13898// Message returns the exception's message. 13899func (s *WAFNonexistentItemException) Message() string { 13900 if s.Message_ != nil { 13901 return *s.Message_ 13902 } 13903 return "" 13904} 13905 13906// OrigErr always returns nil, satisfies awserr.Error interface. 13907func (s *WAFNonexistentItemException) OrigErr() error { 13908 return nil 13909} 13910 13911func (s *WAFNonexistentItemException) Error() string { 13912 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13913} 13914 13915// Status code returns the HTTP status code for the request's response error. 13916func (s *WAFNonexistentItemException) StatusCode() int { 13917 return s.RespMetadata.StatusCode 13918} 13919 13920// RequestID returns the service's response RequestID for request. 13921func (s *WAFNonexistentItemException) RequestID() string { 13922 return s.RespMetadata.RequestID 13923} 13924 13925// AWS WAF couldn’t save your changes because you tried to update or delete 13926// a resource that has changed since you last retrieved it. Get the resource 13927// again, make any changes you need to make to the new copy, and retry your 13928// operation. 13929type WAFOptimisticLockException struct { 13930 _ struct{} `type:"structure"` 13931 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13932 13933 Message_ *string `locationName:"Message" type:"string"` 13934} 13935 13936// String returns the string representation 13937func (s WAFOptimisticLockException) String() string { 13938 return awsutil.Prettify(s) 13939} 13940 13941// GoString returns the string representation 13942func (s WAFOptimisticLockException) GoString() string { 13943 return s.String() 13944} 13945 13946func newErrorWAFOptimisticLockException(v protocol.ResponseMetadata) error { 13947 return &WAFOptimisticLockException{ 13948 RespMetadata: v, 13949 } 13950} 13951 13952// Code returns the exception type name. 13953func (s *WAFOptimisticLockException) Code() string { 13954 return "WAFOptimisticLockException" 13955} 13956 13957// Message returns the exception's message. 13958func (s *WAFOptimisticLockException) Message() string { 13959 if s.Message_ != nil { 13960 return *s.Message_ 13961 } 13962 return "" 13963} 13964 13965// OrigErr always returns nil, satisfies awserr.Error interface. 13966func (s *WAFOptimisticLockException) OrigErr() error { 13967 return nil 13968} 13969 13970func (s *WAFOptimisticLockException) Error() string { 13971 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 13972} 13973 13974// Status code returns the HTTP status code for the request's response error. 13975func (s *WAFOptimisticLockException) StatusCode() int { 13976 return s.RespMetadata.StatusCode 13977} 13978 13979// RequestID returns the service's response RequestID for request. 13980func (s *WAFOptimisticLockException) RequestID() string { 13981 return s.RespMetadata.RequestID 13982} 13983 13984// AWS WAF is not able to access the service linked role. This can be caused 13985// by a previous PutLoggingConfiguration request, which can lock the service 13986// linked role for about 20 seconds. Please try your request again. The service 13987// linked role can also be locked by a previous DeleteServiceLinkedRole request, 13988// which can lock the role for 15 minutes or more. If you recently made a call 13989// to DeleteServiceLinkedRole, wait at least 15 minutes and try the request 13990// again. If you receive this same exception again, you will have to wait additional 13991// time until the role is unlocked. 13992type WAFServiceLinkedRoleErrorException struct { 13993 _ struct{} `type:"structure"` 13994 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 13995 13996 Message_ *string `locationName:"message" type:"string"` 13997} 13998 13999// String returns the string representation 14000func (s WAFServiceLinkedRoleErrorException) String() string { 14001 return awsutil.Prettify(s) 14002} 14003 14004// GoString returns the string representation 14005func (s WAFServiceLinkedRoleErrorException) GoString() string { 14006 return s.String() 14007} 14008 14009func newErrorWAFServiceLinkedRoleErrorException(v protocol.ResponseMetadata) error { 14010 return &WAFServiceLinkedRoleErrorException{ 14011 RespMetadata: v, 14012 } 14013} 14014 14015// Code returns the exception type name. 14016func (s *WAFServiceLinkedRoleErrorException) Code() string { 14017 return "WAFServiceLinkedRoleErrorException" 14018} 14019 14020// Message returns the exception's message. 14021func (s *WAFServiceLinkedRoleErrorException) Message() string { 14022 if s.Message_ != nil { 14023 return *s.Message_ 14024 } 14025 return "" 14026} 14027 14028// OrigErr always returns nil, satisfies awserr.Error interface. 14029func (s *WAFServiceLinkedRoleErrorException) OrigErr() error { 14030 return nil 14031} 14032 14033func (s *WAFServiceLinkedRoleErrorException) Error() string { 14034 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 14035} 14036 14037// Status code returns the HTTP status code for the request's response error. 14038func (s *WAFServiceLinkedRoleErrorException) StatusCode() int { 14039 return s.RespMetadata.StatusCode 14040} 14041 14042// RequestID returns the service's response RequestID for request. 14043func (s *WAFServiceLinkedRoleErrorException) RequestID() string { 14044 return s.RespMetadata.RequestID 14045} 14046 14047type WAFSubscriptionNotFoundException struct { 14048 _ struct{} `type:"structure"` 14049 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 14050 14051 Message_ *string `locationName:"Message" type:"string"` 14052} 14053 14054// String returns the string representation 14055func (s WAFSubscriptionNotFoundException) String() string { 14056 return awsutil.Prettify(s) 14057} 14058 14059// GoString returns the string representation 14060func (s WAFSubscriptionNotFoundException) GoString() string { 14061 return s.String() 14062} 14063 14064func newErrorWAFSubscriptionNotFoundException(v protocol.ResponseMetadata) error { 14065 return &WAFSubscriptionNotFoundException{ 14066 RespMetadata: v, 14067 } 14068} 14069 14070// Code returns the exception type name. 14071func (s *WAFSubscriptionNotFoundException) Code() string { 14072 return "WAFSubscriptionNotFoundException" 14073} 14074 14075// Message returns the exception's message. 14076func (s *WAFSubscriptionNotFoundException) Message() string { 14077 if s.Message_ != nil { 14078 return *s.Message_ 14079 } 14080 return "" 14081} 14082 14083// OrigErr always returns nil, satisfies awserr.Error interface. 14084func (s *WAFSubscriptionNotFoundException) OrigErr() error { 14085 return nil 14086} 14087 14088func (s *WAFSubscriptionNotFoundException) Error() string { 14089 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 14090} 14091 14092// Status code returns the HTTP status code for the request's response error. 14093func (s *WAFSubscriptionNotFoundException) StatusCode() int { 14094 return s.RespMetadata.StatusCode 14095} 14096 14097// RequestID returns the service's response RequestID for request. 14098func (s *WAFSubscriptionNotFoundException) RequestID() string { 14099 return s.RespMetadata.RequestID 14100} 14101 14102// An error occurred during the tagging operation. Retry your request. 14103type WAFTagOperationException struct { 14104 _ struct{} `type:"structure"` 14105 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 14106 14107 Message_ *string `locationName:"Message" type:"string"` 14108} 14109 14110// String returns the string representation 14111func (s WAFTagOperationException) String() string { 14112 return awsutil.Prettify(s) 14113} 14114 14115// GoString returns the string representation 14116func (s WAFTagOperationException) GoString() string { 14117 return s.String() 14118} 14119 14120func newErrorWAFTagOperationException(v protocol.ResponseMetadata) error { 14121 return &WAFTagOperationException{ 14122 RespMetadata: v, 14123 } 14124} 14125 14126// Code returns the exception type name. 14127func (s *WAFTagOperationException) Code() string { 14128 return "WAFTagOperationException" 14129} 14130 14131// Message returns the exception's message. 14132func (s *WAFTagOperationException) Message() string { 14133 if s.Message_ != nil { 14134 return *s.Message_ 14135 } 14136 return "" 14137} 14138 14139// OrigErr always returns nil, satisfies awserr.Error interface. 14140func (s *WAFTagOperationException) OrigErr() error { 14141 return nil 14142} 14143 14144func (s *WAFTagOperationException) Error() string { 14145 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 14146} 14147 14148// Status code returns the HTTP status code for the request's response error. 14149func (s *WAFTagOperationException) StatusCode() int { 14150 return s.RespMetadata.StatusCode 14151} 14152 14153// RequestID returns the service's response RequestID for request. 14154func (s *WAFTagOperationException) RequestID() string { 14155 return s.RespMetadata.RequestID 14156} 14157 14158// AWS WAF couldn’t perform your tagging operation because of an internal 14159// error. Retry your request. 14160type WAFTagOperationInternalErrorException struct { 14161 _ struct{} `type:"structure"` 14162 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 14163 14164 Message_ *string `locationName:"Message" type:"string"` 14165} 14166 14167// String returns the string representation 14168func (s WAFTagOperationInternalErrorException) String() string { 14169 return awsutil.Prettify(s) 14170} 14171 14172// GoString returns the string representation 14173func (s WAFTagOperationInternalErrorException) GoString() string { 14174 return s.String() 14175} 14176 14177func newErrorWAFTagOperationInternalErrorException(v protocol.ResponseMetadata) error { 14178 return &WAFTagOperationInternalErrorException{ 14179 RespMetadata: v, 14180 } 14181} 14182 14183// Code returns the exception type name. 14184func (s *WAFTagOperationInternalErrorException) Code() string { 14185 return "WAFTagOperationInternalErrorException" 14186} 14187 14188// Message returns the exception's message. 14189func (s *WAFTagOperationInternalErrorException) Message() string { 14190 if s.Message_ != nil { 14191 return *s.Message_ 14192 } 14193 return "" 14194} 14195 14196// OrigErr always returns nil, satisfies awserr.Error interface. 14197func (s *WAFTagOperationInternalErrorException) OrigErr() error { 14198 return nil 14199} 14200 14201func (s *WAFTagOperationInternalErrorException) Error() string { 14202 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 14203} 14204 14205// Status code returns the HTTP status code for the request's response error. 14206func (s *WAFTagOperationInternalErrorException) StatusCode() int { 14207 return s.RespMetadata.StatusCode 14208} 14209 14210// RequestID returns the service's response RequestID for request. 14211func (s *WAFTagOperationInternalErrorException) RequestID() string { 14212 return s.RespMetadata.RequestID 14213} 14214 14215// AWS WAF couldn’t retrieve the resource that you requested. Retry your request. 14216type WAFUnavailableEntityException struct { 14217 _ struct{} `type:"structure"` 14218 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 14219 14220 Message_ *string `locationName:"Message" type:"string"` 14221} 14222 14223// String returns the string representation 14224func (s WAFUnavailableEntityException) String() string { 14225 return awsutil.Prettify(s) 14226} 14227 14228// GoString returns the string representation 14229func (s WAFUnavailableEntityException) GoString() string { 14230 return s.String() 14231} 14232 14233func newErrorWAFUnavailableEntityException(v protocol.ResponseMetadata) error { 14234 return &WAFUnavailableEntityException{ 14235 RespMetadata: v, 14236 } 14237} 14238 14239// Code returns the exception type name. 14240func (s *WAFUnavailableEntityException) Code() string { 14241 return "WAFUnavailableEntityException" 14242} 14243 14244// Message returns the exception's message. 14245func (s *WAFUnavailableEntityException) Message() string { 14246 if s.Message_ != nil { 14247 return *s.Message_ 14248 } 14249 return "" 14250} 14251 14252// OrigErr always returns nil, satisfies awserr.Error interface. 14253func (s *WAFUnavailableEntityException) OrigErr() error { 14254 return nil 14255} 14256 14257func (s *WAFUnavailableEntityException) Error() string { 14258 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 14259} 14260 14261// Status code returns the HTTP status code for the request's response error. 14262func (s *WAFUnavailableEntityException) StatusCode() int { 14263 return s.RespMetadata.StatusCode 14264} 14265 14266// RequestID returns the service's response RequestID for request. 14267func (s *WAFUnavailableEntityException) RequestID() string { 14268 return s.RespMetadata.RequestID 14269} 14270 14271// 14272// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 14273// 2019. For information, including how to migrate your AWS WAF resources from 14274// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 14275// 14276// A Web ACL defines a collection of rules to use to inspect and control web 14277// requests. Each rule has an action defined (allow, block, or count) for requests 14278// that match the statement of the rule. In the Web ACL, you assign a default 14279// action to take (allow, block) for any request that does not match any of 14280// the rules. The rules in a Web ACL can be a combination of the types Rule, 14281// RuleGroup, and managed rule group. You can associate a Web ACL with one or 14282// more AWS resources to protect. The resources can be Amazon CloudFront, an 14283// Amazon API Gateway REST API, an Application Load Balancer, or an AWS AppSync 14284// GraphQL API. 14285type WebACL struct { 14286 _ struct{} `type:"structure"` 14287 14288 // The Amazon Resource Name (ARN) of the Web ACL that you want to associate 14289 // with the resource. 14290 // 14291 // ARN is a required field 14292 ARN *string `min:"20" type:"string" required:"true"` 14293 14294 // The web ACL capacity units (WCUs) currently being used by this web ACL. 14295 // 14296 // AWS WAF uses WCUs to calculate and control the operating resources that are 14297 // used to run your rules, rule groups, and web ACLs. AWS WAF calculates capacity 14298 // differently for each rule type, to reflect the relative cost of each rule. 14299 // Simple rules that cost little to run use fewer WCUs than more complex rules 14300 // that use more processing power. Rule group capacity is fixed at creation, 14301 // which helps users plan their web ACL WCU usage when they use a rule group. 14302 // The WCU limit for web ACLs is 1,500. 14303 Capacity *int64 `type:"long"` 14304 14305 // The action to perform if none of the Rules contained in the WebACL match. 14306 // 14307 // DefaultAction is a required field 14308 DefaultAction *DefaultAction `type:"structure" required:"true"` 14309 14310 // A description of the Web ACL that helps with identification. You cannot change 14311 // the description of a Web ACL after you create it. 14312 Description *string `min:"1" type:"string"` 14313 14314 // A unique identifier for the WebACL. This ID is returned in the responses 14315 // to create and list commands. You use this ID to do things like get, update, 14316 // and delete a WebACL. 14317 // 14318 // Id is a required field 14319 Id *string `min:"1" type:"string" required:"true"` 14320 14321 // Indicates whether this web ACL is managed by AWS Firewall Manager. If true, 14322 // then only AWS Firewall Manager can delete the web ACL or any Firewall Manager 14323 // rule groups in the web ACL. 14324 ManagedByFirewallManager *bool `type:"boolean"` 14325 14326 // The name of the Web ACL. You cannot change the name of a Web ACL after you 14327 // create it. 14328 // 14329 // Name is a required field 14330 Name *string `min:"1" type:"string" required:"true"` 14331 14332 // The last set of rules for AWS WAF to process in the web ACL. This is defined 14333 // in an AWS Firewall Manager WAF policy and contains only rule group references. 14334 // You can't alter these. Any rules and rule groups that you define for the 14335 // web ACL are prioritized before these. 14336 // 14337 // In the Firewall Manager WAF policy, the Firewall Manager administrator can 14338 // define a set of rule groups to run first in the web ACL and a set of rule 14339 // groups to run last. Within each set, the administrator prioritizes the rule 14340 // groups, to determine their relative processing order. 14341 PostProcessFirewallManagerRuleGroups []*FirewallManagerRuleGroup `type:"list"` 14342 14343 // The first set of rules for AWS WAF to process in the web ACL. This is defined 14344 // in an AWS Firewall Manager WAF policy and contains only rule group references. 14345 // You can't alter these. Any rules and rule groups that you define for the 14346 // web ACL are prioritized after these. 14347 // 14348 // In the Firewall Manager WAF policy, the Firewall Manager administrator can 14349 // define a set of rule groups to run first in the web ACL and a set of rule 14350 // groups to run last. Within each set, the administrator prioritizes the rule 14351 // groups, to determine their relative processing order. 14352 PreProcessFirewallManagerRuleGroups []*FirewallManagerRuleGroup `type:"list"` 14353 14354 // The Rule statements used to identify the web requests that you want to allow, 14355 // block, or count. Each rule includes one top-level statement that AWS WAF 14356 // uses to identify matching web requests, and parameters that govern how AWS 14357 // WAF handles them. 14358 Rules []*Rule `type:"list"` 14359 14360 // Defines and enables Amazon CloudWatch metrics and web request sample collection. 14361 // 14362 // VisibilityConfig is a required field 14363 VisibilityConfig *VisibilityConfig `type:"structure" required:"true"` 14364} 14365 14366// String returns the string representation 14367func (s WebACL) String() string { 14368 return awsutil.Prettify(s) 14369} 14370 14371// GoString returns the string representation 14372func (s WebACL) GoString() string { 14373 return s.String() 14374} 14375 14376// SetARN sets the ARN field's value. 14377func (s *WebACL) SetARN(v string) *WebACL { 14378 s.ARN = &v 14379 return s 14380} 14381 14382// SetCapacity sets the Capacity field's value. 14383func (s *WebACL) SetCapacity(v int64) *WebACL { 14384 s.Capacity = &v 14385 return s 14386} 14387 14388// SetDefaultAction sets the DefaultAction field's value. 14389func (s *WebACL) SetDefaultAction(v *DefaultAction) *WebACL { 14390 s.DefaultAction = v 14391 return s 14392} 14393 14394// SetDescription sets the Description field's value. 14395func (s *WebACL) SetDescription(v string) *WebACL { 14396 s.Description = &v 14397 return s 14398} 14399 14400// SetId sets the Id field's value. 14401func (s *WebACL) SetId(v string) *WebACL { 14402 s.Id = &v 14403 return s 14404} 14405 14406// SetManagedByFirewallManager sets the ManagedByFirewallManager field's value. 14407func (s *WebACL) SetManagedByFirewallManager(v bool) *WebACL { 14408 s.ManagedByFirewallManager = &v 14409 return s 14410} 14411 14412// SetName sets the Name field's value. 14413func (s *WebACL) SetName(v string) *WebACL { 14414 s.Name = &v 14415 return s 14416} 14417 14418// SetPostProcessFirewallManagerRuleGroups sets the PostProcessFirewallManagerRuleGroups field's value. 14419func (s *WebACL) SetPostProcessFirewallManagerRuleGroups(v []*FirewallManagerRuleGroup) *WebACL { 14420 s.PostProcessFirewallManagerRuleGroups = v 14421 return s 14422} 14423 14424// SetPreProcessFirewallManagerRuleGroups sets the PreProcessFirewallManagerRuleGroups field's value. 14425func (s *WebACL) SetPreProcessFirewallManagerRuleGroups(v []*FirewallManagerRuleGroup) *WebACL { 14426 s.PreProcessFirewallManagerRuleGroups = v 14427 return s 14428} 14429 14430// SetRules sets the Rules field's value. 14431func (s *WebACL) SetRules(v []*Rule) *WebACL { 14432 s.Rules = v 14433 return s 14434} 14435 14436// SetVisibilityConfig sets the VisibilityConfig field's value. 14437func (s *WebACL) SetVisibilityConfig(v *VisibilityConfig) *WebACL { 14438 s.VisibilityConfig = v 14439 return s 14440} 14441 14442// 14443// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 14444// 2019. For information, including how to migrate your AWS WAF resources from 14445// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 14446// 14447// High-level information about a WebACL, returned by operations like create 14448// and list. This provides information like the ID, that you can use to retrieve 14449// and manage a WebACL, and the ARN, that you provide to operations like AssociateWebACL. 14450type WebACLSummary struct { 14451 _ struct{} `type:"structure"` 14452 14453 // The Amazon Resource Name (ARN) of the entity. 14454 ARN *string `min:"20" type:"string"` 14455 14456 // A description of the Web ACL that helps with identification. You cannot change 14457 // the description of a Web ACL after you create it. 14458 Description *string `min:"1" type:"string"` 14459 14460 // The unique identifier for the Web ACL. This ID is returned in the responses 14461 // to create and list commands. You provide it to operations like update and 14462 // delete. 14463 Id *string `min:"1" type:"string"` 14464 14465 // A token used for optimistic locking. AWS WAF returns a token to your get 14466 // and list requests, to mark the state of the entity at the time of the request. 14467 // To make changes to the entity associated with the token, you provide the 14468 // token to operations like update and delete. AWS WAF uses the token to ensure 14469 // that no changes have been made to the entity since you last retrieved it. 14470 // If a change has been made, the update fails with a WAFOptimisticLockException. 14471 // If this happens, perform another get, and use the new token returned by that 14472 // operation. 14473 LockToken *string `min:"1" type:"string"` 14474 14475 // The name of the Web ACL. You cannot change the name of a Web ACL after you 14476 // create it. 14477 Name *string `min:"1" type:"string"` 14478} 14479 14480// String returns the string representation 14481func (s WebACLSummary) String() string { 14482 return awsutil.Prettify(s) 14483} 14484 14485// GoString returns the string representation 14486func (s WebACLSummary) GoString() string { 14487 return s.String() 14488} 14489 14490// SetARN sets the ARN field's value. 14491func (s *WebACLSummary) SetARN(v string) *WebACLSummary { 14492 s.ARN = &v 14493 return s 14494} 14495 14496// SetDescription sets the Description field's value. 14497func (s *WebACLSummary) SetDescription(v string) *WebACLSummary { 14498 s.Description = &v 14499 return s 14500} 14501 14502// SetId sets the Id field's value. 14503func (s *WebACLSummary) SetId(v string) *WebACLSummary { 14504 s.Id = &v 14505 return s 14506} 14507 14508// SetLockToken sets the LockToken field's value. 14509func (s *WebACLSummary) SetLockToken(v string) *WebACLSummary { 14510 s.LockToken = &v 14511 return s 14512} 14513 14514// SetName sets the Name field's value. 14515func (s *WebACLSummary) SetName(v string) *WebACLSummary { 14516 s.Name = &v 14517 return s 14518} 14519 14520// 14521// This is the latest version of AWS WAF, named AWS WAFV2, released in November, 14522// 2019. For information, including how to migrate your AWS WAF resources from 14523// the prior release, see the AWS WAF Developer Guide (https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html). 14524// 14525// A rule statement that defines a cross-site scripting (XSS) match search for 14526// AWS WAF to apply to web requests. XSS attacks are those where the attacker 14527// uses vulnerabilities in a benign website as a vehicle to inject malicious 14528// client-site scripts into other legitimate web browsers. The XSS match statement 14529// provides the location in requests that you want AWS WAF to search and text 14530// transformations to use on the search area before AWS WAF searches for character 14531// sequences that are likely to be malicious strings. 14532type XssMatchStatement struct { 14533 _ struct{} `type:"structure"` 14534 14535 // The part of a web request that you want AWS WAF to inspect. For more information, 14536 // see FieldToMatch. 14537 // 14538 // FieldToMatch is a required field 14539 FieldToMatch *FieldToMatch `type:"structure" required:"true"` 14540 14541 // Text transformations eliminate some of the unusual formatting that attackers 14542 // use in web requests in an effort to bypass detection. If you specify one 14543 // or more transformations in a rule statement, AWS WAF performs all transformations 14544 // on the content of the request component identified by FieldToMatch, starting 14545 // from the lowest priority setting, before inspecting the content for a match. 14546 // 14547 // TextTransformations is a required field 14548 TextTransformations []*TextTransformation `min:"1" type:"list" required:"true"` 14549} 14550 14551// String returns the string representation 14552func (s XssMatchStatement) String() string { 14553 return awsutil.Prettify(s) 14554} 14555 14556// GoString returns the string representation 14557func (s XssMatchStatement) GoString() string { 14558 return s.String() 14559} 14560 14561// Validate inspects the fields of the type to determine if they are valid. 14562func (s *XssMatchStatement) Validate() error { 14563 invalidParams := request.ErrInvalidParams{Context: "XssMatchStatement"} 14564 if s.FieldToMatch == nil { 14565 invalidParams.Add(request.NewErrParamRequired("FieldToMatch")) 14566 } 14567 if s.TextTransformations == nil { 14568 invalidParams.Add(request.NewErrParamRequired("TextTransformations")) 14569 } 14570 if s.TextTransformations != nil && len(s.TextTransformations) < 1 { 14571 invalidParams.Add(request.NewErrParamMinLen("TextTransformations", 1)) 14572 } 14573 if s.FieldToMatch != nil { 14574 if err := s.FieldToMatch.Validate(); err != nil { 14575 invalidParams.AddNested("FieldToMatch", err.(request.ErrInvalidParams)) 14576 } 14577 } 14578 if s.TextTransformations != nil { 14579 for i, v := range s.TextTransformations { 14580 if v == nil { 14581 continue 14582 } 14583 if err := v.Validate(); err != nil { 14584 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TextTransformations", i), err.(request.ErrInvalidParams)) 14585 } 14586 } 14587 } 14588 14589 if invalidParams.Len() > 0 { 14590 return invalidParams 14591 } 14592 return nil 14593} 14594 14595// SetFieldToMatch sets the FieldToMatch field's value. 14596func (s *XssMatchStatement) SetFieldToMatch(v *FieldToMatch) *XssMatchStatement { 14597 s.FieldToMatch = v 14598 return s 14599} 14600 14601// SetTextTransformations sets the TextTransformations field's value. 14602func (s *XssMatchStatement) SetTextTransformations(v []*TextTransformation) *XssMatchStatement { 14603 s.TextTransformations = v 14604 return s 14605} 14606 14607const ( 14608 // ComparisonOperatorEq is a ComparisonOperator enum value 14609 ComparisonOperatorEq = "EQ" 14610 14611 // ComparisonOperatorNe is a ComparisonOperator enum value 14612 ComparisonOperatorNe = "NE" 14613 14614 // ComparisonOperatorLe is a ComparisonOperator enum value 14615 ComparisonOperatorLe = "LE" 14616 14617 // ComparisonOperatorLt is a ComparisonOperator enum value 14618 ComparisonOperatorLt = "LT" 14619 14620 // ComparisonOperatorGe is a ComparisonOperator enum value 14621 ComparisonOperatorGe = "GE" 14622 14623 // ComparisonOperatorGt is a ComparisonOperator enum value 14624 ComparisonOperatorGt = "GT" 14625) 14626 14627// ComparisonOperator_Values returns all elements of the ComparisonOperator enum 14628func ComparisonOperator_Values() []string { 14629 return []string{ 14630 ComparisonOperatorEq, 14631 ComparisonOperatorNe, 14632 ComparisonOperatorLe, 14633 ComparisonOperatorLt, 14634 ComparisonOperatorGe, 14635 ComparisonOperatorGt, 14636 } 14637} 14638 14639const ( 14640 // CountryCodeAf is a CountryCode enum value 14641 CountryCodeAf = "AF" 14642 14643 // CountryCodeAx is a CountryCode enum value 14644 CountryCodeAx = "AX" 14645 14646 // CountryCodeAl is a CountryCode enum value 14647 CountryCodeAl = "AL" 14648 14649 // CountryCodeDz is a CountryCode enum value 14650 CountryCodeDz = "DZ" 14651 14652 // CountryCodeAs is a CountryCode enum value 14653 CountryCodeAs = "AS" 14654 14655 // CountryCodeAd is a CountryCode enum value 14656 CountryCodeAd = "AD" 14657 14658 // CountryCodeAo is a CountryCode enum value 14659 CountryCodeAo = "AO" 14660 14661 // CountryCodeAi is a CountryCode enum value 14662 CountryCodeAi = "AI" 14663 14664 // CountryCodeAq is a CountryCode enum value 14665 CountryCodeAq = "AQ" 14666 14667 // CountryCodeAg is a CountryCode enum value 14668 CountryCodeAg = "AG" 14669 14670 // CountryCodeAr is a CountryCode enum value 14671 CountryCodeAr = "AR" 14672 14673 // CountryCodeAm is a CountryCode enum value 14674 CountryCodeAm = "AM" 14675 14676 // CountryCodeAw is a CountryCode enum value 14677 CountryCodeAw = "AW" 14678 14679 // CountryCodeAu is a CountryCode enum value 14680 CountryCodeAu = "AU" 14681 14682 // CountryCodeAt is a CountryCode enum value 14683 CountryCodeAt = "AT" 14684 14685 // CountryCodeAz is a CountryCode enum value 14686 CountryCodeAz = "AZ" 14687 14688 // CountryCodeBs is a CountryCode enum value 14689 CountryCodeBs = "BS" 14690 14691 // CountryCodeBh is a CountryCode enum value 14692 CountryCodeBh = "BH" 14693 14694 // CountryCodeBd is a CountryCode enum value 14695 CountryCodeBd = "BD" 14696 14697 // CountryCodeBb is a CountryCode enum value 14698 CountryCodeBb = "BB" 14699 14700 // CountryCodeBy is a CountryCode enum value 14701 CountryCodeBy = "BY" 14702 14703 // CountryCodeBe is a CountryCode enum value 14704 CountryCodeBe = "BE" 14705 14706 // CountryCodeBz is a CountryCode enum value 14707 CountryCodeBz = "BZ" 14708 14709 // CountryCodeBj is a CountryCode enum value 14710 CountryCodeBj = "BJ" 14711 14712 // CountryCodeBm is a CountryCode enum value 14713 CountryCodeBm = "BM" 14714 14715 // CountryCodeBt is a CountryCode enum value 14716 CountryCodeBt = "BT" 14717 14718 // CountryCodeBo is a CountryCode enum value 14719 CountryCodeBo = "BO" 14720 14721 // CountryCodeBq is a CountryCode enum value 14722 CountryCodeBq = "BQ" 14723 14724 // CountryCodeBa is a CountryCode enum value 14725 CountryCodeBa = "BA" 14726 14727 // CountryCodeBw is a CountryCode enum value 14728 CountryCodeBw = "BW" 14729 14730 // CountryCodeBv is a CountryCode enum value 14731 CountryCodeBv = "BV" 14732 14733 // CountryCodeBr is a CountryCode enum value 14734 CountryCodeBr = "BR" 14735 14736 // CountryCodeIo is a CountryCode enum value 14737 CountryCodeIo = "IO" 14738 14739 // CountryCodeBn is a CountryCode enum value 14740 CountryCodeBn = "BN" 14741 14742 // CountryCodeBg is a CountryCode enum value 14743 CountryCodeBg = "BG" 14744 14745 // CountryCodeBf is a CountryCode enum value 14746 CountryCodeBf = "BF" 14747 14748 // CountryCodeBi is a CountryCode enum value 14749 CountryCodeBi = "BI" 14750 14751 // CountryCodeKh is a CountryCode enum value 14752 CountryCodeKh = "KH" 14753 14754 // CountryCodeCm is a CountryCode enum value 14755 CountryCodeCm = "CM" 14756 14757 // CountryCodeCa is a CountryCode enum value 14758 CountryCodeCa = "CA" 14759 14760 // CountryCodeCv is a CountryCode enum value 14761 CountryCodeCv = "CV" 14762 14763 // CountryCodeKy is a CountryCode enum value 14764 CountryCodeKy = "KY" 14765 14766 // CountryCodeCf is a CountryCode enum value 14767 CountryCodeCf = "CF" 14768 14769 // CountryCodeTd is a CountryCode enum value 14770 CountryCodeTd = "TD" 14771 14772 // CountryCodeCl is a CountryCode enum value 14773 CountryCodeCl = "CL" 14774 14775 // CountryCodeCn is a CountryCode enum value 14776 CountryCodeCn = "CN" 14777 14778 // CountryCodeCx is a CountryCode enum value 14779 CountryCodeCx = "CX" 14780 14781 // CountryCodeCc is a CountryCode enum value 14782 CountryCodeCc = "CC" 14783 14784 // CountryCodeCo is a CountryCode enum value 14785 CountryCodeCo = "CO" 14786 14787 // CountryCodeKm is a CountryCode enum value 14788 CountryCodeKm = "KM" 14789 14790 // CountryCodeCg is a CountryCode enum value 14791 CountryCodeCg = "CG" 14792 14793 // CountryCodeCd is a CountryCode enum value 14794 CountryCodeCd = "CD" 14795 14796 // CountryCodeCk is a CountryCode enum value 14797 CountryCodeCk = "CK" 14798 14799 // CountryCodeCr is a CountryCode enum value 14800 CountryCodeCr = "CR" 14801 14802 // CountryCodeCi is a CountryCode enum value 14803 CountryCodeCi = "CI" 14804 14805 // CountryCodeHr is a CountryCode enum value 14806 CountryCodeHr = "HR" 14807 14808 // CountryCodeCu is a CountryCode enum value 14809 CountryCodeCu = "CU" 14810 14811 // CountryCodeCw is a CountryCode enum value 14812 CountryCodeCw = "CW" 14813 14814 // CountryCodeCy is a CountryCode enum value 14815 CountryCodeCy = "CY" 14816 14817 // CountryCodeCz is a CountryCode enum value 14818 CountryCodeCz = "CZ" 14819 14820 // CountryCodeDk is a CountryCode enum value 14821 CountryCodeDk = "DK" 14822 14823 // CountryCodeDj is a CountryCode enum value 14824 CountryCodeDj = "DJ" 14825 14826 // CountryCodeDm is a CountryCode enum value 14827 CountryCodeDm = "DM" 14828 14829 // CountryCodeDo is a CountryCode enum value 14830 CountryCodeDo = "DO" 14831 14832 // CountryCodeEc is a CountryCode enum value 14833 CountryCodeEc = "EC" 14834 14835 // CountryCodeEg is a CountryCode enum value 14836 CountryCodeEg = "EG" 14837 14838 // CountryCodeSv is a CountryCode enum value 14839 CountryCodeSv = "SV" 14840 14841 // CountryCodeGq is a CountryCode enum value 14842 CountryCodeGq = "GQ" 14843 14844 // CountryCodeEr is a CountryCode enum value 14845 CountryCodeEr = "ER" 14846 14847 // CountryCodeEe is a CountryCode enum value 14848 CountryCodeEe = "EE" 14849 14850 // CountryCodeEt is a CountryCode enum value 14851 CountryCodeEt = "ET" 14852 14853 // CountryCodeFk is a CountryCode enum value 14854 CountryCodeFk = "FK" 14855 14856 // CountryCodeFo is a CountryCode enum value 14857 CountryCodeFo = "FO" 14858 14859 // CountryCodeFj is a CountryCode enum value 14860 CountryCodeFj = "FJ" 14861 14862 // CountryCodeFi is a CountryCode enum value 14863 CountryCodeFi = "FI" 14864 14865 // CountryCodeFr is a CountryCode enum value 14866 CountryCodeFr = "FR" 14867 14868 // CountryCodeGf is a CountryCode enum value 14869 CountryCodeGf = "GF" 14870 14871 // CountryCodePf is a CountryCode enum value 14872 CountryCodePf = "PF" 14873 14874 // CountryCodeTf is a CountryCode enum value 14875 CountryCodeTf = "TF" 14876 14877 // CountryCodeGa is a CountryCode enum value 14878 CountryCodeGa = "GA" 14879 14880 // CountryCodeGm is a CountryCode enum value 14881 CountryCodeGm = "GM" 14882 14883 // CountryCodeGe is a CountryCode enum value 14884 CountryCodeGe = "GE" 14885 14886 // CountryCodeDe is a CountryCode enum value 14887 CountryCodeDe = "DE" 14888 14889 // CountryCodeGh is a CountryCode enum value 14890 CountryCodeGh = "GH" 14891 14892 // CountryCodeGi is a CountryCode enum value 14893 CountryCodeGi = "GI" 14894 14895 // CountryCodeGr is a CountryCode enum value 14896 CountryCodeGr = "GR" 14897 14898 // CountryCodeGl is a CountryCode enum value 14899 CountryCodeGl = "GL" 14900 14901 // CountryCodeGd is a CountryCode enum value 14902 CountryCodeGd = "GD" 14903 14904 // CountryCodeGp is a CountryCode enum value 14905 CountryCodeGp = "GP" 14906 14907 // CountryCodeGu is a CountryCode enum value 14908 CountryCodeGu = "GU" 14909 14910 // CountryCodeGt is a CountryCode enum value 14911 CountryCodeGt = "GT" 14912 14913 // CountryCodeGg is a CountryCode enum value 14914 CountryCodeGg = "GG" 14915 14916 // CountryCodeGn is a CountryCode enum value 14917 CountryCodeGn = "GN" 14918 14919 // CountryCodeGw is a CountryCode enum value 14920 CountryCodeGw = "GW" 14921 14922 // CountryCodeGy is a CountryCode enum value 14923 CountryCodeGy = "GY" 14924 14925 // CountryCodeHt is a CountryCode enum value 14926 CountryCodeHt = "HT" 14927 14928 // CountryCodeHm is a CountryCode enum value 14929 CountryCodeHm = "HM" 14930 14931 // CountryCodeVa is a CountryCode enum value 14932 CountryCodeVa = "VA" 14933 14934 // CountryCodeHn is a CountryCode enum value 14935 CountryCodeHn = "HN" 14936 14937 // CountryCodeHk is a CountryCode enum value 14938 CountryCodeHk = "HK" 14939 14940 // CountryCodeHu is a CountryCode enum value 14941 CountryCodeHu = "HU" 14942 14943 // CountryCodeIs is a CountryCode enum value 14944 CountryCodeIs = "IS" 14945 14946 // CountryCodeIn is a CountryCode enum value 14947 CountryCodeIn = "IN" 14948 14949 // CountryCodeId is a CountryCode enum value 14950 CountryCodeId = "ID" 14951 14952 // CountryCodeIr is a CountryCode enum value 14953 CountryCodeIr = "IR" 14954 14955 // CountryCodeIq is a CountryCode enum value 14956 CountryCodeIq = "IQ" 14957 14958 // CountryCodeIe is a CountryCode enum value 14959 CountryCodeIe = "IE" 14960 14961 // CountryCodeIm is a CountryCode enum value 14962 CountryCodeIm = "IM" 14963 14964 // CountryCodeIl is a CountryCode enum value 14965 CountryCodeIl = "IL" 14966 14967 // CountryCodeIt is a CountryCode enum value 14968 CountryCodeIt = "IT" 14969 14970 // CountryCodeJm is a CountryCode enum value 14971 CountryCodeJm = "JM" 14972 14973 // CountryCodeJp is a CountryCode enum value 14974 CountryCodeJp = "JP" 14975 14976 // CountryCodeJe is a CountryCode enum value 14977 CountryCodeJe = "JE" 14978 14979 // CountryCodeJo is a CountryCode enum value 14980 CountryCodeJo = "JO" 14981 14982 // CountryCodeKz is a CountryCode enum value 14983 CountryCodeKz = "KZ" 14984 14985 // CountryCodeKe is a CountryCode enum value 14986 CountryCodeKe = "KE" 14987 14988 // CountryCodeKi is a CountryCode enum value 14989 CountryCodeKi = "KI" 14990 14991 // CountryCodeKp is a CountryCode enum value 14992 CountryCodeKp = "KP" 14993 14994 // CountryCodeKr is a CountryCode enum value 14995 CountryCodeKr = "KR" 14996 14997 // CountryCodeKw is a CountryCode enum value 14998 CountryCodeKw = "KW" 14999 15000 // CountryCodeKg is a CountryCode enum value 15001 CountryCodeKg = "KG" 15002 15003 // CountryCodeLa is a CountryCode enum value 15004 CountryCodeLa = "LA" 15005 15006 // CountryCodeLv is a CountryCode enum value 15007 CountryCodeLv = "LV" 15008 15009 // CountryCodeLb is a CountryCode enum value 15010 CountryCodeLb = "LB" 15011 15012 // CountryCodeLs is a CountryCode enum value 15013 CountryCodeLs = "LS" 15014 15015 // CountryCodeLr is a CountryCode enum value 15016 CountryCodeLr = "LR" 15017 15018 // CountryCodeLy is a CountryCode enum value 15019 CountryCodeLy = "LY" 15020 15021 // CountryCodeLi is a CountryCode enum value 15022 CountryCodeLi = "LI" 15023 15024 // CountryCodeLt is a CountryCode enum value 15025 CountryCodeLt = "LT" 15026 15027 // CountryCodeLu is a CountryCode enum value 15028 CountryCodeLu = "LU" 15029 15030 // CountryCodeMo is a CountryCode enum value 15031 CountryCodeMo = "MO" 15032 15033 // CountryCodeMk is a CountryCode enum value 15034 CountryCodeMk = "MK" 15035 15036 // CountryCodeMg is a CountryCode enum value 15037 CountryCodeMg = "MG" 15038 15039 // CountryCodeMw is a CountryCode enum value 15040 CountryCodeMw = "MW" 15041 15042 // CountryCodeMy is a CountryCode enum value 15043 CountryCodeMy = "MY" 15044 15045 // CountryCodeMv is a CountryCode enum value 15046 CountryCodeMv = "MV" 15047 15048 // CountryCodeMl is a CountryCode enum value 15049 CountryCodeMl = "ML" 15050 15051 // CountryCodeMt is a CountryCode enum value 15052 CountryCodeMt = "MT" 15053 15054 // CountryCodeMh is a CountryCode enum value 15055 CountryCodeMh = "MH" 15056 15057 // CountryCodeMq is a CountryCode enum value 15058 CountryCodeMq = "MQ" 15059 15060 // CountryCodeMr is a CountryCode enum value 15061 CountryCodeMr = "MR" 15062 15063 // CountryCodeMu is a CountryCode enum value 15064 CountryCodeMu = "MU" 15065 15066 // CountryCodeYt is a CountryCode enum value 15067 CountryCodeYt = "YT" 15068 15069 // CountryCodeMx is a CountryCode enum value 15070 CountryCodeMx = "MX" 15071 15072 // CountryCodeFm is a CountryCode enum value 15073 CountryCodeFm = "FM" 15074 15075 // CountryCodeMd is a CountryCode enum value 15076 CountryCodeMd = "MD" 15077 15078 // CountryCodeMc is a CountryCode enum value 15079 CountryCodeMc = "MC" 15080 15081 // CountryCodeMn is a CountryCode enum value 15082 CountryCodeMn = "MN" 15083 15084 // CountryCodeMe is a CountryCode enum value 15085 CountryCodeMe = "ME" 15086 15087 // CountryCodeMs is a CountryCode enum value 15088 CountryCodeMs = "MS" 15089 15090 // CountryCodeMa is a CountryCode enum value 15091 CountryCodeMa = "MA" 15092 15093 // CountryCodeMz is a CountryCode enum value 15094 CountryCodeMz = "MZ" 15095 15096 // CountryCodeMm is a CountryCode enum value 15097 CountryCodeMm = "MM" 15098 15099 // CountryCodeNa is a CountryCode enum value 15100 CountryCodeNa = "NA" 15101 15102 // CountryCodeNr is a CountryCode enum value 15103 CountryCodeNr = "NR" 15104 15105 // CountryCodeNp is a CountryCode enum value 15106 CountryCodeNp = "NP" 15107 15108 // CountryCodeNl is a CountryCode enum value 15109 CountryCodeNl = "NL" 15110 15111 // CountryCodeNc is a CountryCode enum value 15112 CountryCodeNc = "NC" 15113 15114 // CountryCodeNz is a CountryCode enum value 15115 CountryCodeNz = "NZ" 15116 15117 // CountryCodeNi is a CountryCode enum value 15118 CountryCodeNi = "NI" 15119 15120 // CountryCodeNe is a CountryCode enum value 15121 CountryCodeNe = "NE" 15122 15123 // CountryCodeNg is a CountryCode enum value 15124 CountryCodeNg = "NG" 15125 15126 // CountryCodeNu is a CountryCode enum value 15127 CountryCodeNu = "NU" 15128 15129 // CountryCodeNf is a CountryCode enum value 15130 CountryCodeNf = "NF" 15131 15132 // CountryCodeMp is a CountryCode enum value 15133 CountryCodeMp = "MP" 15134 15135 // CountryCodeNo is a CountryCode enum value 15136 CountryCodeNo = "NO" 15137 15138 // CountryCodeOm is a CountryCode enum value 15139 CountryCodeOm = "OM" 15140 15141 // CountryCodePk is a CountryCode enum value 15142 CountryCodePk = "PK" 15143 15144 // CountryCodePw is a CountryCode enum value 15145 CountryCodePw = "PW" 15146 15147 // CountryCodePs is a CountryCode enum value 15148 CountryCodePs = "PS" 15149 15150 // CountryCodePa is a CountryCode enum value 15151 CountryCodePa = "PA" 15152 15153 // CountryCodePg is a CountryCode enum value 15154 CountryCodePg = "PG" 15155 15156 // CountryCodePy is a CountryCode enum value 15157 CountryCodePy = "PY" 15158 15159 // CountryCodePe is a CountryCode enum value 15160 CountryCodePe = "PE" 15161 15162 // CountryCodePh is a CountryCode enum value 15163 CountryCodePh = "PH" 15164 15165 // CountryCodePn is a CountryCode enum value 15166 CountryCodePn = "PN" 15167 15168 // CountryCodePl is a CountryCode enum value 15169 CountryCodePl = "PL" 15170 15171 // CountryCodePt is a CountryCode enum value 15172 CountryCodePt = "PT" 15173 15174 // CountryCodePr is a CountryCode enum value 15175 CountryCodePr = "PR" 15176 15177 // CountryCodeQa is a CountryCode enum value 15178 CountryCodeQa = "QA" 15179 15180 // CountryCodeRe is a CountryCode enum value 15181 CountryCodeRe = "RE" 15182 15183 // CountryCodeRo is a CountryCode enum value 15184 CountryCodeRo = "RO" 15185 15186 // CountryCodeRu is a CountryCode enum value 15187 CountryCodeRu = "RU" 15188 15189 // CountryCodeRw is a CountryCode enum value 15190 CountryCodeRw = "RW" 15191 15192 // CountryCodeBl is a CountryCode enum value 15193 CountryCodeBl = "BL" 15194 15195 // CountryCodeSh is a CountryCode enum value 15196 CountryCodeSh = "SH" 15197 15198 // CountryCodeKn is a CountryCode enum value 15199 CountryCodeKn = "KN" 15200 15201 // CountryCodeLc is a CountryCode enum value 15202 CountryCodeLc = "LC" 15203 15204 // CountryCodeMf is a CountryCode enum value 15205 CountryCodeMf = "MF" 15206 15207 // CountryCodePm is a CountryCode enum value 15208 CountryCodePm = "PM" 15209 15210 // CountryCodeVc is a CountryCode enum value 15211 CountryCodeVc = "VC" 15212 15213 // CountryCodeWs is a CountryCode enum value 15214 CountryCodeWs = "WS" 15215 15216 // CountryCodeSm is a CountryCode enum value 15217 CountryCodeSm = "SM" 15218 15219 // CountryCodeSt is a CountryCode enum value 15220 CountryCodeSt = "ST" 15221 15222 // CountryCodeSa is a CountryCode enum value 15223 CountryCodeSa = "SA" 15224 15225 // CountryCodeSn is a CountryCode enum value 15226 CountryCodeSn = "SN" 15227 15228 // CountryCodeRs is a CountryCode enum value 15229 CountryCodeRs = "RS" 15230 15231 // CountryCodeSc is a CountryCode enum value 15232 CountryCodeSc = "SC" 15233 15234 // CountryCodeSl is a CountryCode enum value 15235 CountryCodeSl = "SL" 15236 15237 // CountryCodeSg is a CountryCode enum value 15238 CountryCodeSg = "SG" 15239 15240 // CountryCodeSx is a CountryCode enum value 15241 CountryCodeSx = "SX" 15242 15243 // CountryCodeSk is a CountryCode enum value 15244 CountryCodeSk = "SK" 15245 15246 // CountryCodeSi is a CountryCode enum value 15247 CountryCodeSi = "SI" 15248 15249 // CountryCodeSb is a CountryCode enum value 15250 CountryCodeSb = "SB" 15251 15252 // CountryCodeSo is a CountryCode enum value 15253 CountryCodeSo = "SO" 15254 15255 // CountryCodeZa is a CountryCode enum value 15256 CountryCodeZa = "ZA" 15257 15258 // CountryCodeGs is a CountryCode enum value 15259 CountryCodeGs = "GS" 15260 15261 // CountryCodeSs is a CountryCode enum value 15262 CountryCodeSs = "SS" 15263 15264 // CountryCodeEs is a CountryCode enum value 15265 CountryCodeEs = "ES" 15266 15267 // CountryCodeLk is a CountryCode enum value 15268 CountryCodeLk = "LK" 15269 15270 // CountryCodeSd is a CountryCode enum value 15271 CountryCodeSd = "SD" 15272 15273 // CountryCodeSr is a CountryCode enum value 15274 CountryCodeSr = "SR" 15275 15276 // CountryCodeSj is a CountryCode enum value 15277 CountryCodeSj = "SJ" 15278 15279 // CountryCodeSz is a CountryCode enum value 15280 CountryCodeSz = "SZ" 15281 15282 // CountryCodeSe is a CountryCode enum value 15283 CountryCodeSe = "SE" 15284 15285 // CountryCodeCh is a CountryCode enum value 15286 CountryCodeCh = "CH" 15287 15288 // CountryCodeSy is a CountryCode enum value 15289 CountryCodeSy = "SY" 15290 15291 // CountryCodeTw is a CountryCode enum value 15292 CountryCodeTw = "TW" 15293 15294 // CountryCodeTj is a CountryCode enum value 15295 CountryCodeTj = "TJ" 15296 15297 // CountryCodeTz is a CountryCode enum value 15298 CountryCodeTz = "TZ" 15299 15300 // CountryCodeTh is a CountryCode enum value 15301 CountryCodeTh = "TH" 15302 15303 // CountryCodeTl is a CountryCode enum value 15304 CountryCodeTl = "TL" 15305 15306 // CountryCodeTg is a CountryCode enum value 15307 CountryCodeTg = "TG" 15308 15309 // CountryCodeTk is a CountryCode enum value 15310 CountryCodeTk = "TK" 15311 15312 // CountryCodeTo is a CountryCode enum value 15313 CountryCodeTo = "TO" 15314 15315 // CountryCodeTt is a CountryCode enum value 15316 CountryCodeTt = "TT" 15317 15318 // CountryCodeTn is a CountryCode enum value 15319 CountryCodeTn = "TN" 15320 15321 // CountryCodeTr is a CountryCode enum value 15322 CountryCodeTr = "TR" 15323 15324 // CountryCodeTm is a CountryCode enum value 15325 CountryCodeTm = "TM" 15326 15327 // CountryCodeTc is a CountryCode enum value 15328 CountryCodeTc = "TC" 15329 15330 // CountryCodeTv is a CountryCode enum value 15331 CountryCodeTv = "TV" 15332 15333 // CountryCodeUg is a CountryCode enum value 15334 CountryCodeUg = "UG" 15335 15336 // CountryCodeUa is a CountryCode enum value 15337 CountryCodeUa = "UA" 15338 15339 // CountryCodeAe is a CountryCode enum value 15340 CountryCodeAe = "AE" 15341 15342 // CountryCodeGb is a CountryCode enum value 15343 CountryCodeGb = "GB" 15344 15345 // CountryCodeUs is a CountryCode enum value 15346 CountryCodeUs = "US" 15347 15348 // CountryCodeUm is a CountryCode enum value 15349 CountryCodeUm = "UM" 15350 15351 // CountryCodeUy is a CountryCode enum value 15352 CountryCodeUy = "UY" 15353 15354 // CountryCodeUz is a CountryCode enum value 15355 CountryCodeUz = "UZ" 15356 15357 // CountryCodeVu is a CountryCode enum value 15358 CountryCodeVu = "VU" 15359 15360 // CountryCodeVe is a CountryCode enum value 15361 CountryCodeVe = "VE" 15362 15363 // CountryCodeVn is a CountryCode enum value 15364 CountryCodeVn = "VN" 15365 15366 // CountryCodeVg is a CountryCode enum value 15367 CountryCodeVg = "VG" 15368 15369 // CountryCodeVi is a CountryCode enum value 15370 CountryCodeVi = "VI" 15371 15372 // CountryCodeWf is a CountryCode enum value 15373 CountryCodeWf = "WF" 15374 15375 // CountryCodeEh is a CountryCode enum value 15376 CountryCodeEh = "EH" 15377 15378 // CountryCodeYe is a CountryCode enum value 15379 CountryCodeYe = "YE" 15380 15381 // CountryCodeZm is a CountryCode enum value 15382 CountryCodeZm = "ZM" 15383 15384 // CountryCodeZw is a CountryCode enum value 15385 CountryCodeZw = "ZW" 15386) 15387 15388// CountryCode_Values returns all elements of the CountryCode enum 15389func CountryCode_Values() []string { 15390 return []string{ 15391 CountryCodeAf, 15392 CountryCodeAx, 15393 CountryCodeAl, 15394 CountryCodeDz, 15395 CountryCodeAs, 15396 CountryCodeAd, 15397 CountryCodeAo, 15398 CountryCodeAi, 15399 CountryCodeAq, 15400 CountryCodeAg, 15401 CountryCodeAr, 15402 CountryCodeAm, 15403 CountryCodeAw, 15404 CountryCodeAu, 15405 CountryCodeAt, 15406 CountryCodeAz, 15407 CountryCodeBs, 15408 CountryCodeBh, 15409 CountryCodeBd, 15410 CountryCodeBb, 15411 CountryCodeBy, 15412 CountryCodeBe, 15413 CountryCodeBz, 15414 CountryCodeBj, 15415 CountryCodeBm, 15416 CountryCodeBt, 15417 CountryCodeBo, 15418 CountryCodeBq, 15419 CountryCodeBa, 15420 CountryCodeBw, 15421 CountryCodeBv, 15422 CountryCodeBr, 15423 CountryCodeIo, 15424 CountryCodeBn, 15425 CountryCodeBg, 15426 CountryCodeBf, 15427 CountryCodeBi, 15428 CountryCodeKh, 15429 CountryCodeCm, 15430 CountryCodeCa, 15431 CountryCodeCv, 15432 CountryCodeKy, 15433 CountryCodeCf, 15434 CountryCodeTd, 15435 CountryCodeCl, 15436 CountryCodeCn, 15437 CountryCodeCx, 15438 CountryCodeCc, 15439 CountryCodeCo, 15440 CountryCodeKm, 15441 CountryCodeCg, 15442 CountryCodeCd, 15443 CountryCodeCk, 15444 CountryCodeCr, 15445 CountryCodeCi, 15446 CountryCodeHr, 15447 CountryCodeCu, 15448 CountryCodeCw, 15449 CountryCodeCy, 15450 CountryCodeCz, 15451 CountryCodeDk, 15452 CountryCodeDj, 15453 CountryCodeDm, 15454 CountryCodeDo, 15455 CountryCodeEc, 15456 CountryCodeEg, 15457 CountryCodeSv, 15458 CountryCodeGq, 15459 CountryCodeEr, 15460 CountryCodeEe, 15461 CountryCodeEt, 15462 CountryCodeFk, 15463 CountryCodeFo, 15464 CountryCodeFj, 15465 CountryCodeFi, 15466 CountryCodeFr, 15467 CountryCodeGf, 15468 CountryCodePf, 15469 CountryCodeTf, 15470 CountryCodeGa, 15471 CountryCodeGm, 15472 CountryCodeGe, 15473 CountryCodeDe, 15474 CountryCodeGh, 15475 CountryCodeGi, 15476 CountryCodeGr, 15477 CountryCodeGl, 15478 CountryCodeGd, 15479 CountryCodeGp, 15480 CountryCodeGu, 15481 CountryCodeGt, 15482 CountryCodeGg, 15483 CountryCodeGn, 15484 CountryCodeGw, 15485 CountryCodeGy, 15486 CountryCodeHt, 15487 CountryCodeHm, 15488 CountryCodeVa, 15489 CountryCodeHn, 15490 CountryCodeHk, 15491 CountryCodeHu, 15492 CountryCodeIs, 15493 CountryCodeIn, 15494 CountryCodeId, 15495 CountryCodeIr, 15496 CountryCodeIq, 15497 CountryCodeIe, 15498 CountryCodeIm, 15499 CountryCodeIl, 15500 CountryCodeIt, 15501 CountryCodeJm, 15502 CountryCodeJp, 15503 CountryCodeJe, 15504 CountryCodeJo, 15505 CountryCodeKz, 15506 CountryCodeKe, 15507 CountryCodeKi, 15508 CountryCodeKp, 15509 CountryCodeKr, 15510 CountryCodeKw, 15511 CountryCodeKg, 15512 CountryCodeLa, 15513 CountryCodeLv, 15514 CountryCodeLb, 15515 CountryCodeLs, 15516 CountryCodeLr, 15517 CountryCodeLy, 15518 CountryCodeLi, 15519 CountryCodeLt, 15520 CountryCodeLu, 15521 CountryCodeMo, 15522 CountryCodeMk, 15523 CountryCodeMg, 15524 CountryCodeMw, 15525 CountryCodeMy, 15526 CountryCodeMv, 15527 CountryCodeMl, 15528 CountryCodeMt, 15529 CountryCodeMh, 15530 CountryCodeMq, 15531 CountryCodeMr, 15532 CountryCodeMu, 15533 CountryCodeYt, 15534 CountryCodeMx, 15535 CountryCodeFm, 15536 CountryCodeMd, 15537 CountryCodeMc, 15538 CountryCodeMn, 15539 CountryCodeMe, 15540 CountryCodeMs, 15541 CountryCodeMa, 15542 CountryCodeMz, 15543 CountryCodeMm, 15544 CountryCodeNa, 15545 CountryCodeNr, 15546 CountryCodeNp, 15547 CountryCodeNl, 15548 CountryCodeNc, 15549 CountryCodeNz, 15550 CountryCodeNi, 15551 CountryCodeNe, 15552 CountryCodeNg, 15553 CountryCodeNu, 15554 CountryCodeNf, 15555 CountryCodeMp, 15556 CountryCodeNo, 15557 CountryCodeOm, 15558 CountryCodePk, 15559 CountryCodePw, 15560 CountryCodePs, 15561 CountryCodePa, 15562 CountryCodePg, 15563 CountryCodePy, 15564 CountryCodePe, 15565 CountryCodePh, 15566 CountryCodePn, 15567 CountryCodePl, 15568 CountryCodePt, 15569 CountryCodePr, 15570 CountryCodeQa, 15571 CountryCodeRe, 15572 CountryCodeRo, 15573 CountryCodeRu, 15574 CountryCodeRw, 15575 CountryCodeBl, 15576 CountryCodeSh, 15577 CountryCodeKn, 15578 CountryCodeLc, 15579 CountryCodeMf, 15580 CountryCodePm, 15581 CountryCodeVc, 15582 CountryCodeWs, 15583 CountryCodeSm, 15584 CountryCodeSt, 15585 CountryCodeSa, 15586 CountryCodeSn, 15587 CountryCodeRs, 15588 CountryCodeSc, 15589 CountryCodeSl, 15590 CountryCodeSg, 15591 CountryCodeSx, 15592 CountryCodeSk, 15593 CountryCodeSi, 15594 CountryCodeSb, 15595 CountryCodeSo, 15596 CountryCodeZa, 15597 CountryCodeGs, 15598 CountryCodeSs, 15599 CountryCodeEs, 15600 CountryCodeLk, 15601 CountryCodeSd, 15602 CountryCodeSr, 15603 CountryCodeSj, 15604 CountryCodeSz, 15605 CountryCodeSe, 15606 CountryCodeCh, 15607 CountryCodeSy, 15608 CountryCodeTw, 15609 CountryCodeTj, 15610 CountryCodeTz, 15611 CountryCodeTh, 15612 CountryCodeTl, 15613 CountryCodeTg, 15614 CountryCodeTk, 15615 CountryCodeTo, 15616 CountryCodeTt, 15617 CountryCodeTn, 15618 CountryCodeTr, 15619 CountryCodeTm, 15620 CountryCodeTc, 15621 CountryCodeTv, 15622 CountryCodeUg, 15623 CountryCodeUa, 15624 CountryCodeAe, 15625 CountryCodeGb, 15626 CountryCodeUs, 15627 CountryCodeUm, 15628 CountryCodeUy, 15629 CountryCodeUz, 15630 CountryCodeVu, 15631 CountryCodeVe, 15632 CountryCodeVn, 15633 CountryCodeVg, 15634 CountryCodeVi, 15635 CountryCodeWf, 15636 CountryCodeEh, 15637 CountryCodeYe, 15638 CountryCodeZm, 15639 CountryCodeZw, 15640 } 15641} 15642 15643const ( 15644 // FallbackBehaviorMatch is a FallbackBehavior enum value 15645 FallbackBehaviorMatch = "MATCH" 15646 15647 // FallbackBehaviorNoMatch is a FallbackBehavior enum value 15648 FallbackBehaviorNoMatch = "NO_MATCH" 15649) 15650 15651// FallbackBehavior_Values returns all elements of the FallbackBehavior enum 15652func FallbackBehavior_Values() []string { 15653 return []string{ 15654 FallbackBehaviorMatch, 15655 FallbackBehaviorNoMatch, 15656 } 15657} 15658 15659const ( 15660 // ForwardedIPPositionFirst is a ForwardedIPPosition enum value 15661 ForwardedIPPositionFirst = "FIRST" 15662 15663 // ForwardedIPPositionLast is a ForwardedIPPosition enum value 15664 ForwardedIPPositionLast = "LAST" 15665 15666 // ForwardedIPPositionAny is a ForwardedIPPosition enum value 15667 ForwardedIPPositionAny = "ANY" 15668) 15669 15670// ForwardedIPPosition_Values returns all elements of the ForwardedIPPosition enum 15671func ForwardedIPPosition_Values() []string { 15672 return []string{ 15673 ForwardedIPPositionFirst, 15674 ForwardedIPPositionLast, 15675 ForwardedIPPositionAny, 15676 } 15677} 15678 15679const ( 15680 // IPAddressVersionIpv4 is a IPAddressVersion enum value 15681 IPAddressVersionIpv4 = "IPV4" 15682 15683 // IPAddressVersionIpv6 is a IPAddressVersion enum value 15684 IPAddressVersionIpv6 = "IPV6" 15685) 15686 15687// IPAddressVersion_Values returns all elements of the IPAddressVersion enum 15688func IPAddressVersion_Values() []string { 15689 return []string{ 15690 IPAddressVersionIpv4, 15691 IPAddressVersionIpv6, 15692 } 15693} 15694 15695const ( 15696 // ParameterExceptionFieldWebAcl is a ParameterExceptionField enum value 15697 ParameterExceptionFieldWebAcl = "WEB_ACL" 15698 15699 // ParameterExceptionFieldRuleGroup is a ParameterExceptionField enum value 15700 ParameterExceptionFieldRuleGroup = "RULE_GROUP" 15701 15702 // ParameterExceptionFieldRegexPatternSet is a ParameterExceptionField enum value 15703 ParameterExceptionFieldRegexPatternSet = "REGEX_PATTERN_SET" 15704 15705 // ParameterExceptionFieldIpSet is a ParameterExceptionField enum value 15706 ParameterExceptionFieldIpSet = "IP_SET" 15707 15708 // ParameterExceptionFieldManagedRuleSet is a ParameterExceptionField enum value 15709 ParameterExceptionFieldManagedRuleSet = "MANAGED_RULE_SET" 15710 15711 // ParameterExceptionFieldRule is a ParameterExceptionField enum value 15712 ParameterExceptionFieldRule = "RULE" 15713 15714 // ParameterExceptionFieldExcludedRule is a ParameterExceptionField enum value 15715 ParameterExceptionFieldExcludedRule = "EXCLUDED_RULE" 15716 15717 // ParameterExceptionFieldStatement is a ParameterExceptionField enum value 15718 ParameterExceptionFieldStatement = "STATEMENT" 15719 15720 // ParameterExceptionFieldByteMatchStatement is a ParameterExceptionField enum value 15721 ParameterExceptionFieldByteMatchStatement = "BYTE_MATCH_STATEMENT" 15722 15723 // ParameterExceptionFieldSqliMatchStatement is a ParameterExceptionField enum value 15724 ParameterExceptionFieldSqliMatchStatement = "SQLI_MATCH_STATEMENT" 15725 15726 // ParameterExceptionFieldXssMatchStatement is a ParameterExceptionField enum value 15727 ParameterExceptionFieldXssMatchStatement = "XSS_MATCH_STATEMENT" 15728 15729 // ParameterExceptionFieldSizeConstraintStatement is a ParameterExceptionField enum value 15730 ParameterExceptionFieldSizeConstraintStatement = "SIZE_CONSTRAINT_STATEMENT" 15731 15732 // ParameterExceptionFieldGeoMatchStatement is a ParameterExceptionField enum value 15733 ParameterExceptionFieldGeoMatchStatement = "GEO_MATCH_STATEMENT" 15734 15735 // ParameterExceptionFieldRateBasedStatement is a ParameterExceptionField enum value 15736 ParameterExceptionFieldRateBasedStatement = "RATE_BASED_STATEMENT" 15737 15738 // ParameterExceptionFieldRuleGroupReferenceStatement is a ParameterExceptionField enum value 15739 ParameterExceptionFieldRuleGroupReferenceStatement = "RULE_GROUP_REFERENCE_STATEMENT" 15740 15741 // ParameterExceptionFieldRegexPatternReferenceStatement is a ParameterExceptionField enum value 15742 ParameterExceptionFieldRegexPatternReferenceStatement = "REGEX_PATTERN_REFERENCE_STATEMENT" 15743 15744 // ParameterExceptionFieldIpSetReferenceStatement is a ParameterExceptionField enum value 15745 ParameterExceptionFieldIpSetReferenceStatement = "IP_SET_REFERENCE_STATEMENT" 15746 15747 // ParameterExceptionFieldManagedRuleSetStatement is a ParameterExceptionField enum value 15748 ParameterExceptionFieldManagedRuleSetStatement = "MANAGED_RULE_SET_STATEMENT" 15749 15750 // ParameterExceptionFieldAndStatement is a ParameterExceptionField enum value 15751 ParameterExceptionFieldAndStatement = "AND_STATEMENT" 15752 15753 // ParameterExceptionFieldOrStatement is a ParameterExceptionField enum value 15754 ParameterExceptionFieldOrStatement = "OR_STATEMENT" 15755 15756 // ParameterExceptionFieldNotStatement is a ParameterExceptionField enum value 15757 ParameterExceptionFieldNotStatement = "NOT_STATEMENT" 15758 15759 // ParameterExceptionFieldIpAddress is a ParameterExceptionField enum value 15760 ParameterExceptionFieldIpAddress = "IP_ADDRESS" 15761 15762 // ParameterExceptionFieldIpAddressVersion is a ParameterExceptionField enum value 15763 ParameterExceptionFieldIpAddressVersion = "IP_ADDRESS_VERSION" 15764 15765 // ParameterExceptionFieldFieldToMatch is a ParameterExceptionField enum value 15766 ParameterExceptionFieldFieldToMatch = "FIELD_TO_MATCH" 15767 15768 // ParameterExceptionFieldTextTransformation is a ParameterExceptionField enum value 15769 ParameterExceptionFieldTextTransformation = "TEXT_TRANSFORMATION" 15770 15771 // ParameterExceptionFieldSingleQueryArgument is a ParameterExceptionField enum value 15772 ParameterExceptionFieldSingleQueryArgument = "SINGLE_QUERY_ARGUMENT" 15773 15774 // ParameterExceptionFieldSingleHeader is a ParameterExceptionField enum value 15775 ParameterExceptionFieldSingleHeader = "SINGLE_HEADER" 15776 15777 // ParameterExceptionFieldDefaultAction is a ParameterExceptionField enum value 15778 ParameterExceptionFieldDefaultAction = "DEFAULT_ACTION" 15779 15780 // ParameterExceptionFieldRuleAction is a ParameterExceptionField enum value 15781 ParameterExceptionFieldRuleAction = "RULE_ACTION" 15782 15783 // ParameterExceptionFieldEntityLimit is a ParameterExceptionField enum value 15784 ParameterExceptionFieldEntityLimit = "ENTITY_LIMIT" 15785 15786 // ParameterExceptionFieldOverrideAction is a ParameterExceptionField enum value 15787 ParameterExceptionFieldOverrideAction = "OVERRIDE_ACTION" 15788 15789 // ParameterExceptionFieldScopeValue is a ParameterExceptionField enum value 15790 ParameterExceptionFieldScopeValue = "SCOPE_VALUE" 15791 15792 // ParameterExceptionFieldResourceArn is a ParameterExceptionField enum value 15793 ParameterExceptionFieldResourceArn = "RESOURCE_ARN" 15794 15795 // ParameterExceptionFieldResourceType is a ParameterExceptionField enum value 15796 ParameterExceptionFieldResourceType = "RESOURCE_TYPE" 15797 15798 // ParameterExceptionFieldTags is a ParameterExceptionField enum value 15799 ParameterExceptionFieldTags = "TAGS" 15800 15801 // ParameterExceptionFieldTagKeys is a ParameterExceptionField enum value 15802 ParameterExceptionFieldTagKeys = "TAG_KEYS" 15803 15804 // ParameterExceptionFieldMetricName is a ParameterExceptionField enum value 15805 ParameterExceptionFieldMetricName = "METRIC_NAME" 15806 15807 // ParameterExceptionFieldFirewallManagerStatement is a ParameterExceptionField enum value 15808 ParameterExceptionFieldFirewallManagerStatement = "FIREWALL_MANAGER_STATEMENT" 15809 15810 // ParameterExceptionFieldFallbackBehavior is a ParameterExceptionField enum value 15811 ParameterExceptionFieldFallbackBehavior = "FALLBACK_BEHAVIOR" 15812 15813 // ParameterExceptionFieldPosition is a ParameterExceptionField enum value 15814 ParameterExceptionFieldPosition = "POSITION" 15815 15816 // ParameterExceptionFieldForwardedIpConfig is a ParameterExceptionField enum value 15817 ParameterExceptionFieldForwardedIpConfig = "FORWARDED_IP_CONFIG" 15818 15819 // ParameterExceptionFieldIpSetForwardedIpConfig is a ParameterExceptionField enum value 15820 ParameterExceptionFieldIpSetForwardedIpConfig = "IP_SET_FORWARDED_IP_CONFIG" 15821 15822 // ParameterExceptionFieldHeaderName is a ParameterExceptionField enum value 15823 ParameterExceptionFieldHeaderName = "HEADER_NAME" 15824) 15825 15826// ParameterExceptionField_Values returns all elements of the ParameterExceptionField enum 15827func ParameterExceptionField_Values() []string { 15828 return []string{ 15829 ParameterExceptionFieldWebAcl, 15830 ParameterExceptionFieldRuleGroup, 15831 ParameterExceptionFieldRegexPatternSet, 15832 ParameterExceptionFieldIpSet, 15833 ParameterExceptionFieldManagedRuleSet, 15834 ParameterExceptionFieldRule, 15835 ParameterExceptionFieldExcludedRule, 15836 ParameterExceptionFieldStatement, 15837 ParameterExceptionFieldByteMatchStatement, 15838 ParameterExceptionFieldSqliMatchStatement, 15839 ParameterExceptionFieldXssMatchStatement, 15840 ParameterExceptionFieldSizeConstraintStatement, 15841 ParameterExceptionFieldGeoMatchStatement, 15842 ParameterExceptionFieldRateBasedStatement, 15843 ParameterExceptionFieldRuleGroupReferenceStatement, 15844 ParameterExceptionFieldRegexPatternReferenceStatement, 15845 ParameterExceptionFieldIpSetReferenceStatement, 15846 ParameterExceptionFieldManagedRuleSetStatement, 15847 ParameterExceptionFieldAndStatement, 15848 ParameterExceptionFieldOrStatement, 15849 ParameterExceptionFieldNotStatement, 15850 ParameterExceptionFieldIpAddress, 15851 ParameterExceptionFieldIpAddressVersion, 15852 ParameterExceptionFieldFieldToMatch, 15853 ParameterExceptionFieldTextTransformation, 15854 ParameterExceptionFieldSingleQueryArgument, 15855 ParameterExceptionFieldSingleHeader, 15856 ParameterExceptionFieldDefaultAction, 15857 ParameterExceptionFieldRuleAction, 15858 ParameterExceptionFieldEntityLimit, 15859 ParameterExceptionFieldOverrideAction, 15860 ParameterExceptionFieldScopeValue, 15861 ParameterExceptionFieldResourceArn, 15862 ParameterExceptionFieldResourceType, 15863 ParameterExceptionFieldTags, 15864 ParameterExceptionFieldTagKeys, 15865 ParameterExceptionFieldMetricName, 15866 ParameterExceptionFieldFirewallManagerStatement, 15867 ParameterExceptionFieldFallbackBehavior, 15868 ParameterExceptionFieldPosition, 15869 ParameterExceptionFieldForwardedIpConfig, 15870 ParameterExceptionFieldIpSetForwardedIpConfig, 15871 ParameterExceptionFieldHeaderName, 15872 } 15873} 15874 15875const ( 15876 // PositionalConstraintExactly is a PositionalConstraint enum value 15877 PositionalConstraintExactly = "EXACTLY" 15878 15879 // PositionalConstraintStartsWith is a PositionalConstraint enum value 15880 PositionalConstraintStartsWith = "STARTS_WITH" 15881 15882 // PositionalConstraintEndsWith is a PositionalConstraint enum value 15883 PositionalConstraintEndsWith = "ENDS_WITH" 15884 15885 // PositionalConstraintContains is a PositionalConstraint enum value 15886 PositionalConstraintContains = "CONTAINS" 15887 15888 // PositionalConstraintContainsWord is a PositionalConstraint enum value 15889 PositionalConstraintContainsWord = "CONTAINS_WORD" 15890) 15891 15892// PositionalConstraint_Values returns all elements of the PositionalConstraint enum 15893func PositionalConstraint_Values() []string { 15894 return []string{ 15895 PositionalConstraintExactly, 15896 PositionalConstraintStartsWith, 15897 PositionalConstraintEndsWith, 15898 PositionalConstraintContains, 15899 PositionalConstraintContainsWord, 15900 } 15901} 15902 15903const ( 15904 // RateBasedStatementAggregateKeyTypeIp is a RateBasedStatementAggregateKeyType enum value 15905 RateBasedStatementAggregateKeyTypeIp = "IP" 15906 15907 // RateBasedStatementAggregateKeyTypeForwardedIp is a RateBasedStatementAggregateKeyType enum value 15908 RateBasedStatementAggregateKeyTypeForwardedIp = "FORWARDED_IP" 15909) 15910 15911// RateBasedStatementAggregateKeyType_Values returns all elements of the RateBasedStatementAggregateKeyType enum 15912func RateBasedStatementAggregateKeyType_Values() []string { 15913 return []string{ 15914 RateBasedStatementAggregateKeyTypeIp, 15915 RateBasedStatementAggregateKeyTypeForwardedIp, 15916 } 15917} 15918 15919const ( 15920 // ResourceTypeApplicationLoadBalancer is a ResourceType enum value 15921 ResourceTypeApplicationLoadBalancer = "APPLICATION_LOAD_BALANCER" 15922 15923 // ResourceTypeApiGateway is a ResourceType enum value 15924 ResourceTypeApiGateway = "API_GATEWAY" 15925 15926 // ResourceTypeAppsync is a ResourceType enum value 15927 ResourceTypeAppsync = "APPSYNC" 15928) 15929 15930// ResourceType_Values returns all elements of the ResourceType enum 15931func ResourceType_Values() []string { 15932 return []string{ 15933 ResourceTypeApplicationLoadBalancer, 15934 ResourceTypeApiGateway, 15935 ResourceTypeAppsync, 15936 } 15937} 15938 15939const ( 15940 // ScopeCloudfront is a Scope enum value 15941 ScopeCloudfront = "CLOUDFRONT" 15942 15943 // ScopeRegional is a Scope enum value 15944 ScopeRegional = "REGIONAL" 15945) 15946 15947// Scope_Values returns all elements of the Scope enum 15948func Scope_Values() []string { 15949 return []string{ 15950 ScopeCloudfront, 15951 ScopeRegional, 15952 } 15953} 15954 15955const ( 15956 // TextTransformationTypeNone is a TextTransformationType enum value 15957 TextTransformationTypeNone = "NONE" 15958 15959 // TextTransformationTypeCompressWhiteSpace is a TextTransformationType enum value 15960 TextTransformationTypeCompressWhiteSpace = "COMPRESS_WHITE_SPACE" 15961 15962 // TextTransformationTypeHtmlEntityDecode is a TextTransformationType enum value 15963 TextTransformationTypeHtmlEntityDecode = "HTML_ENTITY_DECODE" 15964 15965 // TextTransformationTypeLowercase is a TextTransformationType enum value 15966 TextTransformationTypeLowercase = "LOWERCASE" 15967 15968 // TextTransformationTypeCmdLine is a TextTransformationType enum value 15969 TextTransformationTypeCmdLine = "CMD_LINE" 15970 15971 // TextTransformationTypeUrlDecode is a TextTransformationType enum value 15972 TextTransformationTypeUrlDecode = "URL_DECODE" 15973) 15974 15975// TextTransformationType_Values returns all elements of the TextTransformationType enum 15976func TextTransformationType_Values() []string { 15977 return []string{ 15978 TextTransformationTypeNone, 15979 TextTransformationTypeCompressWhiteSpace, 15980 TextTransformationTypeHtmlEntityDecode, 15981 TextTransformationTypeLowercase, 15982 TextTransformationTypeCmdLine, 15983 TextTransformationTypeUrlDecode, 15984 } 15985} 15986