aws-sdk-kms 1.0.0.rc7 → 1.0.0.rc8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 05e0ca8918cd70a4c9957bf4c2faed6d33b1c102
4
- data.tar.gz: e055345e7285d89682216712e13ab4a6e0bde13d
3
+ metadata.gz: c2324fa2e80f7a17f721f83bd37868e3ed0dbe9b
4
+ data.tar.gz: 32c5fe7f40d16802d0b410b4d513666406748ef1
5
5
  SHA512:
6
- metadata.gz: f6f4449ede9ca1b92b9c1bde08fbd148109622d067c3f2594acf9eb2a99da728a5de69575ae4e89ce4d0b0ef519be36d8065432d4b3e854967ccf9d3c43c3441
7
- data.tar.gz: f50b80009bb62309c9923a8ab053f8c994a3e05a9b211b4abc92e603ca8f7f35a78051365e9440fdea0c3873a24e7f1a1944ad4c042600ccf80c4f9cb711d050
6
+ metadata.gz: f7f5ecfb91fc7e1bb796f279c351f607692b2b86ccb4905cbd9e2d802306ca62d3c37f251b6a89345aecac76407d96a2863ecfb7a5444922841d7a17d0819d07
7
+ data.tar.gz: 9aa7a896643172044f57330c9be582ec7e6f91cf4ae592f902913c2d232b88a2318b7ac6d511c05c2cb37557fb72055707daec32cd01fb561dd27d3d20ddbe05
data/lib/aws-sdk-kms.rb CHANGED
@@ -42,6 +42,6 @@ require_relative 'aws-sdk-kms/customizations'
42
42
  # @service
43
43
  module Aws::KMS
44
44
 
45
- GEM_VERSION = '1.0.0.rc7'
45
+ GEM_VERSION = '1.0.0.rc8'
46
46
 
47
47
  end
@@ -186,6 +186,20 @@ module Aws::KMS
186
186
  #
187
187
  # * {Types::CancelKeyDeletionResponse#key_id #key_id} => String
188
188
  #
189
+ #
190
+ # @example Example: To cancel deletion of a customer master key (CMK)
191
+ #
192
+ # # The following example cancels deletion of the specified CMK.
193
+ #
194
+ # resp = client.cancel_key_deletion({
195
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose deletion you are canceling. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
196
+ # })
197
+ #
198
+ # resp.to_h outputs the following:
199
+ # {
200
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK whose deletion you canceled.
201
+ # }
202
+ #
189
203
  # @example Request syntax with placeholder values
190
204
  #
191
205
  # resp = client.cancel_key_deletion({
@@ -237,6 +251,16 @@ module Aws::KMS
237
251
  #
238
252
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
239
253
  #
254
+ #
255
+ # @example Example: To create an alias
256
+ #
257
+ # # The following example creates an alias for the specified customer master key (CMK).
258
+ #
259
+ # resp = client.create_alias({
260
+ # alias_name: "alias/ExampleAlias", # The alias to create. Aliases must begin with 'alias/'. Do not use aliases that begin with 'alias/aws' because they are reserved for use by AWS.
261
+ # target_key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose alias you are creating. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
262
+ # })
263
+ #
240
264
  # @example Request syntax with placeholder values
241
265
  #
242
266
  # resp = client.create_alias({
@@ -352,6 +376,26 @@ module Aws::KMS
352
376
  # * {Types::CreateGrantResponse#grant_token #grant_token} => String
353
377
  # * {Types::CreateGrantResponse#grant_id #grant_id} => String
354
378
  #
379
+ #
380
+ # @example Example: To create a grant
381
+ #
382
+ # # The following example creates a grant that allows the specified IAM role to encrypt data with the specified customer master key (CMK).
383
+ #
384
+ # resp = client.create_grant({
385
+ # grantee_principal: "arn:aws:iam::111122223333:role/ExampleRole", # The identity that is given permission to perform the operations specified in the grant.
386
+ # key_id: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to which the grant applies. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
387
+ # operations: [
388
+ # "Encrypt",
389
+ # "Decrypt",
390
+ # ], # A list of operations that the grant allows.
391
+ # })
392
+ #
393
+ # resp.to_h outputs the following:
394
+ # {
395
+ # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", # The unique identifier of the grant.
396
+ # grant_token: "AQpAM2RhZTk1MGMyNTk2ZmZmMzEyYWVhOWViN2I1MWM4Mzc0MWFiYjc0ZDE1ODkyNGFlNTIzODZhMzgyZjBlNGY3NiKIAgEBAgB4Pa6VDCWW__MSrqnre1HIN0Grt00ViSSuUjhqOC8OT3YAAADfMIHcBgkqhkiG9w0BBwaggc4wgcsCAQAwgcUGCSqGSIb3DQEHATAeBglghkgBZQMEAS4wEQQMmqLyBTAegIn9XlK5AgEQgIGXZQjkBcl1dykDdqZBUQ6L1OfUivQy7JVYO2-ZJP7m6f1g8GzV47HX5phdtONAP7K_HQIflcgpkoCqd_fUnE114mSmiagWkbQ5sqAVV3ov-VeqgrvMe5ZFEWLMSluvBAqdjHEdMIkHMlhlj4ENZbzBfo9Wxk8b8SnwP4kc4gGivedzFXo-dwN8fxjjq_ZZ9JFOj2ijIbj5FyogDCN0drOfi8RORSEuCEmPvjFRMFAwcmwFkN2NPp89amA", # The grant token.
397
+ # }
398
+ #
355
399
  # @example Request syntax with placeholder values
356
400
  #
357
401
  # resp = client.create_grant({
@@ -496,6 +540,35 @@ module Aws::KMS
496
540
  #
497
541
  # * {Types::CreateKeyResponse#key_metadata #key_metadata} => Types::KeyMetadata
498
542
  #
543
+ #
544
+ # @example Example: To create a customer master key (CMK)
545
+ #
546
+ # # The following example creates a CMK.
547
+ #
548
+ # resp = client.create_key({
549
+ # tags: [
550
+ # {
551
+ # tag_key: "CreatedBy",
552
+ # tag_value: "ExampleUser",
553
+ # },
554
+ # ], # One or more tags. Each tag consists of a tag key and a tag value.
555
+ # })
556
+ #
557
+ # resp.to_h outputs the following:
558
+ # {
559
+ # key_metadata: {
560
+ # aws_account_id: "111122223333",
561
+ # arn: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
562
+ # creation_date: Time.parse("2017-01-09T12:00:07-08:00"),
563
+ # description: "",
564
+ # enabled: true,
565
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab",
566
+ # key_state: "Enabled",
567
+ # key_usage: "ENCRYPT_DECRYPT",
568
+ # origin: "AWS_KMS",
569
+ # }, # An object that contains information about the CMK created by this operation.
570
+ # }
571
+ #
499
572
  # @example Request syntax with placeholder values
500
573
  #
501
574
  # resp = client.create_key({
@@ -582,6 +655,21 @@ module Aws::KMS
582
655
  # * {Types::DecryptResponse#key_id #key_id} => String
583
656
  # * {Types::DecryptResponse#plaintext #plaintext} => String
584
657
  #
658
+ #
659
+ # @example Example: To decrypt data
660
+ #
661
+ # # The following example decrypts data that was encrypted with a customer master key (CMK) in AWS KMS.
662
+ #
663
+ # resp = client.decrypt({
664
+ # ciphertext_blob: "<binary data>", # The encrypted data (ciphertext).
665
+ # })
666
+ #
667
+ # resp.to_h outputs the following:
668
+ # {
669
+ # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The Amazon Resource Name (ARN) of the CMK that was used to decrypt the data.
670
+ # plaintext: "<binary data>", # The decrypted (plaintext) data.
671
+ # }
672
+ #
585
673
  # @example Request syntax with placeholder values
586
674
  #
587
675
  # resp = client.decrypt({
@@ -616,6 +704,15 @@ module Aws::KMS
616
704
  #
617
705
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
618
706
  #
707
+ #
708
+ # @example Example: To delete an alias
709
+ #
710
+ # # The following example deletes the specified alias.
711
+ #
712
+ # resp = client.delete_alias({
713
+ # alias_name: "alias/ExampleAlias", # The alias to delete.
714
+ # })
715
+ #
619
716
  # @example Request syntax with placeholder values
620
717
  #
621
718
  # resp = client.delete_alias({
@@ -661,6 +758,15 @@ module Aws::KMS
661
758
  #
662
759
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
663
760
  #
761
+ #
762
+ # @example Example: To delete imported key material
763
+ #
764
+ # # The following example deletes the imported key material from the specified customer master key (CMK).
765
+ #
766
+ # resp = client.delete_imported_key_material({
767
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose imported key material you are deleting. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
768
+ # })
769
+ #
664
770
  # @example Request syntax with placeholder values
665
771
  #
666
772
  # resp = client.delete_imported_key_material({
@@ -708,6 +814,30 @@ module Aws::KMS
708
814
  #
709
815
  # * {Types::DescribeKeyResponse#key_metadata #key_metadata} => Types::KeyMetadata
710
816
  #
817
+ #
818
+ # @example Example: To obtain information about a customer master key (CMK)
819
+ #
820
+ # # The following example returns information (metadata) about the specified CMK.
821
+ #
822
+ # resp = client.describe_key({
823
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK that you want information about. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
824
+ # })
825
+ #
826
+ # resp.to_h outputs the following:
827
+ # {
828
+ # key_metadata: {
829
+ # aws_account_id: "111122223333",
830
+ # arn: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
831
+ # creation_date: Time.parse("2015-10-12T11:45:07-07:00"),
832
+ # description: "",
833
+ # enabled: true,
834
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab",
835
+ # key_state: "Enabled",
836
+ # key_usage: "ENCRYPT_DECRYPT",
837
+ # origin: "AWS_KMS",
838
+ # }, # An object that contains information about the specified CMK.
839
+ # }
840
+ #
711
841
  # @example Request syntax with placeholder values
712
842
  #
713
843
  # resp = client.describe_key({
@@ -762,6 +892,15 @@ module Aws::KMS
762
892
  #
763
893
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
764
894
  #
895
+ #
896
+ # @example Example: To disable a customer master key (CMK)
897
+ #
898
+ # # The following example disables the specified CMK.
899
+ #
900
+ # resp = client.disable_key({
901
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to disable. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
902
+ # })
903
+ #
765
904
  # @example Request syntax with placeholder values
766
905
  #
767
906
  # resp = client.disable_key({
@@ -791,6 +930,15 @@ module Aws::KMS
791
930
  #
792
931
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
793
932
  #
933
+ #
934
+ # @example Example: To disable automatic rotation of key material
935
+ #
936
+ # # The following example disables automatic annual rotation of the key material for the specified CMK.
937
+ #
938
+ # resp = client.disable_key_rotation({
939
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose key material will no longer be rotated. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
940
+ # })
941
+ #
794
942
  # @example Request syntax with placeholder values
795
943
  #
796
944
  # resp = client.disable_key_rotation({
@@ -820,6 +968,15 @@ module Aws::KMS
820
968
  #
821
969
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
822
970
  #
971
+ #
972
+ # @example Example: To enable a customer master key (CMK)
973
+ #
974
+ # # The following example enables the specified CMK.
975
+ #
976
+ # resp = client.enable_key({
977
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to enable. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
978
+ # })
979
+ #
823
980
  # @example Request syntax with placeholder values
824
981
  #
825
982
  # resp = client.enable_key({
@@ -849,6 +1006,15 @@ module Aws::KMS
849
1006
  #
850
1007
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
851
1008
  #
1009
+ #
1010
+ # @example Example: To enable automatic rotation of key material
1011
+ #
1012
+ # # The following example enables automatic annual rotation of the key material for the specified CMK.
1013
+ #
1014
+ # resp = client.enable_key_rotation({
1015
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose key material will be rotated annually. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
1016
+ # })
1017
+ #
852
1018
  # @example Request syntax with placeholder values
853
1019
  #
854
1020
  # resp = client.enable_key_rotation({
@@ -932,6 +1098,22 @@ module Aws::KMS
932
1098
  # * {Types::EncryptResponse#ciphertext_blob #ciphertext_blob} => String
933
1099
  # * {Types::EncryptResponse#key_id #key_id} => String
934
1100
  #
1101
+ #
1102
+ # @example Example: To encrypt data
1103
+ #
1104
+ # # The following example encrypts data with the specified customer master key (CMK).
1105
+ #
1106
+ # resp = client.encrypt({
1107
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to use for encryption. 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.
1108
+ # plaintext: "<binary data>", # The data to encrypt.
1109
+ # })
1110
+ #
1111
+ # resp.to_h outputs the following:
1112
+ # {
1113
+ # ciphertext_blob: "<binary data>", # The encrypted data (ciphertext).
1114
+ # key_id: "arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK that was used to encrypt the data.
1115
+ # }
1116
+ #
935
1117
  # @example Request syntax with placeholder values
936
1118
  #
937
1119
  # resp = client.encrypt({
@@ -1063,6 +1245,23 @@ module Aws::KMS
1063
1245
  # * {Types::GenerateDataKeyResponse#plaintext #plaintext} => String
1064
1246
  # * {Types::GenerateDataKeyResponse#key_id #key_id} => String
1065
1247
  #
1248
+ #
1249
+ # @example Example: To generate a data key
1250
+ #
1251
+ # # The following example generates a 256-bit symmetric data encryption key (data key) in two formats. One is the unencrypted (plainext) data key, and the other is the data key encrypted with the specified customer master key (CMK).
1252
+ #
1253
+ # resp = client.generate_data_key({
1254
+ # key_id: "alias/ExampleAlias", # The identifier of the CMK to use to encrypt the data key. 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.
1255
+ # key_spec: "AES_256", # Specifies the type of data key to return.
1256
+ # })
1257
+ #
1258
+ # resp.to_h outputs the following:
1259
+ # {
1260
+ # ciphertext_blob: "<binary data>", # The encrypted data key.
1261
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK that was used to encrypt the data key.
1262
+ # plaintext: "<binary data>", # The unencrypted (plaintext) data key.
1263
+ # }
1264
+ #
1066
1265
  # @example Request syntax with placeholder values
1067
1266
  #
1068
1267
  # resp = client.generate_data_key({
@@ -1162,6 +1361,22 @@ module Aws::KMS
1162
1361
  # * {Types::GenerateDataKeyWithoutPlaintextResponse#ciphertext_blob #ciphertext_blob} => String
1163
1362
  # * {Types::GenerateDataKeyWithoutPlaintextResponse#key_id #key_id} => String
1164
1363
  #
1364
+ #
1365
+ # @example Example: To generate an encrypted data key
1366
+ #
1367
+ # # The following example generates an encrypted copy of a 256-bit symmetric data encryption key (data key). The data key is encrypted with the specified customer master key (CMK).
1368
+ #
1369
+ # resp = client.generate_data_key_without_plaintext({
1370
+ # key_id: "alias/ExampleAlias", # The identifier of the CMK to use to encrypt the data key. 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.
1371
+ # key_spec: "AES_256", # Specifies the type of data key to return.
1372
+ # })
1373
+ #
1374
+ # resp.to_h outputs the following:
1375
+ # {
1376
+ # ciphertext_blob: "<binary data>", # The encrypted data key.
1377
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK that was used to encrypt the data key.
1378
+ # }
1379
+ #
1165
1380
  # @example Request syntax with placeholder values
1166
1381
  #
1167
1382
  # resp = client.generate_data_key_without_plaintext({
@@ -1204,6 +1419,20 @@ module Aws::KMS
1204
1419
  #
1205
1420
  # * {Types::GenerateRandomResponse#plaintext #plaintext} => String
1206
1421
  #
1422
+ #
1423
+ # @example Example: To generate random data
1424
+ #
1425
+ # # The following example uses AWS KMS to generate 32 bytes of random data.
1426
+ #
1427
+ # resp = client.generate_random({
1428
+ # number_of_bytes: 32, # The length of the random data, specified in number of bytes.
1429
+ # })
1430
+ #
1431
+ # resp.to_h outputs the following:
1432
+ # {
1433
+ # plaintext: "<binary data>", # The random data.
1434
+ # }
1435
+ #
1207
1436
  # @example Request syntax with placeholder values
1208
1437
  #
1209
1438
  # resp = client.generate_random({
@@ -1244,6 +1473,21 @@ module Aws::KMS
1244
1473
  #
1245
1474
  # * {Types::GetKeyPolicyResponse#policy #policy} => String
1246
1475
  #
1476
+ #
1477
+ # @example Example: To retrieve a key policy
1478
+ #
1479
+ # # The following example retrieves the key policy for the specified customer master key (CMK).
1480
+ #
1481
+ # resp = client.get_key_policy({
1482
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose key policy you want to retrieve. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
1483
+ # policy_name: "default", # The name of the key policy to retrieve.
1484
+ # })
1485
+ #
1486
+ # resp.to_h outputs the following:
1487
+ # {
1488
+ # policy: "{\n \"Version\" : \"2012-10-17\",\n \"Id\" : \"key-default-1\",\n \"Statement\" : [ {\n \"Sid\" : \"Enable IAM User Permissions\",\n \"Effect\" : \"Allow\",\n \"Principal\" : {\n \"AWS\" : \"arn:aws:iam::111122223333:root\"\n },\n \"Action\" : \"kms:*\",\n \"Resource\" : \"*\"\n } ]\n}", # The key policy document.
1489
+ # }
1490
+ #
1247
1491
  # @example Request syntax with placeholder values
1248
1492
  #
1249
1493
  # resp = client.get_key_policy({
@@ -1281,6 +1525,20 @@ module Aws::KMS
1281
1525
  #
1282
1526
  # * {Types::GetKeyRotationStatusResponse#key_rotation_enabled #key_rotation_enabled} => Boolean
1283
1527
  #
1528
+ #
1529
+ # @example Example: To retrieve the rotation status for a customer master key (CMK)
1530
+ #
1531
+ # # The following example retrieves the status of automatic annual rotation of the key material for the specified CMK.
1532
+ #
1533
+ # resp = client.get_key_rotation_status({
1534
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose key material rotation status you want to retrieve. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
1535
+ # })
1536
+ #
1537
+ # resp.to_h outputs the following:
1538
+ # {
1539
+ # key_rotation_enabled: true, # A boolean that indicates the key material rotation status. Returns true when automatic annual rotation of the key material is enabled, or false when it is not.
1540
+ # }
1541
+ #
1284
1542
  # @example Request syntax with placeholder values
1285
1543
  #
1286
1544
  # resp = client.get_key_rotation_status({
@@ -1356,6 +1614,25 @@ module Aws::KMS
1356
1614
  # * {Types::GetParametersForImportResponse#public_key #public_key} => String
1357
1615
  # * {Types::GetParametersForImportResponse#parameters_valid_to #parameters_valid_to} => Time
1358
1616
  #
1617
+ #
1618
+ # @example Example: To retrieve the public key and import token for a customer master key (CMK)
1619
+ #
1620
+ # # The following example retrieves the public key and import token for the specified CMK.
1621
+ #
1622
+ # resp = client.get_parameters_for_import({
1623
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK for which to retrieve the public key and import token. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
1624
+ # wrapping_algorithm: "RSAES_OAEP_SHA_1", # The algorithm that you will use to encrypt the key material before importing it.
1625
+ # wrapping_key_spec: "RSA_2048", # The type of wrapping key (public key) to return in the response.
1626
+ # })
1627
+ #
1628
+ # resp.to_h outputs the following:
1629
+ # {
1630
+ # import_token: "<binary data>", # The import token to send with a subsequent ImportKeyMaterial request.
1631
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK for which you are retrieving the public key and import token. This is the same CMK specified in the request.
1632
+ # parameters_valid_to: Time.parse("2016-12-01T14:52:17-08:00"), # The time at which the import token and public key are no longer valid.
1633
+ # public_key: "<binary data>", # The public key to use to encrypt the key material before importing it.
1634
+ # }
1635
+ #
1359
1636
  # @example Request syntax with placeholder values
1360
1637
  #
1361
1638
  # resp = client.get_parameters_for_import({
@@ -1446,6 +1723,18 @@ module Aws::KMS
1446
1723
  #
1447
1724
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
1448
1725
  #
1726
+ #
1727
+ # @example Example: To import key material into a customer master key (CMK)
1728
+ #
1729
+ # # The following example imports key material into the specified CMK.
1730
+ #
1731
+ # resp = client.import_key_material({
1732
+ # encrypted_key_material: "<binary data>", # The encrypted key material to import.
1733
+ # expiration_model: "KEY_MATERIAL_DOES_NOT_EXPIRE", # A value that specifies whether the key material expires.
1734
+ # import_token: "<binary data>", # The import token that you received in the response to a previous GetParametersForImport request.
1735
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to import the key material into. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
1736
+ # })
1737
+ #
1449
1738
  # @example Request syntax with placeholder values
1450
1739
  #
1451
1740
  # resp = client.import_key_material({
@@ -1486,6 +1775,61 @@ module Aws::KMS
1486
1775
  # * {Types::ListAliasesResponse#next_marker #next_marker} => String
1487
1776
  # * {Types::ListAliasesResponse#truncated #truncated} => Boolean
1488
1777
  #
1778
+ #
1779
+ # @example Example: To list aliases
1780
+ #
1781
+ # # The following example lists aliases.
1782
+ #
1783
+ # resp = client.list_aliases({
1784
+ # })
1785
+ #
1786
+ # resp.to_h outputs the following:
1787
+ # {
1788
+ # aliases: [
1789
+ # {
1790
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/acm",
1791
+ # alias_name: "alias/aws/acm",
1792
+ # target_key_id: "da03f6f7-d279-427a-9cae-de48d07e5b66",
1793
+ # },
1794
+ # {
1795
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/ebs",
1796
+ # alias_name: "alias/aws/ebs",
1797
+ # target_key_id: "25a217e7-7170-4b8c-8bf6-045ea5f70e5b",
1798
+ # },
1799
+ # {
1800
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/rds",
1801
+ # alias_name: "alias/aws/rds",
1802
+ # target_key_id: "7ec3104e-c3f2-4b5c-bf42-bfc4772c6685",
1803
+ # },
1804
+ # {
1805
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/redshift",
1806
+ # alias_name: "alias/aws/redshift",
1807
+ # target_key_id: "08f7a25a-69e2-4fb5-8f10-393db27326fa",
1808
+ # },
1809
+ # {
1810
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/aws/s3",
1811
+ # alias_name: "alias/aws/s3",
1812
+ # target_key_id: "d2b0f1a3-580d-4f79-b836-bc983be8cfa5",
1813
+ # },
1814
+ # {
1815
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/example1",
1816
+ # alias_name: "alias/example1",
1817
+ # target_key_id: "4da1e216-62d0-46c5-a7c0-5f3a3d2f8046",
1818
+ # },
1819
+ # {
1820
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/example2",
1821
+ # alias_name: "alias/example2",
1822
+ # target_key_id: "f32fef59-2cc2-445b-8573-2d73328acbee",
1823
+ # },
1824
+ # {
1825
+ # alias_arn: "arn:aws:kms:us-east-2:111122223333:alias/example3",
1826
+ # alias_name: "alias/example3",
1827
+ # target_key_id: "1374ef38-d34e-4d5f-b2c9-4e0daee38855",
1828
+ # },
1829
+ # ], # A list of aliases, including the key ID of the customer master key (CMK) that each alias refers to.
1830
+ # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not.
1831
+ # }
1832
+ #
1489
1833
  # @example Request syntax with placeholder values
1490
1834
  #
1491
1835
  # resp = client.list_aliases({
@@ -1542,6 +1886,73 @@ module Aws::KMS
1542
1886
  # * {Types::ListGrantsResponse#next_marker #next_marker} => String
1543
1887
  # * {Types::ListGrantsResponse#truncated #truncated} => Boolean
1544
1888
  #
1889
+ #
1890
+ # @example Example: To list grants for a customer master key (CMK)
1891
+ #
1892
+ # # The following example lists grants for the specified CMK.
1893
+ #
1894
+ # resp = client.list_grants({
1895
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose grants you want to list. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
1896
+ # })
1897
+ #
1898
+ # resp.to_h outputs the following:
1899
+ # {
1900
+ # grants: [
1901
+ # {
1902
+ # creation_date: Time.parse("2016-10-25T14:37:41-07:00"),
1903
+ # grant_id: "91ad875e49b04a9d1f3bdeb84d821f9db6ea95e1098813f6d47f0c65fbe2a172",
1904
+ # grantee_principal: "acm.us-east-2.amazonaws.com",
1905
+ # issuing_account: "arn:aws:iam::111122223333:root",
1906
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
1907
+ # operations: [
1908
+ # "Encrypt",
1909
+ # "ReEncryptFrom",
1910
+ # "ReEncryptTo",
1911
+ # ],
1912
+ # retiring_principal: "acm.us-east-2.amazonaws.com",
1913
+ # },
1914
+ # {
1915
+ # creation_date: Time.parse("2016-10-25T14:37:41-07:00"),
1916
+ # grant_id: "a5d67d3e207a8fc1f4928749ee3e52eb0440493a8b9cf05bbfad91655b056200",
1917
+ # grantee_principal: "acm.us-east-2.amazonaws.com",
1918
+ # issuing_account: "arn:aws:iam::111122223333:root",
1919
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
1920
+ # operations: [
1921
+ # "ReEncryptFrom",
1922
+ # "ReEncryptTo",
1923
+ # ],
1924
+ # retiring_principal: "acm.us-east-2.amazonaws.com",
1925
+ # },
1926
+ # {
1927
+ # creation_date: Time.parse("2016-10-25T14:37:41-07:00"),
1928
+ # grant_id: "c541aaf05d90cb78846a73b346fc43e65be28b7163129488c738e0c9e0628f4f",
1929
+ # grantee_principal: "acm.us-east-2.amazonaws.com",
1930
+ # issuing_account: "arn:aws:iam::111122223333:root",
1931
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
1932
+ # operations: [
1933
+ # "Encrypt",
1934
+ # "ReEncryptFrom",
1935
+ # "ReEncryptTo",
1936
+ # ],
1937
+ # retiring_principal: "acm.us-east-2.amazonaws.com",
1938
+ # },
1939
+ # {
1940
+ # creation_date: Time.parse("2016-10-25T14:37:41-07:00"),
1941
+ # grant_id: "dd2052c67b4c76ee45caf1dc6a1e2d24e8dc744a51b36ae2f067dc540ce0105c",
1942
+ # grantee_principal: "acm.us-east-2.amazonaws.com",
1943
+ # issuing_account: "arn:aws:iam::111122223333:root",
1944
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
1945
+ # operations: [
1946
+ # "Encrypt",
1947
+ # "ReEncryptFrom",
1948
+ # "ReEncryptTo",
1949
+ # ],
1950
+ # retiring_principal: "acm.us-east-2.amazonaws.com",
1951
+ # },
1952
+ # ], # A list of grants.
1953
+ # truncated: true, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not.
1954
+ # }
1955
+ #
1545
1956
  # @example Request syntax with placeholder values
1546
1957
  #
1547
1958
  # resp = client.list_grants({
@@ -1611,6 +2022,23 @@ module Aws::KMS
1611
2022
  # * {Types::ListKeyPoliciesResponse#next_marker #next_marker} => String
1612
2023
  # * {Types::ListKeyPoliciesResponse#truncated #truncated} => Boolean
1613
2024
  #
2025
+ #
2026
+ # @example Example: To list key policies for a customer master key (CMK)
2027
+ #
2028
+ # # The following example lists key policies for the specified CMK.
2029
+ #
2030
+ # resp = client.list_key_policies({
2031
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose key policies you want to list. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2032
+ # })
2033
+ #
2034
+ # resp.to_h outputs the following:
2035
+ # {
2036
+ # policy_names: [
2037
+ # "default",
2038
+ # ], # A list of key policy names.
2039
+ # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not.
2040
+ # }
2041
+ #
1614
2042
  # @example Request syntax with placeholder values
1615
2043
  #
1616
2044
  # resp = client.list_key_policies({
@@ -1657,6 +2085,49 @@ module Aws::KMS
1657
2085
  # * {Types::ListKeysResponse#next_marker #next_marker} => String
1658
2086
  # * {Types::ListKeysResponse#truncated #truncated} => Boolean
1659
2087
  #
2088
+ #
2089
+ # @example Example: To list customer master keys (CMKs)
2090
+ #
2091
+ # # The following example lists CMKs.
2092
+ #
2093
+ # resp = client.list_keys({
2094
+ # })
2095
+ #
2096
+ # resp.to_h outputs the following:
2097
+ # {
2098
+ # keys: [
2099
+ # {
2100
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/0d990263-018e-4e65-a703-eff731de951e",
2101
+ # key_id: "0d990263-018e-4e65-a703-eff731de951e",
2102
+ # },
2103
+ # {
2104
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/144be297-0ae1-44ac-9c8f-93cd8c82f841",
2105
+ # key_id: "144be297-0ae1-44ac-9c8f-93cd8c82f841",
2106
+ # },
2107
+ # {
2108
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/21184251-b765-428e-b852-2c7353e72571",
2109
+ # key_id: "21184251-b765-428e-b852-2c7353e72571",
2110
+ # },
2111
+ # {
2112
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/214fe92f-5b03-4ae1-b350-db2a45dbe10c",
2113
+ # key_id: "214fe92f-5b03-4ae1-b350-db2a45dbe10c",
2114
+ # },
2115
+ # {
2116
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/339963f2-e523-49d3-af24-a0fe752aa458",
2117
+ # key_id: "339963f2-e523-49d3-af24-a0fe752aa458",
2118
+ # },
2119
+ # {
2120
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/b776a44b-df37-4438-9be4-a27494e4271a",
2121
+ # key_id: "b776a44b-df37-4438-9be4-a27494e4271a",
2122
+ # },
2123
+ # {
2124
+ # key_arn: "arn:aws:kms:us-east-2:111122223333:key/deaf6c9e-cf2c-46a6-bf6d-0b6d487cffbb",
2125
+ # key_id: "deaf6c9e-cf2c-46a6-bf6d-0b6d487cffbb",
2126
+ # },
2127
+ # ], # A list of CMKs, including the key ID and Amazon Resource Name (ARN) of each one.
2128
+ # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not.
2129
+ # }
2130
+ #
1660
2131
  # @example Request syntax with placeholder values
1661
2132
  #
1662
2133
  # resp = client.list_keys({
@@ -1716,6 +2187,34 @@ module Aws::KMS
1716
2187
  # * {Types::ListResourceTagsResponse#next_marker #next_marker} => String
1717
2188
  # * {Types::ListResourceTagsResponse#truncated #truncated} => Boolean
1718
2189
  #
2190
+ #
2191
+ # @example Example: To list tags for a customer master key (CMK)
2192
+ #
2193
+ # # The following example lists tags for a CMK.
2194
+ #
2195
+ # resp = client.list_resource_tags({
2196
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose tags you are listing. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2197
+ # })
2198
+ #
2199
+ # resp.to_h outputs the following:
2200
+ # {
2201
+ # tags: [
2202
+ # {
2203
+ # tag_key: "CostCenter",
2204
+ # tag_value: "87654",
2205
+ # },
2206
+ # {
2207
+ # tag_key: "CreatedBy",
2208
+ # tag_value: "ExampleUser",
2209
+ # },
2210
+ # {
2211
+ # tag_key: "Purpose",
2212
+ # tag_value: "Test",
2213
+ # },
2214
+ # ], # A list of tags.
2215
+ # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not.
2216
+ # }
2217
+ #
1719
2218
  # @example Request syntax with placeholder values
1720
2219
  #
1721
2220
  # resp = client.list_resource_tags({
@@ -1781,6 +2280,34 @@ module Aws::KMS
1781
2280
  # * {Types::ListGrantsResponse#next_marker #next_marker} => String
1782
2281
  # * {Types::ListGrantsResponse#truncated #truncated} => Boolean
1783
2282
  #
2283
+ #
2284
+ # @example Example: To list grants that the specified principal can retire
2285
+ #
2286
+ # # The following example lists the grants that the specified principal (identity) can retire.
2287
+ #
2288
+ # resp = client.list_retirable_grants({
2289
+ # retiring_principal: "arn:aws:iam::111122223333:role/ExampleRole", # The retiring principal whose grants you want to list. Use the Amazon Resource Name (ARN) of an AWS principal such as an AWS account (root), IAM user, federated user, or assumed role user.
2290
+ # })
2291
+ #
2292
+ # resp.to_h outputs the following:
2293
+ # {
2294
+ # grants: [
2295
+ # {
2296
+ # creation_date: Time.parse("2016-12-07T11:09:35-08:00"),
2297
+ # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60",
2298
+ # grantee_principal: "arn:aws:iam::111122223333:role/ExampleRole",
2299
+ # issuing_account: "arn:aws:iam::444455556666:root",
2300
+ # key_id: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab",
2301
+ # operations: [
2302
+ # "Decrypt",
2303
+ # "Encrypt",
2304
+ # ],
2305
+ # retiring_principal: "arn:aws:iam::111122223333:role/ExampleRole",
2306
+ # },
2307
+ # ], # A list of grants that the specified principal can retire.
2308
+ # truncated: false, # A boolean that indicates whether there are more items in the list. Returns true when there are more items, or false when there are not.
2309
+ # }
2310
+ #
1784
2311
  # @example Request syntax with placeholder values
1785
2312
  #
1786
2313
  # resp = client.list_retirable_grants({
@@ -1892,6 +2419,17 @@ module Aws::KMS
1892
2419
  #
1893
2420
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
1894
2421
  #
2422
+ #
2423
+ # @example Example: To attach a key policy to a customer master key (CMK)
2424
+ #
2425
+ # # The following example attaches a key policy to the specified CMK.
2426
+ #
2427
+ # resp = client.put_key_policy({
2428
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to attach the key policy to. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2429
+ # policy: "{\n \"Version\": \"2012-10-17\",\n \"Id\": \"custom-policy-2016-12-07\",\n \"Statement\": [\n {\n \"Sid\": \"Enable IAM User Permissions\",\n \"Effect\": \"Allow\",\n \"Principal\": {\n \"AWS\": \"arn:aws:iam::111122223333:root\"\n },\n \"Action\": \"kms:*\",\n \"Resource\": \"*\"\n },\n {\n \"Sid\": \"Allow access for Key Administrators\",\n \"Effect\": \"Allow\",\n \"Principal\": {\n \"AWS\": [\n \"arn:aws:iam::111122223333:user/ExampleAdminUser\",\n \"arn:aws:iam::111122223333:role/ExampleAdminRole\"\n ]\n },\n \"Action\": [\n \"kms:Create*\",\n \"kms:Describe*\",\n \"kms:Enable*\",\n \"kms:List*\",\n \"kms:Put*\",\n \"kms:Update*\",\n \"kms:Revoke*\",\n \"kms:Disable*\",\n \"kms:Get*\",\n \"kms:Delete*\",\n \"kms:ScheduleKeyDeletion\",\n \"kms:CancelKeyDeletion\"\n ],\n \"Resource\": \"*\"\n },\n {\n \"Sid\": \"Allow use of the key\",\n \"Effect\": \"Allow\",\n \"Principal\": {\n \"AWS\": \"arn:aws:iam::111122223333:role/ExamplePowerUserRole\"\n },\n \"Action\": [\n \"kms:Encrypt\",\n \"kms:Decrypt\",\n \"kms:ReEncrypt*\",\n \"kms:GenerateDataKey*\",\n \"kms:DescribeKey\"\n ],\n \"Resource\": \"*\"\n },\n {\n \"Sid\": \"Allow attachment of persistent resources\",\n \"Effect\": \"Allow\",\n \"Principal\": {\n \"AWS\": \"arn:aws:iam::111122223333:role/ExamplePowerUserRole\"\n },\n \"Action\": [\n \"kms:CreateGrant\",\n \"kms:ListGrants\",\n \"kms:RevokeGrant\"\n ],\n \"Resource\": \"*\",\n \"Condition\": {\n \"Bool\": {\n \"kms:GrantIsForAWSResource\": \"true\"\n }\n }\n }\n ]\n}\n", # The key policy document.
2430
+ # policy_name: "default", # The name of the key policy.
2431
+ # })
2432
+ #
1895
2433
  # @example Request syntax with placeholder values
1896
2434
  #
1897
2435
  # resp = client.put_key_policy({
@@ -1970,6 +2508,23 @@ module Aws::KMS
1970
2508
  # * {Types::ReEncryptResponse#source_key_id #source_key_id} => String
1971
2509
  # * {Types::ReEncryptResponse#key_id #key_id} => String
1972
2510
  #
2511
+ #
2512
+ # @example Example: To reencrypt data
2513
+ #
2514
+ # # The following example reencrypts data with the specified CMK.
2515
+ #
2516
+ # resp = client.re_encrypt({
2517
+ # ciphertext_blob: "<binary data>", # The data to reencrypt.
2518
+ # 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.
2519
+ # })
2520
+ #
2521
+ # resp.to_h outputs the following:
2522
+ # {
2523
+ # ciphertext_blob: "<binary data>", # The reencrypted data.
2524
+ # 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.
2525
+ # 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.
2526
+ # }
2527
+ #
1973
2528
  # @example Request syntax with placeholder values
1974
2529
  #
1975
2530
  # resp = client.re_encrypt({
@@ -2039,6 +2594,16 @@ module Aws::KMS
2039
2594
  #
2040
2595
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2041
2596
  #
2597
+ #
2598
+ # @example Example: To retire a grant
2599
+ #
2600
+ # # The following example retires a grant.
2601
+ #
2602
+ # resp = client.retire_grant({
2603
+ # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", # The identifier of the grant to retire.
2604
+ # key_id: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The Amazon Resource Name (ARN) of the customer master key (CMK) associated with the grant.
2605
+ # })
2606
+ #
2042
2607
  # @example Request syntax with placeholder values
2043
2608
  #
2044
2609
  # resp = client.retire_grant({
@@ -2075,6 +2640,16 @@ module Aws::KMS
2075
2640
  #
2076
2641
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2077
2642
  #
2643
+ #
2644
+ # @example Example: To revoke a grant
2645
+ #
2646
+ # # The following example revokes a grant.
2647
+ #
2648
+ # resp = client.revoke_grant({
2649
+ # grant_id: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60", # The identifier of the grant to revoke.
2650
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the customer master key (CMK) associated with the grant. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2651
+ # })
2652
+ #
2078
2653
  # @example Request syntax with placeholder values
2079
2654
  #
2080
2655
  # resp = client.revoke_grant({
@@ -2139,6 +2714,22 @@ module Aws::KMS
2139
2714
  # * {Types::ScheduleKeyDeletionResponse#key_id #key_id} => String
2140
2715
  # * {Types::ScheduleKeyDeletionResponse#deletion_date #deletion_date} => Time
2141
2716
  #
2717
+ #
2718
+ # @example Example: To schedule a customer master key (CMK) for deletion
2719
+ #
2720
+ # # The following example schedules the specified CMK for deletion.
2721
+ #
2722
+ # resp = client.schedule_key_deletion({
2723
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK to schedule for deletion. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2724
+ # pending_window_in_days: 7, # The waiting period, specified in number of days. After the waiting period ends, AWS KMS deletes the CMK.
2725
+ # })
2726
+ #
2727
+ # resp.to_h outputs the following:
2728
+ # {
2729
+ # deletion_date: Time.parse("2016-12-17T16:00:00-08:00"), # The date and time after which AWS KMS deletes the CMK.
2730
+ # key_id: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab", # The ARN of the CMK that is scheduled for deletion.
2731
+ # }
2732
+ #
2142
2733
  # @example Request syntax with placeholder values
2143
2734
  #
2144
2735
  # resp = client.schedule_key_deletion({
@@ -2187,6 +2778,21 @@ module Aws::KMS
2187
2778
  #
2188
2779
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2189
2780
  #
2781
+ #
2782
+ # @example Example: To tag a customer master key (CMK)
2783
+ #
2784
+ # # The following example tags a CMK.
2785
+ #
2786
+ # resp = client.tag_resource({
2787
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK you are tagging. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2788
+ # tags: [
2789
+ # {
2790
+ # tag_key: "Purpose",
2791
+ # tag_value: "Test",
2792
+ # },
2793
+ # ], # A list of tags.
2794
+ # })
2795
+ #
2190
2796
  # @example Request syntax with placeholder values
2191
2797
  #
2192
2798
  # resp = client.tag_resource({
@@ -2230,6 +2836,19 @@ module Aws::KMS
2230
2836
  #
2231
2837
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2232
2838
  #
2839
+ #
2840
+ # @example Example: To remove tags from a customer master key (CMK)
2841
+ #
2842
+ # # The following example removes tags from a CMK.
2843
+ #
2844
+ # resp = client.untag_resource({
2845
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose tags you are removing.
2846
+ # tag_keys: [
2847
+ # "Purpose",
2848
+ # "CostCenter",
2849
+ # ], # A list of tag keys. Provide only the tag keys, not the tag values.
2850
+ # })
2851
+ #
2233
2852
  # @example Request syntax with placeholder values
2234
2853
  #
2235
2854
  # resp = client.untag_resource({
@@ -2282,6 +2901,16 @@ module Aws::KMS
2282
2901
  #
2283
2902
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2284
2903
  #
2904
+ #
2905
+ # @example Example: To update an alias
2906
+ #
2907
+ # # The following example updates the specified alias to refer to the specified customer master key (CMK).
2908
+ #
2909
+ # resp = client.update_alias({
2910
+ # alias_name: "alias/ExampleAlias", # The alias to update.
2911
+ # target_key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK that the alias will refer to after this operation succeeds. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2912
+ # })
2913
+ #
2285
2914
  # @example Request syntax with placeholder values
2286
2915
  #
2287
2916
  # resp = client.update_alias({
@@ -2315,6 +2944,16 @@ module Aws::KMS
2315
2944
  #
2316
2945
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2317
2946
  #
2947
+ #
2948
+ # @example Example: To update the description of a customer master key (CMK)
2949
+ #
2950
+ # # The following example updates the description of the specified CMK.
2951
+ #
2952
+ # resp = client.update_key_description({
2953
+ # description: "Example description that indicates the intended use of this CMK.", # The updated description.
2954
+ # key_id: "1234abcd-12ab-34cd-56ef-1234567890ab", # The identifier of the CMK whose description you are updating. You can use the key ID or the Amazon Resource Name (ARN) of the CMK.
2955
+ # })
2956
+ #
2318
2957
  # @example Request syntax with placeholder values
2319
2958
  #
2320
2959
  # resp = client.update_key_description({
@@ -2344,7 +2983,7 @@ module Aws::KMS
2344
2983
  params: params,
2345
2984
  config: config)
2346
2985
  context[:gem_name] = 'aws-sdk-kms'
2347
- context[:gem_version] = '1.0.0.rc7'
2986
+ context[:gem_version] = '1.0.0.rc8'
2348
2987
  Seahorse::Client::Request.new(handlers, context)
2349
2988
  end
2350
2989
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-kms
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.rc7
4
+ version: 1.0.0.rc8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-05-23 00:00:00.000000000 Z
11
+ date: 2017-06-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 3.0.0.rc12
19
+ version: 3.0.0.rc14
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 3.0.0.rc12
26
+ version: 3.0.0.rc14
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: aws-sigv4
29
29
  requirement: !ruby/object:Gem::Requirement