This rule ensures that S3 buckets enforce SSL for secure data transfer.
Rule | S3 buckets should enforce SSL |
Framework | NIST 800-53 Revision 5 |
Severity | ✔ Medium |
Rule Description
This rule enforces the use of SSL (Secure Sockets Layer) encryption for S3 buckets to comply with the NIST 800-53 Revision 5 security standard. SSL ensures that data transferred between clients and S3 buckets is encrypted and protected from unauthorized access. This rule helps to maintain the confidentiality and integrity of data stored in S3 buckets.
Troubleshooting Steps
If SSL encryption is not enforced for S3 buckets, the following troubleshooting steps can be followed:
Verify SSL Enforcement: Check the bucket policies or access control lists (ACLs) to ensure that SSL encryption is required.
Check Bucket Configuration: Verify the bucket properties and settings to confirm that SSL encryption is enabled.
Verify SSL Certificate: Ensure that the SSL certificate used by the S3 bucket is valid and up to date.
Necessary Code
There is no specific code required for this rule. It can be enforced through bucket policies or ACLs.
Remediation Steps
Follow these step-by-step instructions to enforce SSL for S3 buckets:
Identify the S3 bucket: Determine the bucket for which SSL enforcement needs to be enabled.
Access the AWS Management Console: Log in to the AWS Management Console using appropriate credentials.
Navigate to the S3 service: Go to the S3 service by selecting it from the list of available services.
Select the target bucket: Find and select the target bucket from the list of buckets displayed.
Access bucket properties: In the bucket properties section, select the "Permissions" tab.
Edit bucket policy: Edit the bucket policy or access control list (ACL) associated with the bucket.
Enforce SSL encryption: Add a statement to the bucket policy or ACL to enforce SSL encryption. Below is an example of a policy statement that can be added:
{ "Version": "2012-10-17", "Id": "EnforceSSLEncryption", "Statement": [ { "Sid": "DenyUnencryptedConnections", "Effect": "Deny", "Principal": "*", "Action": "s3:*", "Resource": [ "arn:aws:s3:::bucket-name", "arn:aws:s3:::bucket-name/*" ], "Condition": { "Bool": { "aws:SecureTransport": "false" } } } ] }
Replace "bucket-name" with the actual name of your S3 bucket.
Save the changes: After adding the policy statement, save the changes to the bucket policy or ACL.
Verify SSL enforcement: Access the S3 bucket using an unencrypted connection (HTTP) and confirm that access is denied.
Test SSL-encrypted access: Access the S3 bucket using an encrypted connection (HTTPS) and ensure that access is allowed.