[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6GZP77FXKYVVXTHPQD3627Z":3,"skill-same:01M6GZP77FXKYVVXTHPQD3627Z":90},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":22,"publishedAt":43,"linkOnly":44,"markdownContent":45,"markdownBody":46,"frontMatter":47,"refName":52,"commitSha":53,"skillDirectory":54,"forksCount":55,"repositoryHtmlUrl":56,"repositoryHomepageUrl":6,"ownerHtmlUrl":57,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":58,"install":59,"resources":72},"01M6GZP77FXKYVVXTHPQD3627Z","remediating-s3-bucket-misconfiguration",null,"This skill provides step-by-step procedures for identifying and remediating Amazon S3 bucket misconfigurations that expose sensitive data to unauthorized access. It covers enabling S3 Block Public Access at account and bucket levels, auditing bucket policies and ACLs, enforcing encryption, configuring access logging, and deploying automated remediation using AWS Config and Lambda.","micsapp\u002Fmicstec-skills","micsapp","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F82411001?v=4","01M6GWCFQ6D3PV8EHNY62NN5VW","01M6GWCFVE1PA5HG0DKC7AMFJ3",4,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002F_universal\u002Fcybersecurity-skills\u002Fskills\u002Fremediating-s3-bucket-misconfiguration\u002FSKILL.md",[17],{"categoryNo":18,"categoryName":19,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000033","数据分析师","PROFESSION","适用职业",[23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42],"s3","bucket","misconfiguration","remediating s3 bucket misconfiguration","bucket-misconfiguration","for","at","amazon","block","access","aws-config","public-access-block","cybersecurity","s3-security","data-exposure","lambda","remediation","encryption","cloud-security","config","2026-11-10 10:12:30",false,"---\nname: remediating-s3-bucket-misconfiguration\ndescription: >\n  This skill provides step-by-step procedures for identifying and remediating Amazon S3\n  bucket misconfigurations that expose sensitive data to unauthorized access. It covers\n  enabling S3 Block Public Access at account and bucket levels, auditing bucket policies\n  and ACLs, enforcing encryption, configuring access logging, and deploying automated\n  remediation using AWS Config and Lambda.\ndomain: cybersecurity\nsubdomain: cloud-security\ntags: [s3-security, bucket-misconfiguration, data-exposure, public-access-block, aws-config]\nversion: 1.0.0\nauthor: mahipal\nlicense: Apache-2.0\n---\n\n# Remediating S3 Bucket Misconfiguration\n\n## When to Use\n\n- When AWS Config or Security Hub reports S3 buckets with public access or missing encryption\n- When a security scan reveals S3 bucket policies granting access to Principal \"*\" (everyone)\n- When preparing for a data protection audit requiring evidence of storage security controls\n- When responding to a data exposure incident involving publicly accessible S3 objects\n- When establishing preventive controls for new S3 bucket creation across an AWS Organization\n\n**Do not use** for Azure Blob Storage or GCP Cloud Storage misconfigurations, for S3 data classification (see implementing-cloud-dlp-policy), or for S3 access pattern analysis unrelated to security.\n\n## Prerequisites\n\n- AWS account with S3 administrative permissions (s3:*, s3-outposts:*)\n- AWS Config enabled to evaluate S3 resource compliance\n- AWS CloudTrail logging S3 data events for access auditing\n- Macie enabled for sensitive data discovery in S3 buckets\n\n## Workflow\n\n### Step 1: Identify All Public and Misconfigured Buckets\n\nUse multiple detection methods to identify S3 buckets with public access. Rely on AWS Config rules, S3 Access Analyzer, and Macie rather than manual inspection.\n\n```bash\n# Enable S3 Access Analyzer for external access detection\naws accessanalyzer create-analyzer \\\n  --analyzer-name s3-analyzer \\\n  --type ACCOUNT\n\n# List all S3 buckets with public access indicators\naws s3api list-buckets --query 'Buckets[*].Name' --output text | while read bucket; do\n  public_status=$(aws s3api get-public-access-block --bucket \"$bucket\" 2>\u002Fdev\u002Fnull)\n  if [ $? -ne 0 ]; then\n    echo \"NO PUBLIC ACCESS BLOCK: $bucket\"\n  fi\ndone\n\n# Check bucket policies for public access grants\naws s3api list-buckets --query 'Buckets[*].Name' --output text | while read bucket; do\n  policy=$(aws s3api get-bucket-policy --bucket \"$bucket\" 2>\u002Fdev\u002Fnull)\n  if echo \"$policy\" | grep -q '\"Principal\":\"*\"' 2>\u002Fdev\u002Fnull; then\n    echo \"PUBLIC POLICY DETECTED: $bucket\"\n  fi\ndone\n\n# Use AWS Config to find non-compliant buckets\naws configservice get-compliance-details-by-config-rule \\\n  --config-rule-name s3-bucket-public-read-prohibited \\\n  --compliance-types NON_COMPLIANT \\\n  --query 'EvaluationResults[*].EvaluationResultIdentifier.EvaluationResultQualifier.ResourceId'\n```\n\n### Step 2: Enable S3 Block Public Access at Account Level\n\nApply the four Block Public Access settings at the AWS account level as a safety net. This prevents any bucket in the account from being made public, regardless of individual bucket policies or ACLs.\n\n```bash\n# Enable account-level Block Public Access (all four settings)\naws s3control put-public-access-block \\\n  --account-id 123456789012 \\\n  --public-access-block-configuration '{\n    \"BlockPublicAcls\": true,\n    \"IgnorePublicAcls\": true,\n    \"BlockPublicPolicy\": true,\n    \"RestrictPublicBuckets\": true\n  }'\n\n# Verify account-level settings\naws s3control get-public-access-block --account-id 123456789012\n\n# Enable at bucket level for defense in depth\naws s3api put-public-access-block \\\n  --bucket production-data-bucket \\\n  --public-access-block-configuration '{\n    \"BlockPublicAcls\": true,\n    \"IgnorePublicAcls\": true,\n    \"BlockPublicPolicy\": true,\n    \"RestrictPublicBuckets\": true\n  }'\n```\n\n### Step 3: Audit and Remediate Bucket Policies and ACLs\n\nReview all bucket policies for overly permissive Principal statements and remove legacy ACLs. Enforce bucket ownership controls to disable ACLs entirely.\n\n```bash\n# Remove a public bucket policy\naws s3api delete-bucket-policy --bucket exposed-bucket\n\n# Replace with a restrictive policy\naws s3api put-bucket-policy --bucket exposed-bucket --policy '{\n  \"Version\": \"2012-10-17\",\n  \"Statement\": [\n    {\n      \"Sid\": \"DenyUnencryptedTransport\",\n      \"Effect\": \"Deny\",\n      \"Principal\": \"*\",\n      \"Action\": \"s3:*\",\n      \"Resource\": [\n        \"arn:aws:s3:::exposed-bucket\",\n        \"arn:aws:s3:::exposed-bucket\u002F*\"\n      ],\n      \"Condition\": {\n        \"Bool\": {\"aws:SecureTransport\": \"false\"}\n      }\n    },\n    {\n      \"Sid\": \"AllowOnlyVPCEndpoint\",\n      \"Effect\": \"Deny\",\n      \"Principal\": \"*\",\n      \"Action\": \"s3:*\",\n      \"Resource\": [\n        \"arn:aws:s3:::exposed-bucket\",\n        \"arn:aws:s3:::exposed-bucket\u002F*\"\n      ],\n      \"Condition\": {\n        \"StringNotEquals\": {\"aws:SourceVpce\": \"vpce-0abc123def456\"}\n      }\n    }\n  ]\n}'\n\n# Enforce bucket owner for all objects (disable ACLs)\naws s3api put-bucket-ownership-controls --bucket exposed-bucket \\\n  --ownership-controls '{\"Rules\": [{\"ObjectOwnership\": \"BucketOwnerEnforced\"}]}'\n```\n\n### Step 4: Enforce Default Encryption\n\nEnable default server-side encryption with AWS KMS or AES-256 for all buckets. Add a bucket policy denying unencrypted object uploads.\n\n```bash\n# Enable default KMS encryption\naws s3api put-bucket-encryption --bucket production-data-bucket \\\n  --server-side-encryption-configuration '{\n    \"Rules\": [{\n      \"ApplyServerSideEncryptionByDefault\": {\n        \"SSEAlgorithm\": \"aws:kms\",\n        \"KMSMasterKeyID\": \"arn:aws:kms:us-east-1:123456789012:key\u002Fkey-id\"\n      },\n      \"BucketKeyEnabled\": true\n    }]\n  }'\n\n# Deny unencrypted uploads via bucket policy\naws s3api put-bucket-policy --bucket production-data-bucket --policy '{\n  \"Version\": \"2012-10-17\",\n  \"Statement\": [{\n    \"Sid\": \"DenyUnencryptedUploads\",\n    \"Effect\": \"Deny\",\n    \"Principal\": \"*\",\n    \"Action\": \"s3:PutObject\",\n    \"Resource\": \"arn:aws:s3:::production-data-bucket\u002F*\",\n    \"Condition\": {\n      \"StringNotEquals\": {\"s3:x-amz-server-side-encryption\": [\"aws:kms\", \"AES256\"]}\n    }\n  }]\n}'\n```\n\n### Step 5: Enable Access Logging and Monitoring\n\nConfigure S3 server access logging and CloudTrail data events to track all object-level operations. Set up EventBridge rules to alert on suspicious access patterns.\n\n```bash\n# Enable server access logging\naws s3api put-bucket-logging --bucket production-data-bucket \\\n  --bucket-logging-status '{\n    \"LoggingEnabled\": {\n      \"TargetBucket\": \"s3-access-logs-bucket\",\n      \"TargetPrefix\": \"production-data-bucket\u002F\"\n    }\n  }'\n\n# Enable CloudTrail S3 data events\naws cloudtrail put-event-selectors --trail-name management-trail \\\n  --event-selectors '[{\n    \"ReadWriteType\": \"All\",\n    \"DataResources\": [{\n      \"Type\": \"AWS::S3::Object\",\n      \"Values\": [\"arn:aws:s3:::production-data-bucket\u002F\"]\n    }]\n  }]'\n```\n\n### Step 6: Deploy Preventive Controls with SCP and Config\n\nUse Service Control Policies to prevent disabling Block Public Access across the organization. Deploy AWS Config rules with auto-remediation.\n\n```bash\n# SCP preventing Block Public Access removal\naws organizations create-policy \\\n  --name PreventS3PublicAccess \\\n  --type SERVICE_CONTROL_POLICY \\\n  --content '{\n    \"Version\": \"2012-10-17\",\n    \"Statement\": [{\n      \"Sid\": \"DenyRemovePublicAccessBlock\",\n      \"Effect\": \"Deny\",\n      \"Action\": [\n        \"s3:PutBucketPublicAccessBlock\",\n        \"s3:PutAccountPublicAccessBlock\"\n      ],\n      \"Resource\": \"*\",\n      \"Condition\": {\n        \"StringNotLike\": {\"aws:PrincipalArn\": \"arn:aws:iam::*:role\u002FSecurityAdmin\"}\n      }\n    }]\n  }'\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|------------|\n| S3 Block Public Access | Four account-level and bucket-level settings that override any policy or ACL granting public access to S3 resources |\n| Bucket Policy | JSON-based resource policy attached to an S3 bucket defining who can access what objects under which conditions |\n| ACL (Access Control List) | Legacy S3 access mechanism that grants permissions at the bucket or object level; should be disabled via BucketOwnerEnforced |\n| BucketOwnerEnforced | Ownership control setting that disables all ACLs on a bucket, making the bucket owner the sole authority for access control |\n| Server-Side Encryption | Automatic encryption of objects at rest using AES-256 (SSE-S3), AWS KMS (SSE-KMS), or customer-provided keys (SSE-C) |\n| VPC Endpoint | Private connection between a VPC and S3 that restricts bucket access to traffic originating from within the VPC |\n| S3 Access Analyzer | IAM Access Analyzer capability that identifies S3 buckets shared with external entities outside the account or organization |\n\n## Tools & Systems\n\n- **AWS Config**: Evaluates S3 bucket compliance against managed rules and triggers auto-remediation for non-compliant resources\n- **Amazon Macie**: Discovers and classifies sensitive data in S3 buckets to identify which misconfigurations pose the highest data exposure risk\n- **IAM Access Analyzer**: Identifies S3 buckets with policies or ACLs that grant access to external principals\n- **S3 Storage Lens**: Provides organization-wide visibility into S3 usage patterns, access metrics, and security anomalies\n- **Prowler**: Open-source tool that checks S3 security configurations against CIS benchmarks and best practices\n\n## Common Scenarios\n\n### Scenario: Data Breach from Publicly Readable S3 Bucket Containing PII\n\n**Context**: A security researcher reports that an S3 bucket containing 273,000 bank transfer PDFs is publicly readable. The bucket was created by a developer who needed to share files with an external partner and set the ACL to public-read.\n\n**Approach**:\n1. Immediately enable Block Public Access on the specific bucket to stop the exposure\n2. Revoke all public ACLs by setting BucketOwnerEnforced ownership controls\n3. Audit CloudTrail and S3 access logs to determine which IP addresses accessed the exposed objects\n4. Run Macie on the bucket to classify the types of PII exposed and assess regulatory notification requirements\n5. Enable account-level Block Public Access to prevent recurrence across all buckets\n6. Deploy an SCP preventing any principal except SecurityAdmin from modifying Block Public Access settings\n7. Create a pre-signed URL mechanism or S3 Access Point for the legitimate partner sharing use case\n\n**Pitfalls**: Enabling Block Public Access without notifying the team that set up the public access breaks their workflow. Not running access log analysis before remediation loses evidence of who accessed the exposed data.\n\n## Output Format\n\n```\nS3 Bucket Security Remediation Report\n=======================================\nAccount: 123456789012\nAssessment Date: 2025-02-23\nBuckets Scanned: 156\n\nACCOUNT-LEVEL CONTROLS:\n  Block Public Access: ENABLED (all four settings)\n  SCP Preventing Removal: DEPLOYED\n\nCRITICAL FINDINGS (Remediated):\n  [S3-001] production-uploads - Public READ via ACL\n    Status: REMEDIATED - BucketOwnerEnforced applied\n    Objects Exposed: 273,412\n    Duration of Exposure: 47 days\n    Unique External IPs Accessed: 1,247\n\n  [S3-002] analytics-export - Public bucket policy (Principal: *)\n    Status: REMEDIATED - Policy replaced with VPC endpoint restriction\n    Sensitive Data (Macie): 12,400 objects with PII detected\n\nHIGH FINDINGS:\n  [S3-003] 14 buckets missing default encryption\n    Status: REMEDIATED - KMS encryption enabled\n  [S3-004] 8 buckets without server access logging\n    Status: REMEDIATED - Logging enabled to centralized log bucket\n\nSUMMARY:\n  Buckets Remediated: 24\u002F156\n  Encryption Coverage: 100%\n  Access Logging Coverage: 100%\n  Block Public Access: 156\u002F156 buckets\n```\n","# Remediating S3 Bucket Misconfiguration\n\n## When to Use\n\n- When AWS Config or Security Hub reports S3 buckets with public access or missing encryption\n- When a security scan reveals S3 bucket policies granting access to Principal \"*\" (everyone)\n- When preparing for a data protection audit requiring evidence of storage security controls\n- When responding to a data exposure incident involving publicly accessible S3 objects\n- When establishing preventive controls for new S3 bucket creation across an AWS Organization\n\n**Do not use** for Azure Blob Storage or GCP Cloud Storage misconfigurations, for S3 data classification (see implementing-cloud-dlp-policy), or for S3 access pattern analysis unrelated to security.\n\n## Prerequisites\n\n- AWS account with S3 administrative permissions (s3:*, s3-outposts:*)\n- AWS Config enabled to evaluate S3 resource compliance\n- AWS CloudTrail logging S3 data events for access auditing\n- Macie enabled for sensitive data discovery in S3 buckets\n\n## Workflow\n\n### Step 1: Identify All Public and Misconfigured Buckets\n\nUse multiple detection methods to identify S3 buckets with public access. Rely on AWS Config rules, S3 Access Analyzer, and Macie rather than manual inspection.\n\n```bash\n# Enable S3 Access Analyzer for external access detection\naws accessanalyzer create-analyzer \\\n  --analyzer-name s3-analyzer \\\n  --type ACCOUNT\n\n# List all S3 buckets with public access indicators\naws s3api list-buckets --query 'Buckets[*].Name' --output text | while read bucket; do\n  public_status=$(aws s3api get-public-access-block --bucket \"$bucket\" 2>\u002Fdev\u002Fnull)\n  if [ $? -ne 0 ]; then\n    echo \"NO PUBLIC ACCESS BLOCK: $bucket\"\n  fi\ndone\n\n# Check bucket policies for public access grants\naws s3api list-buckets --query 'Buckets[*].Name' --output text | while read bucket; do\n  policy=$(aws s3api get-bucket-policy --bucket \"$bucket\" 2>\u002Fdev\u002Fnull)\n  if echo \"$policy\" | grep -q '\"Principal\":\"*\"' 2>\u002Fdev\u002Fnull; then\n    echo \"PUBLIC POLICY DETECTED: $bucket\"\n  fi\ndone\n\n# Use AWS Config to find non-compliant buckets\naws configservice get-compliance-details-by-config-rule \\\n  --config-rule-name s3-bucket-public-read-prohibited \\\n  --compliance-types NON_COMPLIANT \\\n  --query 'EvaluationResults[*].EvaluationResultIdentifier.EvaluationResultQualifier.ResourceId'\n```\n\n### Step 2: Enable S3 Block Public Access at Account Level\n\nApply the four Block Public Access settings at the AWS account level as a safety net. This prevents any bucket in the account from being made public, regardless of individual bucket policies or ACLs.\n\n```bash\n# Enable account-level Block Public Access (all four settings)\naws s3control put-public-access-block \\\n  --account-id 123456789012 \\\n  --public-access-block-configuration '{\n    \"BlockPublicAcls\": true,\n    \"IgnorePublicAcls\": true,\n    \"BlockPublicPolicy\": true,\n    \"RestrictPublicBuckets\": true\n  }'\n\n# Verify account-level settings\naws s3control get-public-access-block --account-id 123456789012\n\n# Enable at bucket level for defense in depth\naws s3api put-public-access-block \\\n  --bucket production-data-bucket \\\n  --public-access-block-configuration '{\n    \"BlockPublicAcls\": true,\n    \"IgnorePublicAcls\": true,\n    \"BlockPublicPolicy\": true,\n    \"RestrictPublicBuckets\": true\n  }'\n```\n\n### Step 3: Audit and Remediate Bucket Policies and ACLs\n\nReview all bucket policies for overly permissive Principal statements and remove legacy ACLs. Enforce bucket ownership controls to disable ACLs entirely.\n\n```bash\n# Remove a public bucket policy\naws s3api delete-bucket-policy --bucket exposed-bucket\n\n# Replace with a restrictive policy\naws s3api put-bucket-policy --bucket exposed-bucket --policy '{\n  \"Version\": \"2012-10-17\",\n  \"Statement\": [\n    {\n      \"Sid\": \"DenyUnencryptedTransport\",\n      \"Effect\": \"Deny\",\n      \"Principal\": \"*\",\n      \"Action\": \"s3:*\",\n      \"Resource\": [\n        \"arn:aws:s3:::exposed-bucket\",\n        \"arn:aws:s3:::exposed-bucket\u002F*\"\n      ],\n      \"Condition\": {\n        \"Bool\": {\"aws:SecureTransport\": \"false\"}\n      }\n    },\n    {\n      \"Sid\": \"AllowOnlyVPCEndpoint\",\n      \"Effect\": \"Deny\",\n      \"Principal\": \"*\",\n      \"Action\": \"s3:*\",\n      \"Resource\": [\n        \"arn:aws:s3:::exposed-bucket\",\n        \"arn:aws:s3:::exposed-bucket\u002F*\"\n      ],\n      \"Condition\": {\n        \"StringNotEquals\": {\"aws:SourceVpce\": \"vpce-0abc123def456\"}\n      }\n    }\n  ]\n}'\n\n# Enforce bucket owner for all objects (disable ACLs)\naws s3api put-bucket-ownership-controls --bucket exposed-bucket \\\n  --ownership-controls '{\"Rules\": [{\"ObjectOwnership\": \"BucketOwnerEnforced\"}]}'\n```\n\n### Step 4: Enforce Default Encryption\n\nEnable default server-side encryption with AWS KMS or AES-256 for all buckets. Add a bucket policy denying unencrypted object uploads.\n\n```bash\n# Enable default KMS encryption\naws s3api put-bucket-encryption --bucket production-data-bucket \\\n  --server-side-encryption-configuration '{\n    \"Rules\": [{\n      \"ApplyServerSideEncryptionByDefault\": {\n        \"SSEAlgorithm\": \"aws:kms\",\n        \"KMSMasterKeyID\": \"arn:aws:kms:us-east-1:123456789012:key\u002Fkey-id\"\n      },\n      \"BucketKeyEnabled\": true\n    }]\n  }'\n\n# Deny unencrypted uploads via bucket policy\naws s3api put-bucket-policy --bucket production-data-bucket --policy '{\n  \"Version\": \"2012-10-17\",\n  \"Statement\": [{\n    \"Sid\": \"DenyUnencryptedUploads\",\n    \"Effect\": \"Deny\",\n    \"Principal\": \"*\",\n    \"Action\": \"s3:PutObject\",\n    \"Resource\": \"arn:aws:s3:::production-data-bucket\u002F*\",\n    \"Condition\": {\n      \"StringNotEquals\": {\"s3:x-amz-server-side-encryption\": [\"aws:kms\", \"AES256\"]}\n    }\n  }]\n}'\n```\n\n### Step 5: Enable Access Logging and Monitoring\n\nConfigure S3 server access logging and CloudTrail data events to track all object-level operations. Set up EventBridge rules to alert on suspicious access patterns.\n\n```bash\n# Enable server access logging\naws s3api put-bucket-logging --bucket production-data-bucket \\\n  --bucket-logging-status '{\n    \"LoggingEnabled\": {\n      \"TargetBucket\": \"s3-access-logs-bucket\",\n      \"TargetPrefix\": \"production-data-bucket\u002F\"\n    }\n  }'\n\n# Enable CloudTrail S3 data events\naws cloudtrail put-event-selectors --trail-name management-trail \\\n  --event-selectors '[{\n    \"ReadWriteType\": \"All\",\n    \"DataResources\": [{\n      \"Type\": \"AWS::S3::Object\",\n      \"Values\": [\"arn:aws:s3:::production-data-bucket\u002F\"]\n    }]\n  }]'\n```\n\n### Step 6: Deploy Preventive Controls with SCP and Config\n\nUse Service Control Policies to prevent disabling Block Public Access across the organization. Deploy AWS Config rules with auto-remediation.\n\n```bash\n# SCP preventing Block Public Access removal\naws organizations create-policy \\\n  --name PreventS3PublicAccess \\\n  --type SERVICE_CONTROL_POLICY \\\n  --content '{\n    \"Version\": \"2012-10-17\",\n    \"Statement\": [{\n      \"Sid\": \"DenyRemovePublicAccessBlock\",\n      \"Effect\": \"Deny\",\n      \"Action\": [\n        \"s3:PutBucketPublicAccessBlock\",\n        \"s3:PutAccountPublicAccessBlock\"\n      ],\n      \"Resource\": \"*\",\n      \"Condition\": {\n        \"StringNotLike\": {\"aws:PrincipalArn\": \"arn:aws:iam::*:role\u002FSecurityAdmin\"}\n      }\n    }]\n  }'\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|------------|\n| S3 Block Public Access | Four account-level and bucket-level settings that override any policy or ACL granting public access to S3 resources |\n| Bucket Policy | JSON-based resource policy attached to an S3 bucket defining who can access what objects under which conditions |\n| ACL (Access Control List) | Legacy S3 access mechanism that grants permissions at the bucket or object level; should be disabled via BucketOwnerEnforced |\n| BucketOwnerEnforced | Ownership control setting that disables all ACLs on a bucket, making the bucket owner the sole authority for access control |\n| Server-Side Encryption | Automatic encryption of objects at rest using AES-256 (SSE-S3), AWS KMS (SSE-KMS), or customer-provided keys (SSE-C) |\n| VPC Endpoint | Private connection between a VPC and S3 that restricts bucket access to traffic originating from within the VPC |\n| S3 Access Analyzer | IAM Access Analyzer capability that identifies S3 buckets shared with external entities outside the account or organization |\n\n## Tools & Systems\n\n- **AWS Config**: Evaluates S3 bucket compliance against managed rules and triggers auto-remediation for non-compliant resources\n- **Amazon Macie**: Discovers and classifies sensitive data in S3 buckets to identify which misconfigurations pose the highest data exposure risk\n- **IAM Access Analyzer**: Identifies S3 buckets with policies or ACLs that grant access to external principals\n- **S3 Storage Lens**: Provides organization-wide visibility into S3 usage patterns, access metrics, and security anomalies\n- **Prowler**: Open-source tool that checks S3 security configurations against CIS benchmarks and best practices\n\n## Common Scenarios\n\n### Scenario: Data Breach from Publicly Readable S3 Bucket Containing PII\n\n**Context**: A security researcher reports that an S3 bucket containing 273,000 bank transfer PDFs is publicly readable. The bucket was created by a developer who needed to share files with an external partner and set the ACL to public-read.\n\n**Approach**:\n1. Immediately enable Block Public Access on the specific bucket to stop the exposure\n2. Revoke all public ACLs by setting BucketOwnerEnforced ownership controls\n3. Audit CloudTrail and S3 access logs to determine which IP addresses accessed the exposed objects\n4. Run Macie on the bucket to classify the types of PII exposed and assess regulatory notification requirements\n5. Enable account-level Block Public Access to prevent recurrence across all buckets\n6. Deploy an SCP preventing any principal except SecurityAdmin from modifying Block Public Access settings\n7. Create a pre-signed URL mechanism or S3 Access Point for the legitimate partner sharing use case\n\n**Pitfalls**: Enabling Block Public Access without notifying the team that set up the public access breaks their workflow. Not running access log analysis before remediation loses evidence of who accessed the exposed data.\n\n## Output Format\n\n```\nS3 Bucket Security Remediation Report\n=======================================\nAccount: 123456789012\nAssessment Date: 2025-02-23\nBuckets Scanned: 156\n\nACCOUNT-LEVEL CONTROLS:\n  Block Public Access: ENABLED (all four settings)\n  SCP Preventing Removal: DEPLOYED\n\nCRITICAL FINDINGS (Remediated):\n  [S3-001] production-uploads - Public READ via ACL\n    Status: REMEDIATED - BucketOwnerEnforced applied\n    Objects Exposed: 273,412\n    Duration of Exposure: 47 days\n    Unique External IPs Accessed: 1,247\n\n  [S3-002] analytics-export - Public bucket policy (Principal: *)\n    Status: REMEDIATED - Policy replaced with VPC endpoint restriction\n    Sensitive Data (Macie): 12,400 objects with PII detected\n\nHIGH FINDINGS:\n  [S3-003] 14 buckets missing default encryption\n    Status: REMEDIATED - KMS encryption enabled\n  [S3-004] 8 buckets without server access logging\n    Status: REMEDIATED - Logging enabled to centralized log bucket\n\nSUMMARY:\n  Buckets Remediated: 24\u002F156\n  Encryption Coverage: 100%\n  Access Logging Coverage: 100%\n  Block Public Access: 156\u002F156 buckets\n```\n",{"name":5,"tags":48,"author":49,"domain":35,"license":14,"version":50,"subdomain":41,"description":51},[36,27,37,34,33],"mahipal","1.0.0","This skill provides step-by-step procedures for identifying and remediating Amazon S3 bucket misconfigurations that expose sensitive data to unauthorized access. It covers enabling S3 Block Public Access at account and bucket levels, auditing bucket policies and ACLs, enforcing encryption, configuring access logging, and deploying automated remediation using AWS Config and Lambda.\n","master","3f5d983eb4ef375b749adcd6b07ec03bd82ae8a8","_universal\u002Fcybersecurity-skills\u002Fskills\u002Fremediating-s3-bucket-misconfiguration",0,"https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills","https:\u002F\u002Fgithub.com\u002Fmicsapp","2026-03-20 11:24:18",{"source":8,"skillName":5,"commands":60,"prompt":70,"zipAvailable":71},[61,64,67],{"tool":62,"command":63},"npx","npx skills add micsapp\u002Fmicstec-skills --skill remediating-s3-bucket-misconfiguration",{"tool":65,"command":66},"bunx","bunx skills add micsapp\u002Fmicstec-skills --skill remediating-s3-bucket-misconfiguration",{"tool":68,"command":69},"pnpm","pnpm dlx skills add micsapp\u002Fmicstec-skills --skill remediating-s3-bucket-misconfiguration","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002F_universal\u002Fcybersecurity-skills\u002Fskills\u002Fremediating-s3-bucket-misconfiguration\u002FSKILL.md",true,[73,78,84],{"path":74,"resourceType":74,"resourceTypeDesc":75,"sizeBytes":76,"sourceHtmlUrl":77},"LICENSE","许可证",11255,"https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002F_universal\u002Fcybersecurity-skills\u002Fskills\u002Fremediating-s3-bucket-misconfiguration\u002FLICENSE",{"path":79,"resourceType":80,"resourceTypeDesc":81,"sizeBytes":82,"sourceHtmlUrl":83},"references\u002Fapi-reference.md","REFERENCE","参考文档",2595,"https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002F_universal\u002Fcybersecurity-skills\u002Fskills\u002Fremediating-s3-bucket-misconfiguration\u002Freferences\u002Fapi-reference.md",{"path":85,"resourceType":86,"resourceTypeDesc":87,"sizeBytes":88,"sourceHtmlUrl":89},"scripts\u002Fagent.py","SCRIPT","脚本",7661,"https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002F_universal\u002Fcybersecurity-skills\u002Fskills\u002Fremediating-s3-bucket-misconfiguration\u002Fscripts\u002Fagent.py",[91,126,156,176,196,221],{"skillNo":92,"name":93,"nameZh":6,"description":94,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":106,"publishedAt":43},"01M6HBTJ02FXBFG9NYEHHYAP52","azure-apim-architecture","Analyzes and explains Azure API Management architecture decisions for enterprise API marketplace implementations using VNet Internal mode, Front Door, hybrid authentication, and multi-environment strategies. Use when discussing APIM component selection, network topology, cost optimization, or comparing alternatives like workspaces vs instances, VNet Internal vs External mode, or Front Door vs Application Gateway.","MIT","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002Fcopilot-cli\u002Fcopilot-agent-skills\u002F.github\u002Fskills\u002Fazure-apim-architecture\u002FSKILL.md",[98,103],{"categoryNo":99,"categoryName":100,"taxonomyType":101,"taxonomyTypeDesc":102},"01JBSEEDCAT000000000000010","后端与接口","SCENARIO","使用场景",{"categoryNo":104,"categoryName":105,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000030","开发工程师",[107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,28],"architecture","azure","azure apim architecture","component","authentication","gateway","topology","Optimization","network","api","team","environment","multi-environment","workspaces","instances","selection","strategies","azure api management","mode",{"skillNo":127,"name":128,"nameZh":6,"description":129,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":130,"categories":131,"keywords":140,"publishedAt":43},"01M6HBT7J4H082JEEA670B3EQ9","apiops-deployment","Guides deployment of Azure API Management infrastructure using Infrastructure as Code (Bicep\u002FTerraform), CI\u002FCD pipelines (GitHub Actions\u002FAzure DevOps), and APIOps workflows. Use when deploying APIM, creating pipelines, or implementing dev→test→prod promotion strategies.","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002Fcopilot-cli\u002Fcopilot-agent-skills\u002F.github\u002Fskills\u002Fapiops-deployment\u002FSKILL.md",[132,133,136,139],{"categoryNo":99,"categoryName":100,"taxonomyType":101,"taxonomyTypeDesc":102},{"categoryNo":134,"categoryName":135,"taxonomyType":101,"taxonomyTypeDesc":102},"01JBSEEDCAT000000000000011","运维与部署",{"categoryNo":137,"categoryName":138,"taxonomyType":101,"taxonomyTypeDesc":102},"01JBSEEDCAT000000000000023","Skill与智能体开发",{"categoryNo":104,"categoryName":105,"taxonomyType":20,"taxonomyTypeDesc":21},[141,142,143,144,108,145,146,147,148,149,150,151,116,117,123,152,153,124,154,155],"deployment","apiops deployment","workflows","azure devops","infrastructure","code","infrastructure as code","actions","ci","github actions","github-actions","as","guides","CI\u002FCD","implementing",{"skillNo":157,"name":158,"nameZh":6,"description":159,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":160,"categories":161,"keywords":163,"publishedAt":43},"01M6HBT2HEA23THNE9E00GYQBE","apim-policy-authoring","Creates production-ready Azure API Management policy XML for authentication (OAuth 2.0, JWT validation, subscription keys), rate limiting, CORS configuration, error handling, and API transformations. Use when implementing API security, access control, or request\u002Fresponse processing logic.","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002Fcopilot-cli\u002Fcopilot-agent-skills\u002F.github\u002Fskills\u002Fapim-policy-authoring\u002FSKILL.md",[162],{"categoryNo":99,"categoryName":100,"taxonomyType":101,"taxonomyTypeDesc":102},[164,165,166,167,108,111,116,117,32,168,169,170,171,172,173,124,174,175,155,28],"policy","authoring","apim policy authoring","security","use","ready","api security","Access Control","error","processing","cors configuration","production-ready",{"skillNo":177,"name":178,"nameZh":6,"description":179,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":180,"categories":181,"keywords":184,"publishedAt":43},"01M6HBSY65SB29J9WE9KYD0K6T","api-security-review","Reviews Azure API Management configurations for security vulnerabilities, OWASP API Security Top 10 compliance, VNet Internal mode validation, Private Link verification, and Azure Security Benchmark alignment. Use when performing security audits, pre-deployment validation, or compliance reviews.","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002Fcopilot-cli\u002Fcopilot-agent-skills\u002F.github\u002Fskills\u002Fapi-security-review\u002FSKILL.md",[182,183],{"categoryNo":99,"categoryName":100,"taxonomyType":101,"taxonomyTypeDesc":102},{"categoryNo":104,"categoryName":105,"taxonomyType":20,"taxonomyTypeDesc":21},[185,167,186,116,170,187,108,141,188,189,190,191,117,192,124,193,194,195,125,28],"review","security review","api security review","benchmark","verification","owasp","owasp-api","alignment","azure security","reviews","top",{"skillNo":197,"name":198,"nameZh":6,"description":199,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":200,"categories":201,"keywords":202,"publishedAt":43},"01M6HBSRW4PDFE6K4F8JYPZQ05","jira-cli","Interact with Jira from the command line to create, list, view, edit, and transition issues, manage sprints and epics, and perform common Jira workflows. Use when the user asks about Jira tasks, tickets, issues, sprints, or needs to manage project work items.","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002Fcopilot-cli\u002Fawesome-copilot-agents\u002Fskills\u002Fjira-cli\u002FSKILL.md",[],[203,204,205,143,206,207,208,209,116,210,211,212,213,214,215,216,217,218,219,220],"cli","jira","jira cli","init","tasks","create","issues","common","work","command","edit","list","view","project","project work","token","line","sprints",{"skillNo":222,"name":223,"nameZh":6,"description":224,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":225,"categories":226,"keywords":227,"publishedAt":43},"01M6HBSNS3JHMW603G47TWE31H","calculator","Performs arbitrary-precision arithmetic calculations including addition, subtraction, multiplication, division, and exponents. Use when the user asks to calculate, compute, or evaluate math expressions, or when precise decimal arithmetic is needed to avoid floating-point errors.","https:\u002F\u002Fgithub.com\u002Fmicsapp\u002Fmicstec-skills\u002Fblob\u002Fmaster\u002Fcopilot-cli\u002Fawesome-copilot-agents\u002Fskills\u002Fcalculator\u002FSKILL.md",[],[223,228,229,230,231,232,233,168,234,235],"npm","js","calculate","node","math","user","compute","errors"]