By default, when you enable automatic key rotation for a KMS key, AWS KMS generates new cryptographic material for the KMS key every year. You can also specify a custom rotation-period to define the number of days after you enable automatic key rotation that AWS KMS will rotate your key material, and the number of days between each automatic rotation thereafter.
Automatic key rotation has the following benefits:
The properties of the KMS key, including its key ID, key ARN, region, policies, and permissions, do not change when the key is rotated.
You do not need to change applications or aliases that refer to the key ID or key ARN of the KMS key.
Rotating key material does not affect the use of the KMS key in any AWS service.
After you enable key rotation, AWS KMS rotates the KMS key automatically on the next rotation date defined by your rotation period. You don't need to remember or schedule the update.
You can enable automatic key rotation in the AWS KMS console or by using the EnableKeyRotation operation. To enable automatic key rotation, you need kms:EnableKeyRotation
permissions. For more information about AWS KMS permissions, see the Permissions reference.
Sign in to the AWS Management Console and open the AWS Key Management Service (AWS KMS) console at https://console.aws.amazon.com/kms.
To change the AWS Region, use the Region selector in the upper-right corner of the page.
In the navigation pane, choose Customer managed keys. (You cannot enable or disable rotation of AWS managed keys. They are automatically rotated every year.)
Choose the alias or key ID of a KMS key.
Choose the Key rotation tab.
The Key rotation tab appears only on the detail page of symmetric encryption KMS keys with key material that AWS KMS generated (the Origin is AWS_KMS), including multi-Region symmetric encryption KMS keys.
You cannot automatically rotate asymmetric KMS keys, HMAC KMS keys, KMS keys with imported key material, or KMS keys in custom key stores. However, you can rotate them manually.
In the Automatic key rotation section, choose Edit.
For Key rotation, select Enable.
NoteIf a KMS key is disabled or pending deletion, AWS KMS does not rotate the key material and you cannot update the automatic key rotation status or rotation period. Enable the KMS key or cancel deletion to update the automatic key rotation configuration. For details, see How key rotation works and Key states of AWS KMS keys.
(Optional) Type a rotation period between 90 and 2560 days. The default value is 365 days. If you do not specify a custom rotation period, AWS KMS will rotate the key material every year.
You can use the kms:RotationPeriodInDays condition key to limit the values that principals can specify for the rotation period.
Choose Save.
You can use the AWS Key Management Service (AWS KMS) API to enable automatic key rotation and view the current rotation status of any customer managed key. These examples use the AWS Command Line Interface (AWS CLI), but you can use any supported programming language.
The EnableKeyRotation operation enables automatic key rotation for the specified KMS key. To identify the KMS key in this operation, use its key ID or key ARN. By default, key rotation is disabled for customer managed keys.
You can use the kms:RotationPeriodInDays condition key to limit the values that principals can specify for the RotationPeriodInDays
parameter of an EnableKeyRotation
request.
The following example enables key rotation with a rotation period of 180 days on the specified symmetric encryption KMS key and uses the GetKeyRotationStatus operation to see the result.
$
aws kms enable-key-rotation \
--key-id 1234abcd-12ab-34cd-56ef-1234567890ab
\
--rotation-period-in-days 180
$
aws kms get-key-rotation-status --key-id 1234abcd-12ab-34cd-56ef-1234567890ab
{
"KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
"KeyRotationEnabled": true,
"RotationPeriodInDays": 180,
"NextRotationDate": "2024-02-14T18:14:33.587000+00:00"
}
Rotate keys
Disable automatic key rotation
Did this page help you? - Yes
Thanks for letting us know we're doing a good job!
If you've got a moment, please tell us what we did right so we can do more of it.
Did this page help you? - No
Thanks for letting us know this page needs work. We're sorry we let you down.
If you've got a moment, please tell us how we can make the documentation better.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4