ALB vs NLB vs GLB security features
Which Elastic Load Balancing type fits which protocol, TLS and inspection requirement.
Elastic Load Balancing has three current types. The Classic Load Balancer is the previous generation and AWS recommends migrating off it.
Pick by requirement
| Requirement | ALB | NLB | GWLB |
|---|---|---|---|
| Layer | 7 | 4 | 3 |
| Protocols | HTTP, HTTPS, gRPC | TCP, UDP, TLS | IP |
| Path, host, header, method, query routing | Yes | No | No |
| Redirects and fixed responses | Yes | No | No |
| WAF attachment | Yes | No | No |
| User authentication at the listener (Cognito, OIDC) | Yes | No | No |
| TLS termination | Yes, with SNI | Yes, with SNI | No |
| Mutual TLS | Yes (verify or passthrough) | Not on TLS listeners. Use a TCP listener and handle it on the target | No |
| Static or Elastic IP | No | Yes | No |
| Lambda targets | Yes | No | No |
| Third-party inspection appliances | No | No | Yes |
| PrivateLink | Not as a service directly | Yes | Through Gateway Load Balancer endpoints |
Shared features include health checks, CloudWatch metrics, access logs, cross-zone balancing, connection draining, stickiness and IAM resource and tag permissions. ACM supplies the certificates for HTTPS and TLS listeners.
Exam signal
"Block SQL injection at the load balancer" means ALB plus WAF. "Fixed IP addresses for allow-listing" means NLB. "Inline firewall appliance for all VPC traffic" means Gateway Load Balancer.
Exam trap
You cannot attach WAF to an NLB. For client certificate checks on an NLB the TLS listener cannot do it, so use TCP passthrough.