@aws-sdk/client-wafv2 3.271.0 → 3.272.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2863,6 +2863,17 @@ const serializeAws_json1_1AssociateWebACLRequest = (input, context) => {
2863
2863
  ...(input.WebACLArn != null && { WebACLArn: input.WebACLArn }),
2864
2864
  };
2865
2865
  };
2866
+ const serializeAws_json1_1AWSManagedRulesATPRuleSet = (input, context) => {
2867
+ return {
2868
+ ...(input.LoginPath != null && { LoginPath: input.LoginPath }),
2869
+ ...(input.RequestInspection != null && {
2870
+ RequestInspection: serializeAws_json1_1RequestInspection(input.RequestInspection, context),
2871
+ }),
2872
+ ...(input.ResponseInspection != null && {
2873
+ ResponseInspection: serializeAws_json1_1ResponseInspection(input.ResponseInspection, context),
2874
+ }),
2875
+ };
2876
+ };
2866
2877
  const serializeAws_json1_1AWSManagedRulesBotControlRuleSet = (input, context) => {
2867
2878
  return {
2868
2879
  ...(input.InspectionLevel != null && { InspectionLevel: input.InspectionLevel }),
@@ -3504,6 +3515,9 @@ const serializeAws_json1_1LoggingFilter = (input, context) => {
3504
3515
  };
3505
3516
  const serializeAws_json1_1ManagedRuleGroupConfig = (input, context) => {
3506
3517
  return {
3518
+ ...(input.AWSManagedRulesATPRuleSet != null && {
3519
+ AWSManagedRulesATPRuleSet: serializeAws_json1_1AWSManagedRulesATPRuleSet(input.AWSManagedRulesATPRuleSet, context),
3520
+ }),
3507
3521
  ...(input.AWSManagedRulesBotControlRuleSet != null && {
3508
3522
  AWSManagedRulesBotControlRuleSet: serializeAws_json1_1AWSManagedRulesBotControlRuleSet(input.AWSManagedRulesBotControlRuleSet, context),
3509
3523
  }),
@@ -3647,6 +3661,127 @@ const serializeAws_json1_1RegularExpressionList = (input, context) => {
3647
3661
  return serializeAws_json1_1Regex(entry, context);
3648
3662
  });
3649
3663
  };
3664
+ const serializeAws_json1_1RequestInspection = (input, context) => {
3665
+ return {
3666
+ ...(input.PasswordField != null && {
3667
+ PasswordField: serializeAws_json1_1PasswordField(input.PasswordField, context),
3668
+ }),
3669
+ ...(input.PayloadType != null && { PayloadType: input.PayloadType }),
3670
+ ...(input.UsernameField != null && {
3671
+ UsernameField: serializeAws_json1_1UsernameField(input.UsernameField, context),
3672
+ }),
3673
+ };
3674
+ };
3675
+ const serializeAws_json1_1ResponseInspection = (input, context) => {
3676
+ return {
3677
+ ...(input.BodyContains != null && {
3678
+ BodyContains: serializeAws_json1_1ResponseInspectionBodyContains(input.BodyContains, context),
3679
+ }),
3680
+ ...(input.Header != null && { Header: serializeAws_json1_1ResponseInspectionHeader(input.Header, context) }),
3681
+ ...(input.Json != null && { Json: serializeAws_json1_1ResponseInspectionJson(input.Json, context) }),
3682
+ ...(input.StatusCode != null && {
3683
+ StatusCode: serializeAws_json1_1ResponseInspectionStatusCode(input.StatusCode, context),
3684
+ }),
3685
+ };
3686
+ };
3687
+ const serializeAws_json1_1ResponseInspectionBodyContains = (input, context) => {
3688
+ return {
3689
+ ...(input.FailureStrings != null && {
3690
+ FailureStrings: serializeAws_json1_1ResponseInspectionBodyContainsFailureStrings(input.FailureStrings, context),
3691
+ }),
3692
+ ...(input.SuccessStrings != null && {
3693
+ SuccessStrings: serializeAws_json1_1ResponseInspectionBodyContainsSuccessStrings(input.SuccessStrings, context),
3694
+ }),
3695
+ };
3696
+ };
3697
+ const serializeAws_json1_1ResponseInspectionBodyContainsFailureStrings = (input, context) => {
3698
+ return input
3699
+ .filter((e) => e != null)
3700
+ .map((entry) => {
3701
+ return entry;
3702
+ });
3703
+ };
3704
+ const serializeAws_json1_1ResponseInspectionBodyContainsSuccessStrings = (input, context) => {
3705
+ return input
3706
+ .filter((e) => e != null)
3707
+ .map((entry) => {
3708
+ return entry;
3709
+ });
3710
+ };
3711
+ const serializeAws_json1_1ResponseInspectionHeader = (input, context) => {
3712
+ return {
3713
+ ...(input.FailureValues != null && {
3714
+ FailureValues: serializeAws_json1_1ResponseInspectionHeaderFailureValues(input.FailureValues, context),
3715
+ }),
3716
+ ...(input.Name != null && { Name: input.Name }),
3717
+ ...(input.SuccessValues != null && {
3718
+ SuccessValues: serializeAws_json1_1ResponseInspectionHeaderSuccessValues(input.SuccessValues, context),
3719
+ }),
3720
+ };
3721
+ };
3722
+ const serializeAws_json1_1ResponseInspectionHeaderFailureValues = (input, context) => {
3723
+ return input
3724
+ .filter((e) => e != null)
3725
+ .map((entry) => {
3726
+ return entry;
3727
+ });
3728
+ };
3729
+ const serializeAws_json1_1ResponseInspectionHeaderSuccessValues = (input, context) => {
3730
+ return input
3731
+ .filter((e) => e != null)
3732
+ .map((entry) => {
3733
+ return entry;
3734
+ });
3735
+ };
3736
+ const serializeAws_json1_1ResponseInspectionJson = (input, context) => {
3737
+ return {
3738
+ ...(input.FailureValues != null && {
3739
+ FailureValues: serializeAws_json1_1ResponseInspectionJsonFailureValues(input.FailureValues, context),
3740
+ }),
3741
+ ...(input.Identifier != null && { Identifier: input.Identifier }),
3742
+ ...(input.SuccessValues != null && {
3743
+ SuccessValues: serializeAws_json1_1ResponseInspectionJsonSuccessValues(input.SuccessValues, context),
3744
+ }),
3745
+ };
3746
+ };
3747
+ const serializeAws_json1_1ResponseInspectionJsonFailureValues = (input, context) => {
3748
+ return input
3749
+ .filter((e) => e != null)
3750
+ .map((entry) => {
3751
+ return entry;
3752
+ });
3753
+ };
3754
+ const serializeAws_json1_1ResponseInspectionJsonSuccessValues = (input, context) => {
3755
+ return input
3756
+ .filter((e) => e != null)
3757
+ .map((entry) => {
3758
+ return entry;
3759
+ });
3760
+ };
3761
+ const serializeAws_json1_1ResponseInspectionStatusCode = (input, context) => {
3762
+ return {
3763
+ ...(input.FailureCodes != null && {
3764
+ FailureCodes: serializeAws_json1_1ResponseInspectionStatusCodeFailureCodes(input.FailureCodes, context),
3765
+ }),
3766
+ ...(input.SuccessCodes != null && {
3767
+ SuccessCodes: serializeAws_json1_1ResponseInspectionStatusCodeSuccessCodes(input.SuccessCodes, context),
3768
+ }),
3769
+ };
3770
+ };
3771
+ const serializeAws_json1_1ResponseInspectionStatusCodeFailureCodes = (input, context) => {
3772
+ return input
3773
+ .filter((e) => e != null)
3774
+ .map((entry) => {
3775
+ return entry;
3776
+ });
3777
+ };
3778
+ const serializeAws_json1_1ResponseInspectionStatusCodeSuccessCodes = (input, context) => {
3779
+ return input
3780
+ .filter((e) => e != null)
3781
+ .map((entry) => {
3782
+ return entry;
3783
+ });
3784
+ };
3650
3785
  const serializeAws_json1_1Rule = (input, context) => {
3651
3786
  return {
3652
3787
  ...(input.Action != null && { Action: serializeAws_json1_1RuleAction(input.Action, context) }),
@@ -3983,6 +4118,17 @@ const deserializeAws_json1_1AndStatement = (output, context) => {
3983
4118
  const deserializeAws_json1_1AssociateWebACLResponse = (output, context) => {
3984
4119
  return {};
3985
4120
  };
4121
+ const deserializeAws_json1_1AWSManagedRulesATPRuleSet = (output, context) => {
4122
+ return {
4123
+ LoginPath: __expectString(output.LoginPath),
4124
+ RequestInspection: output.RequestInspection != null
4125
+ ? deserializeAws_json1_1RequestInspection(output.RequestInspection, context)
4126
+ : undefined,
4127
+ ResponseInspection: output.ResponseInspection != null
4128
+ ? deserializeAws_json1_1ResponseInspection(output.ResponseInspection, context)
4129
+ : undefined,
4130
+ };
4131
+ };
3986
4132
  const deserializeAws_json1_1AWSManagedRulesBotControlRuleSet = (output, context) => {
3987
4133
  return {
3988
4134
  InspectionLevel: __expectString(output.InspectionLevel),
@@ -4711,6 +4857,9 @@ const deserializeAws_json1_1LoggingFilter = (output, context) => {
4711
4857
  };
4712
4858
  const deserializeAws_json1_1ManagedRuleGroupConfig = (output, context) => {
4713
4859
  return {
4860
+ AWSManagedRulesATPRuleSet: output.AWSManagedRulesATPRuleSet != null
4861
+ ? deserializeAws_json1_1AWSManagedRulesATPRuleSet(output.AWSManagedRulesATPRuleSet, context)
4862
+ : undefined,
4714
4863
  AWSManagedRulesBotControlRuleSet: output.AWSManagedRulesBotControlRuleSet != null
4715
4864
  ? deserializeAws_json1_1AWSManagedRulesBotControlRuleSet(output.AWSManagedRulesBotControlRuleSet, context)
4716
4865
  : undefined,
@@ -5009,6 +5158,13 @@ const deserializeAws_json1_1ReleaseSummary = (output, context) => {
5009
5158
  Timestamp: output.Timestamp != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Timestamp))) : undefined,
5010
5159
  };
5011
5160
  };
5161
+ const deserializeAws_json1_1RequestInspection = (output, context) => {
5162
+ return {
5163
+ PasswordField: output.PasswordField != null ? deserializeAws_json1_1PasswordField(output.PasswordField, context) : undefined,
5164
+ PayloadType: __expectString(output.PayloadType),
5165
+ UsernameField: output.UsernameField != null ? deserializeAws_json1_1UsernameField(output.UsernameField, context) : undefined,
5166
+ };
5167
+ };
5012
5168
  const deserializeAws_json1_1ResourceArns = (output, context) => {
5013
5169
  const retVal = (output || [])
5014
5170
  .filter((e) => e != null)
@@ -5020,6 +5176,148 @@ const deserializeAws_json1_1ResourceArns = (output, context) => {
5020
5176
  });
5021
5177
  return retVal;
5022
5178
  };
5179
+ const deserializeAws_json1_1ResponseInspection = (output, context) => {
5180
+ return {
5181
+ BodyContains: output.BodyContains != null
5182
+ ? deserializeAws_json1_1ResponseInspectionBodyContains(output.BodyContains, context)
5183
+ : undefined,
5184
+ Header: output.Header != null ? deserializeAws_json1_1ResponseInspectionHeader(output.Header, context) : undefined,
5185
+ Json: output.Json != null ? deserializeAws_json1_1ResponseInspectionJson(output.Json, context) : undefined,
5186
+ StatusCode: output.StatusCode != null
5187
+ ? deserializeAws_json1_1ResponseInspectionStatusCode(output.StatusCode, context)
5188
+ : undefined,
5189
+ };
5190
+ };
5191
+ const deserializeAws_json1_1ResponseInspectionBodyContains = (output, context) => {
5192
+ return {
5193
+ FailureStrings: output.FailureStrings != null
5194
+ ? deserializeAws_json1_1ResponseInspectionBodyContainsFailureStrings(output.FailureStrings, context)
5195
+ : undefined,
5196
+ SuccessStrings: output.SuccessStrings != null
5197
+ ? deserializeAws_json1_1ResponseInspectionBodyContainsSuccessStrings(output.SuccessStrings, context)
5198
+ : undefined,
5199
+ };
5200
+ };
5201
+ const deserializeAws_json1_1ResponseInspectionBodyContainsFailureStrings = (output, context) => {
5202
+ const retVal = (output || [])
5203
+ .filter((e) => e != null)
5204
+ .map((entry) => {
5205
+ if (entry === null) {
5206
+ return null;
5207
+ }
5208
+ return __expectString(entry);
5209
+ });
5210
+ return retVal;
5211
+ };
5212
+ const deserializeAws_json1_1ResponseInspectionBodyContainsSuccessStrings = (output, context) => {
5213
+ const retVal = (output || [])
5214
+ .filter((e) => e != null)
5215
+ .map((entry) => {
5216
+ if (entry === null) {
5217
+ return null;
5218
+ }
5219
+ return __expectString(entry);
5220
+ });
5221
+ return retVal;
5222
+ };
5223
+ const deserializeAws_json1_1ResponseInspectionHeader = (output, context) => {
5224
+ return {
5225
+ FailureValues: output.FailureValues != null
5226
+ ? deserializeAws_json1_1ResponseInspectionHeaderFailureValues(output.FailureValues, context)
5227
+ : undefined,
5228
+ Name: __expectString(output.Name),
5229
+ SuccessValues: output.SuccessValues != null
5230
+ ? deserializeAws_json1_1ResponseInspectionHeaderSuccessValues(output.SuccessValues, context)
5231
+ : undefined,
5232
+ };
5233
+ };
5234
+ const deserializeAws_json1_1ResponseInspectionHeaderFailureValues = (output, context) => {
5235
+ const retVal = (output || [])
5236
+ .filter((e) => e != null)
5237
+ .map((entry) => {
5238
+ if (entry === null) {
5239
+ return null;
5240
+ }
5241
+ return __expectString(entry);
5242
+ });
5243
+ return retVal;
5244
+ };
5245
+ const deserializeAws_json1_1ResponseInspectionHeaderSuccessValues = (output, context) => {
5246
+ const retVal = (output || [])
5247
+ .filter((e) => e != null)
5248
+ .map((entry) => {
5249
+ if (entry === null) {
5250
+ return null;
5251
+ }
5252
+ return __expectString(entry);
5253
+ });
5254
+ return retVal;
5255
+ };
5256
+ const deserializeAws_json1_1ResponseInspectionJson = (output, context) => {
5257
+ return {
5258
+ FailureValues: output.FailureValues != null
5259
+ ? deserializeAws_json1_1ResponseInspectionJsonFailureValues(output.FailureValues, context)
5260
+ : undefined,
5261
+ Identifier: __expectString(output.Identifier),
5262
+ SuccessValues: output.SuccessValues != null
5263
+ ? deserializeAws_json1_1ResponseInspectionJsonSuccessValues(output.SuccessValues, context)
5264
+ : undefined,
5265
+ };
5266
+ };
5267
+ const deserializeAws_json1_1ResponseInspectionJsonFailureValues = (output, context) => {
5268
+ const retVal = (output || [])
5269
+ .filter((e) => e != null)
5270
+ .map((entry) => {
5271
+ if (entry === null) {
5272
+ return null;
5273
+ }
5274
+ return __expectString(entry);
5275
+ });
5276
+ return retVal;
5277
+ };
5278
+ const deserializeAws_json1_1ResponseInspectionJsonSuccessValues = (output, context) => {
5279
+ const retVal = (output || [])
5280
+ .filter((e) => e != null)
5281
+ .map((entry) => {
5282
+ if (entry === null) {
5283
+ return null;
5284
+ }
5285
+ return __expectString(entry);
5286
+ });
5287
+ return retVal;
5288
+ };
5289
+ const deserializeAws_json1_1ResponseInspectionStatusCode = (output, context) => {
5290
+ return {
5291
+ FailureCodes: output.FailureCodes != null
5292
+ ? deserializeAws_json1_1ResponseInspectionStatusCodeFailureCodes(output.FailureCodes, context)
5293
+ : undefined,
5294
+ SuccessCodes: output.SuccessCodes != null
5295
+ ? deserializeAws_json1_1ResponseInspectionStatusCodeSuccessCodes(output.SuccessCodes, context)
5296
+ : undefined,
5297
+ };
5298
+ };
5299
+ const deserializeAws_json1_1ResponseInspectionStatusCodeFailureCodes = (output, context) => {
5300
+ const retVal = (output || [])
5301
+ .filter((e) => e != null)
5302
+ .map((entry) => {
5303
+ if (entry === null) {
5304
+ return null;
5305
+ }
5306
+ return __expectInt32(entry);
5307
+ });
5308
+ return retVal;
5309
+ };
5310
+ const deserializeAws_json1_1ResponseInspectionStatusCodeSuccessCodes = (output, context) => {
5311
+ const retVal = (output || [])
5312
+ .filter((e) => e != null)
5313
+ .map((entry) => {
5314
+ if (entry === null) {
5315
+ return null;
5316
+ }
5317
+ return __expectInt32(entry);
5318
+ });
5319
+ return retVal;
5320
+ };
5023
5321
  const deserializeAws_json1_1Rule = (output, context) => {
5024
5322
  return {
5025
5323
  Action: output.Action != null ? deserializeAws_json1_1RuleAction(output.Action, context) : undefined,
@@ -64,16 +64,15 @@ import { WAFV2Client } from "./WAFV2Client";
64
64
  * see the <a href="https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html">WAF Developer Guide</a>. </p>
65
65
  * </note>
66
66
  * <p>WAF is a web application firewall that lets you monitor the HTTP and HTTPS
67
- * requests that are forwarded to Amazon CloudFront, an Amazon API Gateway REST API, an Application Load Balancer, an AppSync
68
- * GraphQL API, or an Amazon Cognito user pool. WAF also lets you control access to your content. Based on conditions that
67
+ * requests that are forwarded to an Amazon CloudFront distribution, Amazon API Gateway REST API, Application Load Balancer, AppSync
68
+ * GraphQL API, or Amazon Cognito user pool. WAF also lets you control access to your content,
69
+ * to protect the Amazon Web Services resource that WAF is monitoring. Based on conditions that
69
70
  * you specify, such as the IP addresses that requests originate from or the values of query
70
- * strings, the Amazon API Gateway REST API, CloudFront distribution, the Application Load Balancer, the AppSync GraphQL
71
- * API, or the Amazon Cognito user pool responds to requests either with the requested content or with an HTTP 403 status code
72
- * (Forbidden). You also can configure CloudFront to return a custom error page when a request is
73
- * blocked.</p>
71
+ * strings, the protected resource responds to requests with either the requested content, an HTTP 403 status code
72
+ * (Forbidden), or with a custom response. </p>
74
73
  * <p>This API guide is for developers who need detailed information about WAF API actions,
75
- * data types, and errors. For detailed information about WAF features and an overview of
76
- * how to use WAF, see the <a href="https://docs.aws.amazon.com/waf/latest/developerguide/what-is-aws-waf.html">WAF Developer
74
+ * data types, and errors. For detailed information about WAF features and guidance for configuring and using
75
+ * WAF, see the <a href="https://docs.aws.amazon.com/waf/latest/developerguide/what-is-aws-waf.html">WAF Developer
77
76
  * Guide</a>.</p>
78
77
  * <p>You can make calls using the endpoints listed in <a href="https://docs.aws.amazon.com/general/latest/gr/waf.html">WAF endpoints and quotas</a>. </p>
79
78
  * <ul>
@@ -186,16 +186,15 @@ export interface WAFV2ClientResolvedConfig extends WAFV2ClientResolvedConfigType
186
186
  * see the <a href="https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html">WAF Developer Guide</a>. </p>
187
187
  * </note>
188
188
  * <p>WAF is a web application firewall that lets you monitor the HTTP and HTTPS
189
- * requests that are forwarded to Amazon CloudFront, an Amazon API Gateway REST API, an Application Load Balancer, an AppSync
190
- * GraphQL API, or an Amazon Cognito user pool. WAF also lets you control access to your content. Based on conditions that
189
+ * requests that are forwarded to an Amazon CloudFront distribution, Amazon API Gateway REST API, Application Load Balancer, AppSync
190
+ * GraphQL API, or Amazon Cognito user pool. WAF also lets you control access to your content,
191
+ * to protect the Amazon Web Services resource that WAF is monitoring. Based on conditions that
191
192
  * you specify, such as the IP addresses that requests originate from or the values of query
192
- * strings, the Amazon API Gateway REST API, CloudFront distribution, the Application Load Balancer, the AppSync GraphQL
193
- * API, or the Amazon Cognito user pool responds to requests either with the requested content or with an HTTP 403 status code
194
- * (Forbidden). You also can configure CloudFront to return a custom error page when a request is
195
- * blocked.</p>
193
+ * strings, the protected resource responds to requests with either the requested content, an HTTP 403 status code
194
+ * (Forbidden), or with a custom response. </p>
196
195
  * <p>This API guide is for developers who need detailed information about WAF API actions,
197
- * data types, and errors. For detailed information about WAF features and an overview of
198
- * how to use WAF, see the <a href="https://docs.aws.amazon.com/waf/latest/developerguide/what-is-aws-waf.html">WAF Developer
196
+ * data types, and errors. For detailed information about WAF features and guidance for configuring and using
197
+ * WAF, see the <a href="https://docs.aws.amazon.com/waf/latest/developerguide/what-is-aws-waf.html">WAF Developer
199
198
  * Guide</a>.</p>
200
199
  * <p>You can make calls using the endpoints listed in <a href="https://docs.aws.amazon.com/general/latest/gr/waf.html">WAF endpoints and quotas</a>. </p>
201
200
  * <ul>
@@ -12,7 +12,7 @@ export declare const resolveClientEndpointParameters: <T>(options: T & ClientInp
12
12
  defaultSigningName: string;
13
13
  };
14
14
  export interface EndpointParameters extends __EndpointParameters {
15
- Region: string;
15
+ Region?: string;
16
16
  UseDualStack?: boolean;
17
17
  UseFIPS?: boolean;
18
18
  Endpoint?: string;