forked from aws-amplify/aws-sdk-ios
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAWSKMSResources.m
2127 lines (2115 loc) · 140 KB
/
AWSKMSResources.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
//
// Copyright 2010-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License").
// You may not use this file except in compliance with the License.
// A copy of the License is located at
//
// http://aws.amazon.com/apache2.0
//
// or in the "license" file accompanying this file. This file is distributed
// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
// express or implied. See the License for the specific language governing
// permissions and limitations under the License.
//
#import "AWSKMSResources.h"
#import <AWSCore/AWSCocoaLumberjack.h>
@interface AWSKMSResources ()
@property (nonatomic, strong) NSDictionary *definitionDictionary;
@end
@implementation AWSKMSResources
+ (instancetype)sharedInstance {
static AWSKMSResources *_sharedResources = nil;
static dispatch_once_t once_token;
dispatch_once(&once_token, ^{
_sharedResources = [AWSKMSResources new];
});
return _sharedResources;
}
- (NSDictionary *)JSONObject {
return self.definitionDictionary;
}
- (instancetype)init {
if (self = [super init]) {
//init method
NSError *error = nil;
_definitionDictionary = [NSJSONSerialization JSONObjectWithData:[[self definitionString] dataUsingEncoding:NSUTF8StringEncoding]
options:kNilOptions
error:&error];
if (_definitionDictionary == nil) {
if (error) {
AWSDDLogError(@"Failed to parse JSON service definition: %@",error);
}
}
}
return self;
}
- (NSString *)definitionString {
return @"{\
\"version\":\"2.0\",\
\"metadata\":{\
\"apiVersion\":\"2014-11-01\",\
\"endpointPrefix\":\"kms\",\
\"jsonVersion\":\"1.1\",\
\"protocol\":\"json\",\
\"serviceAbbreviation\":\"KMS\",\
\"serviceFullName\":\"AWS Key Management Service\",\
\"serviceId\":\"KMS\",\
\"signatureVersion\":\"v4\",\
\"targetPrefix\":\"TrentService\",\
\"uid\":\"kms-2014-11-01\"\
},\
\"operations\":{\
\"CancelKeyDeletion\":{\
\"name\":\"CancelKeyDeletion\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"CancelKeyDeletionRequest\"},\
\"output\":{\"shape\":\"CancelKeyDeletionResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Cancels the deletion of a customer master key (CMK). When this operation is successful, the CMK is set to the <code>Disabled</code> state. To enable a CMK, use <a>EnableKey</a>. You cannot perform this operation on a CMK in a different AWS account.</p> <p>For more information about scheduling and canceling deletion of a CMK, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html\\\">Deleting Customer Master Keys</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"CreateAlias\":{\
\"name\":\"CreateAlias\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"CreateAliasRequest\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"AlreadyExistsException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidAliasNameException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"LimitExceededException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Creates a display name for a customer-managed customer master key (CMK). You can use an alias to identify a CMK in selected operations, such as <a>Encrypt</a> and <a>GenerateDataKey</a>. </p> <p>Each CMK can have multiple aliases, but each alias points to only one CMK. The alias name must be unique in the AWS account and region. To simplify code that runs in multiple regions, use the same alias name, but point it to a different CMK in each region. </p> <p>Because an alias is not a property of a CMK, you can delete and change the aliases of a CMK without affecting the CMK. Also, aliases do not appear in the response from the <a>DescribeKey</a> operation. To get the aliases of all CMKs, use the <a>ListAliases</a> operation.</p> <p>The alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). Alias names cannot begin with <b>aws/</b>. That alias name prefix is reserved for AWS managed CMKs.</p> <p>The alias and the CMK it is mapped to must be in the same AWS account and the same region. You cannot perform this operation on an alias in a different AWS account.</p> <p>To map an existing alias to a different CMK, call <a>UpdateAlias</a>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"CreateGrant\":{\
\"name\":\"CreateGrant\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"CreateGrantRequest\"},\
\"output\":{\"shape\":\"CreateGrantResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"LimitExceededException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Adds a grant to a customer master key (CMK). The grant specifies who can use the CMK and under what conditions. When setting permissions, grants are an alternative to key policies. </p> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN in the value of the <code>KeyId</code> parameter. For more information about grants, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/grants.html\\\">Grants</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"CreateKey\":{\
\"name\":\"CreateKey\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"CreateKeyRequest\"},\
\"output\":{\"shape\":\"CreateKeyResponse\"},\
\"errors\":[\
{\"shape\":\"MalformedPolicyDocumentException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"UnsupportedOperationException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"LimitExceededException\"},\
{\"shape\":\"TagException\"}\
],\
\"documentation\":\"<p>Creates a customer master key (CMK) in the caller's AWS account.</p> <p>You can use a CMK to encrypt small amounts of data (4 KiB or less) directly. But CMKs are more commonly used to encrypt data encryption keys (DEKs), which are used to encrypt raw data. For more information about DEKs and the difference between CMKs and DEKs, see the following:</p> <ul> <li> <p>The <a>GenerateDataKey</a> operation</p> </li> <li> <p> <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html\\\">AWS Key Management Service Concepts</a> in the <i>AWS Key Management Service Developer Guide</i> </p> </li> </ul> <p>You cannot use this operation to create a CMK in a different AWS account.</p>\"\
},\
\"Decrypt\":{\
\"name\":\"Decrypt\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"DecryptRequest\"},\
\"output\":{\"shape\":\"DecryptResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"InvalidCiphertextException\"},\
{\"shape\":\"KeyUnavailableException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Decrypts ciphertext. Ciphertext is plaintext that has been previously encrypted by using any of the following operations:</p> <ul> <li> <p> <a>GenerateDataKey</a> </p> </li> <li> <p> <a>GenerateDataKeyWithoutPlaintext</a> </p> </li> <li> <p> <a>Encrypt</a> </p> </li> </ul> <p>Whenever possible, use key policies to give users permission to call the Decrypt operation on the CMK, instead of IAM policies. Otherwise, you might create an IAM user policy that gives the user Decrypt permission on all CMKs. This user could decrypt ciphertext that was encrypted by CMKs in other accounts if the key policy for the cross-account CMK permits it. If you must use an IAM policy for <code>Decrypt</code> permissions, limit the user to particular CMKs or particular trusted accounts.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"DeleteAlias\":{\
\"name\":\"DeleteAlias\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"DeleteAliasRequest\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Deletes the specified alias. You cannot perform this operation on an alias in a different AWS account. </p> <p>Because an alias is not a property of a CMK, you can delete and change the aliases of a CMK without affecting the CMK. Also, aliases do not appear in the response from the <a>DescribeKey</a> operation. To get the aliases of all CMKs, use the <a>ListAliases</a> operation. </p> <p>Each CMK can have multiple aliases. To change the alias of a CMK, use <a>DeleteAlias</a> to delete the current alias and <a>CreateAlias</a> to create a new alias. To associate an existing alias with a different customer master key (CMK), call <a>UpdateAlias</a>.</p>\"\
},\
\"DeleteImportedKeyMaterial\":{\
\"name\":\"DeleteImportedKeyMaterial\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"DeleteImportedKeyMaterialRequest\"},\
\"errors\":[\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"UnsupportedOperationException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Deletes key material that you previously imported. This operation makes the specified customer master key (CMK) unusable. For more information about importing key material into AWS KMS, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html\\\">Importing Key Material</a> in the <i>AWS Key Management Service Developer Guide</i>. You cannot perform this operation on a CMK in a different AWS account.</p> <p>When the specified CMK is in the <code>PendingDeletion</code> state, this operation does not change the CMK's state. Otherwise, it changes the CMK's state to <code>PendingImport</code>.</p> <p>After you delete key material, you can use <a>ImportKeyMaterial</a> to reimport the same key material into the CMK.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"DescribeKey\":{\
\"name\":\"DescribeKey\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"DescribeKeyRequest\"},\
\"output\":{\"shape\":\"DescribeKeyResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"}\
],\
\"documentation\":\"<p>Provides detailed information about the specified customer master key (CMK).</p> <p>You can use <code>DescribeKey</code> on a predefined AWS alias, that is, an AWS alias with no key ID. When you do, AWS KMS associates the alias with an <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#master_keys\\\">AWS managed CMK</a> and returns its <code>KeyId</code> and <code>Arn</code> in the response.</p> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN or alias ARN in the value of the KeyId parameter.</p>\"\
},\
\"DisableKey\":{\
\"name\":\"DisableKey\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"DisableKeyRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Sets the state of a customer master key (CMK) to disabled, thereby preventing its use for cryptographic operations. You cannot perform this operation on a CMK in a different AWS account.</p> <p>For more information about how key state affects the use of a CMK, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects the Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"DisableKeyRotation\":{\
\"name\":\"DisableKeyRotation\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"DisableKeyRotationRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"},\
{\"shape\":\"UnsupportedOperationException\"}\
],\
\"documentation\":\"<p>Disables <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html\\\">automatic rotation of the key material</a> for the specified customer master key (CMK). You cannot perform this operation on a CMK in a different AWS account.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"EnableKey\":{\
\"name\":\"EnableKey\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"EnableKeyRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"LimitExceededException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Sets the state of a customer master key (CMK) to enabled, thereby permitting its use for cryptographic operations. You cannot perform this operation on a CMK in a different AWS account.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"EnableKeyRotation\":{\
\"name\":\"EnableKeyRotation\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"EnableKeyRotationRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"},\
{\"shape\":\"UnsupportedOperationException\"}\
],\
\"documentation\":\"<p>Enables <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html\\\">automatic rotation of the key material</a> for the specified customer master key (CMK). You cannot perform this operation on a CMK in a different AWS account.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"Encrypt\":{\
\"name\":\"Encrypt\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"EncryptRequest\"},\
\"output\":{\"shape\":\"EncryptResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"KeyUnavailableException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidKeyUsageException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Encrypts plaintext into ciphertext by using a customer master key (CMK). The <code>Encrypt</code> operation has two primary use cases:</p> <ul> <li> <p>You can encrypt up to 4 kilobytes (4096 bytes) of arbitrary data such as an RSA key, a database password, or other sensitive information.</p> </li> <li> <p>You can use the <code>Encrypt</code> operation to move encrypted data from one AWS region to another. In the first region, generate a data key and use the plaintext key to encrypt the data. Then, in the new region, call the <code>Encrypt</code> method on same plaintext data key. Now, you can safely move the encrypted data and encrypted data key to the new region, and decrypt in the new region when necessary.</p> </li> </ul> <p>You don't need use this operation to encrypt a data key within a region. The <a>GenerateDataKey</a> and <a>GenerateDataKeyWithoutPlaintext</a> operations return an encrypted data key.</p> <p>Also, you don't need to use this operation to encrypt data in your application. You can use the plaintext and encrypted data keys that the <code>GenerateDataKey</code> operation returns.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN or alias ARN in the value of the KeyId parameter.</p>\"\
},\
\"GenerateDataKey\":{\
\"name\":\"GenerateDataKey\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"GenerateDataKeyRequest\"},\
\"output\":{\"shape\":\"GenerateDataKeyResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"KeyUnavailableException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidKeyUsageException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Returns a data encryption key that you can use in your application to encrypt data locally. </p> <p>You must specify the customer master key (CMK) under which to generate the data key. You must also specify the length of the data key using either the <code>KeySpec</code> or <code>NumberOfBytes</code> field. You must specify one field or the other, but not both. For common key lengths (128-bit and 256-bit symmetric keys), we recommend that you use <code>KeySpec</code>. To perform this operation on a CMK in a different AWS account, specify the key ARN or alias ARN in the value of the KeyId parameter.</p> <p>This operation returns a plaintext copy of the data key in the <code>Plaintext</code> field of the response, and an encrypted copy of the data key in the <code>CiphertextBlob</code> field. The data key is encrypted under the CMK specified in the <code>KeyId</code> field of the request. </p> <p>We recommend that you use the following pattern to encrypt data locally in your application:</p> <ol> <li> <p>Use this operation (<code>GenerateDataKey</code>) to get a data encryption key.</p> </li> <li> <p>Use the plaintext data encryption key (returned in the <code>Plaintext</code> field of the response) to encrypt data locally, then erase the plaintext data key from memory.</p> </li> <li> <p>Store the encrypted data key (returned in the <code>CiphertextBlob</code> field of the response) alongside the locally encrypted data.</p> </li> </ol> <p>To decrypt data locally:</p> <ol> <li> <p>Use the <a>Decrypt</a> operation to decrypt the encrypted data key into a plaintext copy of the data key.</p> </li> <li> <p>Use the plaintext data key to decrypt data locally, then erase the plaintext data key from memory.</p> </li> </ol> <p>To return only an encrypted copy of the data key, use <a>GenerateDataKeyWithoutPlaintext</a>. To return a random byte string that is cryptographically secure, use <a>GenerateRandom</a>.</p> <p>If you use the optional <code>EncryptionContext</code> field, you must store at least enough information to be able to reconstruct the full encryption context when you later send the ciphertext to the <a>Decrypt</a> operation. It is a good practice to choose an encryption context that you can reconstruct on the fly to better secure the ciphertext. For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html\\\">Encryption Context</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"GenerateDataKeyWithoutPlaintext\":{\
\"name\":\"GenerateDataKeyWithoutPlaintext\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"GenerateDataKeyWithoutPlaintextRequest\"},\
\"output\":{\"shape\":\"GenerateDataKeyWithoutPlaintextResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"KeyUnavailableException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidKeyUsageException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Returns a data encryption key encrypted under a customer master key (CMK). This operation is identical to <a>GenerateDataKey</a> but returns only the encrypted copy of the data key. </p> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN or alias ARN in the value of the KeyId parameter.</p> <p>This operation is useful in a system that has multiple components with different degrees of trust. For example, consider a system that stores encrypted data in containers. Each container stores the encrypted data and an encrypted copy of the data key. One component of the system, called the <i>control plane</i>, creates new containers. When it creates a new container, it uses this operation (<code>GenerateDataKeyWithoutPlaintext</code>) to get an encrypted data key and then stores it in the container. Later, a different component of the system, called the <i>data plane</i>, puts encrypted data into the containers. To do this, it passes the encrypted data key to the <a>Decrypt</a> operation. It then uses the returned plaintext data key to encrypt data and finally stores the encrypted data in the container. In this system, the control plane never sees the plaintext data key.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"GenerateRandom\":{\
\"name\":\"GenerateRandom\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"GenerateRandomRequest\"},\
\"output\":{\"shape\":\"GenerateRandomResponse\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"}\
],\
\"documentation\":\"<p>Returns a random byte string that is cryptographically secure.</p> <p>For more information about entropy and random number generation, see the <a href=\\\"https://d0.awsstatic.com/whitepapers/KMS-Cryptographic-Details.pdf\\\">AWS Key Management Service Cryptographic Details</a> whitepaper.</p>\"\
},\
\"GetKeyPolicy\":{\
\"name\":\"GetKeyPolicy\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"GetKeyPolicyRequest\"},\
\"output\":{\"shape\":\"GetKeyPolicyResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Gets a key policy attached to the specified customer master key (CMK). You cannot perform this operation on a CMK in a different AWS account.</p>\"\
},\
\"GetKeyRotationStatus\":{\
\"name\":\"GetKeyRotationStatus\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"GetKeyRotationStatusRequest\"},\
\"output\":{\"shape\":\"GetKeyRotationStatusResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"},\
{\"shape\":\"UnsupportedOperationException\"}\
],\
\"documentation\":\"<p>Gets a Boolean value that indicates whether <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html\\\">automatic rotation of the key material</a> is enabled for the specified customer master key (CMK).</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <ul> <li> <p>Disabled: The key rotation status does not change when you disable a CMK. However, while the CMK is disabled, AWS KMS does not rotate the backing key.</p> </li> <li> <p>Pending deletion: While a CMK is pending deletion, its key rotation status is <code>false</code> and AWS KMS does not rotate the backing key. If you cancel the deletion, the original key rotation status is restored.</p> </li> </ul> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN in the value of the <code>KeyId</code> parameter.</p>\"\
},\
\"GetParametersForImport\":{\
\"name\":\"GetParametersForImport\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"GetParametersForImportRequest\"},\
\"output\":{\"shape\":\"GetParametersForImportResponse\"},\
\"errors\":[\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"UnsupportedOperationException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Returns the items you need in order to import key material into AWS KMS from your existing key management infrastructure. For more information about importing key material into AWS KMS, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html\\\">Importing Key Material</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>You must specify the key ID of the customer master key (CMK) into which you will import key material. This CMK's <code>Origin</code> must be <code>EXTERNAL</code>. You must also specify the wrapping algorithm and type of wrapping key (public key) that you will use to encrypt the key material. You cannot perform this operation on a CMK in a different AWS account.</p> <p>This operation returns a public key and an import token. Use the public key to encrypt the key material. Store the import token to send with a subsequent <a>ImportKeyMaterial</a> request. The public key and import token from the same response must be used together. These items are valid for 24 hours. When they expire, they cannot be used for a subsequent <a>ImportKeyMaterial</a> request. To get new ones, send another <code>GetParametersForImport</code> request.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"ImportKeyMaterial\":{\
\"name\":\"ImportKeyMaterial\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ImportKeyMaterialRequest\"},\
\"output\":{\"shape\":\"ImportKeyMaterialResponse\"},\
\"errors\":[\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"UnsupportedOperationException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"},\
{\"shape\":\"InvalidCiphertextException\"},\
{\"shape\":\"IncorrectKeyMaterialException\"},\
{\"shape\":\"ExpiredImportTokenException\"},\
{\"shape\":\"InvalidImportTokenException\"}\
],\
\"documentation\":\"<p>Imports key material into an existing AWS KMS customer master key (CMK) that was created without key material. You cannot perform this operation on a CMK in a different AWS account. For more information about creating CMKs with no key material and then importing key material, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html\\\">Importing Key Material</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>Before using this operation, call <a>GetParametersForImport</a>. Its response includes a public key and an import token. Use the public key to encrypt the key material. Then, submit the import token from the same <code>GetParametersForImport</code> response.</p> <p>When calling this operation, you must specify the following values:</p> <ul> <li> <p>The key ID or key ARN of a CMK with no key material. Its <code>Origin</code> must be <code>EXTERNAL</code>.</p> <p>To create a CMK with no key material, call <a>CreateKey</a> and set the value of its <code>Origin</code> parameter to <code>EXTERNAL</code>. To get the <code>Origin</code> of a CMK, call <a>DescribeKey</a>.)</p> </li> <li> <p>The encrypted key material. To get the public key to encrypt the key material, call <a>GetParametersForImport</a>.</p> </li> <li> <p>The import token that <a>GetParametersForImport</a> returned. This token and the public key used to encrypt the key material must have come from the same response.</p> </li> <li> <p>Whether the key material expires and if so, when. If you set an expiration date, you can change it only by reimporting the same key material and specifying a new expiration date. If the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. To use the CMK again, you must reimport the same key material.</p> </li> </ul> <p>When this operation is successful, the CMK's key state changes from <code>PendingImport</code> to <code>Enabled</code>, and you can use the CMK. After you successfully import key material into a CMK, you can reimport the same key material into that CMK, but you cannot import different key material.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"ListAliases\":{\
\"name\":\"ListAliases\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ListAliasesRequest\"},\
\"output\":{\"shape\":\"ListAliasesResponse\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidMarkerException\"},\
{\"shape\":\"KMSInternalException\"}\
],\
\"documentation\":\"<p>Gets a list of aliases in the caller's AWS account and region. You cannot list aliases in other accounts. For more information about aliases, see <a>CreateAlias</a>.</p> <p>By default, the ListAliases command returns all aliases in the account and region. To get only the aliases that point to a particular customer master key (CMK), use the <code>KeyId</code> parameter.</p> <p>The <code>ListAliases</code> response can include aliases that you created and associated with your customer managed CMKs, and aliases that AWS created and associated with AWS managed CMKs in your account. You can recognize AWS aliases because their names have the format <code>aws/<service-name></code>, such as <code>aws/dynamodb</code>.</p> <p>The response might also include aliases that have no <code>TargetKeyId</code> field. These are predefined aliases that AWS has created but has not yet associated with a CMK. Aliases that AWS creates in your account, including predefined aliases, do not count against your <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/limits.html#aliases-limit\\\">AWS KMS aliases limit</a>.</p>\"\
},\
\"ListGrants\":{\
\"name\":\"ListGrants\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ListGrantsRequest\"},\
\"output\":{\"shape\":\"ListGrantsResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidMarkerException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Gets a list of all grants for the specified customer master key (CMK).</p> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN in the value of the <code>KeyId</code> parameter.</p>\"\
},\
\"ListKeyPolicies\":{\
\"name\":\"ListKeyPolicies\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ListKeyPoliciesRequest\"},\
\"output\":{\"shape\":\"ListKeyPoliciesResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Gets the names of the key policies that are attached to a customer master key (CMK). This operation is designed to get policy names that you can use in a <a>GetKeyPolicy</a> operation. However, the only valid policy name is <code>default</code>. You cannot perform this operation on a CMK in a different AWS account.</p>\"\
},\
\"ListKeys\":{\
\"name\":\"ListKeys\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ListKeysRequest\"},\
\"output\":{\"shape\":\"ListKeysResponse\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"InvalidMarkerException\"}\
],\
\"documentation\":\"<p>Gets a list of all customer master keys (CMKs) in the caller's AWS account and region.</p>\"\
},\
\"ListResourceTags\":{\
\"name\":\"ListResourceTags\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ListResourceTagsRequest\"},\
\"output\":{\"shape\":\"ListResourceTagsResponse\"},\
\"errors\":[\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"InvalidMarkerException\"}\
],\
\"documentation\":\"<p>Returns a list of all tags for the specified customer master key (CMK).</p> <p>You cannot perform this operation on a CMK in a different AWS account.</p>\"\
},\
\"ListRetirableGrants\":{\
\"name\":\"ListRetirableGrants\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ListRetirableGrantsRequest\"},\
\"output\":{\"shape\":\"ListGrantsResponse\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidMarkerException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"KMSInternalException\"}\
],\
\"documentation\":\"<p>Returns a list of all grants for which the grant's <code>RetiringPrincipal</code> matches the one specified.</p> <p>A typical use is to list all grants that you are able to retire. To retire a grant, use <a>RetireGrant</a>.</p>\"\
},\
\"PutKeyPolicy\":{\
\"name\":\"PutKeyPolicy\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"PutKeyPolicyRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"MalformedPolicyDocumentException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"UnsupportedOperationException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"LimitExceededException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Attaches a key policy to the specified customer master key (CMK). You cannot perform this operation on a CMK in a different AWS account.</p> <p>For more information about key policies, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html\\\">Key Policies</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"ReEncrypt\":{\
\"name\":\"ReEncrypt\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ReEncryptRequest\"},\
\"output\":{\"shape\":\"ReEncryptResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DisabledException\"},\
{\"shape\":\"InvalidCiphertextException\"},\
{\"shape\":\"KeyUnavailableException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidKeyUsageException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Encrypts data on the server side with a new customer master key (CMK) without exposing the plaintext of the data on the client side. The data is first decrypted and then reencrypted. You can also use this operation to change the encryption context of a ciphertext. </p> <p>You can reencrypt data using CMKs in different AWS accounts.</p> <p>Unlike other operations, <code>ReEncrypt</code> is authorized twice, once as <code>ReEncryptFrom</code> on the source CMK and once as <code>ReEncryptTo</code> on the destination CMK. We recommend that you include the <code>\\\"kms:ReEncrypt*\\\"</code> permission in your <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html\\\">key policies</a> to permit reencryption from or to the CMK. This permission is automatically included in the key policy when you create a CMK through the console. But you must include it manually when you create a CMK programmatically or when you set a key policy with the <a>PutKeyPolicy</a> operation.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"RetireGrant\":{\
\"name\":\"RetireGrant\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"RetireGrantRequest\"},\
\"errors\":[\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"InvalidGrantTokenException\"},\
{\"shape\":\"InvalidGrantIdException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Retires a grant. To clean up, you can retire a grant when you're done using it. You should revoke a grant when you intend to actively deny operations that depend on it. The following are permitted to call this API:</p> <ul> <li> <p>The AWS account (root user) under which the grant was created</p> </li> <li> <p>The <code>RetiringPrincipal</code>, if present in the grant</p> </li> <li> <p>The <code>GranteePrincipal</code>, if <code>RetireGrant</code> is an operation specified in the grant</p> </li> </ul> <p>You must identify the grant to retire by its grant token or by a combination of the grant ID and the Amazon Resource Name (ARN) of the customer master key (CMK). A grant token is a unique variable-length base64-encoded string. A grant ID is a 64 character unique identifier of a grant. The <a>CreateGrant</a> operation returns both.</p>\"\
},\
\"RevokeGrant\":{\
\"name\":\"RevokeGrant\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"RevokeGrantRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"InvalidGrantIdException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Revokes the specified grant for the specified customer master key (CMK). You can revoke a grant to actively deny operations that depend on it.</p> <p>To perform this operation on a CMK in a different AWS account, specify the key ARN in the value of the <code>KeyId</code> parameter.</p>\"\
},\
\"ScheduleKeyDeletion\":{\
\"name\":\"ScheduleKeyDeletion\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"ScheduleKeyDeletionRequest\"},\
\"output\":{\"shape\":\"ScheduleKeyDeletionResponse\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Schedules the deletion of a customer master key (CMK). You may provide a waiting period, specified in days, before deletion occurs. If you do not provide a waiting period, the default period of 30 days is used. When this operation is successful, the state of the CMK changes to <code>PendingDeletion</code>. Before the waiting period ends, you can use <a>CancelKeyDeletion</a> to cancel the deletion of the CMK. After the waiting period ends, AWS KMS deletes the CMK and all AWS KMS data associated with it, including all aliases that refer to it.</p> <p>You cannot perform this operation on a CMK in a different AWS account.</p> <important> <p>Deleting a CMK is a destructive and potentially dangerous operation. When a CMK is deleted, all data that was encrypted under the CMK is rendered unrecoverable. To restrict the use of a CMK without deleting it, use <a>DisableKey</a>.</p> </important> <p>For more information about scheduling a CMK for deletion, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html\\\">Deleting Customer Master Keys</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"TagResource\":{\
\"name\":\"TagResource\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"TagResourceRequest\"},\
\"errors\":[\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"KMSInvalidStateException\"},\
{\"shape\":\"LimitExceededException\"},\
{\"shape\":\"TagException\"}\
],\
\"documentation\":\"<p>Adds or edits tags for a customer master key (CMK). You cannot perform this operation on a CMK in a different AWS account.</p> <p>Each tag consists of a tag key and a tag value. Tag keys and tag values are both required, but tag values can be empty (null) strings.</p> <p>You can only use a tag key once for each CMK. If you use the tag key again, AWS KMS replaces the current tag value with the specified value.</p> <p>For information about the rules that apply to tag keys and tag values, see <a href=\\\"http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/allocation-tag-restrictions.html\\\">User-Defined Tag Restrictions</a> in the <i>AWS Billing and Cost Management User Guide</i>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"UntagResource\":{\
\"name\":\"UntagResource\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"UntagResourceRequest\"},\
\"errors\":[\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"KMSInvalidStateException\"},\
{\"shape\":\"TagException\"}\
],\
\"documentation\":\"<p>Removes the specified tags from the specified customer master key (CMK). You cannot perform this operation on a CMK in a different AWS account.</p> <p>To remove a tag, specify the tag key. To change the tag value of an existing tag key, use <a>TagResource</a>.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"UpdateAlias\":{\
\"name\":\"UpdateAlias\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"UpdateAliasRequest\"},\
\"errors\":[\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Associates an existing alias with a different customer master key (CMK). Each CMK can have multiple aliases, but the aliases must be unique within the account and region. You cannot perform this operation on an alias in a different AWS account.</p> <p>This operation works only on existing aliases. To change the alias of a CMK to a new value, use <a>CreateAlias</a> to create a new alias and <a>DeleteAlias</a> to delete the old alias.</p> <p>Because an alias is not a property of a CMK, you can create, update, and delete the aliases of a CMK without affecting the CMK. Also, aliases do not appear in the response from the <a>DescribeKey</a> operation. To get the aliases of all CMKs in the account, use the <a>ListAliases</a> operation. </p> <p>An alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). An alias must start with the word <code>alias</code> followed by a forward slash (<code>alias/</code>). The alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). Alias names cannot begin with <code>aws</code>; that alias name prefix is reserved by Amazon Web Services (AWS).</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"UpdateKeyDescription\":{\
\"name\":\"UpdateKeyDescription\",\
\"http\":{\
\"method\":\"POST\",\
\"requestUri\":\"/\"\
},\
\"input\":{\"shape\":\"UpdateKeyDescriptionRequest\"},\
\"errors\":[\
{\"shape\":\"NotFoundException\"},\
{\"shape\":\"InvalidArnException\"},\
{\"shape\":\"DependencyTimeoutException\"},\
{\"shape\":\"KMSInternalException\"},\
{\"shape\":\"KMSInvalidStateException\"}\
],\
\"documentation\":\"<p>Updates the description of a customer master key (CMK). To see the description of a CMK, use <a>DescribeKey</a>. </p> <p>You cannot perform this operation on a CMK in a different AWS account.</p> <p>The result of this operation varies with the key state of the CMK. For details, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html\\\">How Key State Affects Use of a Customer Master Key</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
}\
},\
\"shapes\":{\
\"AWSAccountIdType\":{\"type\":\"string\"},\
\"AlgorithmSpec\":{\
\"type\":\"string\",\
\"enum\":[\
\"RSAES_PKCS1_V1_5\",\
\"RSAES_OAEP_SHA_1\",\
\"RSAES_OAEP_SHA_256\"\
]\
},\
\"AliasList\":{\
\"type\":\"list\",\
\"member\":{\"shape\":\"AliasListEntry\"}\
},\
\"AliasListEntry\":{\
\"type\":\"structure\",\
\"members\":{\
\"AliasName\":{\
\"shape\":\"AliasNameType\",\
\"documentation\":\"<p>String that contains the alias.</p>\"\
},\
\"AliasArn\":{\
\"shape\":\"ArnType\",\
\"documentation\":\"<p>String that contains the key ARN.</p>\"\
},\
\"TargetKeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>String that contains the key identifier referred to by the alias.</p>\"\
}\
},\
\"documentation\":\"<p>Contains information about an alias.</p>\"\
},\
\"AliasNameType\":{\
\"type\":\"string\",\
\"max\":256,\
\"min\":1,\
\"pattern\":\"^[a-zA-Z0-9:/_-]+$\"\
},\
\"AlreadyExistsException\":{\
\"type\":\"structure\",\
\"members\":{\
\"message\":{\"shape\":\"ErrorMessageType\"}\
},\
\"documentation\":\"<p>The request was rejected because it attempted to create a resource that already exists.</p>\",\
\"exception\":true\
},\
\"ArnType\":{\
\"type\":\"string\",\
\"max\":2048,\
\"min\":20\
},\
\"BooleanType\":{\"type\":\"boolean\"},\
\"CancelKeyDeletionRequest\":{\
\"type\":\"structure\",\
\"required\":[\"KeyId\"],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>The unique identifier for the customer master key (CMK) for which to cancel deletion.</p> <p>Specify the key ID or the Amazon Resource Name (ARN) of the CMK.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>.</p>\"\
}\
}\
},\
\"CancelKeyDeletionResponse\":{\
\"type\":\"structure\",\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>The unique identifier of the master key for which deletion is canceled.</p>\"\
}\
}\
},\
\"CiphertextType\":{\
\"type\":\"blob\",\
\"max\":6144,\
\"min\":1\
},\
\"CreateAliasRequest\":{\
\"type\":\"structure\",\
\"required\":[\
\"AliasName\",\
\"TargetKeyId\"\
],\
\"members\":{\
\"AliasName\":{\
\"shape\":\"AliasNameType\",\
\"documentation\":\"<p>Specifies the alias name. This value must begin with <code>alias/</code> followed by the alias name, such as <code>alias/ExampleAlias</code>. The alias name cannot begin with <code>aws/</code>. The <code>alias/aws/</code> prefix is reserved for AWS managed CMKs.</p>\"\
},\
\"TargetKeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>Identifies the CMK for which you are creating the alias. This value cannot be an alias.</p> <p>Specify the key ID or the Amazon Resource Name (ARN) of the CMK.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>.</p>\"\
}\
}\
},\
\"CreateGrantRequest\":{\
\"type\":\"structure\",\
\"required\":[\
\"KeyId\",\
\"GranteePrincipal\",\
\"Operations\"\
],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>The unique identifier for the customer master key (CMK) that the grant applies to.</p> <p>Specify the key ID or the Amazon Resource Name (ARN) of the CMK. To specify a CMK in a different AWS account, you must use the key ARN.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>.</p>\"\
},\
\"GranteePrincipal\":{\
\"shape\":\"PrincipalIdType\",\
\"documentation\":\"<p>The principal that is given permission to perform the operations that the grant permits.</p> <p>To specify the principal, use the <a href=\\\"http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html\\\">Amazon Resource Name (ARN)</a> of an AWS principal. Valid AWS principals include AWS accounts (root), IAM users, IAM roles, federated users, and assumed role users. For examples of the ARN syntax to use for specifying a principal, see <a href=\\\"http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam\\\">AWS Identity and Access Management (IAM)</a> in the Example ARNs section of the <i>AWS General Reference</i>.</p>\"\
},\
\"RetiringPrincipal\":{\
\"shape\":\"PrincipalIdType\",\
\"documentation\":\"<p>The principal that is given permission to retire the grant by using <a>RetireGrant</a> operation.</p> <p>To specify the principal, use the <a href=\\\"http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html\\\">Amazon Resource Name (ARN)</a> of an AWS principal. Valid AWS principals include AWS accounts (root), IAM users, federated users, and assumed role users. For examples of the ARN syntax to use for specifying a principal, see <a href=\\\"http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam\\\">AWS Identity and Access Management (IAM)</a> in the Example ARNs section of the <i>AWS General Reference</i>.</p>\"\
},\
\"Operations\":{\
\"shape\":\"GrantOperationList\",\
\"documentation\":\"<p>A list of operations that the grant permits.</p>\"\
},\
\"Constraints\":{\
\"shape\":\"GrantConstraints\",\
\"documentation\":\"<p>A structure that you can use to allow certain operations in the grant only when the desired encryption context is present. For more information about encryption context, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html\\\">Encryption Context</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"GrantTokens\":{\
\"shape\":\"GrantTokenList\",\
\"documentation\":\"<p>A list of grant tokens.</p> <p>For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token\\\">Grant Tokens</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"Name\":{\
\"shape\":\"GrantNameType\",\
\"documentation\":\"<p>A friendly name for identifying the grant. Use this value to prevent the unintended creation of duplicate grants when retrying this request.</p> <p>When this value is absent, all <code>CreateGrant</code> requests result in a new grant with a unique <code>GrantId</code> even if all the supplied parameters are identical. This can result in unintended duplicates when you retry the <code>CreateGrant</code> request.</p> <p>When this value is present, you can retry a <code>CreateGrant</code> request with identical parameters; if the grant already exists, the original <code>GrantId</code> is returned without creating a new grant. Note that the returned grant token is unique with every <code>CreateGrant</code> request, even when a duplicate <code>GrantId</code> is returned. All grant tokens obtained in this way can be used interchangeably.</p>\"\
}\
}\
},\
\"CreateGrantResponse\":{\
\"type\":\"structure\",\
\"members\":{\
\"GrantToken\":{\
\"shape\":\"GrantTokenType\",\
\"documentation\":\"<p>The grant token.</p> <p>For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token\\\">Grant Tokens</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
},\
\"GrantId\":{\
\"shape\":\"GrantIdType\",\
\"documentation\":\"<p>The unique identifier for the grant.</p> <p>You can use the <code>GrantId</code> in a subsequent <a>RetireGrant</a> or <a>RevokeGrant</a> operation.</p>\"\
}\
}\
},\
\"CreateKeyRequest\":{\
\"type\":\"structure\",\
\"members\":{\
\"Policy\":{\
\"shape\":\"PolicyType\",\
\"documentation\":\"<p>The key policy to attach to the CMK.</p> <p>If you provide a key policy, it must meet the following criteria:</p> <ul> <li> <p>If you don't set <code>BypassPolicyLockoutSafetyCheck</code> to true, the key policy must allow the principal that is making the <code>CreateKey</code> request to make a subsequent <a>PutKeyPolicy</a> request on the CMK. This reduces the risk that the CMK becomes unmanageable. For more information, refer to the scenario in the <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam\\\">Default Key Policy</a> section of the <i>AWS Key Management Service Developer Guide</i>.</p> </li> <li> <p>Each statement in the key policy must contain one or more principals. The principals in the key policy must exist and be visible to AWS KMS. When you create a new AWS principal (for example, an IAM user or role), you might need to enforce a delay before including the new principal in a key policy. The reason for this is that the new principal might not be immediately visible to AWS KMS. For more information, see <a href=\\\"http://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_eventual-consistency\\\">Changes that I make are not always immediately visible</a> in the <i>AWS Identity and Access Management User Guide</i>.</p> </li> </ul> <p>If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK. For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default\\\">Default Key Policy</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The key policy size limit is 32 kilobytes (32768 bytes).</p>\"\
},\
\"Description\":{\
\"shape\":\"DescriptionType\",\
\"documentation\":\"<p>A description of the CMK.</p> <p>Use a description that helps you decide whether the CMK is appropriate for a task.</p>\"\
},\
\"KeyUsage\":{\
\"shape\":\"KeyUsageType\",\
\"documentation\":\"<p>The intended use of the CMK.</p> <p>You can use CMKs only for symmetric encryption and decryption.</p>\"\
},\
\"Origin\":{\
\"shape\":\"OriginType\",\
\"documentation\":\"<p>The source of the CMK's key material.</p> <p>The default is <code>AWS_KMS</code>, which means AWS KMS creates the key material. When this parameter is set to <code>EXTERNAL</code>, the request creates a CMK without key material so that you can import key material from your existing key management infrastructure. For more information about importing key material into AWS KMS, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html\\\">Importing Key Material</a> in the <i>AWS Key Management Service Developer Guide</i>.</p> <p>The CMK's <code>Origin</code> is immutable and is set when the CMK is created.</p>\"\
},\
\"BypassPolicyLockoutSafetyCheck\":{\
\"shape\":\"BooleanType\",\
\"documentation\":\"<p>A flag to indicate whether to bypass the key policy lockout safety check.</p> <important> <p>Setting this value to true increases the risk that the CMK becomes unmanageable. Do not set this value to true indiscriminately.</p> <p>For more information, refer to the scenario in the <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam\\\">Default Key Policy</a> section in the <i>AWS Key Management Service Developer Guide</i>.</p> </important> <p>Use this parameter only when you include a policy in the request and you intend to prevent the principal that is making the request from making a subsequent <a>PutKeyPolicy</a> request on the CMK.</p> <p>The default value is false.</p>\"\
},\
\"Tags\":{\
\"shape\":\"TagList\",\
\"documentation\":\"<p>One or more tags. Each tag consists of a tag key and a tag value. Tag keys and tag values are both required, but tag values can be empty (null) strings.</p> <p>Use this parameter to tag the CMK when it is created. Alternately, you can omit this parameter and instead tag the CMK after it is created using <a>TagResource</a>.</p>\"\
}\
}\
},\
\"CreateKeyResponse\":{\
\"type\":\"structure\",\
\"members\":{\
\"KeyMetadata\":{\
\"shape\":\"KeyMetadata\",\
\"documentation\":\"<p>Metadata associated with the CMK.</p>\"\
}\
}\
},\
\"DataKeySpec\":{\
\"type\":\"string\",\
\"enum\":[\
\"AES_256\",\
\"AES_128\"\
]\
},\
\"DateType\":{\"type\":\"timestamp\"},\
\"DecryptRequest\":{\
\"type\":\"structure\",\
\"required\":[\"CiphertextBlob\"],\
\"members\":{\
\"CiphertextBlob\":{\
\"shape\":\"CiphertextType\",\
\"documentation\":\"<p>Ciphertext to be decrypted. The blob includes metadata.</p>\"\
},\
\"EncryptionContext\":{\
\"shape\":\"EncryptionContextType\",\
\"documentation\":\"<p>The encryption context. If this was specified in the <a>Encrypt</a> function, it must be specified here or the decryption operation will fail. For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html\\\">Encryption Context</a>.</p>\"\
},\
\"GrantTokens\":{\
\"shape\":\"GrantTokenList\",\
\"documentation\":\"<p>A list of grant tokens.</p> <p>For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token\\\">Grant Tokens</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
}\
}\
},\
\"DecryptResponse\":{\
\"type\":\"structure\",\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>ARN of the key used to perform the decryption. This value is returned if no errors are encountered during the operation.</p>\"\
},\
\"Plaintext\":{\
\"shape\":\"PlaintextType\",\
\"documentation\":\"<p>Decrypted plaintext data. When you use the HTTP API or the AWS CLI, the value is Base64-encoded. Otherwise, it is not encoded.</p>\"\
}\
}\
},\
\"DeleteAliasRequest\":{\
\"type\":\"structure\",\
\"required\":[\"AliasName\"],\
\"members\":{\
\"AliasName\":{\
\"shape\":\"AliasNameType\",\
\"documentation\":\"<p>The alias to be deleted. The name must start with the word \\\"alias\\\" followed by a forward slash (alias/). Aliases that begin with \\\"alias/aws\\\" are reserved.</p>\"\
}\
}\
},\
\"DeleteImportedKeyMaterialRequest\":{\
\"type\":\"structure\",\
\"required\":[\"KeyId\"],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>The identifier of the CMK whose key material to delete. The CMK's <code>Origin</code> must be <code>EXTERNAL</code>.</p> <p>Specify the key ID or the Amazon Resource Name (ARN) of the CMK.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>.</p>\"\
}\
}\
},\
\"DependencyTimeoutException\":{\
\"type\":\"structure\",\
\"members\":{\
\"message\":{\"shape\":\"ErrorMessageType\"}\
},\
\"documentation\":\"<p>The system timed out while trying to fulfill the request. The request can be retried.</p>\",\
\"exception\":true,\
\"fault\":true\
},\
\"DescribeKeyRequest\":{\
\"type\":\"structure\",\
\"required\":[\"KeyId\"],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>Describes the specified customer master key (CMK). </p> <p>If you specify a predefined AWS alias (an AWS alias with no key ID), KMS associates the alias with an <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#master_keys\\\">AWS managed CMK</a> and returns its <code>KeyId</code> and <code>Arn</code> in the response.</p> <p>To specify a CMK, use its key ID, Amazon Resource Name (ARN), alias name, or alias ARN. When using an alias name, prefix it with <code>\\\"alias/\\\"</code>. To specify a CMK in a different AWS account, you must use the key ARN or alias ARN.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Alias name: <code>alias/ExampleAlias</code> </p> </li> <li> <p>Alias ARN: <code>arn:aws:kms:us-east-2:111122223333:alias/ExampleAlias</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>. To get the alias name and alias ARN, use <a>ListAliases</a>.</p>\"\
},\
\"GrantTokens\":{\
\"shape\":\"GrantTokenList\",\
\"documentation\":\"<p>A list of grant tokens.</p> <p>For more information, see <a href=\\\"http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token\\\">Grant Tokens</a> in the <i>AWS Key Management Service Developer Guide</i>.</p>\"\
}\
}\
},\
\"DescribeKeyResponse\":{\
\"type\":\"structure\",\
\"members\":{\
\"KeyMetadata\":{\
\"shape\":\"KeyMetadata\",\
\"documentation\":\"<p>Metadata associated with the key.</p>\"\
}\
}\
},\
\"DescriptionType\":{\
\"type\":\"string\",\
\"max\":8192,\
\"min\":0\
},\
\"DisableKeyRequest\":{\
\"type\":\"structure\",\
\"required\":[\"KeyId\"],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>A unique identifier for the customer master key (CMK).</p> <p>Specify the key ID or the Amazon Resource Name (ARN) of the CMK.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>.</p>\"\
}\
}\
},\
\"DisableKeyRotationRequest\":{\
\"type\":\"structure\",\
\"required\":[\"KeyId\"],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\
\"documentation\":\"<p>A unique identifier for the customer master key (CMK).</p> <p>Specify the key ID or the Amazon Resource Name (ARN) of the CMK.</p> <p>For example:</p> <ul> <li> <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> <li> <p>Key ARN: <code>arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code> </p> </li> </ul> <p>To get the key ID and key ARN for a CMK, use <a>ListKeys</a> or <a>DescribeKey</a>.</p>\"\
}\
}\
},\
\"DisabledException\":{\
\"type\":\"structure\",\
\"members\":{\
\"message\":{\"shape\":\"ErrorMessageType\"}\
},\
\"documentation\":\"<p>The request was rejected because the specified CMK is not enabled.</p>\",\
\"exception\":true\
},\
\"EnableKeyRequest\":{\
\"type\":\"structure\",\
\"required\":[\"KeyId\"],\
\"members\":{\
\"KeyId\":{\
\"shape\":\"KeyIdType\",\