Skip to main content
emnode
ComplianceHigh severity

AWS Security Hub · S3

S3.8: Buckets can still be made public; Block Public Access is off

Written and reviewed by Emnode · Last reviewed

What does AWS Security Hub S3.8 check?

S3.8 checks that all four Block Public Access settings are enabled at the bucket level. It reports FAILED if any of BlockPublicAcls, IgnorePublicAcls, BlockPublicPolicy or RestrictPublicBuckets is off, leaving a path for the bucket to be made public.

Why does S3.8 matter?

Public S3 buckets were the dominant source of cloud data leaks for years: Verizon, Accenture, Capital One and more all traced back to the same handful of toggles being left open. With BPA off, a single careless ACL or policy edit silently exposes objects to the entire internet. Turning all four on makes an accidental public grant fail closed.

How do I fix S3.8?

  1. Run put-public-access-block on each failing bucket with all four settings set to true.
  2. For buckets that genuinely need to serve content publicly, front them with CloudFront plus Origin Access Control instead of opening the bucket.
  3. Enable account-level Block Public Access, and add a Config rule or SCP so the toggles cannot be reopened.

Remediation script · bash

# Close the highest-impact public exposure first: databases.
for db in $(aws rds describe-db-instances \
    --query 'DBInstances[?PubliclyAccessible==`true`].DBInstanceIdentifier' --output text); do
  aws rds modify-db-instance --db-instance-identifier "$db" \
    --no-publicly-accessible --apply-immediately
  echo "$db: public access removed"
done

# Ratchet S3 shut at the account level so no bucket can be made public again.
aws s3control put-public-access-block --account-id 123456789012 \
  --public-access-block-configuration \
    'BlockPublicAcls=true,IgnorePublicAcls=true,BlockPublicPolicy=true,RestrictPublicBuckets=true'

Full walkthrough (console steps, edge cases and verification) in the lesson Block public access to AWS resources.

Is S3.8 a false positive?

A static-site bucket served via CloudFront + OAC still passes S3.8: the bucket itself stays locked, so you do not need to disable BPA to host a public site.

Part of the learning pathTrim your network spend
  • S3.1Account-level S3 public access is not fully blocked
  • S3.2Public S3 buckets expose data to anyone on the internet
  • S3.3Buckets can be written to by anyone on the internet
  • S3.5S3 is accepting unencrypted HTTP requests
  • S3.6Bucket policy grants broad access to other AWS accounts
  • S3.9No S3 access logs, so reads and writes go unaudited
  • S3.10Versioned buckets should have lifecycle configurations
  • S3.11Buckets should have event notifications enabled
  • S3.12ACLs should not be used to manage bucket access
  • S3.13Buckets have no lifecycle rules and grow forever
  • S3.15Buckets should have Object Lock enabled
  • S3.17Buckets should be encrypted at rest with KMS keys