Class: AWSCDK::WAFv2::CfnWebACL::ResponseInspectionJsonProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
wa_fv2/cfn_web_acl.rb

Overview

Configures inspection of the response JSON.

AWS WAF can inspect the first 65,536 bytes (64 KB) of the response JSON. This is part of the ResponseInspection configuration for AWSManagedRulesATPRuleSet and AWSManagedRulesACFPRuleSet .

Response inspection is available only in web ACLs that protect Amazon CloudFront distributions.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(failure_values:, identifier:, success_values:) ⇒ ResponseInspectionJsonProperty

Returns a new instance of ResponseInspectionJsonProperty.

Parameters:

  • failure_values (Array<String>)

    Values for the specified identifier in the response JSON that indicate a failed login or account creation attempt.

  • identifier (String)

    The identifier for the value to match against in the JSON.

  • success_values (Array<String>)

    Values for the specified identifier in the response JSON that indicate a successful login or account creation attempt.



5295
5296
5297
5298
5299
5300
5301
5302
# File 'wa_fv2/cfn_web_acl.rb', line 5295

def initialize(failure_values:, identifier:, success_values:)
  @failure_values = failure_values
  Jsii::Type.check_type(@failure_values, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "failureValues")
  @identifier = identifier
  Jsii::Type.check_type(@identifier, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "identifier")
  @success_values = success_values
  Jsii::Type.check_type(@success_values, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "successValues")
end

Instance Attribute Details

#failure_valuesArray<String> (readonly)

Values for the specified identifier in the response JSON that indicate a failed login or account creation attempt.

To be counted as a failure, the value must be an exact match, including case. Each value must be unique among the success and failure values.

JSON example: "FailureValues": [ "False", "Failed" ]



5312
5313
5314
# File 'wa_fv2/cfn_web_acl.rb', line 5312

def failure_values
  @failure_values
end

#identifierString (readonly)

The identifier for the value to match against in the JSON.

The identifier must be an exact match, including case.

JSON examples: "Identifier": [ "/login/success" ] and "Identifier": [ "/sign-up/success" ]



5321
5322
5323
# File 'wa_fv2/cfn_web_acl.rb', line 5321

def identifier
  @identifier
end

#success_valuesArray<String> (readonly)

Values for the specified identifier in the response JSON that indicate a successful login or account creation attempt.

To be counted as a success, the value must be an exact match, including case. Each value must be unique among the success and failure values.

JSON example: "SuccessValues": [ "True", "Succeeded" ]



5330
5331
5332
# File 'wa_fv2/cfn_web_acl.rb', line 5330

def success_values
  @success_values
end

Class Method Details

.jsii_propertiesObject



5332
5333
5334
5335
5336
5337
5338
# File 'wa_fv2/cfn_web_acl.rb', line 5332

def self.jsii_properties
  {
    :failure_values => "failureValues",
    :identifier => "identifier",
    :success_values => "successValues",
  }
end

Instance Method Details

#to_jsiiObject



5340
5341
5342
5343
5344
5345
5346
5347
5348
# File 'wa_fv2/cfn_web_acl.rb', line 5340

def to_jsii
  result = {}
  result.merge!({
    "failureValues" => @failure_values,
    "identifier" => @identifier,
    "successValues" => @success_values,
  })
  result.compact
end