Description

Ensure that every Classic Load Balancer uses only encrypted client-facing listeners. A listener whose front-end protocol is HTTPS or SSL encrypts traffic between clients and the load balancer; a listener using HTTP or TCP sends that traffic in plaintext and is flagged. Only Classic Load Balancers are evaluated here; Application and Network Load Balancers are covered by a separate requirement.

Rationale

Plaintext listeners allow anyone on the network path between clients and the load balancer to read or change the traffic. Attackers on public or untrusted networks can capture credentials and session tokens or inject content through man-in-the-middle attacks, leading to data exposure and unauthorized access. Only HTTPS or SSL listeners should be used, with trusted certificates (for example, from AWS Certificate Manager) and a current TLS security policy.

Impact

  • Encrypts all traffic between clients and the load balancer

  • A Classic Load Balancer cannot redirect HTTP to HTTPS, so clients that still connect over HTTP or plain TCP lose access when those listeners are removed

  • Requires a valid TLS certificate for the load balancer's domain name

Default Value

There is no default listener protocol. A Classic Load Balancer has the listeners that were configured when it was created or added later.

Pre-Requisites

  • IAM permissions: elasticloadbalancing:DescribeLoadBalancers, elasticloadbalancing:CreateLoadBalancerListeners and elasticloadbalancing:DeleteLoadBalancerListeners

  • A TLS certificate in AWS Certificate Manager (ACM) or IAM for the load balancer's domain name

  • Confirmation that all clients can connect using HTTPS or SSL/TLS

Remediation

Test Plan

Console:

  1. Sign in to the AWS Management Console at https://console.aws.amazon.com.

  2. Open the Amazon EC2 console and select Load Balancers under Load Balancing.

  3. Select each load balancer of type classic and open the Listeners tab.

  4. Check the protocol of each listener.

  5. Repeat for each region in use.

  6. If any listener uses HTTP or TCP, follow the implementation steps.

CLI:

List all Classic Load Balancers with the protocol and port of their listeners:

aws elb describe-load-balancers --region <REGION> --query "LoadBalancerDescriptions[].[LoadBalancerName,ListenerDescriptions[].Listener.[Protocol,LoadBalancerPort]]"

A Classic Load Balancer fails if any of its listeners uses a front-end protocol other than HTTPS or SSL; a load balancer with no listeners passes.

Implementation Steps

Console:

  1. Sign in to the AWS Management Console at https://console.aws.amazon.com.

  2. Open the Amazon EC2 console and select Load Balancers under Load Balancing.

  3. Select the Classic Load Balancer and open the Listeners tab.

  4. Choose to manage or edit the listeners.

  5. If no encrypted listener exists, add a listener with protocol HTTPS (port 443) or SSL, and select the TLS certificate.

  6. Remove each listener that uses HTTP or TCP.

  7. Save the changes.

  8. Repeat for each affected load balancer in each region in use.

CLI:

Add an HTTPS listener if the load balancer does not have one:

aws elb create-load-balancer-listeners --load-balancer-name <LOAD_BALANCER_NAME> --listeners Protocol=HTTPS,LoadBalancerPort=443,InstanceProtocol=HTTP,InstancePort=<INSTANCE_PORT>,SSLCertificateId=<CERTIFICATE_ARN> --region <REGION>

Remove the plaintext listener (repeat for each HTTP or TCP listener port):

aws elb delete-load-balancer-listeners --load-balancer-name <LOAD_BALANCER_NAME> --load-balancer-ports 80 --region <REGION>

Backout Plan

Before making changes, save the current load balancer configuration:

aws elb describe-load-balancers --load-balancer-names <LOAD_BALANCER_NAME> --region <REGION> > elb-backup.json

To roll back:

  1. Sign in to the AWS Management Console at https://console.aws.amazon.com.

  2. Open the Amazon EC2 console and select Load Balancers.

  3. Select the Classic Load Balancer and open the Listeners tab.

  4. Add back the removed listeners with the protocol and ports from the saved backup.

  5. Save the changes.

CLI:

aws elb create-load-balancer-listeners --load-balancer-name <LOAD_BALANCER_NAME> --listeners Protocol=HTTP,LoadBalancerPort=80,InstanceProtocol=HTTP,InstancePort=<INSTANCE_PORT> --region <REGION>

Note: rolling back allows clients to send traffic in plaintext again.

Reference