Control: 3 CloudFront distributions should require encryption in transit
Description
This control checks whether an Amazon CloudFront distribution requires viewers to use HTTPS directly or whether it uses redirection. The control fails if ViewerProtocolPolicy
is set to allow-all
for defaultCacheBehavior
or for cacheBehaviors
.
HTTPS (TLS) can be used to help prevent potential attackers from using person-in-the-middle or similar attacks to eavesdrop on or manipulate network traffic. Only encrypted connections over HTTPS (TLS) should be allowed. Encrypting data in transit can affect performance. You should test your application with this feature to understand the performance profile and the impact of TLS.
Remediation
For detailed remediation instructions, see Requiring HTTPS for communication between viewers and CloudFront.
Usage
Run the control in your terminal:
powerpipe control run aws_compliance.control.foundational_security_cloudfront_3
Snapshot and share results via Turbot Pipes:
powerpipe loginpowerpipe control run aws_compliance.control.foundational_security_cloudfront_3 --share
SQL
This control uses a named query:
cloudfront_distribution_encryption_in_transit_enabled