Skip to main content

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

High

Address

Security

Compliance Standards

  • CIS EKS

Triage and Remediation

Remediation

Manual Steps

  1. Gather current endpoint configuration (any machine with AWS CLI access)
    Review:
    • endpointPrivateAccess should be true.
    • If endpointPublicAccess is true, ensure publicAccessCidrs is 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.
  2. 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, and publicAccessCidrs set 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.
  3. 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.
  4. 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).
  5. 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 publicAccessCidrs decided in steps 2 and 4.
        Ensure future deployments/updates cannot revert to 0.0.0.0/0 or an empty publicAccessCidrs.
  6. Verify final state matches the decision (any machine with AWS CLI access)
    Confirm:
    • endpointPrivateAccess is true.
    • endpointPublicAccess and publicAccessCidrs exactly match the chosen model in step 2.
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.
How to run (any machine with AWS CLI access):
How to interpret the output:
  • PRIV = true and PUB = false
    • Generally aligned with “private endpoint only”; review still recommended but low concern.
  • RISK_INDICATOR contains:
    • 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.
Use these results as an input to a manual review and policy decision; do not assume that any non-HIGH status is automatically compliant without human validation.