A global online gaming company hosts its multiplayer matchmaking API on Amazon ECS container instances behind an Application Load Balancer (ALB). The company recently suffered a major distributed denial of service (DDoS) attack in the form of an HTTP flood, which overwhelmed the ALB and caused matchmaking services to fail. Additionally, the security team has identified SQL injection attempts in the request payloads. The company wants to implement a solution to mitigate these Layer 7 attacks, minimize latency for global players, and restrict direct access to the ALB, allowing traffic only from the edge security layer. Which two actions should a solutions architect recommend to meet these requirements? (Select TWO.)
- Deploy an Amazon CloudFront distribution in front of the Application Load Balancer, and associate an AWS WAF web ACL with the distribution that includes a rate-based rule and SQL injection protection rules.Answer
- Configure the security group of the Application Load Balancer to allow inbound HTTP/HTTPS traffic only from the Amazon CloudFront managed prefix list.Answer
- CEnable AWS Shield Advanced on the Application Load Balancer to automatically inspect HTTP request payloads and mitigate SQL injection attempts.
- DConfigure a stateless Network Access Control List (NACL) on the Application Load Balancer's subnets to inspect incoming request bodies for SQL injection patterns and block them.
- EDeploy an AWS WAF web ACL and associate it directly with the Amazon ECS service to filter malicious payloads before they reach the containers.
Answer
Deploy an Amazon CloudFront distribution in front of the Application Load Balancer with AWS WAF associated, and restrict the load balancer's security group to allow inbound traffic only from the CloudFront managed prefix list.
Deploying CloudFront in front of the ALB caches content globally to reduce latency. Associating AWS WAF with CloudFront allows filtering of Layer 7 exploits like SQL injection and mitigating HTTP flood attacks using rate-based rules at the edge. Restricting the ALB security group to the CloudFront managed prefix list ensures that all public traffic must pass through the CloudFront and WAF edge security layer before reaching the backend.
Step-by-Step Solution
Key Concept
Implementing Layer 7 DDoS and exploit mitigation at the edge using Amazon CloudFront and AWS WAF while securing the origin ALB.