Check ID: cloudfront_distributions_custom_ssl_certificate
Provider: AWS
Service: cloudfront
Severity: MEDIUM
Categories: encryption
Resource type: AwsCloudFrontDistribution

What this check verifies

CloudFront distributions are configured with a custom SSL/TLS certificate rather than the default *.cloudfront.net certificate for viewer connections.

Risk

Using the default certificate prevents HTTPS on your own hostnames, breaking hostname validation. Clients may face errors or avoid TLS, impacting authentication and availability. Control over TLS posture and domain-bound security headers is reduced, weakening confidentiality and user trust.

Recommendation

  • Use a custom SSL/TLS certificate covering your domains and configure aliases.
  • Enforce modern TLS policy, SNI, and HSTS; disable legacy protocols.
  • Apply least privilege to certificate lifecycle and rotate/monitor keys.

Remediation

aws cloudfront get-distribution-config —id <DISTRIBUTION_ID> —output json > current-config.json && echo ‘Manually edit current-config.json to add Aliases and ViewerCertificate fields, then run:’ && echo ‘aws cloudfront update-distribution —id <DISTRIBUTION_ID> —distribution-config file://current-config.json —if-match $(aws cloudfront get-distribution-config —id <DISTRIBUTION_ID> —query “ETag” —output text)’

References

Where this check fires

This check runs on every scheduled scan against your AWS account. Findings appear at Cloud Security → Findings filterable by Check ID = cloudfront_distributions_custom_ssl_certificate. To re-evaluate after a fix, hit Run now on the account’s schedule under Cloud Security → Schedules — the next scan re-checks this control and marks the finding fixed or keeps it persistent.
← Back to AWS checks