Runbook 01 Build a Secure Enterprise AWS Network
Module: 04 β Amazon VPC & Network Security
Enterprise Lab: 01
Estimated Time: 3β4 Hours
Difficulty: βββββ
Estimated Cost: AWS Free Tier (Some networking components such as NAT Gateway may incur charges. Always review AWS Pricing and monitor AWS Cost Explorer.)
π― Objective
Section titled βπ― ObjectiveβAs a Cloud Security Engineer at CloudNova Technologies, your task is to design and deploy a secure AWS network that follows enterprise security best practices.
By completing this runbook, you will learn how to:
- Create an Amazon VPC
- Design secure IP addressing
- Create Public and Private Subnets
- Configure Route Tables
- Configure an Internet Gateway
- Deploy a NAT Gateway
- Configure Security Groups
- Configure Network ACLs
- Deploy a Bastion Host
- Configure VPC Flow Logs
- Validate secure network connectivity
π’ Business Scenario
Section titled βπ’ Business ScenarioβCloudNova Technologies is migrating its customer-facing web application to AWS.
The application consists of:
- Web Tier
- Application Tier
- Database Tier
The architecture must follow enterprise security best practices by ensuring only required systems are publicly accessible while protecting internal resources from direct Internet access.
Your responsibility is to build the network foundation that every application team will use.
π Prerequisites
Section titled βπ PrerequisitesβComplete:
- Module 01 β AWS Security Foundations
- Module 02 β Identity & Access Management (IAM)
- Module 03 β AWS Organizations & Multi-Account Security
Required:
- AWS Account
- Administrator Access
- AWS CLI Installed
- Visual Studio Code
- Secure AWS Environment
π Enterprise Architecture
Section titled βπ Enterprise ArchitectureβInternet β βΌInternet Gateway βββββββββββββββββββββββββββββββββββββββββββββββVPC (10.0.0.0/16)ββββ Public Subnet A (10.0.1.0/24)β βββ Bastion Hostβ βββ NAT Gatewayββββ Private Application Subnet A (10.0.2.0/24)β βββ EC2 Application Serverββββ Private Database Subnet A (10.0.3.0/24)β βββ Amazon RDSββββ Route Tablesββββ Security Groupsββββ Network ACLsββββ VPC Flow LogsStep 1 β Create Amazon VPC
Section titled βStep 1 β Create Amazon VPCβNavigate to:
AWS Console
β
VPC
β
Create VPCConfiguration
Name
CloudNova-Production-VPC
IPv4 CIDR
10.0.0.0/16
Tenancy
DefaultAWS CLI
Section titled βAWS CLIβaws ec2 create-vpc \--cidr-block 10.0.0.0/16 \--tag-specifications 'ResourceType=vpc,Tags=[{Key=Name,Value=CloudNova-Production-VPC}]'Step 2 β Create Public and Private Subnets
Section titled βStep 2 β Create Public and Private SubnetsβCreate the following subnets:
| Subnet | CIDR | Purpose |
|---|---|---|
| Public Subnet | 10.0.1.0/24 | Bastion & NAT |
| Private App | 10.0.2.0/24 | EC2 Application Servers |
| Private Database | 10.0.3.0/24 | Amazon RDS |
Console
VPC
β
Subnets
β
Create SubnetCLI Example
Section titled βCLI Exampleβaws ec2 create-subnet \--vpc-id <vpc-id> \--cidr-block 10.0.1.0/24Repeat for all subnets.
Step 3 β Create Internet Gateway
Section titled βStep 3 β Create Internet GatewayβNavigate to:
VPC
β
Internet Gateways
β
CreateAttach the Internet Gateway to your VPC.
aws ec2 create-internet-gatewayAttach:
aws ec2 attach-internet-gateway \--internet-gateway-id <igw-id> \--vpc-id <vpc-id>Step 4 β Configure Route Tables
Section titled βStep 4 β Configure Route TablesβCreate:
- Public Route Table
- Private Route Table
Public Route Table
Destination
0.0.0.0/0
β
Internet GatewayPrivate Route Table
Destination
0.0.0.0/0
β
NAT GatewayAssociate the appropriate subnets.
Step 5 β Deploy NAT Gateway
Section titled βStep 5 β Deploy NAT GatewayβNavigate to:
VPC
β
NAT Gateway
β
CreateConfiguration:
- Public Subnet
- Allocate Elastic IP
Discuss:
- Why private resources should not have direct Internet access.
- Why outbound updates should pass through the NAT Gateway.
Step 6 β Configure Security Groups
Section titled βStep 6 β Configure Security GroupsβCreate the following Security Groups:
Bastion Host
Section titled βBastion HostβAllow:
SSH (22)
Source:
Your Public IPApplication Servers
Section titled βApplication ServersβAllow:
HTTP (80)
HTTPS (443)
Source:
Public Load Balancer (or Bastion for testing)Database
Section titled βDatabaseβAllow:
MySQL (3306)
Source:
Application Security GroupDiscuss:
- Stateful firewall
- Least privilege
- Restricting inbound access
Step 7 β Configure Network ACLs
Section titled βStep 7 β Configure Network ACLsβReview the default Network ACL.
Create custom Network ACLs for:
- Public Subnet
- Private Application Subnet
- Private Database Subnet
Review:
- Inbound Rules
- Outbound Rules
- Rule Order
Discuss:
- Stateless filtering
- Difference between Security Groups and NACLs
Step 8 β Deploy Bastion Host
Section titled βStep 8 β Deploy Bastion HostβLaunch an EC2 instance in the Public Subnet.
Configure:
- Amazon Linux 2023
- SSH Key Pair
- Bastion Security Group
Validate:
SSH access from your workstation.
Step 9 β Configure VPC Flow Logs
Section titled βStep 9 β Configure VPC Flow LogsβNavigate to:
VPC
β
Flow Logs
β
Create Flow LogDestination:
- CloudWatch Logs
Review:
- Accepted Traffic
- Rejected Traffic
Discuss:
- Network monitoring
- Incident response
- Threat hunting
Step 10 β Validate Connectivity
Section titled βStep 10 β Validate ConnectivityβVerify:
- Bastion Host is accessible
- Application Server has outbound Internet access through the NAT Gateway
- Database is not publicly accessible
- Security Groups allow only required traffic
- Network ACLs behave as expected
- VPC Flow Logs capture traffic
Useful validation commands:
ping <private-ip>curl https://aws.amazon.comtraceroute <destination>π§ͺ Enterprise Challenge
Section titled βπ§ͺ Enterprise ChallengeβCloudNova Technologies plans to host:
- Customer Web Portal
- Internal HR Application
- Finance System
- SOC Platform
Design a secure VPC architecture that provides:
- Network Segmentation
- High Availability
- Secure Internet Access
- Secure Administrative Access
- Private Database Connectivity
- Monitoring and Logging
Create a network diagram and explain your design decisions.
π Deliverables
Section titled βπ DeliverablesβCapture screenshots of:
- Amazon VPC
- Subnets
- Route Tables
- Internet Gateway
- NAT Gateway
- Security Groups
- Network ACLs
- Bastion Host
- VPC Flow Logs
Submit:
- VPC Architecture Diagram
- Subnet Design
- Route Table Design
- Security Group Matrix
- Network ACL Matrix
- Validation Results
π§Ή Cleanup
Section titled βπ§Ή CleanupβDelete:
- Bastion Host
- NAT Gateway (to avoid ongoing charges)
- Elastic IP (if no longer required)
- Temporary EC2 Instances
- Test Security Groups
- Test Network ACLs
- Temporary Route Tables
- Test Flow Logs (if not required)
Keep:
- Amazon VPC (if it will be reused in future modules)
- IP Addressing Plan
- Network Design Documentation
β Runbook Checklist
Section titled ββ Runbook Checklistβ- Amazon VPC Created
- Public Subnet Created
- Private Application Subnet Created
- Private Database Subnet Created
- Internet Gateway Configured
- NAT Gateway Configured
- Route Tables Configured
- Security Groups Configured
- Network ACLs Configured
- Bastion Host Deployed
- VPC Flow Logs Enabled
- Connectivity Validated
π‘ Lessons Learned
Section titled βπ‘ Lessons LearnedβWhat did you learn?
Section titled βWhat did you learn?βWhy should databases remain in private subnets?
Section titled βWhy should databases remain in private subnets?βWhen should Security Groups be used instead of Network ACLs?
Section titled βWhen should Security Groups be used instead of Network ACLs?βHow do NAT Gateways improve network security?
Section titled βHow do NAT Gateways improve network security?βHow would you improve this architecture for production?
Section titled βHow would you improve this architecture for production?βπ Next Enterprise Runbook
Section titled βπ Next Enterprise RunbookβEnterprise Runbook 02 β Enterprise AWS Network Security Assessment
In the next runbook, you will assess an existing AWS network, identify security weaknesses, evaluate routing, subnet design, Security Groups, Network ACLs, Internet exposure, and VPC Flow Logs, then produce an enterprise network security assessment report.