aws-sdk-kms 1.38.0 → 1.43.0

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION ADDED
@@ -0,0 +1 @@
1
+ 1.43.0
data/lib/aws-sdk-kms.rb CHANGED
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -48,6 +48,6 @@ require_relative 'aws-sdk-kms/customizations'
48
48
  # @!group service
49
49
  module Aws::KMS
50
50
 
51
- GEM_VERSION = '1.38.0'
51
+ GEM_VERSION = '1.43.0'
52
52
 
53
53
  end
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -339,8 +339,7 @@ module Aws::KMS
339
339
 
340
340
  # Cancels the deletion of a customer master key (CMK). When this
341
341
  # operation succeeds, the key state of the CMK is `Disabled`. To enable
342
- # the CMK, use EnableKey. You cannot perform this operation on a CMK in
343
- # a different AWS account.
342
+ # the CMK, use EnableKey.
344
343
  #
345
344
  # For more information about scheduling and canceling deletion of a CMK,
346
345
  # see [Deleting Customer Master Keys][1] in the *AWS Key Management
@@ -350,10 +349,18 @@ module Aws::KMS
350
349
  # state. For details, see [How Key State Affects Use of a Customer
351
350
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
352
351
  #
352
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
353
+ # in a different AWS account.
354
+ #
355
+ # **Required permissions**\: [kms:CancelKeyDeletion][3] (key policy)
356
+ #
357
+ # **Related operations**\: ScheduleKeyDeletion
358
+ #
353
359
  #
354
360
  #
355
361
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html
356
362
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
363
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
357
364
  #
358
365
  # @option params [required, String] :key_id
359
366
  # The unique identifier for the customer master key (CMK) for which to
@@ -448,6 +455,23 @@ module Aws::KMS
448
455
  # store, see [Troubleshooting a Custom Key Store][5] in the *AWS Key
449
456
  # Management Service Developer Guide*.
450
457
  #
458
+ # **Cross-account use**\: No. You cannot perform this operation on a
459
+ # custom key store in a different AWS account.
460
+ #
461
+ # **Required permissions**\: [kms:ConnectCustomKeyStore][6] (IAM policy)
462
+ #
463
+ # **Related operations**
464
+ #
465
+ # * CreateCustomKeyStore
466
+ #
467
+ # * DeleteCustomKeyStore
468
+ #
469
+ # * DescribeCustomKeyStores
470
+ #
471
+ # * DisconnectCustomKeyStore
472
+ #
473
+ # * UpdateCustomKeyStore
474
+ #
451
475
  #
452
476
  #
453
477
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
@@ -455,6 +479,7 @@ module Aws::KMS
455
479
  # [3]: https://docs.aws.amazon.com/cloudhsm/latest/APIReference/API_CreateHsm.html
456
480
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-store-concepts.html#concept-kmsuser
457
481
  # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html
482
+ # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
458
483
  #
459
484
  # @option params [required, String] :custom_key_store_id
460
485
  # Enter the key store ID of the custom key store that you want to
@@ -478,96 +503,98 @@ module Aws::KMS
478
503
  req.send_request(options)
479
504
  end
480
505
 
481
- # Creates a display name for a customer managed customer master key
482
- # (CMK). You can use an alias to identify a CMK in [cryptographic
483
- # operations][1], such as Encrypt and GenerateDataKey. You can change
484
- # the CMK associated with the alias at any time.
485
- #
486
- # Aliases are easier to remember than key IDs. They can also help to
487
- # simplify your applications. For example, if you use an alias in your
488
- # code, you can change the CMK your code uses by associating a given
489
- # alias with a different CMK.
490
- #
491
- # To run the same code in multiple AWS regions, use an alias in your
492
- # code, such as `alias/ApplicationKey`. Then, in each AWS Region, create
493
- # an `alias/ApplicationKey` alias that is associated with a CMK in that
494
- # Region. When you run your code, it uses the `alias/ApplicationKey` CMK
495
- # for that AWS Region without any Region-specific code.
506
+ # Creates a friendly name for a customer master key (CMK). You can use
507
+ # an alias to identify a CMK in the AWS KMS console, in the DescribeKey
508
+ # operation and in [cryptographic operations][1], such as Encrypt and
509
+ # GenerateDataKey.
510
+ #
511
+ # You can also change the CMK that's associated with the alias
512
+ # (UpdateAlias) or delete the alias (DeleteAlias) at any time. These
513
+ # operations don't affect the underlying CMK.
514
+ #
515
+ # You can associate the alias with any customer managed CMK in the same
516
+ # AWS Region. Each alias is associated with only on CMK at a time, but a
517
+ # CMK can have multiple aliases. A valid CMK is required. You can't
518
+ # create an alias without a CMK.
519
+ #
520
+ # The alias must be unique in the account and Region, but you can have
521
+ # aliases with the same name in different Regions. For detailed
522
+ # information about aliases, see [Using aliases][2] in the *AWS Key
523
+ # Management Service Developer Guide*.
496
524
  #
497
525
  # This operation does not return a response. To get the alias that you
498
526
  # created, use the ListAliases operation.
499
527
  #
500
- # To use aliases successfully, be aware of the following information.
528
+ # The CMK that you use for this operation must be in a compatible key
529
+ # state. For details, see [How Key State Affects Use of a Customer
530
+ # Master Key][3] in the *AWS Key Management Service Developer Guide*.
531
+ #
532
+ # **Cross-account use**\: No. You cannot perform this operation on an
533
+ # alias in a different AWS account.
501
534
  #
502
- # * Each alias points to only one CMK at a time, although a single CMK
503
- # can have multiple aliases. The alias and its associated CMK must be
504
- # in the same AWS account and Region.
535
+ # **Required permissions**
505
536
  #
506
- # * You can associate an alias with any customer managed CMK in the same
507
- # AWS account and Region. However, you do not have permission to
508
- # associate an alias with an [AWS managed CMK][2] or an [AWS owned
509
- # CMK][3].
537
+ # * [kms:CreateAlias][4] on the alias (IAM policy).
510
538
  #
511
- # * To change the CMK associated with an alias, use the UpdateAlias
512
- # operation. The current CMK and the new CMK must be the same type
513
- # (both symmetric or both asymmetric) and they must have the same key
514
- # usage (`ENCRYPT_DECRYPT` or `SIGN_VERIFY`). This restriction
515
- # prevents cryptographic errors in code that uses aliases.
516
- #
517
- # * The alias name must begin with `alias/` followed by a name, such as
518
- # `alias/ExampleAlias`. It can contain only alphanumeric characters,
519
- # forward slashes (/), underscores (\_), and dashes (-). The alias
520
- # name cannot begin with `alias/aws/`. The `alias/aws/` prefix is
521
- # reserved for [AWS managed CMKs][2].
522
- #
523
- # * The alias name must be unique within an AWS Region. However, you can
524
- # use the same alias name in multiple Regions of the same AWS account.
525
- # Each instance of the alias is associated with a CMK in its Region.
526
- #
527
- # * After you create an alias, you cannot change its alias name.
528
- # However, you can use the DeleteAlias operation to delete the alias
529
- # and then create a new alias with the desired name.
530
- #
531
- # * You can use an alias name or alias ARN to identify a CMK in AWS KMS
532
- # [cryptographic operations][1] and in the DescribeKey operation.
533
- # However, you cannot use alias names or alias ARNs in API operations
534
- # that manage CMKs, such as DisableKey or GetKeyPolicy. For
535
- # information about the valid CMK identifiers for each AWS KMS API
536
- # operation, see the descriptions of the `KeyId` parameter in the API
537
- # operation documentation.
539
+ # * [kms:CreateAlias][4] on the CMK (key policy).
538
540
  #
539
- # Because an alias is not a property of a CMK, you can delete and change
540
- # the aliases of a CMK without affecting the CMK. Also, aliases do not
541
- # appear in the response from the DescribeKey operation. To get the
542
- # aliases and alias ARNs of CMKs in each AWS account and Region, use the
543
- # ListAliases operation.
541
+ # For details, see [Controlling access to aliases][5] in the *AWS Key
542
+ # Management Service Developer Guide*.
544
543
  #
545
- # The CMK that you use for this operation must be in a compatible key
546
- # state. For details, see [How Key State Affects Use of a Customer
547
- # Master Key][4] in the *AWS Key Management Service Developer Guide*.
544
+ # **Related operations:**
545
+ #
546
+ # * DeleteAlias
547
+ #
548
+ # * ListAliases
549
+ #
550
+ # * UpdateAlias
548
551
  #
549
552
  #
550
553
  #
551
554
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
552
- # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
553
- # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-owned-cmk
554
- # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
555
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html
556
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
557
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
558
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access
555
559
  #
556
560
  # @option params [required, String] :alias_name
557
561
  # Specifies the alias name. This value must begin with `alias/` followed
558
- # by a name, such as `alias/ExampleAlias`. The alias name cannot begin
559
- # with `alias/aws/`. The `alias/aws/` prefix is reserved for AWS managed
560
- # CMKs.
562
+ # by a name, such as `alias/ExampleAlias`.
563
+ #
564
+ # The `AliasName` value must be string of 1-256 characters. It can
565
+ # contain only alphanumeric characters, forward slashes (/), underscores
566
+ # (\_), and dashes (-). The alias name cannot begin with `alias/aws/`.
567
+ # The `alias/aws/` prefix is reserved for [AWS managed CMKs][1].
568
+ #
569
+ #
570
+ #
571
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
561
572
  #
562
573
  # @option params [required, String] :target_key_id
563
- # Identifies the CMK to which the alias refers. Specify the key ID or
564
- # the Amazon Resource Name (ARN) of the CMK. You cannot specify another
565
- # alias. For help finding the key ID and ARN, see [Finding the Key ID
566
- # and ARN][1] in the *AWS Key Management Service Developer Guide*.
574
+ # Associates the alias with the specified [customer managed CMK][1]. The
575
+ # CMK must be in the same AWS Region.
576
+ #
577
+ # A valid CMK ID is required. If you supply a null or empty string
578
+ # value, this operation returns an error.
579
+ #
580
+ # For help finding the key ID and ARN, see [Finding the Key ID and
581
+ # ARN][2] in the *AWS Key Management Service Developer Guide*.
582
+ #
583
+ # Specify the key ID or the Amazon Resource Name (ARN) of the CMK.
584
+ #
585
+ # For example:
586
+ #
587
+ # * Key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
588
+ #
589
+ # * Key ARN:
590
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
591
+ #
592
+ # To get the key ID and key ARN for a CMK, use ListKeys or DescribeKey.
567
593
  #
568
594
  #
569
595
  #
570
- # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/viewing-keys.html#find-cmk-id-arn
596
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
597
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/viewing-keys.html#find-cmk-id-arn
571
598
  #
572
599
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
573
600
  #
@@ -621,12 +648,30 @@ module Aws::KMS
621
648
  # For help with failures, see [Troubleshooting a Custom Key Store][4] in
622
649
  # the *AWS Key Management Service Developer Guide*.
623
650
  #
651
+ # **Cross-account use**\: No. You cannot perform this operation on a
652
+ # custom key store in a different AWS account.
653
+ #
654
+ # **Required permissions**\: [kms:CreateCustomKeyStore][5] (IAM policy).
655
+ #
656
+ # **Related operations:**
657
+ #
658
+ # * ConnectCustomKeyStore
659
+ #
660
+ # * DeleteCustomKeyStore
661
+ #
662
+ # * DescribeCustomKeyStores
663
+ #
664
+ # * DisconnectCustomKeyStore
665
+ #
666
+ # * UpdateCustomKeyStore
667
+ #
624
668
  #
625
669
  #
626
670
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
627
671
  # [2]: https://docs.aws.amazon.com/cloudhsm/latest/userguide/clusters.html
628
672
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/create-keystore.html#before-keystore
629
673
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html
674
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
630
675
  #
631
676
  # @option params [required, String] :custom_key_store_name
632
677
  # Specifies a friendly name for the custom key store. The name must be
@@ -728,17 +773,29 @@ module Aws::KMS
728
773
  #
729
774
  # For information about symmetric and asymmetric CMKs, see [Using
730
775
  # Symmetric and Asymmetric CMKs][8] in the *AWS Key Management Service
731
- # Developer Guide*.
732
- #
733
- # To perform this operation on a CMK in a different AWS account, specify
734
- # the key ARN in the value of the `KeyId` parameter. For more
735
- # information about grants, see [Grants][9] in the <i> <i>AWS Key
736
- # Management Service Developer Guide</i> </i>.
776
+ # Developer Guide*. For more information about grants, see [Grants][9]
777
+ # in the <i> <i>AWS Key Management Service Developer Guide</i> </i>.
737
778
  #
738
779
  # The CMK that you use for this operation must be in a compatible key
739
780
  # state. For details, see [How Key State Affects Use of a Customer
740
781
  # Master Key][10] in the *AWS Key Management Service Developer Guide*.
741
782
  #
783
+ # **Cross-account use**\: Yes. To perform this operation on a CMK in a
784
+ # different AWS account, specify the key ARN in the value of the `KeyId`
785
+ # parameter.
786
+ #
787
+ # **Required permissions**\: [kms:CreateGrant][11] (key policy)
788
+ #
789
+ # **Related operations:**
790
+ #
791
+ # * ListGrants
792
+ #
793
+ # * ListRetirableGrants
794
+ #
795
+ # * RetireGrant
796
+ #
797
+ # * RevokeGrant
798
+ #
742
799
  #
743
800
  #
744
801
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
@@ -751,6 +808,7 @@ module Aws::KMS
751
808
  # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
752
809
  # [9]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html
753
810
  # [10]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
811
+ # [11]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
754
812
  #
755
813
  # @option params [required, String] :key_id
756
814
  # The unique identifier for the customer master key (CMK) that the grant
@@ -810,6 +868,10 @@ module Aws::KMS
810
868
  # [Encryption Context][2] in the <i> <i>AWS Key Management Service
811
869
  # Developer Guide</i> </i>.
812
870
  #
871
+ # Grant constraints are not applied to operations that do not support an
872
+ # encryption context, such as cryptographic operations with asymmetric
873
+ # CMKs and management operations, such as DescribeKey or RetireGrant.
874
+ #
813
875
  #
814
876
  #
815
877
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
@@ -826,9 +888,8 @@ module Aws::KMS
826
888
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
827
889
  #
828
890
  # @option params [String] :name
829
- # A friendly name for identifying the grant. Use this value to prevent
830
- # the unintended creation of duplicate grants when retrying this
831
- # request.
891
+ # A friendly name for the grant. Use this value to prevent the
892
+ # unintended creation of duplicate grants when retrying this request.
832
893
  #
833
894
  # When this value is absent, all `CreateGrant` requests result in a new
834
895
  # grant with a unique `GrantId` even if all the supplied parameters are
@@ -839,8 +900,8 @@ module Aws::KMS
839
900
  # identical parameters; if the grant already exists, the original
840
901
  # `GrantId` is returned without creating a new grant. Note that the
841
902
  # returned grant token is unique with every `CreateGrant` request, even
842
- # when a duplicate `GrantId` is returned. All grant tokens obtained in
843
- # this way can be used interchangeably.
903
+ # when a duplicate `GrantId` is returned. All grant tokens for the same
904
+ # grant ID can be used interchangeably.
844
905
  #
845
906
  # @return [Types::CreateGrantResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
846
907
  #
@@ -902,8 +963,7 @@ module Aws::KMS
902
963
  end
903
964
 
904
965
  # Creates a unique customer managed [customer master key][1] (CMK) in
905
- # your AWS account and Region. You cannot use this operation to create a
906
- # CMK in a different AWS account.
966
+ # your AWS account and Region.
907
967
  #
908
968
  # You can use the `CreateKey` operation to create symmetric or
909
969
  # asymmetric CMKs.
@@ -978,6 +1038,22 @@ module Aws::KMS
978
1038
  # Stores][6] in the <i> <i>AWS Key Management Service Developer
979
1039
  # Guide</i> </i>.
980
1040
  #
1041
+ # **Cross-account use**\: No. You cannot use this operation to create a
1042
+ # CMK in a different AWS account.
1043
+ #
1044
+ # **Required permissions**\: [kms:CreateKey][7] (IAM policy). To use the
1045
+ # `Tags` parameter, [kms:TagResource][7] (IAM policy). For examples and
1046
+ # information about related permissions, see [Allow a user to create
1047
+ # CMKs][8] in the *AWS Key Management Service Developer Guide*.
1048
+ #
1049
+ # **Related operations:**
1050
+ #
1051
+ # * DescribeKey
1052
+ #
1053
+ # * ListKeys
1054
+ #
1055
+ # * ScheduleKeyDeletion
1056
+ #
981
1057
  #
982
1058
  #
983
1059
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#master-keys
@@ -986,6 +1062,8 @@ module Aws::KMS
986
1062
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
987
1063
  # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html
988
1064
  # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
1065
+ # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1066
+ # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/iam-policies.html#iam-policy-example-create-key
989
1067
  #
990
1068
  # @option params [String] :policy
991
1069
  # The key policy to attach to the CMK.
@@ -1015,11 +1093,15 @@ module Aws::KMS
1015
1093
  #
1016
1094
  # The key policy size quota is 32 kilobytes (32768 bytes).
1017
1095
  #
1096
+ # For help writing and formatting a JSON policy document, see the [IAM
1097
+ # JSON Policy Reference][4] in the <i> <i>IAM User Guide</i> </i>.
1098
+ #
1018
1099
  #
1019
1100
  #
1020
1101
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
1021
1102
  # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_eventual-consistency
1022
1103
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default
1104
+ # [4]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies.html
1023
1105
  #
1024
1106
  # @option params [String] :description
1025
1107
  # A description of the CMK.
@@ -1188,9 +1270,13 @@ module Aws::KMS
1188
1270
  # Use this parameter to tag the CMK when it is created. To add tags to
1189
1271
  # an existing CMK, use the TagResource operation.
1190
1272
  #
1273
+ # To use this parameter, you must have [kms:TagResource][2] permission
1274
+ # in an IAM policy.
1275
+ #
1191
1276
  #
1192
1277
  #
1193
1278
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html
1279
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1194
1280
  #
1195
1281
  # @return [Types::CreateKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1196
1282
  #
@@ -1303,33 +1389,55 @@ module Aws::KMS
1303
1389
  # encryption][3]. These libraries return a ciphertext format that is
1304
1390
  # incompatible with AWS KMS.
1305
1391
  #
1306
- # If the ciphertext was encrypted under a symmetric CMK, you do not need
1307
- # to specify the CMK or the encryption algorithm. AWS KMS can get this
1308
- # information from metadata that it adds to the symmetric ciphertext
1309
- # blob. However, if you prefer, you can specify the `KeyId` to ensure
1310
- # that a particular CMK is used to decrypt the ciphertext. If you
1311
- # specify a different CMK than the one used to encrypt the ciphertext,
1312
- # the `Decrypt` operation fails.
1392
+ # If the ciphertext was encrypted under a symmetric CMK, the `KeyId`
1393
+ # parameter is optional. AWS KMS can get this information from metadata
1394
+ # that it adds to the symmetric ciphertext blob. This feature adds
1395
+ # durability to your implementation by ensuring that authorized users
1396
+ # can decrypt ciphertext decades after it was encrypted, even if
1397
+ # they've lost track of the CMK ID. However, specifying the CMK is
1398
+ # always recommended as a best practice. When you use the `KeyId`
1399
+ # parameter to specify a CMK, AWS KMS only uses the CMK you specify. If
1400
+ # the ciphertext was encrypted under a different CMK, the `Decrypt`
1401
+ # operation fails. This practice ensures that you use the CMK that you
1402
+ # intend.
1313
1403
  #
1314
1404
  # Whenever possible, use key policies to give users permission to call
1315
- # the Decrypt operation on a particular CMK, instead of using IAM
1405
+ # the `Decrypt` operation on a particular CMK, instead of using IAM
1316
1406
  # policies. Otherwise, you might create an IAM user policy that gives
1317
- # the user Decrypt permission on all CMKs. This user could decrypt
1407
+ # the user `Decrypt` permission on all CMKs. This user could decrypt
1318
1408
  # ciphertext that was encrypted by CMKs in other accounts if the key
1319
1409
  # policy for the cross-account CMK permits it. If you must use an IAM
1320
1410
  # policy for `Decrypt` permissions, limit the user to particular CMKs or
1321
- # particular trusted accounts.
1411
+ # particular trusted accounts. For details, see [Best practices for IAM
1412
+ # policies][4] in the *AWS Key Management Service Developer Guide*.
1322
1413
  #
1323
1414
  # The CMK that you use for this operation must be in a compatible key
1324
1415
  # state. For details, see [How Key State Affects Use of a Customer
1325
- # Master Key][4] in the *AWS Key Management Service Developer Guide*.
1416
+ # Master Key][5] in the *AWS Key Management Service Developer Guide*.
1417
+ #
1418
+ # **Cross-account use**\: Yes. You can decrypt a ciphertext using a CMK
1419
+ # in a different AWS account.
1420
+ #
1421
+ # **Required permissions**\: [kms:Decrypt][6] (key policy)
1422
+ #
1423
+ # **Related operations:**
1424
+ #
1425
+ # * Encrypt
1426
+ #
1427
+ # * GenerateDataKey
1428
+ #
1429
+ # * GenerateDataKeyPair
1430
+ #
1431
+ # * ReEncrypt
1326
1432
  #
1327
1433
  #
1328
1434
  #
1329
1435
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
1330
1436
  # [2]: https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/
1331
1437
  # [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html
1332
- # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
1438
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/iam-policies.html#iam-policies-best-practices
1439
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
1440
+ # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1333
1441
  #
1334
1442
  # @option params [required, String, StringIO, File] :ciphertext_blob
1335
1443
  # Ciphertext to be decrypted. The blob includes metadata.
@@ -1366,22 +1474,20 @@ module Aws::KMS
1366
1474
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
1367
1475
  #
1368
1476
  # @option params [String] :key_id
1369
- # Specifies the customer master key (CMK) that AWS KMS will use to
1370
- # decrypt the ciphertext. Enter a key ID of the CMK that was used to
1371
- # encrypt the ciphertext.
1372
- #
1373
- # If you specify a `KeyId` value, the `Decrypt` operation succeeds only
1374
- # if the specified CMK was used to encrypt the ciphertext.
1477
+ # Specifies the customer master key (CMK) that AWS KMS uses to decrypt
1478
+ # the ciphertext. Enter a key ID of the CMK that was used to encrypt the
1479
+ # ciphertext.
1375
1480
  #
1376
1481
  # This parameter is required only when the ciphertext was encrypted
1377
- # under an asymmetric CMK. Otherwise, AWS KMS uses the metadata that it
1378
- # adds to the ciphertext blob to determine which CMK was used to encrypt
1379
- # the ciphertext. However, you can use this parameter to ensure that a
1380
- # particular CMK (of any kind) is used to decrypt the ciphertext.
1482
+ # under an asymmetric CMK. If you used a symmetric CMK, AWS KMS can get
1483
+ # the CMK from metadata that it adds to the symmetric ciphertext blob.
1484
+ # However, it is always recommended as a best practice. This practice
1485
+ # ensures that you use the CMK that you intend.
1381
1486
  #
1382
1487
  # To specify a CMK, use its key ID, Amazon Resource Name (ARN), alias
1383
1488
  # name, or alias ARN. When using an alias name, prefix it with
1384
- # `"alias/"`.
1489
+ # `"alias/"`. To specify a CMK in a different AWS account, you must use
1490
+ # the key ARN or alias ARN.
1385
1491
  #
1386
1492
  # For example:
1387
1493
  #
@@ -1421,6 +1527,7 @@ module Aws::KMS
1421
1527
  #
1422
1528
  # resp = client.decrypt({
1423
1529
  # ciphertext_blob: "<binary data>", # The encrypted data (ciphertext).
1530
+ # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # A key identifier for the CMK to use to decrypt the data.
1424
1531
  # })
1425
1532
  #
1426
1533
  # resp.to_h outputs the following:
@@ -1456,8 +1563,7 @@ module Aws::KMS
1456
1563
  req.send_request(options)
1457
1564
  end
1458
1565
 
1459
- # Deletes the specified alias. You cannot perform this operation on an
1460
- # alias in a different AWS account.
1566
+ # Deletes the specified alias.
1461
1567
  #
1462
1568
  # Because an alias is not a property of a CMK, you can delete and change
1463
1569
  # the aliases of a CMK without affecting the CMK. Also, aliases do not
@@ -1469,6 +1575,31 @@ module Aws::KMS
1469
1575
  # new alias. To associate an existing alias with a different customer
1470
1576
  # master key (CMK), call UpdateAlias.
1471
1577
  #
1578
+ # **Cross-account use**\: No. You cannot perform this operation on an
1579
+ # alias in a different AWS account.
1580
+ #
1581
+ # **Required permissions**
1582
+ #
1583
+ # * [kms:DeleteAlias][1] on the alias (IAM policy).
1584
+ #
1585
+ # * [kms:DeleteAlias][1] on the CMK (key policy).
1586
+ #
1587
+ # For details, see [Controlling access to aliases][2] in the *AWS Key
1588
+ # Management Service Developer Guide*.
1589
+ #
1590
+ # **Related operations:**
1591
+ #
1592
+ # * CreateAlias
1593
+ #
1594
+ # * ListAliases
1595
+ #
1596
+ # * UpdateAlias
1597
+ #
1598
+ #
1599
+ #
1600
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1601
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access
1602
+ #
1472
1603
  # @option params [required, String] :alias_name
1473
1604
  # The alias to be deleted. The alias name must begin with `alias/`
1474
1605
  # followed by the alias name, such as `alias/ExampleAlias`.
@@ -1531,12 +1662,30 @@ module Aws::KMS
1531
1662
  # AWS KMS, which combines the convenience and extensive integration of
1532
1663
  # AWS KMS with the isolation and control of a single-tenant key store.
1533
1664
  #
1665
+ # **Cross-account use**\: No. You cannot perform this operation on a
1666
+ # custom key store in a different AWS account.
1667
+ #
1668
+ # **Required permissions**\: [kms:DeleteCustomKeyStore][5] (IAM policy)
1669
+ #
1670
+ # **Related operations:**
1671
+ #
1672
+ # * ConnectCustomKeyStore
1673
+ #
1674
+ # * CreateCustomKeyStore
1675
+ #
1676
+ # * DescribeCustomKeyStores
1677
+ #
1678
+ # * DisconnectCustomKeyStore
1679
+ #
1680
+ # * UpdateCustomKeyStore
1681
+ #
1534
1682
  #
1535
1683
  #
1536
1684
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
1537
1685
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#master_keys
1538
1686
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
1539
1687
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html#fix-keystore-orphaned-key
1688
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1540
1689
  #
1541
1690
  # @option params [required, String] :custom_key_store_id
1542
1691
  # Enter the ID of the custom key store you want to delete. To find the
@@ -1563,7 +1712,6 @@ module Aws::KMS
1563
1712
  # makes the specified customer master key (CMK) unusable. For more
1564
1713
  # information about importing key material into AWS KMS, see [Importing
1565
1714
  # Key Material][1] in the *AWS Key Management Service Developer Guide*.
1566
- # You cannot perform this operation on a CMK in a different AWS account.
1567
1715
  #
1568
1716
  # When the specified CMK is in the `PendingDeletion` state, this
1569
1717
  # operation does not change the CMK's state. Otherwise, it changes the
@@ -1576,10 +1724,23 @@ module Aws::KMS
1576
1724
  # state. For details, see [How Key State Affects Use of a Customer
1577
1725
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
1578
1726
  #
1727
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
1728
+ # in a different AWS account.
1729
+ #
1730
+ # **Required permissions**\: [kms:DeleteImportedKeyMaterial][3] (key
1731
+ # policy)
1732
+ #
1733
+ # **Related operations:**
1734
+ #
1735
+ # * GetParametersForImport
1736
+ #
1737
+ # * ImportKeyMaterial
1738
+ #
1579
1739
  #
1580
1740
  #
1581
1741
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html
1582
1742
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
1743
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1583
1744
  #
1584
1745
  # @option params [required, String] :key_id
1585
1746
  # Identifies the CMK from which you are deleting imported key material.
@@ -1652,10 +1813,29 @@ module Aws::KMS
1652
1813
  # Custom Key Stores][2] topic in the *AWS Key Management Service
1653
1814
  # Developer Guide*.
1654
1815
  #
1816
+ # **Cross-account use**\: No. You cannot perform this operation on a
1817
+ # custom key store in a different AWS account.
1818
+ #
1819
+ # **Required permissions**\: [kms:DescribeCustomKeyStores][3] (IAM
1820
+ # policy)
1821
+ #
1822
+ # **Related operations:**
1823
+ #
1824
+ # * ConnectCustomKeyStore
1825
+ #
1826
+ # * CreateCustomKeyStore
1827
+ #
1828
+ # * DeleteCustomKeyStore
1829
+ #
1830
+ # * DisconnectCustomKeyStore
1831
+ #
1832
+ # * UpdateCustomKeyStore
1833
+ #
1655
1834
  #
1656
1835
  #
1657
1836
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
1658
1837
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html
1838
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1659
1839
  #
1660
1840
  # @option params [String] :custom_key_store_id
1661
1841
  # Gets only information about the specified custom key store. Enter the
@@ -1757,8 +1937,27 @@ module Aws::KMS
1757
1937
  # CMK][4]. Then, it associates the alias with the new CMK, and returns
1758
1938
  # the `KeyId` and `Arn` of the new CMK in the response.
1759
1939
  #
1760
- # To perform this operation on a CMK in a different AWS account, specify
1761
- # the key ARN or alias ARN in the value of the KeyId parameter.
1940
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
1941
+ # different AWS account, specify the key ARN or alias ARN in the value
1942
+ # of the `KeyId` parameter.
1943
+ #
1944
+ # **Required permissions**\: [kms:DescribeKey][5] (key policy)
1945
+ #
1946
+ # **Related operations:**
1947
+ #
1948
+ # * GetKeyPolicy
1949
+ #
1950
+ # * GetKeyRotationStatus
1951
+ #
1952
+ # * ListAliases
1953
+ #
1954
+ # * ListGrants
1955
+ #
1956
+ # * ListKeys
1957
+ #
1958
+ # * ListResourceTags
1959
+ #
1960
+ # * ListRetirableGrants
1762
1961
  #
1763
1962
  #
1764
1963
  #
@@ -1766,6 +1965,7 @@ module Aws::KMS
1766
1965
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
1767
1966
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html#rotate-keys-how-it-works
1768
1967
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#master_keys
1968
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1769
1969
  #
1770
1970
  # @option params [required, String] :key_id
1771
1971
  # Describes the specified customer master key (CMK).
@@ -1875,9 +2075,8 @@ module Aws::KMS
1875
2075
  req.send_request(options)
1876
2076
  end
1877
2077
 
1878
- # Sets the state of a customer master key (CMK) to disabled, thereby
1879
- # preventing its use for [cryptographic operations][1]. You cannot
1880
- # perform this operation on a CMK in a different AWS account.
2078
+ # Sets the state of a customer master key (CMK) to disabled. This change
2079
+ # temporarily prevents use of the CMK for [cryptographic operations][1].
1881
2080
  #
1882
2081
  # For more information about how key state affects the use of a CMK, see
1883
2082
  # [How Key State Affects the Use of a Customer Master Key][2] in the <i>
@@ -1887,10 +2086,18 @@ module Aws::KMS
1887
2086
  # state. For details, see [How Key State Affects Use of a Customer
1888
2087
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
1889
2088
  #
2089
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
2090
+ # in a different AWS account.
2091
+ #
2092
+ # **Required permissions**\: [kms:DisableKey][3] (key policy)
2093
+ #
2094
+ # **Related operations**\: EnableKey
2095
+ #
1890
2096
  #
1891
2097
  #
1892
2098
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
1893
2099
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
2100
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1894
2101
  #
1895
2102
  # @option params [required, String] :key_id
1896
2103
  # A unique identifier for the customer master key (CMK).
@@ -1936,23 +2143,34 @@ module Aws::KMS
1936
2143
  # symmetric customer master key (CMK).
1937
2144
  #
1938
2145
  # You cannot enable automatic rotation of asymmetric CMKs, CMKs with
1939
- # imported key material, or CMKs in a [custom key store][2]. You cannot
1940
- # perform this operation on a CMK in a different AWS account.
2146
+ # imported key material, or CMKs in a [custom key store][2].
1941
2147
  #
1942
2148
  # The CMK that you use for this operation must be in a compatible key
1943
2149
  # state. For details, see [How Key State Affects Use of a Customer
1944
2150
  # Master Key][3] in the *AWS Key Management Service Developer Guide*.
1945
2151
  #
2152
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
2153
+ # in a different AWS account.
2154
+ #
2155
+ # **Required permissions**\: [kms:DisableKeyRotation][4] (key policy)
2156
+ #
2157
+ # **Related operations:**
2158
+ #
2159
+ # * EnableKeyRotation
2160
+ #
2161
+ # * GetKeyRotationStatus
2162
+ #
1946
2163
  #
1947
2164
  #
1948
2165
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html
1949
2166
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
1950
2167
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
2168
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
1951
2169
  #
1952
2170
  # @option params [required, String] :key_id
1953
- # Identifies a symmetric customer master key (CMK). You cannot enable
1954
- # automatic rotation of [asymmetric CMKs][1], CMKs with [imported key
1955
- # material][2], or CMKs in a [custom key store][3].
2171
+ # Identifies a symmetric customer master key (CMK). You cannot enable or
2172
+ # disable automatic rotation of [asymmetric CMKs][1], CMKs with
2173
+ # [imported key material][2], or CMKs in a [custom key store][3].
1956
2174
  #
1957
2175
  # Specify the key ID or the Amazon Resource Name (ARN) of the CMK.
1958
2176
  #
@@ -2023,10 +2241,29 @@ module Aws::KMS
2023
2241
  # AWS KMS, which combines the convenience and extensive integration of
2024
2242
  # AWS KMS with the isolation and control of a single-tenant key store.
2025
2243
  #
2244
+ # **Cross-account use**\: No. You cannot perform this operation on a
2245
+ # custom key store in a different AWS account.
2246
+ #
2247
+ # **Required permissions**\: [kms:DisconnectCustomKeyStore][3] (IAM
2248
+ # policy)
2249
+ #
2250
+ # **Related operations:**
2251
+ #
2252
+ # * ConnectCustomKeyStore
2253
+ #
2254
+ # * CreateCustomKeyStore
2255
+ #
2256
+ # * DeleteCustomKeyStore
2257
+ #
2258
+ # * DescribeCustomKeyStores
2259
+ #
2260
+ # * UpdateCustomKeyStore
2261
+ #
2026
2262
  #
2027
2263
  #
2028
2264
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
2029
2265
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
2266
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2030
2267
  #
2031
2268
  # @option params [required, String] :custom_key_store_id
2032
2269
  # Enter the ID of the custom key store you want to disconnect. To find
@@ -2051,17 +2288,24 @@ module Aws::KMS
2051
2288
  end
2052
2289
 
2053
2290
  # Sets the key state of a customer master key (CMK) to enabled. This
2054
- # allows you to use the CMK for [cryptographic operations][1]. You
2055
- # cannot perform this operation on a CMK in a different AWS account.
2291
+ # allows you to use the CMK for [cryptographic operations][1].
2056
2292
  #
2057
2293
  # The CMK that you use for this operation must be in a compatible key
2058
2294
  # state. For details, see [How Key State Affects Use of a Customer
2059
2295
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
2060
2296
  #
2297
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
2298
+ # in a different AWS account.
2299
+ #
2300
+ # **Required permissions**\: [kms:EnableKey][3] (key policy)
2301
+ #
2302
+ # **Related operations**\: DisableKey
2303
+ #
2061
2304
  #
2062
2305
  #
2063
2306
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations
2064
2307
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
2308
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2065
2309
  #
2066
2310
  # @option params [required, String] :key_id
2067
2311
  # A unique identifier for the customer master key (CMK).
@@ -2104,8 +2348,7 @@ module Aws::KMS
2104
2348
  end
2105
2349
 
2106
2350
  # Enables [automatic rotation of the key material][1] for the specified
2107
- # symmetric customer master key (CMK). You cannot perform this operation
2108
- # on a CMK in a different AWS account.
2351
+ # symmetric customer master key (CMK).
2109
2352
  #
2110
2353
  # You cannot enable automatic rotation of asymmetric CMKs, CMKs with
2111
2354
  # imported key material, or CMKs in a [custom key store][2].
@@ -2114,11 +2357,23 @@ module Aws::KMS
2114
2357
  # state. For details, see [How Key State Affects Use of a Customer
2115
2358
  # Master Key][3] in the *AWS Key Management Service Developer Guide*.
2116
2359
  #
2360
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
2361
+ # in a different AWS account.
2362
+ #
2363
+ # **Required permissions**\: [kms:EnableKeyRotation][4] (key policy)
2364
+ #
2365
+ # **Related operations:**
2366
+ #
2367
+ # * DisableKeyRotation
2368
+ #
2369
+ # * GetKeyRotationStatus
2370
+ #
2117
2371
  #
2118
2372
  #
2119
2373
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html
2120
2374
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
2121
2375
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
2376
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2122
2377
  #
2123
2378
  # @option params [required, String] :key_id
2124
2379
  # Identifies a symmetric customer master key (CMK). You cannot enable
@@ -2244,13 +2499,25 @@ module Aws::KMS
2244
2499
  # state. For details, see [How Key State Affects Use of a Customer
2245
2500
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
2246
2501
  #
2247
- # To perform this operation on a CMK in a different AWS account, specify
2248
- # the key ARN or alias ARN in the value of the KeyId parameter.
2502
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
2503
+ # different AWS account, specify the key ARN or alias ARN in the value
2504
+ # of the `KeyId` parameter.
2505
+ #
2506
+ # **Required permissions**\: [kms:Encrypt][3] (key policy)
2507
+ #
2508
+ # **Related operations:**
2509
+ #
2510
+ # * Decrypt
2511
+ #
2512
+ # * GenerateDataKey
2513
+ #
2514
+ # * GenerateDataKeyPair
2249
2515
  #
2250
2516
  #
2251
2517
  #
2252
2518
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context
2253
2519
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
2520
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2254
2521
  #
2255
2522
  # @option params [required, String] :key_id
2256
2523
  # A unique identifier for the customer master key (CMK).
@@ -2429,6 +2696,24 @@ module Aws::KMS
2429
2696
  # 2. Use the plaintext data key to decrypt data outside of AWS KMS,
2430
2697
  # then erase the plaintext data key from memory.
2431
2698
  #
2699
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
2700
+ # different AWS account, specify the key ARN or alias ARN in the value
2701
+ # of the `KeyId` parameter.
2702
+ #
2703
+ # **Required permissions**\: [kms:GenerateDataKey][6] (key policy)
2704
+ #
2705
+ # **Related operations:**
2706
+ #
2707
+ # * Decrypt
2708
+ #
2709
+ # * Encrypt
2710
+ #
2711
+ # * GenerateDataKeyPair
2712
+ #
2713
+ # * GenerateDataKeyPairWithoutPlaintext
2714
+ #
2715
+ # * GenerateDataKeyWithoutPlaintext
2716
+ #
2432
2717
  #
2433
2718
  #
2434
2719
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context
@@ -2436,6 +2721,7 @@ module Aws::KMS
2436
2721
  # [3]: https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/
2437
2722
  # [4]: https://docs.aws.amazon.com/dynamodb-encryption-client/latest/devguide/
2438
2723
  # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html
2724
+ # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2439
2725
  #
2440
2726
  # @option params [required, String] :key_id
2441
2727
  # Identifies the symmetric CMK that encrypts the data key.
@@ -2597,10 +2883,29 @@ module Aws::KMS
2597
2883
  # state. For details, see [How Key State Affects Use of a Customer
2598
2884
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
2599
2885
  #
2886
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
2887
+ # different AWS account, specify the key ARN or alias ARN in the value
2888
+ # of the `KeyId` parameter.
2889
+ #
2890
+ # **Required permissions**\: [kms:GenerateDataKeyPair][3] (key policy)
2891
+ #
2892
+ # **Related operations:**
2893
+ #
2894
+ # * Decrypt
2895
+ #
2896
+ # * Encrypt
2897
+ #
2898
+ # * GenerateDataKey
2899
+ #
2900
+ # * GenerateDataKeyPairWithoutPlaintext
2901
+ #
2902
+ # * GenerateDataKeyWithoutPlaintext
2903
+ #
2600
2904
  #
2601
2905
  #
2602
2906
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context
2603
2907
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
2908
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2604
2909
  #
2605
2910
  # @option params [Hash<String,String>] :encryption_context
2606
2911
  # Specifies the encryption context that will be used when encrypting the
@@ -2733,10 +3038,30 @@ module Aws::KMS
2733
3038
  # state. For details, see [How Key State Affects Use of a Customer
2734
3039
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
2735
3040
  #
3041
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
3042
+ # different AWS account, specify the key ARN or alias ARN in the value
3043
+ # of the `KeyId` parameter.
3044
+ #
3045
+ # **Required permissions**\:
3046
+ # [kms:GenerateDataKeyPairWithoutPlaintext][3] (key policy)
3047
+ #
3048
+ # **Related operations:**
3049
+ #
3050
+ # * Decrypt
3051
+ #
3052
+ # * Encrypt
3053
+ #
3054
+ # * GenerateDataKey
3055
+ #
3056
+ # * GenerateDataKeyPair
3057
+ #
3058
+ # * GenerateDataKeyWithoutPlaintext
3059
+ #
2736
3060
  #
2737
3061
  #
2738
3062
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context
2739
3063
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
3064
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2740
3065
  #
2741
3066
  # @option params [Hash<String,String>] :encryption_context
2742
3067
  # Specifies the encryption context that will be used when encrypting the
@@ -2764,7 +3089,8 @@ module Aws::KMS
2764
3089
  #
2765
3090
  # To specify a CMK, use its key ID, Amazon Resource Name (ARN), alias
2766
3091
  # name, or alias ARN. When using an alias name, prefix it with
2767
- # `"alias/"`.
3092
+ # `"alias/"`. To specify a CMK in a different AWS account, you must use
3093
+ # the key ARN or alias ARN.
2768
3094
  #
2769
3095
  # For example:
2770
3096
  #
@@ -2877,10 +3203,30 @@ module Aws::KMS
2877
3203
  # state. For details, see [How Key State Affects Use of a Customer
2878
3204
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
2879
3205
  #
3206
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
3207
+ # different AWS account, specify the key ARN or alias ARN in the value
3208
+ # of the `KeyId` parameter.
3209
+ #
3210
+ # **Required permissions**\: [kms:GenerateDataKeyWithoutPlaintext][3]
3211
+ # (key policy)
3212
+ #
3213
+ # **Related operations:**
3214
+ #
3215
+ # * Decrypt
3216
+ #
3217
+ # * Encrypt
3218
+ #
3219
+ # * GenerateDataKey
3220
+ #
3221
+ # * GenerateDataKeyPair
3222
+ #
3223
+ # * GenerateDataKeyPairWithoutPlaintext
3224
+ #
2880
3225
  #
2881
3226
  #
2882
3227
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context
2883
3228
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
3229
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
2884
3230
  #
2885
3231
  # @option params [required, String] :key_id
2886
3232
  # The identifier of the symmetric customer master key (CMK) that
@@ -3001,10 +3347,13 @@ module Aws::KMS
3001
3347
  # For more information about entropy and random number generation, see
3002
3348
  # the [AWS Key Management Service Cryptographic Details][2] whitepaper.
3003
3349
  #
3350
+ # **Required permissions**\: [kms:GenerateRandom][3] (IAM policy)
3351
+ #
3004
3352
  #
3005
3353
  #
3006
3354
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
3007
3355
  # [2]: https://d0.awsstatic.com/whitepapers/KMS-Cryptographic-Details.pdf
3356
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3008
3357
  #
3009
3358
  # @option params [Integer] :number_of_bytes
3010
3359
  # The length of the byte string.
@@ -3057,7 +3406,17 @@ module Aws::KMS
3057
3406
  end
3058
3407
 
3059
3408
  # Gets a key policy attached to the specified customer master key (CMK).
3060
- # You cannot perform this operation on a CMK in a different AWS account.
3409
+ #
3410
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
3411
+ # in a different AWS account.
3412
+ #
3413
+ # **Required permissions**\: [kms:GetKeyPolicy][1] (key policy)
3414
+ #
3415
+ # **Related operations**\: PutKeyPolicy
3416
+ #
3417
+ #
3418
+ #
3419
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3061
3420
  #
3062
3421
  # @option params [required, String] :key_id
3063
3422
  # A unique identifier for the customer master key (CMK).
@@ -3137,14 +3496,24 @@ module Aws::KMS
3137
3496
  # you cancel the deletion, the original key rotation status is
3138
3497
  # restored.
3139
3498
  #
3140
- # To perform this operation on a CMK in a different AWS account, specify
3141
- # the key ARN in the value of the `KeyId` parameter.
3499
+ # **Cross-account use**\: Yes. To perform this operation on a CMK in a
3500
+ # different AWS account, specify the key ARN in the value of the `KeyId`
3501
+ # parameter.
3502
+ #
3503
+ # **Required permissions**\: [kms:GetKeyRotationStatus][4] (key policy)
3504
+ #
3505
+ # **Related operations:**
3506
+ #
3507
+ # * DisableKeyRotation
3508
+ #
3509
+ # * EnableKeyRotation
3142
3510
  #
3143
3511
  #
3144
3512
  #
3145
3513
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html
3146
3514
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
3147
3515
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
3516
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3148
3517
  #
3149
3518
  # @option params [required, String] :key_id
3150
3519
  # A unique identifier for the customer master key (CMK).
@@ -3225,10 +3594,23 @@ module Aws::KMS
3225
3594
  # state. For details, see [How Key State Affects Use of a Customer
3226
3595
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
3227
3596
  #
3597
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
3598
+ # in a different AWS account.
3599
+ #
3600
+ # **Required permissions**\: [kms:GetParametersForImport][3] (key
3601
+ # policy)
3602
+ #
3603
+ # **Related operations:**
3604
+ #
3605
+ # * ImportKeyMaterial
3606
+ #
3607
+ # * DeleteImportedKeyMaterial
3608
+ #
3228
3609
  #
3229
3610
  #
3230
3611
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html
3231
3612
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
3613
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3232
3614
  #
3233
3615
  # @option params [required, String] :key_id
3234
3616
  # The identifier of the symmetric CMK into which you will import key
@@ -3351,6 +3733,14 @@ module Aws::KMS
3351
3733
  # state. For details, see [How Key State Affects Use of a Customer
3352
3734
  # Master Key][7] in the *AWS Key Management Service Developer Guide*.
3353
3735
  #
3736
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
3737
+ # different AWS account, specify the key ARN or alias ARN in the value
3738
+ # of the `KeyId` parameter.
3739
+ #
3740
+ # **Required permissions**\: [kms:GetPublicKey][8] (key policy)
3741
+ #
3742
+ # **Related operations**\: CreateKey
3743
+ #
3354
3744
  #
3355
3745
  #
3356
3746
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
@@ -3360,6 +3750,7 @@ module Aws::KMS
3360
3750
  # [5]: https://docs.aws.amazon.com/kms/latest/APIReference/API_GetPublicKey.html#KMS-GetPublicKey-response-EncryptionAlgorithms
3361
3751
  # [6]: https://docs.aws.amazon.com/kms/latest/APIReference/API_GetPublicKey.html#KMS-GetPublicKey-response-SigningAlgorithms
3362
3752
  # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
3753
+ # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3363
3754
  #
3364
3755
  # @option params [required, String] :key_id
3365
3756
  # Identifies the asymmetric CMK that includes the public key.
@@ -3482,12 +3873,24 @@ module Aws::KMS
3482
3873
  # state. For details, see [How Key State Affects Use of a Customer
3483
3874
  # Master Key][4] in the *AWS Key Management Service Developer Guide*.
3484
3875
  #
3876
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
3877
+ # in a different AWS account.
3878
+ #
3879
+ # **Required permissions**\: [kms:ImportKeyMaterial][5] (key policy)
3880
+ #
3881
+ # **Related operations:**
3882
+ #
3883
+ # * DeleteImportedKeyMaterial
3884
+ #
3885
+ # * GetParametersForImport
3886
+ #
3485
3887
  #
3486
3888
  #
3487
3889
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html#reimport-key-material
3488
3890
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html
3489
3891
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html#importing-keys-overview
3490
3892
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
3893
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3491
3894
  #
3492
3895
  # @option params [required, String] :key_id
3493
3896
  # The identifier of the symmetric CMK that receives the imported key
@@ -3563,13 +3966,12 @@ module Aws::KMS
3563
3966
  req.send_request(options)
3564
3967
  end
3565
3968
 
3566
- # Gets a list of aliases in the caller's AWS account and region. You
3567
- # cannot list aliases in other accounts. For more information about
3568
- # aliases, see CreateAlias.
3969
+ # Gets a list of aliases in the caller's AWS account and region. For
3970
+ # more information about aliases, see CreateAlias.
3569
3971
  #
3570
- # By default, the ListAliases command returns all aliases in the account
3571
- # and region. To get only the aliases that point to a particular
3572
- # customer master key (CMK), use the `KeyId` parameter.
3972
+ # By default, the `ListAliases` operation returns all aliases in the
3973
+ # account and region. To get only the aliases associated with a
3974
+ # particular customer master key (CMK), use the `KeyId` parameter.
3573
3975
  #
3574
3976
  # The `ListAliases` response can include aliases that you created and
3575
3977
  # associated with your customer managed CMKs, and aliases that AWS
@@ -3583,18 +3985,45 @@ module Aws::KMS
3583
3985
  # including predefined aliases, do not count against your [AWS KMS
3584
3986
  # aliases quota][1].
3585
3987
  #
3988
+ # **Cross-account use**\: No. `ListAliases` does not return aliases in
3989
+ # other AWS accounts.
3990
+ #
3991
+ # **Required permissions**\: [kms:ListAliases][2] (IAM policy)
3992
+ #
3993
+ # For details, see [Controlling access to aliases][3] in the *AWS Key
3994
+ # Management Service Developer Guide*.
3995
+ #
3996
+ # **Related operations:**
3997
+ #
3998
+ # * CreateAlias
3999
+ #
4000
+ # * DeleteAlias
4001
+ #
4002
+ # * UpdateAlias
4003
+ #
3586
4004
  #
3587
4005
  #
3588
4006
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/limits.html#aliases-limit
4007
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4008
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access
3589
4009
  #
3590
4010
  # @option params [String] :key_id
3591
- # Lists only aliases that refer to the specified CMK. The value of this
3592
- # parameter can be the ID or Amazon Resource Name (ARN) of a CMK in the
3593
- # caller's account and region. You cannot use an alias name or alias
3594
- # ARN in this value.
4011
+ # Lists only aliases that are associated with the specified CMK. Enter a
4012
+ # CMK in your AWS account.
3595
4013
  #
3596
4014
  # This parameter is optional. If you omit it, `ListAliases` returns all
3597
- # aliases in the account and region.
4015
+ # aliases in the account and Region.
4016
+ #
4017
+ # Specify the key ID or the Amazon Resource Name (ARN) of the CMK.
4018
+ #
4019
+ # For example:
4020
+ #
4021
+ # * Key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
4022
+ #
4023
+ # * Key ARN:
4024
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
4025
+ #
4026
+ # To get the key ID and key ARN for a CMK, use ListKeys or DescribeKey.
3598
4027
  #
3599
4028
  # @option params [Integer] :limit
3600
4029
  # Use this parameter to specify the maximum number of items to return.
@@ -3686,6 +4115,8 @@ module Aws::KMS
3686
4115
  # resp.aliases[0].alias_name #=> String
3687
4116
  # resp.aliases[0].alias_arn #=> String
3688
4117
  # resp.aliases[0].target_key_id #=> String
4118
+ # resp.aliases[0].creation_date #=> Time
4119
+ # resp.aliases[0].last_updated_date #=> Time
3689
4120
  # resp.next_marker #=> String
3690
4121
  # resp.truncated #=> Boolean
3691
4122
  #
@@ -3700,8 +4131,8 @@ module Aws::KMS
3700
4131
 
3701
4132
  # Gets a list of all grants for the specified customer master key (CMK).
3702
4133
  #
3703
- # To perform this operation on a CMK in a different AWS account, specify
3704
- # the key ARN in the value of the `KeyId` parameter.
4134
+ # You must specify the CMK in all requests. You can filter the grant
4135
+ # list by grant ID or grantee principal.
3705
4136
  #
3706
4137
  # <note markdown="1"> The `GranteePrincipal` field in the `ListGrants` response usually
3707
4138
  # contains the user or role designated as the grantee principal in the
@@ -3712,9 +4143,26 @@ module Aws::KMS
3712
4143
  #
3713
4144
  # </note>
3714
4145
  #
4146
+ # **Cross-account use**\: Yes. To perform this operation on a CMK in a
4147
+ # different AWS account, specify the key ARN in the value of the `KeyId`
4148
+ # parameter.
4149
+ #
4150
+ # **Required permissions**\: [kms:ListGrants][2] (key policy)
4151
+ #
4152
+ # **Related operations:**
4153
+ #
4154
+ # * CreateGrant
4155
+ #
4156
+ # * ListRetirableGrants
4157
+ #
4158
+ # * RetireGrant
4159
+ #
4160
+ # * RevokeGrant
4161
+ #
3715
4162
  #
3716
4163
  #
3717
4164
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_principal.html#principal-services
4165
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
3718
4166
  #
3719
4167
  # @option params [Integer] :limit
3720
4168
  # Use this parameter to specify the maximum number of items to return.
@@ -3730,7 +4178,8 @@ module Aws::KMS
3730
4178
  # from the truncated response you just received.
3731
4179
  #
3732
4180
  # @option params [required, String] :key_id
3733
- # A unique identifier for the customer master key (CMK).
4181
+ # Returns only grants for the specified customer master key (CMK). This
4182
+ # parameter is required.
3734
4183
  #
3735
4184
  # Specify the key ID or the Amazon Resource Name (ARN) of the CMK. To
3736
4185
  # specify a CMK in a different AWS account, you must use the key ARN.
@@ -3744,6 +4193,14 @@ module Aws::KMS
3744
4193
  #
3745
4194
  # To get the key ID and key ARN for a CMK, use ListKeys or DescribeKey.
3746
4195
  #
4196
+ # @option params [String] :grant_id
4197
+ # Returns only the grant with the specified grant ID. The grant ID
4198
+ # uniquely identifies the grant.
4199
+ #
4200
+ # @option params [String] :grantee_principal
4201
+ # Returns only grants where the specified principal is the grantee
4202
+ # principal for the grant.
4203
+ #
3747
4204
  # @return [Types::ListGrantsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
3748
4205
  #
3749
4206
  # * {Types::ListGrantsResponse#grants #grants} => Array&lt;Types::GrantListEntry&gt;
@@ -3825,6 +4282,8 @@ module Aws::KMS
3825
4282
  # limit: 1,
3826
4283
  # marker: "MarkerType",
3827
4284
  # key_id: "KeyIdType", # required
4285
+ # grant_id: "GrantIdType",
4286
+ # grantee_principal: "PrincipalIdType",
3828
4287
  # })
3829
4288
  #
3830
4289
  # @example Response structure
@@ -3858,9 +4317,23 @@ module Aws::KMS
3858
4317
  # Gets the names of the key policies that are attached to a customer
3859
4318
  # master key (CMK). This operation is designed to get policy names that
3860
4319
  # you can use in a GetKeyPolicy operation. However, the only valid
3861
- # policy name is `default`. You cannot perform this operation on a CMK
4320
+ # policy name is `default`.
4321
+ #
4322
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
3862
4323
  # in a different AWS account.
3863
4324
  #
4325
+ # **Required permissions**\: [kms:ListKeyPolicies][1] (key policy)
4326
+ #
4327
+ # **Related operations:**
4328
+ #
4329
+ # * GetKeyPolicy
4330
+ #
4331
+ # * PutKeyPolicy
4332
+ #
4333
+ #
4334
+ #
4335
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4336
+ #
3864
4337
  # @option params [required, String] :key_id
3865
4338
  # A unique identifier for the customer master key (CMK).
3866
4339
  #
@@ -3943,6 +4416,25 @@ module Aws::KMS
3943
4416
  # Gets a list of all customer master keys (CMKs) in the caller's AWS
3944
4417
  # account and Region.
3945
4418
  #
4419
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
4420
+ # in a different AWS account.
4421
+ #
4422
+ # **Required permissions**\: [kms:ListKeys][1] (IAM policy)
4423
+ #
4424
+ # **Related operations:**
4425
+ #
4426
+ # * CreateKey
4427
+ #
4428
+ # * DescribeKey
4429
+ #
4430
+ # * ListAliases
4431
+ #
4432
+ # * ListResourceTags
4433
+ #
4434
+ #
4435
+ #
4436
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4437
+ #
3946
4438
  # @option params [Integer] :limit
3947
4439
  # Use this parameter to specify the maximum number of items to return.
3948
4440
  # When this value is present, AWS KMS does not return more than the
@@ -4032,10 +4524,29 @@ module Aws::KMS
4032
4524
  req.send_request(options)
4033
4525
  end
4034
4526
 
4035
- # Returns a list of all tags for the specified customer master key
4036
- # (CMK).
4527
+ # Returns all tags on the specified customer master key (CMK).
4528
+ #
4529
+ # For general information about tags, including the format and syntax,
4530
+ # see [Tagging AWS resources][1] in the *Amazon Web Services General
4531
+ # Reference*. For information about using tags in AWS KMS, see [Tagging
4532
+ # keys][2].
4533
+ #
4534
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
4535
+ # in a different AWS account.
4536
+ #
4537
+ # **Required permissions**\: [kms:ListResourceTags][3] (key policy)
4538
+ #
4539
+ # **Related operations:**
4037
4540
  #
4038
- # You cannot perform this operation on a CMK in a different AWS account.
4541
+ # * TagResource
4542
+ #
4543
+ # * UntagResource
4544
+ #
4545
+ #
4546
+ #
4547
+ # [1]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
4548
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html
4549
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4039
4550
  #
4040
4551
  # @option params [required, String] :key_id
4041
4552
  # A unique identifier for the customer master key (CMK).
@@ -4126,11 +4637,37 @@ module Aws::KMS
4126
4637
  req.send_request(options)
4127
4638
  end
4128
4639
 
4129
- # Returns a list of all grants for which the grant's
4130
- # `RetiringPrincipal` matches the one specified.
4640
+ # Returns all grants in which the specified principal is the
4641
+ # `RetiringPrincipal` in the grant.
4642
+ #
4643
+ # You can specify any principal in your AWS account. The grants that are
4644
+ # returned include grants for CMKs in your AWS account and other AWS
4645
+ # accounts.
4646
+ #
4647
+ # You might use this operation to determine which grants you may retire.
4648
+ # To retire a grant, use the RetireGrant operation.
4649
+ #
4650
+ # **Cross-account use**\: You must specify a principal in your AWS
4651
+ # account. However, this operation can return grants in any AWS account.
4652
+ # You do not need `kms:ListRetirableGrants` permission (or any other
4653
+ # additional permission) in any AWS account other than your own.
4131
4654
  #
4132
- # A typical use is to list all grants that you are able to retire. To
4133
- # retire a grant, use RetireGrant.
4655
+ # **Required permissions**\: [kms:ListRetirableGrants][1] (IAM policy)
4656
+ # in your AWS account.
4657
+ #
4658
+ # **Related operations:**
4659
+ #
4660
+ # * CreateGrant
4661
+ #
4662
+ # * ListGrants
4663
+ #
4664
+ # * RetireGrant
4665
+ #
4666
+ # * RevokeGrant
4667
+ #
4668
+ #
4669
+ #
4670
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4134
4671
  #
4135
4672
  # @option params [Integer] :limit
4136
4673
  # Use this parameter to specify the maximum number of items to return.
@@ -4146,7 +4683,8 @@ module Aws::KMS
4146
4683
  # from the truncated response you just received.
4147
4684
  #
4148
4685
  # @option params [required, String] :retiring_principal
4149
- # The retiring principal for which to list grants.
4686
+ # The retiring principal for which to list grants. Enter a principal in
4687
+ # your AWS account.
4150
4688
  #
4151
4689
  # To specify the retiring principal, use the [Amazon Resource Name
4152
4690
  # (ARN)][1] of an AWS principal. Valid AWS principals include AWS
@@ -4230,15 +4768,28 @@ module Aws::KMS
4230
4768
  req.send_request(options)
4231
4769
  end
4232
4770
 
4233
- # Attaches a key policy to the specified customer master key (CMK). You
4234
- # cannot perform this operation on a CMK in a different AWS account.
4771
+ # Attaches a key policy to the specified customer master key (CMK).
4235
4772
  #
4236
4773
  # For more information about key policies, see [Key Policies][1] in the
4237
- # *AWS Key Management Service Developer Guide*.
4774
+ # *AWS Key Management Service Developer Guide*. For help writing and
4775
+ # formatting a JSON policy document, see the [IAM JSON Policy
4776
+ # Reference][2] in the <i> <i>IAM User Guide</i> </i>. For examples of
4777
+ # adding a key policy in multiple programming languages, see [Setting a
4778
+ # key policy][3] in the *AWS Key Management Service Developer Guide*.
4779
+ #
4780
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
4781
+ # in a different AWS account.
4782
+ #
4783
+ # **Required permissions**\: [kms:PutKeyPolicy][4] (key policy)
4784
+ #
4785
+ # **Related operations**\: GetKeyPolicy
4238
4786
  #
4239
4787
  #
4240
4788
  #
4241
4789
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html
4790
+ # [2]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies.html
4791
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/programming-key-policies.html#put-policy
4792
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4242
4793
  #
4243
4794
  # @option params [required, String] :key_id
4244
4795
  # A unique identifier for the customer master key (CMK).
@@ -4361,21 +4912,27 @@ module Aws::KMS
4361
4912
  # operation.
4362
4913
  #
4363
4914
  # * If your ciphertext was encrypted under an asymmetric CMK, you must
4364
- # identify the *source CMK*, that is, the CMK that encrypted the
4365
- # ciphertext. You must also supply the encryption algorithm that was
4366
- # used. This information is required to decrypt the data.
4367
- #
4368
- # * It is optional, but you can specify a source CMK even when the
4369
- # ciphertext was encrypted under a symmetric CMK. This ensures that
4370
- # the ciphertext is decrypted only by using a particular CMK. If the
4371
- # CMK that you specify cannot decrypt the ciphertext, the `ReEncrypt`
4372
- # operation fails.
4373
- #
4374
- # * To reencrypt the data, you must specify the *destination CMK*, that
4375
- # is, the CMK that re-encrypts the data after it is decrypted. You can
4376
- # select a symmetric or asymmetric CMK. If the destination CMK is an
4377
- # asymmetric CMK, you must also provide the encryption algorithm. The
4378
- # algorithm that you choose must be compatible with the CMK.
4915
+ # use the `SourceKeyId` parameter to identify the CMK that encrypted
4916
+ # the ciphertext. You must also supply the encryption algorithm that
4917
+ # was used. This information is required to decrypt the data.
4918
+ #
4919
+ # * If your ciphertext was encrypted under a symmetric CMK, the
4920
+ # `SourceKeyId` parameter is optional. AWS KMS can get this
4921
+ # information from metadata that it adds to the symmetric ciphertext
4922
+ # blob. This feature adds durability to your implementation by
4923
+ # ensuring that authorized users can decrypt ciphertext decades after
4924
+ # it was encrypted, even if they've lost track of the CMK ID.
4925
+ # However, specifying the source CMK is always recommended as a best
4926
+ # practice. When you use the `SourceKeyId` parameter to specify a CMK,
4927
+ # AWS KMS uses only the CMK you specify. If the ciphertext was
4928
+ # encrypted under a different CMK, the `ReEncrypt` operation fails.
4929
+ # This practice ensures that you use the CMK that you intend.
4930
+ #
4931
+ # * To reencrypt the data, you must use the `DestinationKeyId` parameter
4932
+ # specify the CMK that re-encrypts the data after it is decrypted. You
4933
+ # can select a symmetric or asymmetric CMK. If the destination CMK is
4934
+ # an asymmetric CMK, you must also provide the encryption algorithm.
4935
+ # The algorithm that you choose must be compatible with the CMK.
4379
4936
  #
4380
4937
  # When you use an asymmetric CMK to encrypt or reencrypt data, be sure
4381
4938
  # to record the CMK and encryption algorithm that you choose. You will
@@ -4389,23 +4946,36 @@ module Aws::KMS
4389
4946
  # ciphertext generated with asymmetric keys. The standard format for
4390
4947
  # asymmetric key ciphertext does not include configurable fields.
4391
4948
  #
4392
- # Unlike other AWS KMS API operations, `ReEncrypt` callers must have two
4393
- # permissions:
4949
+ # The CMK that you use for this operation must be in a compatible key
4950
+ # state. For details, see [How Key State Affects Use of a Customer
4951
+ # Master Key][6] in the *AWS Key Management Service Developer Guide*.
4952
+ #
4953
+ # **Cross-account use**\: Yes. The source CMK and destination CMK can be
4954
+ # in different AWS accounts. Either or both CMKs can be in a different
4955
+ # account than the caller.
4956
+ #
4957
+ # **Required permissions**\:
4394
4958
  #
4395
- # * `kms:ReEncryptFrom` permission on the source CMK
4959
+ # * [kms:ReEncryptFrom][7] permission on the source CMK (key policy)
4396
4960
  #
4397
- # * `kms:ReEncryptTo` permission on the destination CMK
4961
+ # * [kms:ReEncryptTo][7] permission on the destination CMK (key policy)
4398
4962
  #
4399
4963
  # To permit reencryption from or to a CMK, include the
4400
- # `"kms:ReEncrypt*"` permission in your [key policy][6]. This permission
4964
+ # `"kms:ReEncrypt*"` permission in your [key policy][8]. This permission
4401
4965
  # is automatically included in the key policy when you use the console
4402
4966
  # to create a CMK. But you must include it manually when you create a
4403
4967
  # CMK programmatically or when you use the PutKeyPolicy operation to set
4404
4968
  # a key policy.
4405
4969
  #
4406
- # The CMK that you use for this operation must be in a compatible key
4407
- # state. For details, see [How Key State Affects Use of a Customer
4408
- # Master Key][7] in the *AWS Key Management Service Developer Guide*.
4970
+ # **Related operations:**
4971
+ #
4972
+ # * Decrypt
4973
+ #
4974
+ # * Encrypt
4975
+ #
4976
+ # * GenerateDataKey
4977
+ #
4978
+ # * GenerateDataKeyPair
4409
4979
  #
4410
4980
  #
4411
4981
  #
@@ -4414,8 +4984,9 @@ module Aws::KMS
4414
4984
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/symm-asymm-concepts.html#asymmetric-cmks
4415
4985
  # [4]: https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/
4416
4986
  # [5]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html
4417
- # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html
4418
- # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
4987
+ # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
4988
+ # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4989
+ # [8]: https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html
4419
4990
  #
4420
4991
  # @option params [required, String, StringIO, File] :ciphertext_blob
4421
4992
  # Ciphertext of the data to reencrypt.
@@ -4440,23 +5011,20 @@ module Aws::KMS
4440
5011
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context
4441
5012
  #
4442
5013
  # @option params [String] :source_key_id
4443
- # A unique identifier for the CMK that is used to decrypt the ciphertext
4444
- # before it reencrypts it using the destination CMK.
5014
+ # Specifies the customer master key (CMK) that AWS KMS will use to
5015
+ # decrypt the ciphertext before it is re-encrypted. Enter a key ID of
5016
+ # the CMK that was used to encrypt the ciphertext.
4445
5017
  #
4446
5018
  # This parameter is required only when the ciphertext was encrypted
4447
- # under an asymmetric CMK. Otherwise, AWS KMS uses the metadata that it
4448
- # adds to the ciphertext blob to determine which CMK was used to encrypt
4449
- # the ciphertext. However, you can use this parameter to ensure that a
4450
- # particular CMK (of any kind) is used to decrypt the ciphertext before
4451
- # it is reencrypted.
4452
- #
4453
- # If you specify a `KeyId` value, the decrypt part of the `ReEncrypt`
4454
- # operation succeeds only if the specified CMK was used to encrypt the
4455
- # ciphertext.
5019
+ # under an asymmetric CMK. If you used a symmetric CMK, AWS KMS can get
5020
+ # the CMK from metadata that it adds to the symmetric ciphertext blob.
5021
+ # However, it is always recommended as a best practice. This practice
5022
+ # ensures that you use the CMK that you intend.
4456
5023
  #
4457
5024
  # To specify a CMK, use its key ID, Amazon Resource Name (ARN), alias
4458
5025
  # name, or alias ARN. When using an alias name, prefix it with
4459
- # `"alias/"`.
5026
+ # `"alias/"`. To specify a CMK in a different AWS account, you must use
5027
+ # the key ARN or alias ARN.
4460
5028
  #
4461
5029
  # For example:
4462
5030
  #
@@ -4564,14 +5132,14 @@ module Aws::KMS
4564
5132
  #
4565
5133
  # resp = client.re_encrypt({
4566
5134
  # ciphertext_blob: "<binary data>", # The data to reencrypt.
4567
- # destination_key_id: "0987dcba-09fe-87dc-65ba-ab0987654321", # The identifier of the CMK to use to reencrypt the data. You can use the key ID or Amazon Resource Name (ARN) of the CMK, or the name or ARN of an alias that refers to the CMK.
5135
+ # destination_key_id: "0987dcba-09fe-87dc-65ba-ab0987654321", # The identifier of the CMK to use to reencrypt the data. You can use any valid key identifier.
4568
5136
  # })
4569
5137
  #
4570
5138
  # resp.to_h outputs the following:
4571
5139
  # {
4572
5140
  # ciphertext_blob: "<binary data>", # The reencrypted data.
4573
5141
  # key_id: "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321", # The ARN of the CMK that was used to reencrypt the data.
4574
- # source_key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK that was used to originally encrypt the data.
5142
+ # source_key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK that was originally used to encrypt the data.
4575
5143
  # }
4576
5144
  #
4577
5145
  # @example Request syntax with placeholder values
@@ -4626,6 +5194,28 @@ module Aws::KMS
4626
5194
  # base64-encoded string. A grant ID is a 64 character unique identifier
4627
5195
  # of a grant. The CreateGrant operation returns both.
4628
5196
  #
5197
+ # **Cross-account use**\: Yes. You can retire a grant on a CMK in a
5198
+ # different AWS account.
5199
+ #
5200
+ # **Required permissions:**\: Permission to retire a grant is specified
5201
+ # in the grant. You cannot control access to this operation in a policy.
5202
+ # For more information, see [Using grants][1] in the *AWS Key Management
5203
+ # Service Developer Guide*.
5204
+ #
5205
+ # **Related operations:**
5206
+ #
5207
+ # * CreateGrant
5208
+ #
5209
+ # * ListGrants
5210
+ #
5211
+ # * ListRetirableGrants
5212
+ #
5213
+ # * RevokeGrant
5214
+ #
5215
+ #
5216
+ #
5217
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/grants.html
5218
+ #
4629
5219
  # @option params [String] :grant_token
4630
5220
  # Token that identifies the grant to be retired.
4631
5221
  #
@@ -4677,8 +5267,25 @@ module Aws::KMS
4677
5267
  # (CMK). You can revoke a grant to actively deny operations that depend
4678
5268
  # on it.
4679
5269
  #
4680
- # To perform this operation on a CMK in a different AWS account, specify
4681
- # the key ARN in the value of the `KeyId` parameter.
5270
+ # **Cross-account use**\: Yes. To perform this operation on a CMK in a
5271
+ # different AWS account, specify the key ARN in the value of the `KeyId`
5272
+ # parameter.
5273
+ #
5274
+ # **Required permissions**\: [kms:RevokeGrant][1] (key policy)
5275
+ #
5276
+ # **Related operations:**
5277
+ #
5278
+ # * CreateGrant
5279
+ #
5280
+ # * ListGrants
5281
+ #
5282
+ # * ListRetirableGrants
5283
+ #
5284
+ # * RetireGrant
5285
+ #
5286
+ #
5287
+ #
5288
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4682
5289
  #
4683
5290
  # @option params [required, String] :key_id
4684
5291
  # A unique identifier for the customer master key associated with the
@@ -4748,8 +5355,6 @@ module Aws::KMS
4748
5355
  # manually [delete the orphaned key material][2] from the cluster and
4749
5356
  # its backups.
4750
5357
  #
4751
- # You cannot perform this operation on a CMK in a different AWS account.
4752
- #
4753
5358
  # For more information about scheduling a CMK for deletion, see
4754
5359
  # [Deleting Customer Master Keys][3] in the *AWS Key Management Service
4755
5360
  # Developer Guide*.
@@ -4758,12 +5363,24 @@ module Aws::KMS
4758
5363
  # state. For details, see [How Key State Affects Use of a Customer
4759
5364
  # Master Key][4] in the *AWS Key Management Service Developer Guide*.
4760
5365
  #
5366
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
5367
+ # in a different AWS account.
5368
+ #
5369
+ # **Required permissions**\: [kms:ScheduleKeyDeletion][5] (key policy)
5370
+ #
5371
+ # **Related operations**
5372
+ #
5373
+ # * CancelKeyDeletion
5374
+ #
5375
+ # * DisableKey
5376
+ #
4761
5377
  #
4762
5378
  #
4763
5379
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
4764
5380
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html#fix-keystore-orphaned-key
4765
5381
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html
4766
5382
  # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5383
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4767
5384
  #
4768
5385
  # @option params [required, String] :key_id
4769
5386
  # The unique identifier of the customer master key (CMK) to delete.
@@ -4870,11 +5487,20 @@ module Aws::KMS
4870
5487
  # state. For details, see [How Key State Affects Use of a Customer
4871
5488
  # Master Key][3] in the *AWS Key Management Service Developer Guide*.
4872
5489
  #
5490
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
5491
+ # different AWS account, specify the key ARN or alias ARN in the value
5492
+ # of the `KeyId` parameter.
5493
+ #
5494
+ # **Required permissions**\: [kms:Sign][4] (key policy)
5495
+ #
5496
+ # **Related operations**\: Verify
5497
+ #
4873
5498
  #
4874
5499
  #
4875
5500
  # [1]: https://en.wikipedia.org/wiki/Digital_signature
4876
5501
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
4877
5502
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5503
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4878
5504
  #
4879
5505
  # @option params [required, String] :key_id
4880
5506
  # Identifies an asymmetric CMK. AWS KMS uses the private key in the
@@ -4960,31 +5586,50 @@ module Aws::KMS
4960
5586
  req.send_request(options)
4961
5587
  end
4962
5588
 
4963
- # Adds or edits tags for a customer master key (CMK). You cannot perform
4964
- # this operation on a CMK in a different AWS account.
5589
+ # Adds or edits tags on a [customer managed CMK][1].
4965
5590
  #
4966
- # Each tag consists of a tag key and a tag value. Tag keys and tag
4967
- # values are both required, but tag values can be empty (null) strings.
5591
+ # Each tag consists of a tag key and a tag value, both of which are
5592
+ # case-sensitive strings. The tag value can be an empty (null) string.
4968
5593
  #
4969
- # You can only use a tag key once for each CMK. If you use the tag key
4970
- # again, AWS KMS replaces the current tag value with the specified
4971
- # value.
5594
+ # To add a tag, specify a new tag key and a tag value. To edit a tag,
5595
+ # specify an existing tag key and a new tag value.
4972
5596
  #
4973
- # For information about the rules that apply to tag keys and tag values,
4974
- # see [User-Defined Tag Restrictions][1] in the *AWS Billing and Cost
4975
- # Management User Guide*.
5597
+ # You can use this operation to tag a [customer managed CMK][1], but you
5598
+ # cannot tag an [AWS managed CMK][2], an [AWS owned CMK][3], or an
5599
+ # alias.
5600
+ #
5601
+ # For general information about tags, including the format and syntax,
5602
+ # see [Tagging AWS resources][4] in the *Amazon Web Services General
5603
+ # Reference*. For information about using tags in AWS KMS, see [Tagging
5604
+ # keys][5].
4976
5605
  #
4977
5606
  # The CMK that you use for this operation must be in a compatible key
4978
5607
  # state. For details, see [How Key State Affects Use of a Customer
4979
- # Master Key][2] in the *AWS Key Management Service Developer Guide*.
5608
+ # Master Key][6] in the *AWS Key Management Service Developer Guide*.
4980
5609
  #
5610
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
5611
+ # in a different AWS account.
4981
5612
  #
5613
+ # **Required permissions**\: [kms:TagResource][7] (key policy)
4982
5614
  #
4983
- # [1]: https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/allocation-tag-restrictions.html
4984
- # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5615
+ # **Related operations**
5616
+ #
5617
+ # * UntagResource
5618
+ #
5619
+ # * ListResourceTags
5620
+ #
5621
+ #
5622
+ #
5623
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
5624
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
5625
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-owned-cmk
5626
+ # [4]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
5627
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html
5628
+ # [6]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5629
+ # [7]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
4985
5630
  #
4986
5631
  # @option params [required, String] :key_id
4987
- # A unique identifier for the CMK you are tagging.
5632
+ # Identifies a customer managed CMK in the account and Region.
4988
5633
  #
4989
5634
  # Specify the key ID or the Amazon Resource Name (ARN) of the CMK.
4990
5635
  #
@@ -4998,7 +5643,14 @@ module Aws::KMS
4998
5643
  # To get the key ID and key ARN for a CMK, use ListKeys or DescribeKey.
4999
5644
  #
5000
5645
  # @option params [required, Array<Types::Tag>] :tags
5001
- # One or more tags. Each tag consists of a tag key and a tag value.
5646
+ # One or more tags.
5647
+ #
5648
+ # Each tag consists of a tag key and a tag value. The tag value can be
5649
+ # an empty (null) string.
5650
+ #
5651
+ # You cannot have more than one tag on a CMK with the same tag key. If
5652
+ # you specify an existing tag key with a different tag value, AWS KMS
5653
+ # replaces the current tag value with the specified one.
5002
5654
  #
5003
5655
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
5004
5656
  #
@@ -5038,23 +5690,44 @@ module Aws::KMS
5038
5690
  req.send_request(options)
5039
5691
  end
5040
5692
 
5041
- # Removes the specified tags from the specified customer master key
5042
- # (CMK). You cannot perform this operation on a CMK in a different AWS
5043
- # account.
5693
+ # Deletes tags from a [customer managed CMK][1]. To delete a tag,
5694
+ # specify the tag key and the CMK.
5695
+ #
5696
+ # When it succeeds, the `UntagResource` operation doesn't return any
5697
+ # output. Also, if the specified tag key isn't found on the CMK, it
5698
+ # doesn't throw an exception or return a response. To confirm that the
5699
+ # operation worked, use the ListResourceTags operation.
5044
5700
  #
5045
- # To remove a tag, specify the tag key. To change the tag value of an
5046
- # existing tag key, use TagResource.
5701
+ # For general information about tags, including the format and syntax,
5702
+ # see [Tagging AWS resources][2] in the *Amazon Web Services General
5703
+ # Reference*. For information about using tags in AWS KMS, see [Tagging
5704
+ # keys][3].
5047
5705
  #
5048
5706
  # The CMK that you use for this operation must be in a compatible key
5049
5707
  # state. For details, see [How Key State Affects Use of a Customer
5050
- # Master Key][1] in the *AWS Key Management Service Developer Guide*.
5708
+ # Master Key][4] in the *AWS Key Management Service Developer Guide*.
5709
+ #
5710
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
5711
+ # in a different AWS account.
5051
5712
  #
5713
+ # **Required permissions**\: [kms:UntagResource][5] (key policy)
5052
5714
  #
5715
+ # **Related operations**
5053
5716
  #
5054
- # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5717
+ # * TagResource
5718
+ #
5719
+ # * ListResourceTags
5720
+ #
5721
+ #
5722
+ #
5723
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
5724
+ # [2]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
5725
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/tagging-keys.html
5726
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5727
+ # [5]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
5055
5728
  #
5056
5729
  # @option params [required, String] :key_id
5057
- # A unique identifier for the CMK from which you are removing tags.
5730
+ # Identifies the CMK from which you are removing tags.
5058
5731
  #
5059
5732
  # Specify the key ID or the Amazon Resource Name (ARN) of the CMK.
5060
5733
  #
@@ -5104,8 +5777,7 @@ module Aws::KMS
5104
5777
  # Associates an existing AWS KMS alias with a different customer master
5105
5778
  # key (CMK). Each alias is associated with only one CMK at a time,
5106
5779
  # although a CMK can have multiple aliases. The alias and the CMK must
5107
- # be in the same AWS account and region. You cannot perform this
5108
- # operation on an alias in a different AWS account.
5780
+ # be in the same AWS account and region.
5109
5781
  #
5110
5782
  # The current and new CMK must be the same type (both symmetric or both
5111
5783
  # asymmetric), and they must have the same key usage (`ENCRYPT_DECRYPT`
@@ -5128,9 +5800,33 @@ module Aws::KMS
5128
5800
  # state. For details, see [How Key State Affects Use of a Customer
5129
5801
  # Master Key][1] in the *AWS Key Management Service Developer Guide*.
5130
5802
  #
5803
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
5804
+ # in a different AWS account.
5805
+ #
5806
+ # **Required permissions**
5807
+ #
5808
+ # * [kms:UpdateAlias][2] on the alias (IAM policy).
5809
+ #
5810
+ # * [kms:UpdateAlias][2] on the current CMK (key policy).
5811
+ #
5812
+ # * [kms:UpdateAlias][2] on the new CMK (key policy).
5813
+ #
5814
+ # For details, see [Controlling access to aliases][3] in the *AWS Key
5815
+ # Management Service Developer Guide*.
5816
+ #
5817
+ # **Related operations:**
5818
+ #
5819
+ # * CreateAlias
5820
+ #
5821
+ # * DeleteAlias
5822
+ #
5823
+ # * ListAliases
5824
+ #
5131
5825
  #
5132
5826
  #
5133
5827
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
5828
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
5829
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access
5134
5830
  #
5135
5831
  # @option params [required, String] :alias_name
5136
5832
  # Identifies the alias that is changing its CMK. This value must begin
@@ -5139,8 +5835,9 @@ module Aws::KMS
5139
5835
  # name.
5140
5836
  #
5141
5837
  # @option params [required, String] :target_key_id
5142
- # Identifies the CMK to associate with the alias. When the update
5143
- # operation completes, the alias will point to this CMK.
5838
+ # Identifies the [customer managed CMK][1] to associate with the alias.
5839
+ # You don't have permission to associate an alias with an [AWS managed
5840
+ # CMK][2].
5144
5841
  #
5145
5842
  # The CMK must be in the same AWS account and Region as the alias. Also,
5146
5843
  # the new target CMK must be the same type as the current target CMK
@@ -5161,6 +5858,11 @@ module Aws::KMS
5161
5858
  # To verify that the alias is mapped to the correct CMK, use
5162
5859
  # ListAliases.
5163
5860
  #
5861
+ #
5862
+ #
5863
+ # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
5864
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
5865
+ #
5164
5866
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
5165
5867
  #
5166
5868
  #
@@ -5230,11 +5932,29 @@ module Aws::KMS
5230
5932
  # AWS KMS, which combines the convenience and extensive integration of
5231
5933
  # AWS KMS with the isolation and control of a single-tenant key store.
5232
5934
  #
5935
+ # **Cross-account use**\: No. You cannot perform this operation on a
5936
+ # custom key store in a different AWS account.
5937
+ #
5938
+ # **Required permissions**\: [kms:UpdateCustomKeyStore][4] (IAM policy)
5939
+ #
5940
+ # **Related operations:**
5941
+ #
5942
+ # * ConnectCustomKeyStore
5943
+ #
5944
+ # * CreateCustomKeyStore
5945
+ #
5946
+ # * DeleteCustomKeyStore
5947
+ #
5948
+ # * DescribeCustomKeyStores
5949
+ #
5950
+ # * DisconnectCustomKeyStore
5951
+ #
5233
5952
  #
5234
5953
  #
5235
5954
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-store-concepts.html#concept-kmsuser
5236
5955
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/fix-keystore.html#fix-keystore-password
5237
5956
  # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html
5957
+ # [4]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
5238
5958
  #
5239
5959
  # @option params [required, String] :custom_key_store_id
5240
5960
  # Identifies the custom key store that you want to update. Enter the ID
@@ -5294,15 +6014,25 @@ module Aws::KMS
5294
6014
  # Updates the description of a customer master key (CMK). To see the
5295
6015
  # description of a CMK, use DescribeKey.
5296
6016
  #
5297
- # You cannot perform this operation on a CMK in a different AWS account.
5298
- #
5299
6017
  # The CMK that you use for this operation must be in a compatible key
5300
6018
  # state. For details, see [How Key State Affects Use of a Customer
5301
6019
  # Master Key][1] in the *AWS Key Management Service Developer Guide*.
5302
6020
  #
6021
+ # **Cross-account use**\: No. You cannot perform this operation on a CMK
6022
+ # in a different AWS account.
6023
+ #
6024
+ # **Required permissions**\: [kms:UpdateKeyDescription][2] (key policy)
6025
+ #
6026
+ # **Related operations**
6027
+ #
6028
+ # * CreateKey
6029
+ #
6030
+ # * DescribeKey
6031
+ #
5303
6032
  #
5304
6033
  #
5305
6034
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
6035
+ # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
5306
6036
  #
5307
6037
  # @option params [required, String] :key_id
5308
6038
  # A unique identifier for the customer master key (CMK).
@@ -5384,10 +6114,19 @@ module Aws::KMS
5384
6114
  # state. For details, see [How Key State Affects Use of a Customer
5385
6115
  # Master Key][2] in the *AWS Key Management Service Developer Guide*.
5386
6116
  #
6117
+ # **Cross-account use**\: Yes. To perform this operation with a CMK in a
6118
+ # different AWS account, specify the key ARN or alias ARN in the value
6119
+ # of the `KeyId` parameter.
6120
+ #
6121
+ # **Required permissions**\: [kms:Verify][3] (key policy)
6122
+ #
6123
+ # **Related operations**\: Sign
6124
+ #
5387
6125
  #
5388
6126
  #
5389
6127
  # [1]: https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html
5390
6128
  # [2]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
6129
+ # [3]: https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html
5391
6130
  #
5392
6131
  # @option params [required, String] :key_id
5393
6132
  # Identifies the asymmetric CMK that will be used to verify the
@@ -5494,7 +6233,7 @@ module Aws::KMS
5494
6233
  params: params,
5495
6234
  config: config)
5496
6235
  context[:gem_name] = 'aws-sdk-kms'
5497
- context[:gem_version] = '1.38.0'
6236
+ context[:gem_version] = '1.43.0'
5498
6237
  Seahorse::Client::Request.new(handlers, context)
5499
6238
  end
5500
6239