Class: AWSCDK::WAFv2::CfnWebACL::IPSetReferenceStatementProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::WAFv2::CfnWebACL::IPSetReferenceStatementProperty
- Defined in:
- wa_fv2/cfn_web_acl.rb
Overview
A rule statement used to detect web requests coming from particular IP addresses or address ranges.
To use this, create an IPSet that specifies the addresses you want to detect, then use the ARN of that set in this statement.
Each IP set rule statement references an IP set. You create and maintain the set independent of your rules. This allows you to use the single set in multiple rules. When you update the referenced set, AWS WAF automatically updates all rules that reference it.
Instance Attribute Summary collapse
-
#arn ⇒ String
readonly
The Amazon Resource Name (ARN) of the
IPSetthat this statement references. -
#ip_set_forwarded_ip_config ⇒ AWSCDK::IResolvable, ...
readonly
The configuration for inspecting IP addresses in an HTTP header that you specify, instead of using the IP address that's reported by the web request origin.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(arn:, ip_set_forwarded_ip_config: nil) ⇒ IPSetReferenceStatementProperty
constructor
A new instance of IPSetReferenceStatementProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(arn:, ip_set_forwarded_ip_config: nil) ⇒ IPSetReferenceStatementProperty
Returns a new instance of IPSetReferenceStatementProperty.
3079 3080 3081 3082 3083 3084 |
# File 'wa_fv2/cfn_web_acl.rb', line 3079 def initialize(arn:, ip_set_forwarded_ip_config: nil) @arn = arn Jsii::Type.check_type(@arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "arn") @ip_set_forwarded_ip_config = ip_set_forwarded_ip_config.is_a?(Hash) ? ::AWSCDK::WAFv2::CfnWebACL::IPSetForwardedIPConfigurationProperty.new(**ip_set_forwarded_ip_config.transform_keys(&:to_sym)) : ip_set_forwarded_ip_config Jsii::Type.check_type(@ip_set_forwarded_ip_config, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c193YWZ2Mi5DZm5XZWJBQ0wuSVBTZXRGb3J3YXJkZWRJUENvbmZpZ3VyYXRpb25Qcm9wZXJ0eSJ9XX19")), "ipSetForwardedIpConfig") unless @ip_set_forwarded_ip_config.nil? end |
Instance Attribute Details
#arn ⇒ String (readonly)
The Amazon Resource Name (ARN) of the IPSet that this statement references.
3090 3091 3092 |
# File 'wa_fv2/cfn_web_acl.rb', line 3090 def arn @arn end |
#ip_set_forwarded_ip_config ⇒ AWSCDK::IResolvable, ... (readonly)
The configuration for inspecting IP addresses in an HTTP header that you specify, instead of using the IP address that's reported by the web request origin.
Commonly, this is the X-Forwarded-For (XFF) header, but you can specify any header name.
If the specified header isn't present in the request, AWS WAF doesn't apply the rule to the web request at all.
3099 3100 3101 |
# File 'wa_fv2/cfn_web_acl.rb', line 3099 def ip_set_forwarded_ip_config @ip_set_forwarded_ip_config end |
Class Method Details
.jsii_properties ⇒ Object
3101 3102 3103 3104 3105 3106 |
# File 'wa_fv2/cfn_web_acl.rb', line 3101 def self.jsii_properties { :arn => "arn", :ip_set_forwarded_ip_config => "ipSetForwardedIpConfig", } end |
Instance Method Details
#to_jsii ⇒ Object
3108 3109 3110 3111 3112 3113 3114 3115 |
# File 'wa_fv2/cfn_web_acl.rb', line 3108 def to_jsii result = {} result.merge!({ "arn" => @arn, "ipSetForwardedIpConfig" => @ip_set_forwarded_ip_config, }) result.compact end |