AWS SOC 2 Readiness Checker — Compliance Made Easy
A Python-based tool to quickly assess SOC 2 readiness across AWS services and MongoDB Atlas. Get pass/fail reports in table, JSON, or interactive HTML format.
GitHub Repo: https://github.com/bibhutimail/aws-SOC2-compliance-checker
Overview
The AWS SOC 2 Readiness Checker helps you evaluate security and compliance controls across AWS and MongoDB Atlas. It validates IAM, CloudFront, API Gateway, ECS, ECR, S3, CloudWatch, NLB, and Atlas resources — providing actionable insights into SOC 2 posture.
Features
- Checks IAM, CloudFront, API Gateway, NLB, ECS, ECR, S3, CloudWatch, and MongoDB Atlas
- Modular checks for each service
- Outputs results in table or JSON
- Error handling and pagination support
Prerequisites
- Python 3.7+
- AWS credentials configured (environment variables, AWS CLI, or instance profile)
- MongoDB Atlas API keys (optional)
Setup
git clone https://github.com/bibhutimail/aws-SOC2-compliance-checker
cd aws-SOC2-compliance-checker
python -m venv .venv
.venv\Scripts\activate # (Windows)
source .venv/bin/activate # (Linux/Mac)
pip install boto3 requests tabulate
AWS Credentials
The script uses your default AWS credentials. Configure them with:
aws configure
(recommended)- Set
AWS_ACCESS_KEY_ID
andAWS_SECRET_ACCESS_KEY
as environment variables - Use EC2 instance profile or IAM role
MongoDB Atlas Credentials (Optional)
To check Atlas:
- Atlas Public Key
- Atlas Private Key
- Atlas Project ID
Generate API keys under Organization Access Management in Atlas UI.
Usage Examples
Run all checks
python soc2_checker.py
Use a specific AWS profile
python soc2_checker.py --profile myprofile
Export to JSON
python soc2_checker.py --output report.json
Export to interactive HTML
python soc2_checker.py --output report.html
Skip or Include Atlas Checks
# Skip Atlas
python soc2_checker.py --skip-atlas
# Include Atlas
python soc2_checker.py --atlas-public-key <PUBLIC_KEY> --atlas-private-key <PRIVATE_KEY> --atlas-project-id <PROJECT_ID>
Full Example
python soc2_checker.py --output soc2_report.html \
--atlas-public-key ABC \
--atlas-private-key XYZ \
--atlas-project-id 1234567890abcdef
Output Formats
- Console Table (default)
- JSON (
--output file.json
) - Interactive HTML (
--output file.html
)
Each result includes: Service, Control, Status (Pass/Fail), and Details.
Extending Checks
Each service check is a separate function in soc2_checker.py
. Add new checks by creating new functions and calling them from main()
.
Troubleshooting
- Ensure AWS credentials are valid and permissions are sufficient.
- For MongoDB Atlas, verify API keys and project ID.
- If errors occur, review the Details column in output.