Cette page a été traduite par l'API Cloud Translation.
Switch to English

Tous les exemples de code Cloud KMS

Add a rotation schedule to an existing key

Add a rotation schedule to an existing key.

View in documentation

Add an IAM member to a resource

Add an IAM member to a resource.

View in documentation

Configure automatic key rotation

Configure an automatic key rotation schedule.

View in documentation

Create a key with labels

When creating a key, you can add labels by providing one or more key-value pairs as labels when you create your key.

View in documentation

Create a new key version

Create a new version of the given key.

View in documentation

Create a symmetric key

Create a new symmetric encryption/decryption key in Cloud KMS.

View in documentation

Create an asymmetric decryption key

Create an asymmetric decryption key.

View in documentation

Create an asymmetric signing key

Create an asymmetric signing key.

View in documentation

Create an HSM key

Create a Cloud HSM key on the specified key ring and location.

View in documentation

Decrypt with a symmetric key

Decrypt the ciphertext by using the symmetric key.

Decrypt with an asymmetric key

Decrypt the ciphertext by using an asymmetric key.

Destroy a key version

Schedule the destruction of the given key version.

Encrypt with a symmetric key

Encrypt plaintext by using a symmetric key.

Encrypt with an asymmetric key

Encrypt plaintext using the public key portion of an asymmetric key.

Get a key and its labels

Get a key and its labels.

View in documentation

Get a key version's attestation

Get an HSM-backend key's attestation.

Get the IAM policy for a resource

Get the IAM policy for a resource.

View in documentation

Get the public key for an asymmetric key

Get the public key for an asymmetric key.

View in documentation

Remove a rotation schedule from an existing key

Remove a rotation schedule from an existing key.

View in documentation

Remove an IAM member from a resource

Remove an IAM member from a resource.

View in documentation

Remove labels from an existing key

Remove labels from an existing key.

View in documentation

Restore a key version scheduled for destruction

Restore a key version that is scheduled for destruction.

Retrieve an asymmetric signature

Get an asymmetric signature of the SHA-256 hash of an input message using the KMS API.

Update labels on an existing key

Update labels on an existing key.

View in documentation

Update the primary version of a key

Update the primary version of a key.

View in documentation

Verify an asymmetric signature of an EC key

Verify the signature of a message signed with an asymmetric EC key.

Verify asymmetric signature of an RSA key

Verify the signature of a message signed with an asymmetric RSA key.