Prerequisites
Make sure you are in a group that has at least theeditor role within your tenant or project; for example, the default editors group. Alternatively, you can have an access permit with the editor role assigned to the required key. To check your access rights, go to the Administration → IAM section in the web console.
How to update a symmetric key
-
List symmetric keys:
In the output, copy the ID of the required symmetric key.
-
Update the key:
The command contains the following parameters:
-
--id: ID of the symmetric key that you update. -
--name(optional): New name of the key. -
--description(optional): New description of the key. -
--rotation-period(optional): New period after which KMS automatically rotates the key material. When a key is rotated, KMS generates a new key version and immediately sets it as the default version. Specify the value in theNhNmNsformat, for example,24hor48h30m10s. The minimum value is86400s(one day) and the maximum value is315360000s(3650 days). The default value is7776000s(90 days).
-
How to update an asymmetric key
-
List asymmetric keys:
In the output, copy the ID of the required asymmetric key.
-
Update the key:
The command contains the following parameters:
--id: ID of the asymmetric key that you update.--name(optional): New name of the key.--description(optional): New description of the key.