More Info:
Enable private endpoint access to the Kubernetes API server and restrict public access to specific CIDR blocks so the control plane is not exposed to all IP addresses.Risk Level
HighAddress
SecurityCompliance Standards
- CIS EKS
Triage and Remediation
- Remediation
Remediation
Manual Steps
Manual Steps
-
Gather current endpoint configuration (any machine with AWS CLI access)
Review:
endpointPrivateAccessshould betrue.- If
endpointPublicAccessistrue, ensurepublicAccessCidrsis a small, explicit list of trusted CIDRs (ideally /32 for admin IPs or narrow corporate ranges), not["0.0.0.0/0"]and not empty.
-
Decide the desired exposure model (design decision, no command)
Choose one of:- Private-only:
endpointPrivateAccess=true,endpointPublicAccess=false; access via VPC/VPN/Direct Connect/bastion. - Private + restricted public:
endpointPrivateAccess=true,endpointPublicAccess=true, andpublicAccessCidrsset to only necessary admin IPs or ranges.
Confirm that the networking team can reach the API via VPC paths if you disable or significantly restrict public access.
- Private-only:
-
Update to private-only endpoint if public access is not required (any machine with AWS CLI access)
Be aware: turning off public access immediately cuts off internet-based kubectl/API access; ensure admins have connectivity via the VPC first.
-
Update to private + restricted public access if limited internet access is required (any machine with AWS CLI access)
Replace the CIDRs with your approved admin IPs/ranges (must not include reserved addresses):Coordinate with stakeholders so only documented, maintained CIDRs are allowed; avoid broad ranges (e.g. /0, /8). -
Align IaC / automation with the chosen configuration (Git/IaC system, no AWS command)
- For CloudFormation/CDK/Terraform/etc., set:
- Private endpoint enabled.
- Public endpoint disabled, or enabled with the exact
publicAccessCidrsdecided in steps 2 and 4.
Ensure future deployments/updates cannot revert to0.0.0.0/0or an emptypublicAccessCidrs.
- For CloudFormation/CDK/Terraform/etc., set:
-
Verify final state matches the decision (any machine with AWS CLI access)
Confirm:
endpointPrivateAccessistrue.endpointPublicAccessandpublicAccessCidrsexactly match the chosen model in step 2.
Using kubectl
Using kubectl
kubectl cannot modify the EKS control plane endpoint exposure or its allowed CIDR blocks; those settings are managed in the AWS control plane via the AWS Console, AWS CLI, or IaC. Use kubectl only to inspect cluster state, and follow the guidance in the Manual Steps section to update the endpoint configuration.
Automation
Automation
-
PRIV=trueandPUB=false- Generally aligned with “private endpoint only”; review still recommended but low concern.
-
RISK_INDICATORcontains:HIGH: Public endpoint open to the world (0.0.0.0/0)- Fails the intent of the control; public API is exposed to all IPs.
MEDIUM: Public endpoint CIDR(s) appear broad; review- Likely not minimal; ranges look like internal-wide or large networks.
REVIEW: Public endpoint restricted; verify IP list is minimal/justified- Public access is limited, but you must manually confirm those CIDRs are specific, necessary, and documented.
...; Private endpoint disabled- Private endpoint not enabled; consider enabling to keep node–API traffic inside the VPC.
HIGH status is automatically compliant without human validation.
