Class: AWSCDK::S3::CfnAccessPoint::PublicAccessBlockConfigurationProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::S3::CfnAccessPoint::PublicAccessBlockConfigurationProperty
- Defined in:
- s3/cfn_access_point.rb
Overview
The PublicAccessBlock configuration that you want to apply to this Amazon S3 bucket.
You can enable the configuration options in any combination. Bucket-level settings work alongside account-level settings (which may inherit from organization-level policies). For more information about when Amazon S3 considers a bucket or object public, see The Meaning of "Public" in the Amazon S3 User Guide .
Instance Attribute Summary collapse
-
#block_public_acls ⇒ Boolean, ...
readonly
Specifies whether Amazon S3 should block public access control lists (ACLs) for this bucket and objects in this bucket.
-
#block_public_policy ⇒ Boolean, ...
readonly
Specifies whether Amazon S3 should block public bucket policies for this bucket.
-
#ignore_public_acls ⇒ Boolean, ...
readonly
Specifies whether Amazon S3 should ignore public ACLs for this bucket and objects in this bucket.
-
#restrict_public_buckets ⇒ Boolean, ...
readonly
Specifies whether Amazon S3 should restrict public bucket policies for this bucket.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(block_public_acls: nil, block_public_policy: nil, ignore_public_acls: nil, restrict_public_buckets: nil) ⇒ PublicAccessBlockConfigurationProperty
constructor
A new instance of PublicAccessBlockConfigurationProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(block_public_acls: nil, block_public_policy: nil, ignore_public_acls: nil, restrict_public_buckets: nil) ⇒ PublicAccessBlockConfigurationProperty
Returns a new instance of PublicAccessBlockConfigurationProperty.
656 657 658 659 660 661 662 663 664 665 |
# File 's3/cfn_access_point.rb', line 656 def initialize(block_public_acls: nil, block_public_policy: nil, ignore_public_acls: nil, restrict_public_buckets: nil) @block_public_acls = block_public_acls Jsii::Type.check_type(@block_public_acls, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "blockPublicAcls") unless @block_public_acls.nil? @block_public_policy = block_public_policy Jsii::Type.check_type(@block_public_policy, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "blockPublicPolicy") unless @block_public_policy.nil? @ignore_public_acls = ignore_public_acls Jsii::Type.check_type(@ignore_public_acls, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "ignorePublicAcls") unless @ignore_public_acls.nil? @restrict_public_buckets = restrict_public_buckets Jsii::Type.check_type(@restrict_public_buckets, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "restrictPublicBuckets") unless @restrict_public_buckets.nil? end |
Instance Attribute Details
#block_public_acls ⇒ Boolean, ... (readonly)
Specifies whether Amazon S3 should block public access control lists (ACLs) for this bucket and objects in this bucket.
Setting this element to TRUE causes the following behavior:
- PUT Bucket ACL and PUT Object ACL calls fail if the specified ACL is public.
- PUT Object calls fail if the request includes a public ACL.
- PUT Bucket calls fail if the request includes a public ACL.
Enabling this setting doesn't affect existing policies or ACLs.
679 680 681 |
# File 's3/cfn_access_point.rb', line 679 def block_public_acls @block_public_acls end |
#block_public_policy ⇒ Boolean, ... (readonly)
Specifies whether Amazon S3 should block public bucket policies for this bucket.
Setting this element to TRUE causes Amazon S3 to reject calls to PUT Bucket policy if the specified bucket policy allows public access.
Enabling this setting doesn't affect existing bucket policies.
688 689 690 |
# File 's3/cfn_access_point.rb', line 688 def block_public_policy @block_public_policy end |
#ignore_public_acls ⇒ Boolean, ... (readonly)
Specifies whether Amazon S3 should ignore public ACLs for this bucket and objects in this bucket.
Setting this element to TRUE causes Amazon S3 to ignore all public ACLs on this bucket and objects in this bucket.
Enabling this setting doesn't affect the persistence of any existing ACLs and doesn't prevent new public ACLs from being set.
697 698 699 |
# File 's3/cfn_access_point.rb', line 697 def ignore_public_acls @ignore_public_acls end |
#restrict_public_buckets ⇒ Boolean, ... (readonly)
Specifies whether Amazon S3 should restrict public bucket policies for this bucket.
Setting this element to TRUE restricts access to this bucket to only AWS service principals and authorized users within this account if the bucket has a public policy.
Enabling this setting doesn't affect previously stored bucket policies, except that public and cross-account access within any public bucket policy, including non-public delegation to specific accounts, is blocked.
706 707 708 |
# File 's3/cfn_access_point.rb', line 706 def restrict_public_buckets @restrict_public_buckets end |
Class Method Details
.jsii_properties ⇒ Object
708 709 710 711 712 713 714 715 |
# File 's3/cfn_access_point.rb', line 708 def self.jsii_properties { :block_public_acls => "blockPublicAcls", :block_public_policy => "blockPublicPolicy", :ignore_public_acls => "ignorePublicAcls", :restrict_public_buckets => "restrictPublicBuckets", } end |
Instance Method Details
#to_jsii ⇒ Object
717 718 719 720 721 722 723 724 725 726 |
# File 's3/cfn_access_point.rb', line 717 def to_jsii result = {} result.merge!({ "blockPublicAcls" => @block_public_acls, "blockPublicPolicy" => @block_public_policy, "ignorePublicAcls" => @ignore_public_acls, "restrictPublicBuckets" => @restrict_public_buckets, }) result.compact end |