Los clústeres de Anthos en VMware ahora son Google Distributed Cloud (solo software) para VMware. Para obtener más información, consulta la descripción general del producto.
Organiza tus páginas con colecciones
Guarda y categoriza el contenido según tus preferencias.
La versión 1.10 de Google Distributed Cloud admite secretos de encriptación sin necesidad de un KMS externo (servicio de administración de claves) ni ninguna otra dependencia.
Habilita la encriptación de secretos siempre activa
La encriptación de secretos siempre activa funciona mediante la generación automática de una clave de encriptación que se usa a fin de encriptar los secretos antes de que se almacenen en la base de datos etcd para ese clúster. Los secretos se encriptan con una clave de encriptación de datos (DEK) que se genera para cada operación de escritura de Secret. Esta DEK se usa en el modo AES-GCM para encriptar el objeto Secret. La DEK, a su vez, está encriptada con una clave de encriptación de claves (KEK). El algoritmo de encriptación es A256GCM (AES GCM con clave de 256 bits).
La versión de clave es un número de versión para indicar la clave que está actualmente en uso.
Puedes habilitar la encriptación de secretos después de crear un clúster.
ADMIN_KUBECONFIG: la ruta de acceso al archivo kubeconfig del clúster de administrador
ADMIN_CLUSTER_CONFIG por la ruta de acceso del archivo de configuración del clúster de administrador
USER_CLUSTER_CONFIG es la ruta de acceso del archivo de configuración del clúster de usuario.
Los comandos gkectl update que se proporcionan en esta sección también se pueden usar para cualquier otra actualización del clúster correspondiente.
Almacenamiento de claves
Las claves de encriptación del clúster de administrador se almacenan en el disco de datos del clúster de administrador. Este disco se activa en la máquina de la instancia principal del administrador en /opt/data y las claves de encriptación se pueden encontrar en /opt/data/gke-k8s-kms-plugin/generatedkeys/. Se debe crear una copia de seguridad de estas claves para conservar el acceso a los secretos encriptados que usa esa clave. Debes habilitar la encriptación de VM o almacenamiento en el hipervisor o medidas similares para garantizar que los discos de VM del plano de control estén protegidos.
Rotación de claves
Para rotar una clave de encriptación existente en un clúster, aumenta la keyVersion en el archivo de configuración del clúster de administrador o en el archivo de configuración del clúster de usuarios y ejecuta el comando gkectl update adecuado. Esto crea una clave nueva que coincide con el número de versión nuevo, vuelve a encriptar cada secreto y borra el anterior de forma segura. Todos los secretos nuevos posteriores se encriptan con la clave de encriptación nueva.
Inhabilita la encriptación de secretos siempre activa
Para inhabilitar la encriptación de secretos en un clúster existente, agrega un campo disabled: true. A continuación, ejecuta el comando gkectl update correspondiente. Esta actualización desencripta cada secreto existente y almacena cada secreto en texto sin formato. Todos los secretos nuevos posteriores se almacenan en texto sin formato.
[[["Fácil de comprender","easyToUnderstand","thumb-up"],["Resolvió mi problema","solvedMyProblem","thumb-up"],["Otro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Información o código de muestra incorrectos","incorrectInformationOrSampleCode","thumb-down"],["Faltan la información o los ejemplos que necesito","missingTheInformationSamplesINeed","thumb-down"],["Problema de traducción","translationIssue","thumb-down"],["Otro","otherDown","thumb-down"]],["Última actualización: 2025-05-03 (UTC)"],[],[],null,["Google Distributed Cloud version 1.10 supports encrypting secrets without the need for\nan external KMS (Key Management Service), or any other dependencies.\n\nNote the following limitation with advanced clusters:\n\n- Version 1.31: always-on secrets encryption isn't supported on [advanced clusters](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/user-cluster-configuration-file-latest#enable-advanced-cluster-field).\n- Version 1.32 and higher: always-on encryption is supported on advanced clusters.\n\nEnable always-on secrets encryption\n\nAlways-on secrets encryption works by automatically generating an encryption key that is used to encrypt secrets before they are stored on the etcd database for that cluster. The secrets are encrypted using a Data Encryption Key (DEK) generated for every Secret write. This DEK is used in AES-GCM mode to encrypt the Secret object. The DEK is in turn encrypted with a Key Encrypting Key (KEK). The encryption algorithm is A256GCM (AES GCM using 256-bit key).\n\nThe key version is a version number to indicate the key currently in use.\n\nYou can enable secrets encryption after a cluster has already been created.\n\n- For the admin cluster:\n\n 1. Edit the [admin cluster configuration file](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/admin-cluster-configuration-file-latest#secretsencryption-section) to add the `secretsEncryption` section.\n\n 2. Run the `gkectl update` command.\n\n ```\n gkectl update admin --config ADMIN_CLUSTER_CONFIG_FILE --kubeconfig ADMIN_CLUSTER_KUBECONFIG\n ```\n- For a user cluster:\n\n 1. Edit the [user cluster configuration file](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/user-cluster-configuration-file-latest#secretsencryption-section) to add the `secretsEncryption` section.\n\n 2. Run the `gkectl update` command.\n\n ```\n gkectl update cluster --config USER_CONFIG_FILE --kubeconfig ADMIN_CLUSTER_KUBECONFIG\n ```\n\nReplace the following:\n\n- `ADMIN_KUBECONFIG` with the path of your admin cluster kubeconfig file.\n- `ADMIN_CLUSTER_CONFIG` with the path of your admin cluster configuration file.\n- `USER_CLUSTER_CONFIG` with the path of your user cluster configuration file.\n\nThe `gkectl update` commands provided in this section can also be used for any other updates to the corresponding cluster.\n\nKey storage\n\nThe encryption keys for the admin cluster are stored on the admin cluster data disk. This disk is mounted on the admin master machine at /opt/data, and the encryption keys can be found at /opt/data/gke-k8s-kms-plugin/generatedkeys/. These keys must be backed up to retain access to the encrypted secrets used by that key. You should enable [VM/storage encryption in the hypervisor](https://docs.vmware.com/en/VMware-vSphere/7.0/com.vmware.vsphere.security.doc/GUID-5E2C3F74-38C1-44C3-ABC5-C2C9353B9DC4.html) or similar measures to ensure that the control plane VM disks are protected.\n\nKey rotation\n\nTo rotate an existing encryption key for a cluster, increment the `keyVersion` in the corresponding [admin cluster configuration file](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/admin-cluster-configuration-file-latest#secretsencryption-generatedkey-version-field) or [user cluster configuration file](/kubernetes-engine/distributed-cloud/vmware/docs/how-to/user-cluster-configuration-file-latest#secretsencryption-generatedkey-version-field), and run the appropriate `gkectl update` command. This creates a new key matching the new version number, re-encrypts each secret, and securely erases the old one. All subsequent new secrets are encrypted using the new encryption key.\n\nDisable always-on secrets encryption\n\nTo disable secrets encryption on an existing cluster, add a `disabled: true` field. Next, run the corresponding `gkectl update` command. This update decrypts each existing secret and stores each secret in plain text. All subsequent new secrets are stored in plain text.\n\n```\nsecretsEncryption:\n mode: GeneratedKey\n generatedKey:\n keyVersion: KEY_VERSION\n disabled: true\n```"]]