aws-sdk-kms 1.55.0 → 1.58.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +15 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-kms/client.rb +1296 -621
- data/lib/aws-sdk-kms/client_api.rb +91 -3
- data/lib/aws-sdk-kms/errors.rb +16 -0
- data/lib/aws-sdk-kms/types.rb +576 -234
- data/lib/aws-sdk-kms.rb +1 -1
- metadata +2 -2
@@ -90,6 +90,8 @@ module Aws::KMS
|
|
90
90
|
GenerateDataKeyResponse = Shapes::StructureShape.new(name: 'GenerateDataKeyResponse')
|
91
91
|
GenerateDataKeyWithoutPlaintextRequest = Shapes::StructureShape.new(name: 'GenerateDataKeyWithoutPlaintextRequest')
|
92
92
|
GenerateDataKeyWithoutPlaintextResponse = Shapes::StructureShape.new(name: 'GenerateDataKeyWithoutPlaintextResponse')
|
93
|
+
GenerateMacRequest = Shapes::StructureShape.new(name: 'GenerateMacRequest')
|
94
|
+
GenerateMacResponse = Shapes::StructureShape.new(name: 'GenerateMacResponse')
|
93
95
|
GenerateRandomRequest = Shapes::StructureShape.new(name: 'GenerateRandomRequest')
|
94
96
|
GenerateRandomResponse = Shapes::StructureShape.new(name: 'GenerateRandomResponse')
|
95
97
|
GetKeyPolicyRequest = Shapes::StructureShape.new(name: 'GetKeyPolicyRequest')
|
@@ -123,6 +125,7 @@ module Aws::KMS
|
|
123
125
|
InvalidKeyUsageException = Shapes::StructureShape.new(name: 'InvalidKeyUsageException')
|
124
126
|
InvalidMarkerException = Shapes::StructureShape.new(name: 'InvalidMarkerException')
|
125
127
|
KMSInternalException = Shapes::StructureShape.new(name: 'KMSInternalException')
|
128
|
+
KMSInvalidMacException = Shapes::StructureShape.new(name: 'KMSInvalidMacException')
|
126
129
|
KMSInvalidSignatureException = Shapes::StructureShape.new(name: 'KMSInvalidSignatureException')
|
127
130
|
KMSInvalidStateException = Shapes::StructureShape.new(name: 'KMSInvalidStateException')
|
128
131
|
KeyIdType = Shapes::StringShape.new(name: 'KeyIdType')
|
@@ -148,6 +151,8 @@ module Aws::KMS
|
|
148
151
|
ListResourceTagsRequest = Shapes::StructureShape.new(name: 'ListResourceTagsRequest')
|
149
152
|
ListResourceTagsResponse = Shapes::StructureShape.new(name: 'ListResourceTagsResponse')
|
150
153
|
ListRetirableGrantsRequest = Shapes::StructureShape.new(name: 'ListRetirableGrantsRequest')
|
154
|
+
MacAlgorithmSpec = Shapes::StringShape.new(name: 'MacAlgorithmSpec')
|
155
|
+
MacAlgorithmSpecList = Shapes::ListShape.new(name: 'MacAlgorithmSpecList')
|
151
156
|
MalformedPolicyDocumentException = Shapes::StructureShape.new(name: 'MalformedPolicyDocumentException')
|
152
157
|
MarkerType = Shapes::StringShape.new(name: 'MarkerType')
|
153
158
|
MessageType = Shapes::StringShape.new(name: 'MessageType')
|
@@ -195,6 +200,8 @@ module Aws::KMS
|
|
195
200
|
UpdateCustomKeyStoreResponse = Shapes::StructureShape.new(name: 'UpdateCustomKeyStoreResponse')
|
196
201
|
UpdateKeyDescriptionRequest = Shapes::StructureShape.new(name: 'UpdateKeyDescriptionRequest')
|
197
202
|
UpdatePrimaryRegionRequest = Shapes::StructureShape.new(name: 'UpdatePrimaryRegionRequest')
|
203
|
+
VerifyMacRequest = Shapes::StructureShape.new(name: 'VerifyMacRequest')
|
204
|
+
VerifyMacResponse = Shapes::StructureShape.new(name: 'VerifyMacResponse')
|
198
205
|
VerifyRequest = Shapes::StructureShape.new(name: 'VerifyRequest')
|
199
206
|
VerifyResponse = Shapes::StructureShape.new(name: 'VerifyResponse')
|
200
207
|
WrappingKeySpec = Shapes::StringShape.new(name: 'WrappingKeySpec')
|
@@ -242,9 +249,9 @@ module Aws::KMS
|
|
242
249
|
CreateAliasRequest.struct_class = Types::CreateAliasRequest
|
243
250
|
|
244
251
|
CreateCustomKeyStoreRequest.add_member(:custom_key_store_name, Shapes::ShapeRef.new(shape: CustomKeyStoreNameType, required: true, location_name: "CustomKeyStoreName"))
|
245
|
-
CreateCustomKeyStoreRequest.add_member(:cloud_hsm_cluster_id, Shapes::ShapeRef.new(shape: CloudHsmClusterIdType,
|
246
|
-
CreateCustomKeyStoreRequest.add_member(:trust_anchor_certificate, Shapes::ShapeRef.new(shape: TrustAnchorCertificateType,
|
247
|
-
CreateCustomKeyStoreRequest.add_member(:key_store_password, Shapes::ShapeRef.new(shape: KeyStorePasswordType,
|
252
|
+
CreateCustomKeyStoreRequest.add_member(:cloud_hsm_cluster_id, Shapes::ShapeRef.new(shape: CloudHsmClusterIdType, location_name: "CloudHsmClusterId"))
|
253
|
+
CreateCustomKeyStoreRequest.add_member(:trust_anchor_certificate, Shapes::ShapeRef.new(shape: TrustAnchorCertificateType, location_name: "TrustAnchorCertificate"))
|
254
|
+
CreateCustomKeyStoreRequest.add_member(:key_store_password, Shapes::ShapeRef.new(shape: KeyStorePasswordType, location_name: "KeyStorePassword"))
|
248
255
|
CreateCustomKeyStoreRequest.struct_class = Types::CreateCustomKeyStoreRequest
|
249
256
|
|
250
257
|
CreateCustomKeyStoreResponse.add_member(:custom_key_store_id, Shapes::ShapeRef.new(shape: CustomKeyStoreIdType, location_name: "CustomKeyStoreId"))
|
@@ -433,6 +440,17 @@ module Aws::KMS
|
|
433
440
|
GenerateDataKeyWithoutPlaintextResponse.add_member(:key_id, Shapes::ShapeRef.new(shape: KeyIdType, location_name: "KeyId"))
|
434
441
|
GenerateDataKeyWithoutPlaintextResponse.struct_class = Types::GenerateDataKeyWithoutPlaintextResponse
|
435
442
|
|
443
|
+
GenerateMacRequest.add_member(:message, Shapes::ShapeRef.new(shape: PlaintextType, required: true, location_name: "Message"))
|
444
|
+
GenerateMacRequest.add_member(:key_id, Shapes::ShapeRef.new(shape: KeyIdType, required: true, location_name: "KeyId"))
|
445
|
+
GenerateMacRequest.add_member(:mac_algorithm, Shapes::ShapeRef.new(shape: MacAlgorithmSpec, required: true, location_name: "MacAlgorithm"))
|
446
|
+
GenerateMacRequest.add_member(:grant_tokens, Shapes::ShapeRef.new(shape: GrantTokenList, location_name: "GrantTokens"))
|
447
|
+
GenerateMacRequest.struct_class = Types::GenerateMacRequest
|
448
|
+
|
449
|
+
GenerateMacResponse.add_member(:mac, Shapes::ShapeRef.new(shape: CiphertextType, location_name: "Mac"))
|
450
|
+
GenerateMacResponse.add_member(:mac_algorithm, Shapes::ShapeRef.new(shape: MacAlgorithmSpec, location_name: "MacAlgorithm"))
|
451
|
+
GenerateMacResponse.add_member(:key_id, Shapes::ShapeRef.new(shape: KeyIdType, location_name: "KeyId"))
|
452
|
+
GenerateMacResponse.struct_class = Types::GenerateMacResponse
|
453
|
+
|
436
454
|
GenerateRandomRequest.add_member(:number_of_bytes, Shapes::ShapeRef.new(shape: NumberOfBytesType, location_name: "NumberOfBytes"))
|
437
455
|
GenerateRandomRequest.add_member(:custom_key_store_id, Shapes::ShapeRef.new(shape: CustomKeyStoreIdType, location_name: "CustomKeyStoreId"))
|
438
456
|
GenerateRandomRequest.struct_class = Types::GenerateRandomRequest
|
@@ -543,6 +561,9 @@ module Aws::KMS
|
|
543
561
|
KMSInternalException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessageType, location_name: "message"))
|
544
562
|
KMSInternalException.struct_class = Types::KMSInternalException
|
545
563
|
|
564
|
+
KMSInvalidMacException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessageType, location_name: "message"))
|
565
|
+
KMSInvalidMacException.struct_class = Types::KMSInvalidMacException
|
566
|
+
|
546
567
|
KMSInvalidSignatureException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessageType, location_name: "message"))
|
547
568
|
KMSInvalidSignatureException.struct_class = Types::KMSInvalidSignatureException
|
548
569
|
|
@@ -577,6 +598,7 @@ module Aws::KMS
|
|
577
598
|
KeyMetadata.add_member(:multi_region, Shapes::ShapeRef.new(shape: NullableBooleanType, location_name: "MultiRegion"))
|
578
599
|
KeyMetadata.add_member(:multi_region_configuration, Shapes::ShapeRef.new(shape: MultiRegionConfiguration, location_name: "MultiRegionConfiguration"))
|
579
600
|
KeyMetadata.add_member(:pending_deletion_window_in_days, Shapes::ShapeRef.new(shape: PendingWindowInDaysType, location_name: "PendingDeletionWindowInDays"))
|
601
|
+
KeyMetadata.add_member(:mac_algorithms, Shapes::ShapeRef.new(shape: MacAlgorithmSpecList, location_name: "MacAlgorithms"))
|
580
602
|
KeyMetadata.struct_class = Types::KeyMetadata
|
581
603
|
|
582
604
|
KeyUnavailableException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessageType, location_name: "message"))
|
@@ -641,6 +663,8 @@ module Aws::KMS
|
|
641
663
|
ListRetirableGrantsRequest.add_member(:retiring_principal, Shapes::ShapeRef.new(shape: PrincipalIdType, required: true, location_name: "RetiringPrincipal"))
|
642
664
|
ListRetirableGrantsRequest.struct_class = Types::ListRetirableGrantsRequest
|
643
665
|
|
666
|
+
MacAlgorithmSpecList.member = Shapes::ShapeRef.new(shape: MacAlgorithmSpec)
|
667
|
+
|
644
668
|
MalformedPolicyDocumentException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessageType, location_name: "message"))
|
645
669
|
MalformedPolicyDocumentException.struct_class = Types::MalformedPolicyDocumentException
|
646
670
|
|
@@ -771,6 +795,18 @@ module Aws::KMS
|
|
771
795
|
UpdatePrimaryRegionRequest.add_member(:primary_region, Shapes::ShapeRef.new(shape: RegionType, required: true, location_name: "PrimaryRegion"))
|
772
796
|
UpdatePrimaryRegionRequest.struct_class = Types::UpdatePrimaryRegionRequest
|
773
797
|
|
798
|
+
VerifyMacRequest.add_member(:message, Shapes::ShapeRef.new(shape: PlaintextType, required: true, location_name: "Message"))
|
799
|
+
VerifyMacRequest.add_member(:key_id, Shapes::ShapeRef.new(shape: KeyIdType, required: true, location_name: "KeyId"))
|
800
|
+
VerifyMacRequest.add_member(:mac_algorithm, Shapes::ShapeRef.new(shape: MacAlgorithmSpec, required: true, location_name: "MacAlgorithm"))
|
801
|
+
VerifyMacRequest.add_member(:mac, Shapes::ShapeRef.new(shape: CiphertextType, required: true, location_name: "Mac"))
|
802
|
+
VerifyMacRequest.add_member(:grant_tokens, Shapes::ShapeRef.new(shape: GrantTokenList, location_name: "GrantTokens"))
|
803
|
+
VerifyMacRequest.struct_class = Types::VerifyMacRequest
|
804
|
+
|
805
|
+
VerifyMacResponse.add_member(:key_id, Shapes::ShapeRef.new(shape: KeyIdType, location_name: "KeyId"))
|
806
|
+
VerifyMacResponse.add_member(:mac_valid, Shapes::ShapeRef.new(shape: BooleanType, location_name: "MacValid"))
|
807
|
+
VerifyMacResponse.add_member(:mac_algorithm, Shapes::ShapeRef.new(shape: MacAlgorithmSpec, location_name: "MacAlgorithm"))
|
808
|
+
VerifyMacResponse.struct_class = Types::VerifyMacResponse
|
809
|
+
|
774
810
|
VerifyRequest.add_member(:key_id, Shapes::ShapeRef.new(shape: KeyIdType, required: true, location_name: "KeyId"))
|
775
811
|
VerifyRequest.add_member(:message, Shapes::ShapeRef.new(shape: PlaintextType, required: true, location_name: "Message"))
|
776
812
|
VerifyRequest.add_member(:message_type, Shapes::ShapeRef.new(shape: MessageType, location_name: "MessageType"))
|
@@ -958,6 +994,13 @@ module Aws::KMS
|
|
958
994
|
o.errors << Shapes::ShapeRef.new(shape: CustomKeyStoreNotFoundException)
|
959
995
|
o.errors << Shapes::ShapeRef.new(shape: InvalidMarkerException)
|
960
996
|
o.errors << Shapes::ShapeRef.new(shape: KMSInternalException)
|
997
|
+
o[:pager] = Aws::Pager.new(
|
998
|
+
more_results: "truncated",
|
999
|
+
limit_key: "limit",
|
1000
|
+
tokens: {
|
1001
|
+
"next_marker" => "marker"
|
1002
|
+
}
|
1003
|
+
)
|
961
1004
|
end)
|
962
1005
|
|
963
1006
|
api.add_operation(:describe_key, Seahorse::Model::Operation.new.tap do |o|
|
@@ -1122,6 +1165,21 @@ module Aws::KMS
|
|
1122
1165
|
o.errors << Shapes::ShapeRef.new(shape: KMSInvalidStateException)
|
1123
1166
|
end)
|
1124
1167
|
|
1168
|
+
api.add_operation(:generate_mac, Seahorse::Model::Operation.new.tap do |o|
|
1169
|
+
o.name = "GenerateMac"
|
1170
|
+
o.http_method = "POST"
|
1171
|
+
o.http_request_uri = "/"
|
1172
|
+
o.input = Shapes::ShapeRef.new(shape: GenerateMacRequest)
|
1173
|
+
o.output = Shapes::ShapeRef.new(shape: GenerateMacResponse)
|
1174
|
+
o.errors << Shapes::ShapeRef.new(shape: NotFoundException)
|
1175
|
+
o.errors << Shapes::ShapeRef.new(shape: DisabledException)
|
1176
|
+
o.errors << Shapes::ShapeRef.new(shape: KeyUnavailableException)
|
1177
|
+
o.errors << Shapes::ShapeRef.new(shape: InvalidKeyUsageException)
|
1178
|
+
o.errors << Shapes::ShapeRef.new(shape: InvalidGrantTokenException)
|
1179
|
+
o.errors << Shapes::ShapeRef.new(shape: KMSInternalException)
|
1180
|
+
o.errors << Shapes::ShapeRef.new(shape: KMSInvalidStateException)
|
1181
|
+
end)
|
1182
|
+
|
1125
1183
|
api.add_operation(:generate_random, Seahorse::Model::Operation.new.tap do |o|
|
1126
1184
|
o.name = "GenerateRandom"
|
1127
1185
|
o.http_method = "POST"
|
@@ -1301,6 +1359,13 @@ module Aws::KMS
|
|
1301
1359
|
o.errors << Shapes::ShapeRef.new(shape: NotFoundException)
|
1302
1360
|
o.errors << Shapes::ShapeRef.new(shape: InvalidArnException)
|
1303
1361
|
o.errors << Shapes::ShapeRef.new(shape: InvalidMarkerException)
|
1362
|
+
o[:pager] = Aws::Pager.new(
|
1363
|
+
more_results: "truncated",
|
1364
|
+
limit_key: "limit",
|
1365
|
+
tokens: {
|
1366
|
+
"next_marker" => "marker"
|
1367
|
+
}
|
1368
|
+
)
|
1304
1369
|
end)
|
1305
1370
|
|
1306
1371
|
api.add_operation(:list_retirable_grants, Seahorse::Model::Operation.new.tap do |o|
|
@@ -1314,6 +1379,13 @@ module Aws::KMS
|
|
1314
1379
|
o.errors << Shapes::ShapeRef.new(shape: InvalidArnException)
|
1315
1380
|
o.errors << Shapes::ShapeRef.new(shape: NotFoundException)
|
1316
1381
|
o.errors << Shapes::ShapeRef.new(shape: KMSInternalException)
|
1382
|
+
o[:pager] = Aws::Pager.new(
|
1383
|
+
more_results: "truncated",
|
1384
|
+
limit_key: "limit",
|
1385
|
+
tokens: {
|
1386
|
+
"next_marker" => "marker"
|
1387
|
+
}
|
1388
|
+
)
|
1317
1389
|
end)
|
1318
1390
|
|
1319
1391
|
api.add_operation(:put_key_policy, Seahorse::Model::Operation.new.tap do |o|
|
@@ -1525,6 +1597,22 @@ module Aws::KMS
|
|
1525
1597
|
o.errors << Shapes::ShapeRef.new(shape: KMSInvalidStateException)
|
1526
1598
|
o.errors << Shapes::ShapeRef.new(shape: KMSInvalidSignatureException)
|
1527
1599
|
end)
|
1600
|
+
|
1601
|
+
api.add_operation(:verify_mac, Seahorse::Model::Operation.new.tap do |o|
|
1602
|
+
o.name = "VerifyMac"
|
1603
|
+
o.http_method = "POST"
|
1604
|
+
o.http_request_uri = "/"
|
1605
|
+
o.input = Shapes::ShapeRef.new(shape: VerifyMacRequest)
|
1606
|
+
o.output = Shapes::ShapeRef.new(shape: VerifyMacResponse)
|
1607
|
+
o.errors << Shapes::ShapeRef.new(shape: NotFoundException)
|
1608
|
+
o.errors << Shapes::ShapeRef.new(shape: DisabledException)
|
1609
|
+
o.errors << Shapes::ShapeRef.new(shape: KeyUnavailableException)
|
1610
|
+
o.errors << Shapes::ShapeRef.new(shape: InvalidKeyUsageException)
|
1611
|
+
o.errors << Shapes::ShapeRef.new(shape: InvalidGrantTokenException)
|
1612
|
+
o.errors << Shapes::ShapeRef.new(shape: KMSInternalException)
|
1613
|
+
o.errors << Shapes::ShapeRef.new(shape: KMSInvalidMacException)
|
1614
|
+
o.errors << Shapes::ShapeRef.new(shape: KMSInvalidStateException)
|
1615
|
+
end)
|
1528
1616
|
end
|
1529
1617
|
|
1530
1618
|
end
|
data/lib/aws-sdk-kms/errors.rb
CHANGED
@@ -52,6 +52,7 @@ module Aws::KMS
|
|
52
52
|
# * {InvalidKeyUsageException}
|
53
53
|
# * {InvalidMarkerException}
|
54
54
|
# * {KMSInternalException}
|
55
|
+
# * {KMSInvalidMacException}
|
55
56
|
# * {KMSInvalidSignatureException}
|
56
57
|
# * {KMSInvalidStateException}
|
57
58
|
# * {KeyUnavailableException}
|
@@ -442,6 +443,21 @@ module Aws::KMS
|
|
442
443
|
end
|
443
444
|
end
|
444
445
|
|
446
|
+
class KMSInvalidMacException < ServiceError
|
447
|
+
|
448
|
+
# @param [Seahorse::Client::RequestContext] context
|
449
|
+
# @param [String] message
|
450
|
+
# @param [Aws::KMS::Types::KMSInvalidMacException] data
|
451
|
+
def initialize(context, message, data = Aws::EmptyStructure.new)
|
452
|
+
super(context, message, data)
|
453
|
+
end
|
454
|
+
|
455
|
+
# @return [String]
|
456
|
+
def message
|
457
|
+
@message || @data[:message]
|
458
|
+
end
|
459
|
+
end
|
460
|
+
|
445
461
|
class KMSInvalidSignatureException < ServiceError
|
446
462
|
|
447
463
|
# @param [Seahorse::Client::RequestContext] context
|