Skip to Content
Asterrr's Handbook
Service cheat sheetsSecurity and identity cheat sheets

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.

HTTPallowedTCP, UDPany IPGENEVEClientsWAF web ACLALBNLBGateway LBSecurityappliance
ALB reads HTTP and can be fronted by WAF. NLB passes TCP, UDP or TLS. Gateway Load Balancer steers traffic through appliances.

Pick by requirement

RequirementALBNLBGWLB
Layer743
ProtocolsHTTP, HTTPS, gRPCTCP, UDP, TLSIP
Path, host, header, method, query routingYesNoNo
Redirects and fixed responsesYesNoNo
WAF attachmentYesNoNo
User authentication at the listener (Cognito, OIDC)YesNoNo
TLS terminationYes, with SNIYes, with SNINo
Mutual TLSYes (verify or passthrough)Not on TLS listeners. Use a TCP listener and handle it on the targetNo
Static or Elastic IPNoYesNo
Lambda targetsYesNoNo
Third-party inspection appliancesNoNoYes
PrivateLinkNot as a service directlyYesThrough 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.

AWS WAF, Certificate Manager

Further reading

On this page