X.509 certificates are essential for verifying identities and encrypting communication within CCE clusters. These certificates enable authorized clients to access target clusters while encrypting data transmission between them. This prevents threats like eavesdropping and tampering, ensuring secure communication, authenticated identities, and valid access. To initiate a connection using X.509 certificates, obtain the cluster certificate from the CCE console and use it to configure the client accordingly.
For example, run the curl command to call an API to obtain the pod information. The following is an example:
curl --cacert ./ca.crt --cert ./client.crt --key ./client.key https://192.168.0.18:5443/api/v1/namespaces/default/pods/
If the following information is displayed, the X.509 certificate is correctly configured and the API Server of the cluster is running properly:
{"kind": "PodList","apiVersion": "v1",...
For more cluster APIs, see Kubernetes API.