How thatvirdiguy/aws-security-check works
Step 1: Identify the Main Components
• Security Check Driver: At the core is the main script (security_check.sh) that orchestrates the execution of the individual modules.
• Modules: Separate scripts for each AWS service:
– ec2.sh (which includes VPC checks as well)
– iam.sh
– s3.sh
• Logs Output: Although the file tree doesn’t show a “logs” directory, the README indicates that all reports (CSV files) are stored in a dedicated logs folder.
• External AWS Environment: Represent the target AWS environment (including regions and accounts) that these scripts interface with, and external dependencies such as the AWS CLI.
Step 2: Define the Relationships and Interactions Between Components
• Optionally, indicate that the modules are designed to report detailed findings including account, region, service, resource, rule violation, vulnerability level, and recommended remediation.
Step 3: Highlight Architectural Patterns and Design Principles
• Modularity: Stress that each AWS service check is encapsulated in its own Bash script, promoting separation of concerns.
• Extensibility: Identify that the design is open to expansion by adding more modules for additional AWS services or checks.
Step 4: Include Relevant Technologies and External Factors
• Underlying Shell Environment: Note that this is a Bash script running in a Unix-like shell.
• AWS CLI: Underpinning these checks likely is the AWS CLI or similar commands interacting with AWS services.
• CSV Logging: The output format for security findings is CSV, which can be highlighted in the logs component.
– “Main Script: security_check.sh”
– “Module: EC2/VPC Checks (ec2.sh)”
– “Module: S3 Checks (s3.sh)”
– “Module: IAM Checks (iam.sh)”
– “Output: Logs (CSV Files)”
– “External: AWS Environment”
• Modular breakdown and integration points by clearly annotating that the main script orchestrates calls and that each module reports its findings independently.
Since this is a focused security audit tool rather than a full-stack web application or compiler:
• Separation of functionality into discrete modules for each AWS service.
• How findings are generated and stored in a logs directory, making it easier to track report generation.
• Calls to external AWS services (if visually relevant), showing that the modules interact with AWS’s public endpoints using the CLI.