Control: EKS cluster endpoints should prohibit public access
Description
Ensure that Elastic Kubernetes Service (EKS) endpoints are not publicly accessible.
Usage
Run the control in your terminal:
powerpipe control run aws_perimeter.control.eks_cluster_endpoint_prohibit_public_accessSnapshot and share results via Turbot Pipes:
powerpipe loginpowerpipe control run aws_perimeter.control.eks_cluster_endpoint_prohibit_public_access --shareSteampipe Tables
SQL
select  arn as resource,  case    when resources_vpc_config ->> 'EndpointPublicAccess' = 'true' then 'alarm'    else 'ok'  end as status,  case    when resources_vpc_config ->> 'EndpointPublicAccess' = 'true' then title || ' endpoint publicly accessible.'    else title || ' endpoint not publicly accessible.'  end as reason    , region, account_idfrom  aws_eks_cluster;