aws-sdk-kms 1.0.0.rc1 → 1.0.0.rc2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,23 +1,14 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module KMS
10
- module Errors
8
+ module Aws::KMS
9
+ module Errors
11
10
 
12
- extend Aws::Errors::DynamicErrors
11
+ extend Aws::Errors::DynamicErrors
13
12
 
14
- # Raised when calling #load or #data on a resource class that can not be
15
- # loaded. This can happen when:
16
- #
17
- # * A resource class has identifiers, but no data attributes.
18
- # * Resource data is only available when making an API call that
19
- # enumerates all resources of that type.
20
- class ResourceNotLoadable < RuntimeError; end
21
- end
22
13
  end
23
14
  end
@@ -1,25 +1,23 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module KMS
10
- class Resource
8
+ module Aws::KMS
9
+ class Resource
11
10
 
12
- # @param options ({})
13
- # @option options [Client] :client
14
- def initialize(options = {})
15
- @client = options[:client] || Client.new(options)
16
- end
17
-
18
- # @return [Client]
19
- def client
20
- @client
21
- end
11
+ # @param options ({})
12
+ # @option options [Client] :client
13
+ def initialize(options = {})
14
+ @client = options[:client] || Client.new(options)
15
+ end
22
16
 
17
+ # @return [Client]
18
+ def client
19
+ @client
23
20
  end
21
+
24
22
  end
25
23
  end
@@ -1,1930 +1,1987 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module KMS
10
- module Types
8
+ module Aws::KMS
9
+ module Types
11
10
 
12
- # Contains information about an alias.
13
- # @!attribute [rw] alias_name
14
- # String that contains the alias.
15
- # @return [String]
16
- #
17
- # @!attribute [rw] alias_arn
18
- # String that contains the key ARN.
19
- # @return [String]
20
- #
21
- # @!attribute [rw] target_key_id
22
- # String that contains the key identifier pointed to by the alias.
23
- # @return [String]
24
- class AliasListEntry < Struct.new(
25
- :alias_name,
26
- :alias_arn,
27
- :target_key_id)
28
- include Aws::Structure
29
- end
30
-
31
- # @note When making an API call, pass CancelKeyDeletionRequest
32
- # data as a hash:
33
- #
34
- # {
35
- # key_id: "KeyIdType", # required
36
- # }
37
- # @!attribute [rw] key_id
38
- # The unique identifier for the customer master key (CMK) for which to
39
- # cancel deletion.
40
- #
41
- # To specify this value, use the unique key ID or the Amazon Resource
42
- # Name (ARN) of the CMK. Examples:
43
- #
44
- # * Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab
45
- #
46
- # * Key ARN:
47
- # arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
48
- #
49
- # To obtain the unique key ID and key ARN for a given CMK, use
50
- # ListKeys or DescribeKey.
51
- # @return [String]
52
- class CancelKeyDeletionRequest < Struct.new(
53
- :key_id)
54
- include Aws::Structure
55
- end
11
+ # Contains information about an alias.
12
+ #
13
+ # @!attribute [rw] alias_name
14
+ # String that contains the alias.
15
+ # @return [String]
16
+ #
17
+ # @!attribute [rw] alias_arn
18
+ # String that contains the key ARN.
19
+ # @return [String]
20
+ #
21
+ # @!attribute [rw] target_key_id
22
+ # String that contains the key identifier referred to by the alias.
23
+ # @return [String]
24
+ #
25
+ class AliasListEntry < Struct.new(
26
+ :alias_name,
27
+ :alias_arn,
28
+ :target_key_id)
29
+ include Aws::Structure
30
+ end
56
31
 
57
- # @!attribute [rw] key_id
58
- # The unique identifier of the master key for which deletion is
59
- # canceled.
60
- # @return [String]
61
- class CancelKeyDeletionResponse < Struct.new(
62
- :key_id)
63
- include Aws::Structure
64
- end
32
+ # @note When making an API call, you may pass CancelKeyDeletionRequest
33
+ # data as a hash:
34
+ #
35
+ # {
36
+ # key_id: "KeyIdType", # required
37
+ # }
38
+ #
39
+ # @!attribute [rw] key_id
40
+ # The unique identifier for the customer master key (CMK) for which to
41
+ # cancel deletion.
42
+ #
43
+ # To specify this value, use the unique key ID or the Amazon Resource
44
+ # Name (ARN) of the CMK. Examples:
45
+ #
46
+ # * Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab
47
+ #
48
+ # * Key ARN:
49
+ # arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
50
+ #
51
+ # To obtain the unique key ID and key ARN for a given CMK, use
52
+ # ListKeys or DescribeKey.
53
+ # @return [String]
54
+ #
55
+ class CancelKeyDeletionRequest < Struct.new(
56
+ :key_id)
57
+ include Aws::Structure
58
+ end
65
59
 
66
- # @note When making an API call, pass CreateAliasRequest
67
- # data as a hash:
68
- #
69
- # {
70
- # alias_name: "AliasNameType", # required
71
- # target_key_id: "KeyIdType", # required
72
- # }
73
- # @!attribute [rw] alias_name
74
- # String that contains the display name. The name must start with the
75
- # word "alias" followed by a forward slash (alias/). Aliases that
76
- # begin with "alias/AWS" are reserved.
77
- # @return [String]
78
- #
79
- # @!attribute [rw] target_key_id
80
- # An identifier of the key for which you are creating the alias. This
81
- # value cannot be another alias but can be a globally unique
82
- # identifier or a fully specified ARN to a key.
83
- #
84
- # * Key ARN Example -
85
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
86
- #
87
- # * Globally Unique Key ID Example -
88
- # 12345678-1234-1234-1234-123456789012
89
- # @return [String]
90
- class CreateAliasRequest < Struct.new(
91
- :alias_name,
92
- :target_key_id)
93
- include Aws::Structure
94
- end
60
+ # @!attribute [rw] key_id
61
+ # The unique identifier of the master key for which deletion is
62
+ # canceled.
63
+ # @return [String]
64
+ #
65
+ class CancelKeyDeletionResponse < Struct.new(
66
+ :key_id)
67
+ include Aws::Structure
68
+ end
95
69
 
96
- # @note When making an API call, pass CreateGrantRequest
97
- # data as a hash:
98
- #
99
- # {
100
- # key_id: "KeyIdType", # required
101
- # grantee_principal: "PrincipalIdType", # required
102
- # retiring_principal: "PrincipalIdType",
103
- # operations: ["Decrypt"], # accepts Decrypt, Encrypt, GenerateDataKey, GenerateDataKeyWithoutPlaintext, ReEncryptFrom, ReEncryptTo, CreateGrant, RetireGrant, DescribeKey
104
- # constraints: {
105
- # encryption_context_subset: {
106
- # "EncryptionContextKey" => "EncryptionContextValue",
107
- # },
108
- # encryption_context_equals: {
109
- # "EncryptionContextKey" => "EncryptionContextValue",
110
- # },
111
- # },
112
- # grant_tokens: ["GrantTokenType"],
113
- # name: "GrantNameType",
114
- # }
115
- # @!attribute [rw] key_id
116
- # The unique identifier for the customer master key (CMK) that the
117
- # grant applies to.
118
- #
119
- # To specify this value, use the globally unique key ID or the Amazon
120
- # Resource Name (ARN) of the key. Examples:
121
- #
122
- # * Globally unique key ID: 12345678-1234-1234-1234-123456789012
123
- #
124
- # * Key ARN:
125
- # arn:aws:kms:us-west-2:123456789012:key/12345678-1234-1234-1234-123456789012
126
- # @return [String]
127
- #
128
- # @!attribute [rw] grantee_principal
129
- # The principal that is given permission to perform the operations
130
- # that the grant permits.
131
- #
132
- # To specify the principal, use the [Amazon Resource Name (ARN)][1] of
133
- # an AWS principal. Valid AWS principals include AWS accounts (root),
134
- # IAM users, federated users, and assumed role users. For examples of
135
- # the ARN syntax to use for specifying a principal, see [AWS Identity
136
- # and Access Management (IAM)][2] in the Example ARNs section of the
137
- # *AWS General Reference*.
138
- #
139
- #
140
- #
141
- # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
142
- # [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam
143
- # @return [String]
144
- #
145
- # @!attribute [rw] retiring_principal
146
- # The principal that is given permission to retire the grant by using
147
- # RetireGrant operation.
148
- #
149
- # To specify the principal, use the [Amazon Resource Name (ARN)][1] of
150
- # an AWS principal. Valid AWS principals include AWS accounts (root),
151
- # IAM users, federated users, and assumed role users. For examples of
152
- # the ARN syntax to use for specifying a principal, see [AWS Identity
153
- # and Access Management (IAM)][2] in the Example ARNs section of the
154
- # *AWS General Reference*.
155
- #
156
- #
157
- #
158
- # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
159
- # [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam
160
- # @return [String]
161
- #
162
- # @!attribute [rw] operations
163
- # A list of operations that the grant permits. The list can contain
164
- # any combination of one or more of the following values:
165
- #
166
- # * Decrypt
167
- #
168
- # * Encrypt
169
- #
170
- # * GenerateDataKey
171
- #
172
- # * GenerateDataKeyWithoutPlaintext
173
- #
174
- # * [ReEncryptFrom][1]
175
- #
176
- # * [ReEncryptTo][1]
177
- #
178
- # * CreateGrant
179
- #
180
- # * RetireGrant
181
- #
182
- # * DescribeKey
183
- #
184
- #
185
- #
186
- # [1]: http://docs.aws.amazon.com/kms/latest/APIReference/API_ReEncrypt.html
187
- # @return [Array<String>]
188
- #
189
- # @!attribute [rw] constraints
190
- # The conditions under which the operations permitted by the grant are
191
- # allowed.
192
- #
193
- # You can use this value to allow the operations permitted by the
194
- # grant only when a specified encryption context is present. For more
195
- # information, see [Encryption Context][1] in the *AWS Key Management
196
- # Service Developer Guide*.
197
- #
198
- #
199
- #
200
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
201
- # @return [Types::GrantConstraints]
202
- #
203
- # @!attribute [rw] grant_tokens
204
- # A list of grant tokens.
205
- #
206
- # For more information, see [Grant Tokens][1] in the *AWS Key
207
- # Management Service Developer Guide*.
208
- #
209
- #
210
- #
211
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
212
- # @return [Array<String>]
213
- #
214
- # @!attribute [rw] name
215
- # A friendly name for identifying the grant. Use this value to prevent
216
- # unintended creation of duplicate grants when retrying this request.
217
- #
218
- # When this value is absent, all `CreateGrant` requests result in a
219
- # new grant with a unique `GrantId` even if all the supplied
220
- # parameters are identical. This can result in unintended duplicates
221
- # when you retry the `CreateGrant` request.
222
- #
223
- # When this value is present, you can retry a `CreateGrant` request
224
- # with identical parameters; if the grant already exists, the original
225
- # `GrantId` is returned without creating a new grant. Note that the
226
- # returned grant token is unique with every `CreateGrant` request,
227
- # even when a duplicate `GrantId` is returned. All grant tokens
228
- # obtained in this way can be used interchangeably.
229
- # @return [String]
230
- class CreateGrantRequest < Struct.new(
231
- :key_id,
232
- :grantee_principal,
233
- :retiring_principal,
234
- :operations,
235
- :constraints,
236
- :grant_tokens,
237
- :name)
238
- include Aws::Structure
239
- end
70
+ # @note When making an API call, you may pass CreateAliasRequest
71
+ # data as a hash:
72
+ #
73
+ # {
74
+ # alias_name: "AliasNameType", # required
75
+ # target_key_id: "KeyIdType", # required
76
+ # }
77
+ #
78
+ # @!attribute [rw] alias_name
79
+ # String that contains the display name. The name must start with the
80
+ # word "alias" followed by a forward slash (alias/). Aliases that
81
+ # begin with "alias/AWS" are reserved.
82
+ # @return [String]
83
+ #
84
+ # @!attribute [rw] target_key_id
85
+ # An identifier of the key for which you are creating the alias. This
86
+ # value cannot be another alias but can be a globally unique
87
+ # identifier or a fully specified ARN to a key.
88
+ #
89
+ # * Key ARN Example -
90
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
91
+ #
92
+ # * Globally Unique Key ID Example -
93
+ # 12345678-1234-1234-1234-123456789012
94
+ # @return [String]
95
+ #
96
+ class CreateAliasRequest < Struct.new(
97
+ :alias_name,
98
+ :target_key_id)
99
+ include Aws::Structure
100
+ end
240
101
 
241
- # @!attribute [rw] grant_token
242
- # The grant token.
243
- #
244
- # For more information, see [Grant Tokens][1] in the *AWS Key
245
- # Management Service Developer Guide*.
246
- #
247
- #
248
- #
249
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
250
- # @return [String]
251
- #
252
- # @!attribute [rw] grant_id
253
- # The unique identifier for the grant.
254
- #
255
- # You can use the `GrantId` in a subsequent RetireGrant or RevokeGrant
256
- # operation.
257
- # @return [String]
258
- class CreateGrantResponse < Struct.new(
259
- :grant_token,
260
- :grant_id)
261
- include Aws::Structure
262
- end
102
+ # @note When making an API call, you may pass CreateGrantRequest
103
+ # data as a hash:
104
+ #
105
+ # {
106
+ # key_id: "KeyIdType", # required
107
+ # grantee_principal: "PrincipalIdType", # required
108
+ # retiring_principal: "PrincipalIdType",
109
+ # operations: ["Decrypt"], # accepts Decrypt, Encrypt, GenerateDataKey, GenerateDataKeyWithoutPlaintext, ReEncryptFrom, ReEncryptTo, CreateGrant, RetireGrant, DescribeKey
110
+ # constraints: {
111
+ # encryption_context_subset: {
112
+ # "EncryptionContextKey" => "EncryptionContextValue",
113
+ # },
114
+ # encryption_context_equals: {
115
+ # "EncryptionContextKey" => "EncryptionContextValue",
116
+ # },
117
+ # },
118
+ # grant_tokens: ["GrantTokenType"],
119
+ # name: "GrantNameType",
120
+ # }
121
+ #
122
+ # @!attribute [rw] key_id
123
+ # The unique identifier for the customer master key (CMK) that the
124
+ # grant applies to.
125
+ #
126
+ # To specify this value, use the globally unique key ID or the Amazon
127
+ # Resource Name (ARN) of the key. Examples:
128
+ #
129
+ # * Globally unique key ID: 12345678-1234-1234-1234-123456789012
130
+ #
131
+ # * Key ARN:
132
+ # arn:aws:kms:us-west-2:123456789012:key/12345678-1234-1234-1234-123456789012
133
+ # @return [String]
134
+ #
135
+ # @!attribute [rw] grantee_principal
136
+ # The principal that is given permission to perform the operations
137
+ # that the grant permits.
138
+ #
139
+ # To specify the principal, use the [Amazon Resource Name (ARN)][1] of
140
+ # an AWS principal. Valid AWS principals include AWS accounts (root),
141
+ # IAM users, federated users, and assumed role users. For examples of
142
+ # the ARN syntax to use for specifying a principal, see [AWS Identity
143
+ # and Access Management (IAM)][2] in the Example ARNs section of the
144
+ # *AWS General Reference*.
145
+ #
146
+ #
147
+ #
148
+ # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
149
+ # [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam
150
+ # @return [String]
151
+ #
152
+ # @!attribute [rw] retiring_principal
153
+ # The principal that is given permission to retire the grant by using
154
+ # RetireGrant operation.
155
+ #
156
+ # To specify the principal, use the [Amazon Resource Name (ARN)][1] of
157
+ # an AWS principal. Valid AWS principals include AWS accounts (root),
158
+ # IAM users, federated users, and assumed role users. For examples of
159
+ # the ARN syntax to use for specifying a principal, see [AWS Identity
160
+ # and Access Management (IAM)][2] in the Example ARNs section of the
161
+ # *AWS General Reference*.
162
+ #
163
+ #
164
+ #
165
+ # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
166
+ # [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam
167
+ # @return [String]
168
+ #
169
+ # @!attribute [rw] operations
170
+ # A list of operations that the grant permits.
171
+ # @return [Array<String>]
172
+ #
173
+ # @!attribute [rw] constraints
174
+ # The conditions under which the operations permitted by the grant are
175
+ # allowed.
176
+ #
177
+ # You can use this value to allow the operations permitted by the
178
+ # grant only when a specified encryption context is present. For more
179
+ # information, see [Encryption Context][1] in the *AWS Key Management
180
+ # Service Developer Guide*.
181
+ #
182
+ #
183
+ #
184
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
185
+ # @return [Types::GrantConstraints]
186
+ #
187
+ # @!attribute [rw] grant_tokens
188
+ # A list of grant tokens.
189
+ #
190
+ # For more information, see [Grant Tokens][1] in the *AWS Key
191
+ # Management Service Developer Guide*.
192
+ #
193
+ #
194
+ #
195
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
196
+ # @return [Array<String>]
197
+ #
198
+ # @!attribute [rw] name
199
+ # A friendly name for identifying the grant. Use this value to prevent
200
+ # unintended creation of duplicate grants when retrying this request.
201
+ #
202
+ # When this value is absent, all `CreateGrant` requests result in a
203
+ # new grant with a unique `GrantId` even if all the supplied
204
+ # parameters are identical. This can result in unintended duplicates
205
+ # when you retry the `CreateGrant` request.
206
+ #
207
+ # When this value is present, you can retry a `CreateGrant` request
208
+ # with identical parameters; if the grant already exists, the original
209
+ # `GrantId` is returned without creating a new grant. Note that the
210
+ # returned grant token is unique with every `CreateGrant` request,
211
+ # even when a duplicate `GrantId` is returned. All grant tokens
212
+ # obtained in this way can be used interchangeably.
213
+ # @return [String]
214
+ #
215
+ class CreateGrantRequest < Struct.new(
216
+ :key_id,
217
+ :grantee_principal,
218
+ :retiring_principal,
219
+ :operations,
220
+ :constraints,
221
+ :grant_tokens,
222
+ :name)
223
+ include Aws::Structure
224
+ end
263
225
 
264
- # @note When making an API call, pass CreateKeyRequest
265
- # data as a hash:
266
- #
267
- # {
268
- # policy: "PolicyType",
269
- # description: "DescriptionType",
270
- # key_usage: "ENCRYPT_DECRYPT", # accepts ENCRYPT_DECRYPT
271
- # origin: "AWS_KMS", # accepts AWS_KMS, EXTERNAL
272
- # bypass_policy_lockout_safety_check: false,
273
- # }
274
- # @!attribute [rw] policy
275
- # The key policy to attach to the CMK.
276
- #
277
- # If you specify a policy and do not set
278
- # `BypassPolicyLockoutSafetyCheck` to true, the policy must meet the
279
- # following criteria:
280
- #
281
- # * It must allow the principal making the `CreateKey` request to make
282
- # a subsequent PutKeyPolicy request on the CMK. This reduces the
283
- # likelihood that the CMK becomes unmanageable. For more
284
- # information, refer to the scenario in the [Default Key Policy][1]
285
- # section in the *AWS Key Management Service Developer Guide*.
286
- #
287
- # * The principal(s) specified in the key policy must exist and be
288
- # visible to AWS KMS. When you create a new AWS principal (for
289
- # example, an IAM user or role), you might need to enforce a delay
290
- # before specifying the new principal in a key policy because the
291
- # new principal might not immediately be visible to AWS KMS. For
292
- # more information, see [Changes that I make are not always
293
- # immediately visible][2] in the *IAM User Guide*.
294
- #
295
- # If you do not specify a policy, AWS KMS attaches a default key
296
- # policy to the CMK. For more information, see [Default Key Policy][3]
297
- # in the *AWS Key Management Service Developer Guide*.
298
- #
299
- # The policy size limit is 32 KiB (32768 bytes).
300
- #
301
- #
302
- #
303
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
304
- # [2]: http://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_eventual-consistency
305
- # [3]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default
306
- # @return [String]
307
- #
308
- # @!attribute [rw] description
309
- # A description of the CMK.
310
- #
311
- # Use a description that helps you decide whether the CMK is
312
- # appropriate for a task.
313
- # @return [String]
314
- #
315
- # @!attribute [rw] key_usage
316
- # The intended use of the CMK.
317
- #
318
- # You can use CMKs only for symmetric encryption and decryption.
319
- # @return [String]
320
- #
321
- # @!attribute [rw] origin
322
- # The source of the CMK's key material.
323
- #
324
- # The default is `AWS_KMS`, which means AWS KMS creates the key
325
- # material. When this parameter is set to `EXTERNAL`, the request
326
- # creates a CMK without key material so that you can import key
327
- # material from your existing key management infrastructure. For more
328
- # information about importing key material into AWS KMS, see
329
- # [Importing Key Material][1] in the *AWS Key Management Service
330
- # Developer Guide*.
331
- #
332
- # The CMK's `Origin` is immutable and is set when the CMK is created.
333
- #
334
- #
335
- #
336
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html
337
- # @return [String]
338
- #
339
- # @!attribute [rw] bypass_policy_lockout_safety_check
340
- # A flag to indicate whether to bypass the key policy lockout safety
341
- # check.
342
- #
343
- # Setting this value to true increases the likelihood that the CMK
344
- # becomes unmanageable. Do not set this value to true
345
- # indiscriminately.
346
- #
347
- # For more information, refer to the scenario in the [Default Key
348
- # Policy][1] section in the *AWS Key Management Service Developer
349
- # Guide*.
350
- #
351
- # Use this parameter only when you include a policy in the request and
352
- # you intend to prevent the principal making the request from making a
353
- # subsequent PutKeyPolicy request on the CMK.
354
- #
355
- # The default value is false.
356
- #
357
- #
358
- #
359
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
360
- # @return [Boolean]
361
- class CreateKeyRequest < Struct.new(
362
- :policy,
363
- :description,
364
- :key_usage,
365
- :origin,
366
- :bypass_policy_lockout_safety_check)
367
- include Aws::Structure
368
- end
226
+ # @!attribute [rw] grant_token
227
+ # The grant token.
228
+ #
229
+ # For more information, see [Grant Tokens][1] in the *AWS Key
230
+ # Management Service Developer Guide*.
231
+ #
232
+ #
233
+ #
234
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
235
+ # @return [String]
236
+ #
237
+ # @!attribute [rw] grant_id
238
+ # The unique identifier for the grant.
239
+ #
240
+ # You can use the `GrantId` in a subsequent RetireGrant or RevokeGrant
241
+ # operation.
242
+ # @return [String]
243
+ #
244
+ class CreateGrantResponse < Struct.new(
245
+ :grant_token,
246
+ :grant_id)
247
+ include Aws::Structure
248
+ end
369
249
 
370
- # @!attribute [rw] key_metadata
371
- # Metadata associated with the CMK.
372
- # @return [Types::KeyMetadata]
373
- class CreateKeyResponse < Struct.new(
374
- :key_metadata)
375
- include Aws::Structure
376
- end
250
+ # @note When making an API call, you may pass CreateKeyRequest
251
+ # data as a hash:
252
+ #
253
+ # {
254
+ # policy: "PolicyType",
255
+ # description: "DescriptionType",
256
+ # key_usage: "ENCRYPT_DECRYPT", # accepts ENCRYPT_DECRYPT
257
+ # origin: "AWS_KMS", # accepts AWS_KMS, EXTERNAL
258
+ # bypass_policy_lockout_safety_check: false,
259
+ # }
260
+ #
261
+ # @!attribute [rw] policy
262
+ # The key policy to attach to the CMK.
263
+ #
264
+ # If you specify a policy and do not set
265
+ # `BypassPolicyLockoutSafetyCheck` to true, the policy must meet the
266
+ # following criteria:
267
+ #
268
+ # * It must allow the principal making the `CreateKey` request to make
269
+ # a subsequent PutKeyPolicy request on the CMK. This reduces the
270
+ # likelihood that the CMK becomes unmanageable. For more
271
+ # information, refer to the scenario in the [Default Key Policy][1]
272
+ # section in the *AWS Key Management Service Developer Guide*.
273
+ #
274
+ # * The principal(s) specified in the key policy must exist and be
275
+ # visible to AWS KMS. When you create a new AWS principal (for
276
+ # example, an IAM user or role), you might need to enforce a delay
277
+ # before specifying the new principal in a key policy because the
278
+ # new principal might not immediately be visible to AWS KMS. For
279
+ # more information, see [Changes that I make are not always
280
+ # immediately visible][2] in the *IAM User Guide*.
281
+ #
282
+ # If you do not specify a policy, AWS KMS attaches a default key
283
+ # policy to the CMK. For more information, see [Default Key Policy][3]
284
+ # in the *AWS Key Management Service Developer Guide*.
285
+ #
286
+ # The policy size limit is 32 KiB (32768 bytes).
287
+ #
288
+ #
289
+ #
290
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
291
+ # [2]: http://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_eventual-consistency
292
+ # [3]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default
293
+ # @return [String]
294
+ #
295
+ # @!attribute [rw] description
296
+ # A description of the CMK.
297
+ #
298
+ # Use a description that helps you decide whether the CMK is
299
+ # appropriate for a task.
300
+ # @return [String]
301
+ #
302
+ # @!attribute [rw] key_usage
303
+ # The intended use of the CMK.
304
+ #
305
+ # You can use CMKs only for symmetric encryption and decryption.
306
+ # @return [String]
307
+ #
308
+ # @!attribute [rw] origin
309
+ # The source of the CMK's key material.
310
+ #
311
+ # The default is `AWS_KMS`, which means AWS KMS creates the key
312
+ # material. When this parameter is set to `EXTERNAL`, the request
313
+ # creates a CMK without key material so that you can import key
314
+ # material from your existing key management infrastructure. For more
315
+ # information about importing key material into AWS KMS, see
316
+ # [Importing Key Material][1] in the *AWS Key Management Service
317
+ # Developer Guide*.
318
+ #
319
+ # The CMK's `Origin` is immutable and is set when the CMK is created.
320
+ #
321
+ #
322
+ #
323
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html
324
+ # @return [String]
325
+ #
326
+ # @!attribute [rw] bypass_policy_lockout_safety_check
327
+ # A flag to indicate whether to bypass the key policy lockout safety
328
+ # check.
329
+ #
330
+ # Setting this value to true increases the likelihood that the CMK
331
+ # becomes unmanageable. Do not set this value to true
332
+ # indiscriminately.
333
+ #
334
+ # For more information, refer to the scenario in the [Default Key
335
+ # Policy][1] section in the *AWS Key Management Service Developer
336
+ # Guide*.
337
+ #
338
+ # Use this parameter only when you include a policy in the request and
339
+ # you intend to prevent the principal making the request from making a
340
+ # subsequent PutKeyPolicy request on the CMK.
341
+ #
342
+ # The default value is false.
343
+ #
344
+ #
345
+ #
346
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
347
+ # @return [Boolean]
348
+ #
349
+ class CreateKeyRequest < Struct.new(
350
+ :policy,
351
+ :description,
352
+ :key_usage,
353
+ :origin,
354
+ :bypass_policy_lockout_safety_check)
355
+ include Aws::Structure
356
+ end
377
357
 
378
- # @note When making an API call, pass DecryptRequest
379
- # data as a hash:
380
- #
381
- # {
382
- # ciphertext_blob: "data", # required
383
- # encryption_context: {
384
- # "EncryptionContextKey" => "EncryptionContextValue",
385
- # },
386
- # grant_tokens: ["GrantTokenType"],
387
- # }
388
- # @!attribute [rw] ciphertext_blob
389
- # Ciphertext to be decrypted. The blob includes metadata.
390
- # @return [String]
391
- #
392
- # @!attribute [rw] encryption_context
393
- # The encryption context. If this was specified in the Encrypt
394
- # function, it must be specified here or the decryption operation will
395
- # fail. For more information, see [Encryption Context][1].
396
- #
397
- #
398
- #
399
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
400
- # @return [Hash<String,String>]
401
- #
402
- # @!attribute [rw] grant_tokens
403
- # A list of grant tokens.
404
- #
405
- # For more information, see [Grant Tokens][1] in the *AWS Key
406
- # Management Service Developer Guide*.
407
- #
408
- #
409
- #
410
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
411
- # @return [Array<String>]
412
- class DecryptRequest < Struct.new(
413
- :ciphertext_blob,
414
- :encryption_context,
415
- :grant_tokens)
416
- include Aws::Structure
417
- end
358
+ # @!attribute [rw] key_metadata
359
+ # Metadata associated with the CMK.
360
+ # @return [Types::KeyMetadata]
361
+ #
362
+ class CreateKeyResponse < Struct.new(
363
+ :key_metadata)
364
+ include Aws::Structure
365
+ end
418
366
 
419
- # @!attribute [rw] key_id
420
- # ARN of the key used to perform the decryption. This value is
421
- # returned if no errors are encountered during the operation.
422
- # @return [String]
423
- #
424
- # @!attribute [rw] plaintext
425
- # Decrypted plaintext data. This value may not be returned if the
426
- # customer master key is not available or if you didn't have
427
- # permission to use it.
428
- # @return [String]
429
- class DecryptResponse < Struct.new(
430
- :key_id,
431
- :plaintext)
432
- include Aws::Structure
433
- end
367
+ # @note When making an API call, you may pass DecryptRequest
368
+ # data as a hash:
369
+ #
370
+ # {
371
+ # ciphertext_blob: "data", # required
372
+ # encryption_context: {
373
+ # "EncryptionContextKey" => "EncryptionContextValue",
374
+ # },
375
+ # grant_tokens: ["GrantTokenType"],
376
+ # }
377
+ #
378
+ # @!attribute [rw] ciphertext_blob
379
+ # Ciphertext to be decrypted. The blob includes metadata.
380
+ # @return [String]
381
+ #
382
+ # @!attribute [rw] encryption_context
383
+ # The encryption context. If this was specified in the Encrypt
384
+ # function, it must be specified here or the decryption operation will
385
+ # fail. For more information, see [Encryption Context][1].
386
+ #
387
+ #
388
+ #
389
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
390
+ # @return [Hash<String,String>]
391
+ #
392
+ # @!attribute [rw] grant_tokens
393
+ # A list of grant tokens.
394
+ #
395
+ # For more information, see [Grant Tokens][1] in the *AWS Key
396
+ # Management Service Developer Guide*.
397
+ #
398
+ #
399
+ #
400
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
401
+ # @return [Array<String>]
402
+ #
403
+ class DecryptRequest < Struct.new(
404
+ :ciphertext_blob,
405
+ :encryption_context,
406
+ :grant_tokens)
407
+ include Aws::Structure
408
+ end
434
409
 
435
- # @note When making an API call, pass DeleteAliasRequest
436
- # data as a hash:
437
- #
438
- # {
439
- # alias_name: "AliasNameType", # required
440
- # }
441
- # @!attribute [rw] alias_name
442
- # The alias to be deleted. The name must start with the word "alias"
443
- # followed by a forward slash (alias/). Aliases that begin with
444
- # "alias/AWS" are reserved.
445
- # @return [String]
446
- class DeleteAliasRequest < Struct.new(
447
- :alias_name)
448
- include Aws::Structure
449
- end
410
+ # @!attribute [rw] key_id
411
+ # ARN of the key used to perform the decryption. This value is
412
+ # returned if no errors are encountered during the operation.
413
+ # @return [String]
414
+ #
415
+ # @!attribute [rw] plaintext
416
+ # Decrypted plaintext data. This value may not be returned if the
417
+ # customer master key is not available or if you didn't have
418
+ # permission to use it.
419
+ # @return [String]
420
+ #
421
+ class DecryptResponse < Struct.new(
422
+ :key_id,
423
+ :plaintext)
424
+ include Aws::Structure
425
+ end
450
426
 
451
- # @note When making an API call, pass DeleteImportedKeyMaterialRequest
452
- # data as a hash:
453
- #
454
- # {
455
- # key_id: "KeyIdType", # required
456
- # }
457
- # @!attribute [rw] key_id
458
- # The identifier of the CMK whose key material to delete. The CMK's
459
- # `Origin` must be `EXTERNAL`.
460
- #
461
- # A valid identifier is the unique key ID or the Amazon Resource Name
462
- # (ARN) of the CMK. Examples:
463
- #
464
- # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
465
- #
466
- # * Key ARN:
467
- # `arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
468
- # @return [String]
469
- class DeleteImportedKeyMaterialRequest < Struct.new(
470
- :key_id)
471
- include Aws::Structure
472
- end
427
+ # @note When making an API call, you may pass DeleteAliasRequest
428
+ # data as a hash:
429
+ #
430
+ # {
431
+ # alias_name: "AliasNameType", # required
432
+ # }
433
+ #
434
+ # @!attribute [rw] alias_name
435
+ # The alias to be deleted. The name must start with the word "alias"
436
+ # followed by a forward slash (alias/). Aliases that begin with
437
+ # "alias/AWS" are reserved.
438
+ # @return [String]
439
+ #
440
+ class DeleteAliasRequest < Struct.new(
441
+ :alias_name)
442
+ include Aws::Structure
443
+ end
473
444
 
474
- # @note When making an API call, pass DescribeKeyRequest
475
- # data as a hash:
476
- #
477
- # {
478
- # key_id: "KeyIdType", # required
479
- # grant_tokens: ["GrantTokenType"],
480
- # }
481
- # @!attribute [rw] key_id
482
- # A unique identifier for the customer master key. This value can be a
483
- # globally unique identifier, a fully specified ARN to either an alias
484
- # or a key, or an alias name prefixed by "alias/".
485
- #
486
- # * Key ARN Example -
487
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
488
- #
489
- # * Alias ARN Example -
490
- # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
491
- #
492
- # * Globally Unique Key ID Example -
493
- # 12345678-1234-1234-1234-123456789012
494
- #
495
- # * Alias Name Example - alias/MyAliasName
496
- # @return [String]
497
- #
498
- # @!attribute [rw] grant_tokens
499
- # A list of grant tokens.
500
- #
501
- # For more information, see [Grant Tokens][1] in the *AWS Key
502
- # Management Service Developer Guide*.
503
- #
504
- #
505
- #
506
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
507
- # @return [Array<String>]
508
- class DescribeKeyRequest < Struct.new(
509
- :key_id,
510
- :grant_tokens)
511
- include Aws::Structure
512
- end
445
+ # @note When making an API call, you may pass DeleteImportedKeyMaterialRequest
446
+ # data as a hash:
447
+ #
448
+ # {
449
+ # key_id: "KeyIdType", # required
450
+ # }
451
+ #
452
+ # @!attribute [rw] key_id
453
+ # The identifier of the CMK whose key material to delete. The CMK's
454
+ # `Origin` must be `EXTERNAL`.
455
+ #
456
+ # A valid identifier is the unique key ID or the Amazon Resource Name
457
+ # (ARN) of the CMK. Examples:
458
+ #
459
+ # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
460
+ #
461
+ # * Key ARN:
462
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
463
+ # @return [String]
464
+ #
465
+ class DeleteImportedKeyMaterialRequest < Struct.new(
466
+ :key_id)
467
+ include Aws::Structure
468
+ end
513
469
 
514
- # @!attribute [rw] key_metadata
515
- # Metadata associated with the key.
516
- # @return [Types::KeyMetadata]
517
- class DescribeKeyResponse < Struct.new(
518
- :key_metadata)
519
- include Aws::Structure
520
- end
470
+ # @note When making an API call, you may pass DescribeKeyRequest
471
+ # data as a hash:
472
+ #
473
+ # {
474
+ # key_id: "KeyIdType", # required
475
+ # grant_tokens: ["GrantTokenType"],
476
+ # }
477
+ #
478
+ # @!attribute [rw] key_id
479
+ # A unique identifier for the customer master key. This value can be a
480
+ # globally unique identifier, a fully specified ARN to either an alias
481
+ # or a key, or an alias name prefixed by "alias/".
482
+ #
483
+ # * Key ARN Example -
484
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
485
+ #
486
+ # * Alias ARN Example -
487
+ # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
488
+ #
489
+ # * Globally Unique Key ID Example -
490
+ # 12345678-1234-1234-1234-123456789012
491
+ #
492
+ # * Alias Name Example - alias/MyAliasName
493
+ # @return [String]
494
+ #
495
+ # @!attribute [rw] grant_tokens
496
+ # A list of grant tokens.
497
+ #
498
+ # For more information, see [Grant Tokens][1] in the *AWS Key
499
+ # Management Service Developer Guide*.
500
+ #
501
+ #
502
+ #
503
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
504
+ # @return [Array<String>]
505
+ #
506
+ class DescribeKeyRequest < Struct.new(
507
+ :key_id,
508
+ :grant_tokens)
509
+ include Aws::Structure
510
+ end
521
511
 
522
- # @note When making an API call, pass DisableKeyRequest
523
- # data as a hash:
524
- #
525
- # {
526
- # key_id: "KeyIdType", # required
527
- # }
528
- # @!attribute [rw] key_id
529
- # A unique identifier for the CMK.
530
- #
531
- # Use the CMK's unique identifier or its Amazon Resource Name (ARN).
532
- # For example:
533
- #
534
- # * Unique ID: 1234abcd-12ab-34cd-56ef-1234567890ab
535
- #
536
- # * ARN:
537
- # arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
538
- # @return [String]
539
- class DisableKeyRequest < Struct.new(
540
- :key_id)
541
- include Aws::Structure
542
- end
512
+ # @!attribute [rw] key_metadata
513
+ # Metadata associated with the key.
514
+ # @return [Types::KeyMetadata]
515
+ #
516
+ class DescribeKeyResponse < Struct.new(
517
+ :key_metadata)
518
+ include Aws::Structure
519
+ end
543
520
 
544
- # @note When making an API call, pass DisableKeyRotationRequest
545
- # data as a hash:
546
- #
547
- # {
548
- # key_id: "KeyIdType", # required
549
- # }
550
- # @!attribute [rw] key_id
551
- # A unique identifier for the customer master key. This value can be a
552
- # globally unique identifier or the fully specified ARN to a key.
553
- #
554
- # * Key ARN Example -
555
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
556
- #
557
- # * Globally Unique Key ID Example -
558
- # 12345678-1234-1234-1234-123456789012
559
- # @return [String]
560
- class DisableKeyRotationRequest < Struct.new(
561
- :key_id)
562
- include Aws::Structure
563
- end
521
+ # @note When making an API call, you may pass DisableKeyRequest
522
+ # data as a hash:
523
+ #
524
+ # {
525
+ # key_id: "KeyIdType", # required
526
+ # }
527
+ #
528
+ # @!attribute [rw] key_id
529
+ # A unique identifier for the CMK.
530
+ #
531
+ # Use the CMK's unique identifier or its Amazon Resource Name (ARN).
532
+ # For example:
533
+ #
534
+ # * Unique ID: 1234abcd-12ab-34cd-56ef-1234567890ab
535
+ #
536
+ # * ARN:
537
+ # arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
538
+ # @return [String]
539
+ #
540
+ class DisableKeyRequest < Struct.new(
541
+ :key_id)
542
+ include Aws::Structure
543
+ end
564
544
 
565
- # @note When making an API call, pass EnableKeyRequest
566
- # data as a hash:
567
- #
568
- # {
569
- # key_id: "KeyIdType", # required
570
- # }
571
- # @!attribute [rw] key_id
572
- # A unique identifier for the customer master key. This value can be a
573
- # globally unique identifier or the fully specified ARN to a key.
574
- #
575
- # * Key ARN Example -
576
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
577
- #
578
- # * Globally Unique Key ID Example -
579
- # 12345678-1234-1234-1234-123456789012
580
- # @return [String]
581
- class EnableKeyRequest < Struct.new(
582
- :key_id)
583
- include Aws::Structure
584
- end
545
+ # @note When making an API call, you may pass DisableKeyRotationRequest
546
+ # data as a hash:
547
+ #
548
+ # {
549
+ # key_id: "KeyIdType", # required
550
+ # }
551
+ #
552
+ # @!attribute [rw] key_id
553
+ # A unique identifier for the customer master key. This value can be a
554
+ # globally unique identifier or the fully specified ARN to a key.
555
+ #
556
+ # * Key ARN Example -
557
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
558
+ #
559
+ # * Globally Unique Key ID Example -
560
+ # 12345678-1234-1234-1234-123456789012
561
+ # @return [String]
562
+ #
563
+ class DisableKeyRotationRequest < Struct.new(
564
+ :key_id)
565
+ include Aws::Structure
566
+ end
585
567
 
586
- # @note When making an API call, pass EnableKeyRotationRequest
587
- # data as a hash:
588
- #
589
- # {
590
- # key_id: "KeyIdType", # required
591
- # }
592
- # @!attribute [rw] key_id
593
- # A unique identifier for the customer master key. This value can be a
594
- # globally unique identifier or the fully specified ARN to a key.
595
- #
596
- # * Key ARN Example -
597
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
598
- #
599
- # * Globally Unique Key ID Example -
600
- # 12345678-1234-1234-1234-123456789012
601
- # @return [String]
602
- class EnableKeyRotationRequest < Struct.new(
603
- :key_id)
604
- include Aws::Structure
605
- end
568
+ # @note When making an API call, you may pass EnableKeyRequest
569
+ # data as a hash:
570
+ #
571
+ # {
572
+ # key_id: "KeyIdType", # required
573
+ # }
574
+ #
575
+ # @!attribute [rw] key_id
576
+ # A unique identifier for the customer master key. This value can be a
577
+ # globally unique identifier or the fully specified ARN to a key.
578
+ #
579
+ # * Key ARN Example -
580
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
581
+ #
582
+ # * Globally Unique Key ID Example -
583
+ # 12345678-1234-1234-1234-123456789012
584
+ # @return [String]
585
+ #
586
+ class EnableKeyRequest < Struct.new(
587
+ :key_id)
588
+ include Aws::Structure
589
+ end
606
590
 
607
- # @note When making an API call, pass EncryptRequest
608
- # data as a hash:
609
- #
610
- # {
611
- # key_id: "KeyIdType", # required
612
- # plaintext: "data", # required
613
- # encryption_context: {
614
- # "EncryptionContextKey" => "EncryptionContextValue",
615
- # },
616
- # grant_tokens: ["GrantTokenType"],
617
- # }
618
- # @!attribute [rw] key_id
619
- # A unique identifier for the customer master key. This value can be a
620
- # globally unique identifier, a fully specified ARN to either an alias
621
- # or a key, or an alias name prefixed by "alias/".
622
- #
623
- # * Key ARN Example -
624
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
625
- #
626
- # * Alias ARN Example -
627
- # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
628
- #
629
- # * Globally Unique Key ID Example -
630
- # 12345678-1234-1234-1234-123456789012
631
- #
632
- # * Alias Name Example - alias/MyAliasName
633
- # @return [String]
634
- #
635
- # @!attribute [rw] plaintext
636
- # Data to be encrypted.
637
- # @return [String]
638
- #
639
- # @!attribute [rw] encryption_context
640
- # Name-value pair that specifies the encryption context to be used for
641
- # authenticated encryption. If used here, the same value must be
642
- # supplied to the `Decrypt` API or decryption will fail. For more
643
- # information, see [Encryption Context][1].
644
- #
645
- #
646
- #
647
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
648
- # @return [Hash<String,String>]
649
- #
650
- # @!attribute [rw] grant_tokens
651
- # A list of grant tokens.
652
- #
653
- # For more information, see [Grant Tokens][1] in the *AWS Key
654
- # Management Service Developer Guide*.
655
- #
656
- #
657
- #
658
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
659
- # @return [Array<String>]
660
- class EncryptRequest < Struct.new(
661
- :key_id,
662
- :plaintext,
663
- :encryption_context,
664
- :grant_tokens)
665
- include Aws::Structure
666
- end
591
+ # @note When making an API call, you may pass EnableKeyRotationRequest
592
+ # data as a hash:
593
+ #
594
+ # {
595
+ # key_id: "KeyIdType", # required
596
+ # }
597
+ #
598
+ # @!attribute [rw] key_id
599
+ # A unique identifier for the customer master key. This value can be a
600
+ # globally unique identifier or the fully specified ARN to a key.
601
+ #
602
+ # * Key ARN Example -
603
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
604
+ #
605
+ # * Globally Unique Key ID Example -
606
+ # 12345678-1234-1234-1234-123456789012
607
+ # @return [String]
608
+ #
609
+ class EnableKeyRotationRequest < Struct.new(
610
+ :key_id)
611
+ include Aws::Structure
612
+ end
667
613
 
668
- # @!attribute [rw] ciphertext_blob
669
- # The encrypted plaintext. If you are using the CLI, the value is
670
- # Base64 encoded. Otherwise, it is not encoded.
671
- # @return [String]
672
- #
673
- # @!attribute [rw] key_id
674
- # The ID of the key used during encryption.
675
- # @return [String]
676
- class EncryptResponse < Struct.new(
677
- :ciphertext_blob,
678
- :key_id)
679
- include Aws::Structure
680
- end
614
+ # @note When making an API call, you may pass EncryptRequest
615
+ # data as a hash:
616
+ #
617
+ # {
618
+ # key_id: "KeyIdType", # required
619
+ # plaintext: "data", # required
620
+ # encryption_context: {
621
+ # "EncryptionContextKey" => "EncryptionContextValue",
622
+ # },
623
+ # grant_tokens: ["GrantTokenType"],
624
+ # }
625
+ #
626
+ # @!attribute [rw] key_id
627
+ # A unique identifier for the customer master key. This value can be a
628
+ # globally unique identifier, a fully specified ARN to either an alias
629
+ # or a key, or an alias name prefixed by "alias/".
630
+ #
631
+ # * Key ARN Example -
632
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
633
+ #
634
+ # * Alias ARN Example -
635
+ # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
636
+ #
637
+ # * Globally Unique Key ID Example -
638
+ # 12345678-1234-1234-1234-123456789012
639
+ #
640
+ # * Alias Name Example - alias/MyAliasName
641
+ # @return [String]
642
+ #
643
+ # @!attribute [rw] plaintext
644
+ # Data to be encrypted.
645
+ # @return [String]
646
+ #
647
+ # @!attribute [rw] encryption_context
648
+ # Name-value pair that specifies the encryption context to be used for
649
+ # authenticated encryption. If used here, the same value must be
650
+ # supplied to the `Decrypt` API or decryption will fail. For more
651
+ # information, see [Encryption Context][1].
652
+ #
653
+ #
654
+ #
655
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
656
+ # @return [Hash<String,String>]
657
+ #
658
+ # @!attribute [rw] grant_tokens
659
+ # A list of grant tokens.
660
+ #
661
+ # For more information, see [Grant Tokens][1] in the *AWS Key
662
+ # Management Service Developer Guide*.
663
+ #
664
+ #
665
+ #
666
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
667
+ # @return [Array<String>]
668
+ #
669
+ class EncryptRequest < Struct.new(
670
+ :key_id,
671
+ :plaintext,
672
+ :encryption_context,
673
+ :grant_tokens)
674
+ include Aws::Structure
675
+ end
681
676
 
682
- # @note When making an API call, pass GenerateDataKeyRequest
683
- # data as a hash:
684
- #
685
- # {
686
- # key_id: "KeyIdType", # required
687
- # encryption_context: {
688
- # "EncryptionContextKey" => "EncryptionContextValue",
689
- # },
690
- # number_of_bytes: 1,
691
- # key_spec: "AES_256", # accepts AES_256, AES_128
692
- # grant_tokens: ["GrantTokenType"],
693
- # }
694
- # @!attribute [rw] key_id
695
- # The identifier of the CMK under which to generate and encrypt the
696
- # data encryption key.
697
- #
698
- # A valid identifier is the unique key ID or the Amazon Resource Name
699
- # (ARN) of the CMK, or the alias name or ARN of an alias that points
700
- # to the CMK. Examples:
701
- #
702
- # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
703
- #
704
- # * CMK ARN:
705
- # `arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
706
- #
707
- # * Alias name: `alias/ExampleAlias`
708
- #
709
- # * Alias ARN: `arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias`
710
- # @return [String]
711
- #
712
- # @!attribute [rw] encryption_context
713
- # A set of key-value pairs that represents additional authenticated
714
- # data.
715
- #
716
- # For more information, see [Encryption Context][1] in the *AWS Key
717
- # Management Service Developer Guide*.
718
- #
719
- #
720
- #
721
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
722
- # @return [Hash<String,String>]
723
- #
724
- # @!attribute [rw] number_of_bytes
725
- # The length of the data encryption key in bytes. For example, use the
726
- # value 64 to generate a 512-bit data key (64 bytes is 512 bits). For
727
- # common key lengths (128-bit and 256-bit symmetric keys), we
728
- # recommend that you use the `KeySpec` field instead of this one.
729
- # @return [Integer]
730
- #
731
- # @!attribute [rw] key_spec
732
- # The length of the data encryption key. Use `AES_128` to generate a
733
- # 128-bit symmetric key, or `AES_256` to generate a 256-bit symmetric
734
- # key.
735
- # @return [String]
736
- #
737
- # @!attribute [rw] grant_tokens
738
- # A list of grant tokens.
739
- #
740
- # For more information, see [Grant Tokens][1] in the *AWS Key
741
- # Management Service Developer Guide*.
742
- #
743
- #
744
- #
745
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
746
- # @return [Array<String>]
747
- class GenerateDataKeyRequest < Struct.new(
748
- :key_id,
749
- :encryption_context,
750
- :number_of_bytes,
751
- :key_spec,
752
- :grant_tokens)
753
- include Aws::Structure
754
- end
677
+ # @!attribute [rw] ciphertext_blob
678
+ # The encrypted plaintext. If you are using the CLI, the value is
679
+ # Base64 encoded. Otherwise, it is not encoded.
680
+ # @return [String]
681
+ #
682
+ # @!attribute [rw] key_id
683
+ # The ID of the key used during encryption.
684
+ # @return [String]
685
+ #
686
+ class EncryptResponse < Struct.new(
687
+ :ciphertext_blob,
688
+ :key_id)
689
+ include Aws::Structure
690
+ end
755
691
 
756
- # @!attribute [rw] ciphertext_blob
757
- # The encrypted data encryption key.
758
- # @return [String]
759
- #
760
- # @!attribute [rw] plaintext
761
- # The data encryption key. Use this data key for local encryption and
762
- # decryption, then remove it from memory as soon as possible.
763
- # @return [String]
764
- #
765
- # @!attribute [rw] key_id
766
- # The identifier of the CMK under which the data encryption key was
767
- # generated and encrypted.
768
- # @return [String]
769
- class GenerateDataKeyResponse < Struct.new(
770
- :ciphertext_blob,
771
- :plaintext,
772
- :key_id)
773
- include Aws::Structure
774
- end
692
+ # @note When making an API call, you may pass GenerateDataKeyRequest
693
+ # data as a hash:
694
+ #
695
+ # {
696
+ # key_id: "KeyIdType", # required
697
+ # encryption_context: {
698
+ # "EncryptionContextKey" => "EncryptionContextValue",
699
+ # },
700
+ # number_of_bytes: 1,
701
+ # key_spec: "AES_256", # accepts AES_256, AES_128
702
+ # grant_tokens: ["GrantTokenType"],
703
+ # }
704
+ #
705
+ # @!attribute [rw] key_id
706
+ # The identifier of the CMK under which to generate and encrypt the
707
+ # data encryption key.
708
+ #
709
+ # A valid identifier is the unique key ID or the Amazon Resource Name
710
+ # (ARN) of the CMK, or the alias name or ARN of an alias that refers
711
+ # to the CMK. Examples:
712
+ #
713
+ # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
714
+ #
715
+ # * CMK ARN:
716
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
717
+ #
718
+ # * Alias name: `alias/ExampleAlias`
719
+ #
720
+ # * Alias ARN: `arn:aws:kms:us-east-2:111122223333:alias/ExampleAlias`
721
+ # @return [String]
722
+ #
723
+ # @!attribute [rw] encryption_context
724
+ # A set of key-value pairs that represents additional authenticated
725
+ # data.
726
+ #
727
+ # For more information, see [Encryption Context][1] in the *AWS Key
728
+ # Management Service Developer Guide*.
729
+ #
730
+ #
731
+ #
732
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
733
+ # @return [Hash<String,String>]
734
+ #
735
+ # @!attribute [rw] number_of_bytes
736
+ # The length of the data encryption key in bytes. For example, use the
737
+ # value 64 to generate a 512-bit data key (64 bytes is 512 bits). For
738
+ # common key lengths (128-bit and 256-bit symmetric keys), we
739
+ # recommend that you use the `KeySpec` field instead of this one.
740
+ # @return [Integer]
741
+ #
742
+ # @!attribute [rw] key_spec
743
+ # The length of the data encryption key. Use `AES_128` to generate a
744
+ # 128-bit symmetric key, or `AES_256` to generate a 256-bit symmetric
745
+ # key.
746
+ # @return [String]
747
+ #
748
+ # @!attribute [rw] grant_tokens
749
+ # A list of grant tokens.
750
+ #
751
+ # For more information, see [Grant Tokens][1] in the *AWS Key
752
+ # Management Service Developer Guide*.
753
+ #
754
+ #
755
+ #
756
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
757
+ # @return [Array<String>]
758
+ #
759
+ class GenerateDataKeyRequest < Struct.new(
760
+ :key_id,
761
+ :encryption_context,
762
+ :number_of_bytes,
763
+ :key_spec,
764
+ :grant_tokens)
765
+ include Aws::Structure
766
+ end
775
767
 
776
- # @note When making an API call, pass GenerateDataKeyWithoutPlaintextRequest
777
- # data as a hash:
778
- #
779
- # {
780
- # key_id: "KeyIdType", # required
781
- # encryption_context: {
782
- # "EncryptionContextKey" => "EncryptionContextValue",
783
- # },
784
- # key_spec: "AES_256", # accepts AES_256, AES_128
785
- # number_of_bytes: 1,
786
- # grant_tokens: ["GrantTokenType"],
787
- # }
788
- # @!attribute [rw] key_id
789
- # The identifier of the CMK under which to generate and encrypt the
790
- # data encryption key.
791
- #
792
- # A valid identifier is the unique key ID or the Amazon Resource Name
793
- # (ARN) of the CMK, or the alias name or ARN of an alias that points
794
- # to the CMK. Examples:
795
- #
796
- # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
797
- #
798
- # * CMK ARN:
799
- # `arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
800
- #
801
- # * Alias name: `alias/ExampleAlias`
802
- #
803
- # * Alias ARN: `arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias`
804
- # @return [String]
805
- #
806
- # @!attribute [rw] encryption_context
807
- # A set of key-value pairs that represents additional authenticated
808
- # data.
809
- #
810
- # For more information, see [Encryption Context][1] in the *AWS Key
811
- # Management Service Developer Guide*.
812
- #
813
- #
814
- #
815
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
816
- # @return [Hash<String,String>]
817
- #
818
- # @!attribute [rw] key_spec
819
- # The length of the data encryption key. Use `AES_128` to generate a
820
- # 128-bit symmetric key, or `AES_256` to generate a 256-bit symmetric
821
- # key.
822
- # @return [String]
823
- #
824
- # @!attribute [rw] number_of_bytes
825
- # The length of the data encryption key in bytes. For example, use the
826
- # value 64 to generate a 512-bit data key (64 bytes is 512 bits). For
827
- # common key lengths (128-bit and 256-bit symmetric keys), we
828
- # recommend that you use the `KeySpec` field instead of this one.
829
- # @return [Integer]
830
- #
831
- # @!attribute [rw] grant_tokens
832
- # A list of grant tokens.
833
- #
834
- # For more information, see [Grant Tokens][1] in the *AWS Key
835
- # Management Service Developer Guide*.
836
- #
837
- #
838
- #
839
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
840
- # @return [Array<String>]
841
- class GenerateDataKeyWithoutPlaintextRequest < Struct.new(
842
- :key_id,
843
- :encryption_context,
844
- :key_spec,
845
- :number_of_bytes,
846
- :grant_tokens)
847
- include Aws::Structure
848
- end
768
+ # @!attribute [rw] ciphertext_blob
769
+ # The encrypted data encryption key.
770
+ # @return [String]
771
+ #
772
+ # @!attribute [rw] plaintext
773
+ # The data encryption key. Use this data key for local encryption and
774
+ # decryption, then remove it from memory as soon as possible.
775
+ # @return [String]
776
+ #
777
+ # @!attribute [rw] key_id
778
+ # The identifier of the CMK under which the data encryption key was
779
+ # generated and encrypted.
780
+ # @return [String]
781
+ #
782
+ class GenerateDataKeyResponse < Struct.new(
783
+ :ciphertext_blob,
784
+ :plaintext,
785
+ :key_id)
786
+ include Aws::Structure
787
+ end
849
788
 
850
- # @!attribute [rw] ciphertext_blob
851
- # The encrypted data encryption key.
852
- # @return [String]
853
- #
854
- # @!attribute [rw] key_id
855
- # The identifier of the CMK under which the data encryption key was
856
- # generated and encrypted.
857
- # @return [String]
858
- class GenerateDataKeyWithoutPlaintextResponse < Struct.new(
859
- :ciphertext_blob,
860
- :key_id)
861
- include Aws::Structure
862
- end
789
+ # @note When making an API call, you may pass GenerateDataKeyWithoutPlaintextRequest
790
+ # data as a hash:
791
+ #
792
+ # {
793
+ # key_id: "KeyIdType", # required
794
+ # encryption_context: {
795
+ # "EncryptionContextKey" => "EncryptionContextValue",
796
+ # },
797
+ # key_spec: "AES_256", # accepts AES_256, AES_128
798
+ # number_of_bytes: 1,
799
+ # grant_tokens: ["GrantTokenType"],
800
+ # }
801
+ #
802
+ # @!attribute [rw] key_id
803
+ # The identifier of the CMK under which to generate and encrypt the
804
+ # data encryption key.
805
+ #
806
+ # A valid identifier is the unique key ID or the Amazon Resource Name
807
+ # (ARN) of the CMK, or the alias name or ARN of an alias that refers
808
+ # to the CMK. Examples:
809
+ #
810
+ # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
811
+ #
812
+ # * CMK ARN:
813
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
814
+ #
815
+ # * Alias name: `alias/ExampleAlias`
816
+ #
817
+ # * Alias ARN: `arn:aws:kms:us-east-2:111122223333:alias/ExampleAlias`
818
+ # @return [String]
819
+ #
820
+ # @!attribute [rw] encryption_context
821
+ # A set of key-value pairs that represents additional authenticated
822
+ # data.
823
+ #
824
+ # For more information, see [Encryption Context][1] in the *AWS Key
825
+ # Management Service Developer Guide*.
826
+ #
827
+ #
828
+ #
829
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
830
+ # @return [Hash<String,String>]
831
+ #
832
+ # @!attribute [rw] key_spec
833
+ # The length of the data encryption key. Use `AES_128` to generate a
834
+ # 128-bit symmetric key, or `AES_256` to generate a 256-bit symmetric
835
+ # key.
836
+ # @return [String]
837
+ #
838
+ # @!attribute [rw] number_of_bytes
839
+ # The length of the data encryption key in bytes. For example, use the
840
+ # value 64 to generate a 512-bit data key (64 bytes is 512 bits). For
841
+ # common key lengths (128-bit and 256-bit symmetric keys), we
842
+ # recommend that you use the `KeySpec` field instead of this one.
843
+ # @return [Integer]
844
+ #
845
+ # @!attribute [rw] grant_tokens
846
+ # A list of grant tokens.
847
+ #
848
+ # For more information, see [Grant Tokens][1] in the *AWS Key
849
+ # Management Service Developer Guide*.
850
+ #
851
+ #
852
+ #
853
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
854
+ # @return [Array<String>]
855
+ #
856
+ class GenerateDataKeyWithoutPlaintextRequest < Struct.new(
857
+ :key_id,
858
+ :encryption_context,
859
+ :key_spec,
860
+ :number_of_bytes,
861
+ :grant_tokens)
862
+ include Aws::Structure
863
+ end
863
864
 
864
- # @note When making an API call, pass GenerateRandomRequest
865
- # data as a hash:
866
- #
867
- # {
868
- # number_of_bytes: 1,
869
- # }
870
- # @!attribute [rw] number_of_bytes
871
- # The length of the byte string.
872
- # @return [Integer]
873
- class GenerateRandomRequest < Struct.new(
874
- :number_of_bytes)
875
- include Aws::Structure
876
- end
865
+ # @!attribute [rw] ciphertext_blob
866
+ # The encrypted data encryption key.
867
+ # @return [String]
868
+ #
869
+ # @!attribute [rw] key_id
870
+ # The identifier of the CMK under which the data encryption key was
871
+ # generated and encrypted.
872
+ # @return [String]
873
+ #
874
+ class GenerateDataKeyWithoutPlaintextResponse < Struct.new(
875
+ :ciphertext_blob,
876
+ :key_id)
877
+ include Aws::Structure
878
+ end
877
879
 
878
- # @!attribute [rw] plaintext
879
- # The unpredictable byte string.
880
- # @return [String]
881
- class GenerateRandomResponse < Struct.new(
882
- :plaintext)
883
- include Aws::Structure
884
- end
880
+ # @note When making an API call, you may pass GenerateRandomRequest
881
+ # data as a hash:
882
+ #
883
+ # {
884
+ # number_of_bytes: 1,
885
+ # }
886
+ #
887
+ # @!attribute [rw] number_of_bytes
888
+ # The length of the byte string.
889
+ # @return [Integer]
890
+ #
891
+ class GenerateRandomRequest < Struct.new(
892
+ :number_of_bytes)
893
+ include Aws::Structure
894
+ end
885
895
 
886
- # @note When making an API call, pass GetKeyPolicyRequest
887
- # data as a hash:
888
- #
889
- # {
890
- # key_id: "KeyIdType", # required
891
- # policy_name: "PolicyNameType", # required
892
- # }
893
- # @!attribute [rw] key_id
894
- # A unique identifier for the customer master key. This value can be a
895
- # globally unique identifier or the fully specified ARN to a key.
896
- #
897
- # * Key ARN Example -
898
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
899
- #
900
- # * Globally Unique Key ID Example -
901
- # 12345678-1234-1234-1234-123456789012
902
- # @return [String]
903
- #
904
- # @!attribute [rw] policy_name
905
- # String that contains the name of the policy. Currently, this must be
906
- # "default". Policy names can be discovered by calling
907
- # ListKeyPolicies.
908
- # @return [String]
909
- class GetKeyPolicyRequest < Struct.new(
910
- :key_id,
911
- :policy_name)
912
- include Aws::Structure
913
- end
896
+ # @!attribute [rw] plaintext
897
+ # The unpredictable byte string.
898
+ # @return [String]
899
+ #
900
+ class GenerateRandomResponse < Struct.new(
901
+ :plaintext)
902
+ include Aws::Structure
903
+ end
914
904
 
915
- # @!attribute [rw] policy
916
- # A policy document in JSON format.
917
- # @return [String]
918
- class GetKeyPolicyResponse < Struct.new(
919
- :policy)
920
- include Aws::Structure
921
- end
905
+ # @note When making an API call, you may pass GetKeyPolicyRequest
906
+ # data as a hash:
907
+ #
908
+ # {
909
+ # key_id: "KeyIdType", # required
910
+ # policy_name: "PolicyNameType", # required
911
+ # }
912
+ #
913
+ # @!attribute [rw] key_id
914
+ # A unique identifier for the customer master key. This value can be a
915
+ # globally unique identifier or the fully specified ARN to a key.
916
+ #
917
+ # * Key ARN Example -
918
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
919
+ #
920
+ # * Globally Unique Key ID Example -
921
+ # 12345678-1234-1234-1234-123456789012
922
+ # @return [String]
923
+ #
924
+ # @!attribute [rw] policy_name
925
+ # String that contains the name of the policy. Currently, this must be
926
+ # "default". Policy names can be discovered by calling
927
+ # ListKeyPolicies.
928
+ # @return [String]
929
+ #
930
+ class GetKeyPolicyRequest < Struct.new(
931
+ :key_id,
932
+ :policy_name)
933
+ include Aws::Structure
934
+ end
922
935
 
923
- # @note When making an API call, pass GetKeyRotationStatusRequest
924
- # data as a hash:
925
- #
926
- # {
927
- # key_id: "KeyIdType", # required
928
- # }
929
- # @!attribute [rw] key_id
930
- # A unique identifier for the customer master key. This value can be a
931
- # globally unique identifier or the fully specified ARN to a key.
932
- #
933
- # * Key ARN Example -
934
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
935
- #
936
- # * Globally Unique Key ID Example -
937
- # 12345678-1234-1234-1234-123456789012
938
- # @return [String]
939
- class GetKeyRotationStatusRequest < Struct.new(
940
- :key_id)
941
- include Aws::Structure
942
- end
936
+ # @!attribute [rw] policy
937
+ # A policy document in JSON format.
938
+ # @return [String]
939
+ #
940
+ class GetKeyPolicyResponse < Struct.new(
941
+ :policy)
942
+ include Aws::Structure
943
+ end
943
944
 
944
- # @!attribute [rw] key_rotation_enabled
945
- # A Boolean value that specifies whether key rotation is enabled.
946
- # @return [Boolean]
947
- class GetKeyRotationStatusResponse < Struct.new(
948
- :key_rotation_enabled)
949
- include Aws::Structure
950
- end
945
+ # @note When making an API call, you may pass GetKeyRotationStatusRequest
946
+ # data as a hash:
947
+ #
948
+ # {
949
+ # key_id: "KeyIdType", # required
950
+ # }
951
+ #
952
+ # @!attribute [rw] key_id
953
+ # A unique identifier for the customer master key. This value can be a
954
+ # globally unique identifier or the fully specified ARN to a key.
955
+ #
956
+ # * Key ARN Example -
957
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
958
+ #
959
+ # * Globally Unique Key ID Example -
960
+ # 12345678-1234-1234-1234-123456789012
961
+ # @return [String]
962
+ #
963
+ class GetKeyRotationStatusRequest < Struct.new(
964
+ :key_id)
965
+ include Aws::Structure
966
+ end
951
967
 
952
- # @note When making an API call, pass GetParametersForImportRequest
953
- # data as a hash:
954
- #
955
- # {
956
- # key_id: "KeyIdType", # required
957
- # wrapping_algorithm: "RSAES_PKCS1_V1_5", # required, accepts RSAES_PKCS1_V1_5, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256
958
- # wrapping_key_spec: "RSA_2048", # required, accepts RSA_2048
959
- # }
960
- # @!attribute [rw] key_id
961
- # The identifier of the CMK into which you will import key material.
962
- # The CMK's `Origin` must be `EXTERNAL`.
963
- #
964
- # A valid identifier is the unique key ID or the Amazon Resource Name
965
- # (ARN) of the CMK. Examples:
966
- #
967
- # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
968
- #
969
- # * Key ARN:
970
- # `arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
971
- # @return [String]
972
- #
973
- # @!attribute [rw] wrapping_algorithm
974
- # The algorithm you will use to encrypt the key material before
975
- # importing it with ImportKeyMaterial. For more information, see
976
- # [Encrypt the Key Material][1] in the *AWS Key Management Service
977
- # Developer Guide*.
978
- #
979
- #
980
- #
981
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys-encrypt-key-material.html
982
- # @return [String]
983
- #
984
- # @!attribute [rw] wrapping_key_spec
985
- # The type of wrapping key (public key) to return in the response.
986
- # Only 2048-bit RSA public keys are supported.
987
- # @return [String]
988
- class GetParametersForImportRequest < Struct.new(
989
- :key_id,
990
- :wrapping_algorithm,
991
- :wrapping_key_spec)
992
- include Aws::Structure
993
- end
968
+ # @!attribute [rw] key_rotation_enabled
969
+ # A Boolean value that specifies whether key rotation is enabled.
970
+ # @return [Boolean]
971
+ #
972
+ class GetKeyRotationStatusResponse < Struct.new(
973
+ :key_rotation_enabled)
974
+ include Aws::Structure
975
+ end
994
976
 
995
- # @!attribute [rw] key_id
996
- # The identifier of the CMK to use in a subsequent ImportKeyMaterial
997
- # request. This is the same CMK specified in the
998
- # `GetParametersForImport` request.
999
- # @return [String]
1000
- #
1001
- # @!attribute [rw] import_token
1002
- # The import token to send in a subsequent ImportKeyMaterial request.
1003
- # @return [String]
1004
- #
1005
- # @!attribute [rw] public_key
1006
- # The public key to use to encrypt the key material before importing
1007
- # it with ImportKeyMaterial.
1008
- # @return [String]
1009
- #
1010
- # @!attribute [rw] parameters_valid_to
1011
- # The time at which the import token and public key are no longer
1012
- # valid. After this time, you cannot use them to make an
1013
- # ImportKeyMaterial request and you must send another
1014
- # `GetParametersForImport` request to retrieve new ones.
1015
- # @return [Time]
1016
- class GetParametersForImportResponse < Struct.new(
1017
- :key_id,
1018
- :import_token,
1019
- :public_key,
1020
- :parameters_valid_to)
1021
- include Aws::Structure
1022
- end
977
+ # @note When making an API call, you may pass GetParametersForImportRequest
978
+ # data as a hash:
979
+ #
980
+ # {
981
+ # key_id: "KeyIdType", # required
982
+ # wrapping_algorithm: "RSAES_PKCS1_V1_5", # required, accepts RSAES_PKCS1_V1_5, RSAES_OAEP_SHA_1, RSAES_OAEP_SHA_256
983
+ # wrapping_key_spec: "RSA_2048", # required, accepts RSA_2048
984
+ # }
985
+ #
986
+ # @!attribute [rw] key_id
987
+ # The identifier of the CMK into which you will import key material.
988
+ # The CMK's `Origin` must be `EXTERNAL`.
989
+ #
990
+ # A valid identifier is the unique key ID or the Amazon Resource Name
991
+ # (ARN) of the CMK. Examples:
992
+ #
993
+ # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
994
+ #
995
+ # * Key ARN:
996
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
997
+ # @return [String]
998
+ #
999
+ # @!attribute [rw] wrapping_algorithm
1000
+ # The algorithm you will use to encrypt the key material before
1001
+ # importing it with ImportKeyMaterial. For more information, see
1002
+ # [Encrypt the Key Material][1] in the *AWS Key Management Service
1003
+ # Developer Guide*.
1004
+ #
1005
+ #
1006
+ #
1007
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/importing-keys-encrypt-key-material.html
1008
+ # @return [String]
1009
+ #
1010
+ # @!attribute [rw] wrapping_key_spec
1011
+ # The type of wrapping key (public key) to return in the response.
1012
+ # Only 2048-bit RSA public keys are supported.
1013
+ # @return [String]
1014
+ #
1015
+ class GetParametersForImportRequest < Struct.new(
1016
+ :key_id,
1017
+ :wrapping_algorithm,
1018
+ :wrapping_key_spec)
1019
+ include Aws::Structure
1020
+ end
1023
1021
 
1024
- # A structure for specifying the conditions under which the operations
1025
- # permitted by the grant are allowed.
1026
- #
1027
- # You can use this structure to allow the operations permitted by the
1028
- # grant only when a specified encryption context is present. For more
1029
- # information about encryption context, see [Encryption Context][1] in
1030
- # the *AWS Key Management Service Developer Guide*.
1031
- #
1032
- #
1033
- #
1034
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
1035
- # @note When making an API call, pass GrantConstraints
1036
- # data as a hash:
1037
- #
1038
- # {
1039
- # encryption_context_subset: {
1040
- # "EncryptionContextKey" => "EncryptionContextValue",
1041
- # },
1042
- # encryption_context_equals: {
1043
- # "EncryptionContextKey" => "EncryptionContextValue",
1044
- # },
1045
- # }
1046
- # @!attribute [rw] encryption_context_subset
1047
- # Contains a list of key-value pairs, a subset of which must be
1048
- # present in the encryption context of a subsequent operation
1049
- # permitted by the grant. When a subsequent operation permitted by the
1050
- # grant includes an encryption context that matches this list or is a
1051
- # subset of this list, the grant allows the operation. Otherwise, the
1052
- # operation is not allowed.
1053
- # @return [Hash<String,String>]
1054
- #
1055
- # @!attribute [rw] encryption_context_equals
1056
- # Contains a list of key-value pairs that must be present in the
1057
- # encryption context of a subsequent operation permitted by the grant.
1058
- # When a subsequent operation permitted by the grant includes an
1059
- # encryption context that matches this list, the grant allows the
1060
- # operation. Otherwise, the operation is not allowed.
1061
- # @return [Hash<String,String>]
1062
- class GrantConstraints < Struct.new(
1063
- :encryption_context_subset,
1064
- :encryption_context_equals)
1065
- include Aws::Structure
1066
- end
1022
+ # @!attribute [rw] key_id
1023
+ # The identifier of the CMK to use in a subsequent ImportKeyMaterial
1024
+ # request. This is the same CMK specified in the
1025
+ # `GetParametersForImport` request.
1026
+ # @return [String]
1027
+ #
1028
+ # @!attribute [rw] import_token
1029
+ # The import token to send in a subsequent ImportKeyMaterial request.
1030
+ # @return [String]
1031
+ #
1032
+ # @!attribute [rw] public_key
1033
+ # The public key to use to encrypt the key material before importing
1034
+ # it with ImportKeyMaterial.
1035
+ # @return [String]
1036
+ #
1037
+ # @!attribute [rw] parameters_valid_to
1038
+ # The time at which the import token and public key are no longer
1039
+ # valid. After this time, you cannot use them to make an
1040
+ # ImportKeyMaterial request and you must send another
1041
+ # `GetParametersForImport` request to retrieve new ones.
1042
+ # @return [Time]
1043
+ #
1044
+ class GetParametersForImportResponse < Struct.new(
1045
+ :key_id,
1046
+ :import_token,
1047
+ :public_key,
1048
+ :parameters_valid_to)
1049
+ include Aws::Structure
1050
+ end
1067
1051
 
1068
- # Contains information about an entry in a list of grants.
1069
- # @!attribute [rw] key_id
1070
- # The unique identifier for the customer master key (CMK) to which the
1071
- # grant applies.
1072
- # @return [String]
1073
- #
1074
- # @!attribute [rw] grant_id
1075
- # The unique identifier for the grant.
1076
- # @return [String]
1077
- #
1078
- # @!attribute [rw] name
1079
- # The friendly name that identifies the grant. If a name was provided
1080
- # in the CreateGrant request, that name is returned. Otherwise this
1081
- # value is null.
1082
- # @return [String]
1083
- #
1084
- # @!attribute [rw] creation_date
1085
- # The date and time when the grant was created.
1086
- # @return [Time]
1087
- #
1088
- # @!attribute [rw] grantee_principal
1089
- # The principal that receives the grant's permissions.
1090
- # @return [String]
1091
- #
1092
- # @!attribute [rw] retiring_principal
1093
- # The principal that can retire the grant.
1094
- # @return [String]
1095
- #
1096
- # @!attribute [rw] issuing_account
1097
- # The AWS account under which the grant was issued.
1098
- # @return [String]
1099
- #
1100
- # @!attribute [rw] operations
1101
- # The list of operations permitted by the grant.
1102
- # @return [Array<String>]
1103
- #
1104
- # @!attribute [rw] constraints
1105
- # The conditions under which the grant's operations are allowed.
1106
- # @return [Types::GrantConstraints]
1107
- class GrantListEntry < Struct.new(
1108
- :key_id,
1109
- :grant_id,
1110
- :name,
1111
- :creation_date,
1112
- :grantee_principal,
1113
- :retiring_principal,
1114
- :issuing_account,
1115
- :operations,
1116
- :constraints)
1117
- include Aws::Structure
1118
- end
1052
+ # A structure for specifying the conditions under which the operations
1053
+ # permitted by the grant are allowed.
1054
+ #
1055
+ # You can use this structure to allow the operations permitted by the
1056
+ # grant only when a specified encryption context is present. For more
1057
+ # information about encryption context, see [Encryption Context][1] in
1058
+ # the *AWS Key Management Service Developer Guide*.
1059
+ #
1060
+ #
1061
+ #
1062
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/encryption-context.html
1063
+ #
1064
+ # @note When making an API call, you may pass GrantConstraints
1065
+ # data as a hash:
1066
+ #
1067
+ # {
1068
+ # encryption_context_subset: {
1069
+ # "EncryptionContextKey" => "EncryptionContextValue",
1070
+ # },
1071
+ # encryption_context_equals: {
1072
+ # "EncryptionContextKey" => "EncryptionContextValue",
1073
+ # },
1074
+ # }
1075
+ #
1076
+ # @!attribute [rw] encryption_context_subset
1077
+ # Contains a list of key-value pairs, a subset of which must be
1078
+ # present in the encryption context of a subsequent operation
1079
+ # permitted by the grant. When a subsequent operation permitted by the
1080
+ # grant includes an encryption context that matches this list or is a
1081
+ # subset of this list, the grant allows the operation. Otherwise, the
1082
+ # operation is not allowed.
1083
+ # @return [Hash<String,String>]
1084
+ #
1085
+ # @!attribute [rw] encryption_context_equals
1086
+ # Contains a list of key-value pairs that must be present in the
1087
+ # encryption context of a subsequent operation permitted by the grant.
1088
+ # When a subsequent operation permitted by the grant includes an
1089
+ # encryption context that matches this list, the grant allows the
1090
+ # operation. Otherwise, the operation is not allowed.
1091
+ # @return [Hash<String,String>]
1092
+ #
1093
+ class GrantConstraints < Struct.new(
1094
+ :encryption_context_subset,
1095
+ :encryption_context_equals)
1096
+ include Aws::Structure
1097
+ end
1119
1098
 
1120
- # @note When making an API call, pass ImportKeyMaterialRequest
1121
- # data as a hash:
1122
- #
1123
- # {
1124
- # key_id: "KeyIdType", # required
1125
- # import_token: "data", # required
1126
- # encrypted_key_material: "data", # required
1127
- # valid_to: Time.now,
1128
- # expiration_model: "KEY_MATERIAL_EXPIRES", # accepts KEY_MATERIAL_EXPIRES, KEY_MATERIAL_DOES_NOT_EXPIRE
1129
- # }
1130
- # @!attribute [rw] key_id
1131
- # The identifier of the CMK to import the key material into. The
1132
- # CMK's `Origin` must be `EXTERNAL`.
1133
- #
1134
- # A valid identifier is the unique key ID or the Amazon Resource Name
1135
- # (ARN) of the CMK. Examples:
1136
- #
1137
- # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
1138
- #
1139
- # * Key ARN:
1140
- # `arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
1141
- # @return [String]
1142
- #
1143
- # @!attribute [rw] import_token
1144
- # The import token that you received in the response to a previous
1145
- # GetParametersForImport request. It must be from the same response
1146
- # that contained the public key that you used to encrypt the key
1147
- # material.
1148
- # @return [String]
1149
- #
1150
- # @!attribute [rw] encrypted_key_material
1151
- # The encrypted key material to import. It must be encrypted with the
1152
- # public key that you received in the response to a previous
1153
- # GetParametersForImport request, using the wrapping algorithm that
1154
- # you specified in that request.
1155
- # @return [String]
1156
- #
1157
- # @!attribute [rw] valid_to
1158
- # The time at which the imported key material expires. When the key
1159
- # material expires, AWS KMS deletes the key material and the CMK
1160
- # becomes unusable. You must omit this parameter when the
1161
- # `ExpirationModel` parameter is set to
1162
- # `KEY_MATERIAL_DOES_NOT_EXPIRE`. Otherwise it is required.
1163
- # @return [Time]
1164
- #
1165
- # @!attribute [rw] expiration_model
1166
- # Specifies whether the key material expires. The default is
1167
- # `KEY_MATERIAL_EXPIRES`, in which case you must include the `ValidTo`
1168
- # parameter. When this parameter is set to
1169
- # `KEY_MATERIAL_DOES_NOT_EXPIRE`, you must omit the `ValidTo`
1170
- # parameter.
1171
- # @return [String]
1172
- class ImportKeyMaterialRequest < Struct.new(
1173
- :key_id,
1174
- :import_token,
1175
- :encrypted_key_material,
1176
- :valid_to,
1177
- :expiration_model)
1178
- include Aws::Structure
1179
- end
1099
+ # Contains information about an entry in a list of grants.
1100
+ #
1101
+ # @!attribute [rw] key_id
1102
+ # The unique identifier for the customer master key (CMK) to which the
1103
+ # grant applies.
1104
+ # @return [String]
1105
+ #
1106
+ # @!attribute [rw] grant_id
1107
+ # The unique identifier for the grant.
1108
+ # @return [String]
1109
+ #
1110
+ # @!attribute [rw] name
1111
+ # The friendly name that identifies the grant. If a name was provided
1112
+ # in the CreateGrant request, that name is returned. Otherwise this
1113
+ # value is null.
1114
+ # @return [String]
1115
+ #
1116
+ # @!attribute [rw] creation_date
1117
+ # The date and time when the grant was created.
1118
+ # @return [Time]
1119
+ #
1120
+ # @!attribute [rw] grantee_principal
1121
+ # The principal that receives the grant's permissions.
1122
+ # @return [String]
1123
+ #
1124
+ # @!attribute [rw] retiring_principal
1125
+ # The principal that can retire the grant.
1126
+ # @return [String]
1127
+ #
1128
+ # @!attribute [rw] issuing_account
1129
+ # The AWS account under which the grant was issued.
1130
+ # @return [String]
1131
+ #
1132
+ # @!attribute [rw] operations
1133
+ # The list of operations permitted by the grant.
1134
+ # @return [Array<String>]
1135
+ #
1136
+ # @!attribute [rw] constraints
1137
+ # The conditions under which the grant's operations are allowed.
1138
+ # @return [Types::GrantConstraints]
1139
+ #
1140
+ class GrantListEntry < Struct.new(
1141
+ :key_id,
1142
+ :grant_id,
1143
+ :name,
1144
+ :creation_date,
1145
+ :grantee_principal,
1146
+ :retiring_principal,
1147
+ :issuing_account,
1148
+ :operations,
1149
+ :constraints)
1150
+ include Aws::Structure
1151
+ end
1180
1152
 
1181
- class ImportKeyMaterialResponse < Aws::EmptyStructure; end
1153
+ # @note When making an API call, you may pass ImportKeyMaterialRequest
1154
+ # data as a hash:
1155
+ #
1156
+ # {
1157
+ # key_id: "KeyIdType", # required
1158
+ # import_token: "data", # required
1159
+ # encrypted_key_material: "data", # required
1160
+ # valid_to: Time.now,
1161
+ # expiration_model: "KEY_MATERIAL_EXPIRES", # accepts KEY_MATERIAL_EXPIRES, KEY_MATERIAL_DOES_NOT_EXPIRE
1162
+ # }
1163
+ #
1164
+ # @!attribute [rw] key_id
1165
+ # The identifier of the CMK to import the key material into. The
1166
+ # CMK's `Origin` must be `EXTERNAL`.
1167
+ #
1168
+ # A valid identifier is the unique key ID or the Amazon Resource Name
1169
+ # (ARN) of the CMK. Examples:
1170
+ #
1171
+ # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
1172
+ #
1173
+ # * Key ARN:
1174
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
1175
+ # @return [String]
1176
+ #
1177
+ # @!attribute [rw] import_token
1178
+ # The import token that you received in the response to a previous
1179
+ # GetParametersForImport request. It must be from the same response
1180
+ # that contained the public key that you used to encrypt the key
1181
+ # material.
1182
+ # @return [String]
1183
+ #
1184
+ # @!attribute [rw] encrypted_key_material
1185
+ # The encrypted key material to import. It must be encrypted with the
1186
+ # public key that you received in the response to a previous
1187
+ # GetParametersForImport request, using the wrapping algorithm that
1188
+ # you specified in that request.
1189
+ # @return [String]
1190
+ #
1191
+ # @!attribute [rw] valid_to
1192
+ # The time at which the imported key material expires. When the key
1193
+ # material expires, AWS KMS deletes the key material and the CMK
1194
+ # becomes unusable. You must omit this parameter when the
1195
+ # `ExpirationModel` parameter is set to
1196
+ # `KEY_MATERIAL_DOES_NOT_EXPIRE`. Otherwise it is required.
1197
+ # @return [Time]
1198
+ #
1199
+ # @!attribute [rw] expiration_model
1200
+ # Specifies whether the key material expires. The default is
1201
+ # `KEY_MATERIAL_EXPIRES`, in which case you must include the `ValidTo`
1202
+ # parameter. When this parameter is set to
1203
+ # `KEY_MATERIAL_DOES_NOT_EXPIRE`, you must omit the `ValidTo`
1204
+ # parameter.
1205
+ # @return [String]
1206
+ #
1207
+ class ImportKeyMaterialRequest < Struct.new(
1208
+ :key_id,
1209
+ :import_token,
1210
+ :encrypted_key_material,
1211
+ :valid_to,
1212
+ :expiration_model)
1213
+ include Aws::Structure
1214
+ end
1182
1215
 
1183
- # Contains information about each entry in the key list.
1184
- # @!attribute [rw] key_id
1185
- # Unique identifier of the key.
1186
- # @return [String]
1187
- #
1188
- # @!attribute [rw] key_arn
1189
- # ARN of the key.
1190
- # @return [String]
1191
- class KeyListEntry < Struct.new(
1192
- :key_id,
1193
- :key_arn)
1194
- include Aws::Structure
1195
- end
1216
+ class ImportKeyMaterialResponse < Aws::EmptyStructure; end
1196
1217
 
1197
- # Contains metadata about a customer master key (CMK).
1198
- #
1199
- # This data type is used as a response element for the CreateKey and
1200
- # DescribeKey operations.
1201
- # @!attribute [rw] aws_account_id
1202
- # The twelve-digit account ID of the AWS account that owns the CMK.
1203
- # @return [String]
1204
- #
1205
- # @!attribute [rw] key_id
1206
- # The globally unique identifier for the CMK.
1207
- # @return [String]
1208
- #
1209
- # @!attribute [rw] arn
1210
- # The Amazon Resource Name (ARN) of the CMK. For examples, see [AWS
1211
- # Key Management Service (AWS KMS)][1] in the Example ARNs section of
1212
- # the *AWS General Reference*.
1213
- #
1214
- #
1215
- #
1216
- # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-kms
1217
- # @return [String]
1218
- #
1219
- # @!attribute [rw] creation_date
1220
- # The date and time when the CMK was created.
1221
- # @return [Time]
1222
- #
1223
- # @!attribute [rw] enabled
1224
- # Specifies whether the CMK is enabled. When `KeyState` is `Enabled`
1225
- # this value is true, otherwise it is false.
1226
- # @return [Boolean]
1227
- #
1228
- # @!attribute [rw] description
1229
- # The description of the CMK.
1230
- # @return [String]
1231
- #
1232
- # @!attribute [rw] key_usage
1233
- # The cryptographic operations for which you can use the CMK.
1234
- # Currently the only allowed value is `ENCRYPT_DECRYPT`, which means
1235
- # you can use the CMK for the Encrypt and Decrypt operations.
1236
- # @return [String]
1237
- #
1238
- # @!attribute [rw] key_state
1239
- # The state of the CMK.
1240
- #
1241
- # For more information about how key state affects the use of a CMK,
1242
- # see [How Key State Affects the Use of a Customer Master Key][1] in
1243
- # the *AWS Key Management Service Developer Guide*.
1244
- #
1245
- #
1246
- #
1247
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
1248
- # @return [String]
1249
- #
1250
- # @!attribute [rw] deletion_date
1251
- # The date and time after which AWS KMS deletes the CMK. This value is
1252
- # present only when `KeyState` is `PendingDeletion`, otherwise this
1253
- # value is omitted.
1254
- # @return [Time]
1255
- #
1256
- # @!attribute [rw] valid_to
1257
- # The time at which the imported key material expires. When the key
1258
- # material expires, AWS KMS deletes the key material and the CMK
1259
- # becomes unusable. This value is present only for CMKs whose `Origin`
1260
- # is `EXTERNAL` and whose `ExpirationModel` is `KEY_MATERIAL_EXPIRES`,
1261
- # otherwise this value is omitted.
1262
- # @return [Time]
1263
- #
1264
- # @!attribute [rw] origin
1265
- # The source of the CMK's key material. When this value is `AWS_KMS`,
1266
- # AWS KMS created the key material. When this value is `EXTERNAL`, the
1267
- # key material was imported from your existing key management
1268
- # infrastructure or the CMK lacks key material.
1269
- # @return [String]
1270
- #
1271
- # @!attribute [rw] expiration_model
1272
- # Specifies whether the CMK's key material expires. This value is
1273
- # present only when `Origin` is `EXTERNAL`, otherwise this value is
1274
- # omitted.
1275
- # @return [String]
1276
- class KeyMetadata < Struct.new(
1277
- :aws_account_id,
1278
- :key_id,
1279
- :arn,
1280
- :creation_date,
1281
- :enabled,
1282
- :description,
1283
- :key_usage,
1284
- :key_state,
1285
- :deletion_date,
1286
- :valid_to,
1287
- :origin,
1288
- :expiration_model)
1289
- include Aws::Structure
1290
- end
1218
+ # Contains information about each entry in the key list.
1219
+ #
1220
+ # @!attribute [rw] key_id
1221
+ # Unique identifier of the key.
1222
+ # @return [String]
1223
+ #
1224
+ # @!attribute [rw] key_arn
1225
+ # ARN of the key.
1226
+ # @return [String]
1227
+ #
1228
+ class KeyListEntry < Struct.new(
1229
+ :key_id,
1230
+ :key_arn)
1231
+ include Aws::Structure
1232
+ end
1291
1233
 
1292
- # @note When making an API call, pass ListAliasesRequest
1293
- # data as a hash:
1294
- #
1295
- # {
1296
- # limit: 1,
1297
- # marker: "MarkerType",
1298
- # }
1299
- # @!attribute [rw] limit
1300
- # When paginating results, specify the maximum number of items to
1301
- # return in the response. If additional items exist beyond the number
1302
- # you specify, the `Truncated` element in the response is set to true.
1303
- #
1304
- # This value is optional. If you include a value, it must be between 1
1305
- # and 100, inclusive. If you do not include a value, it defaults to
1306
- # 50.
1307
- # @return [Integer]
1308
- #
1309
- # @!attribute [rw] marker
1310
- # Use this parameter only when paginating results and only in a
1311
- # subsequent request after you receive a response with truncated
1312
- # results. Set it to the value of `NextMarker` from the response you
1313
- # just received.
1314
- # @return [String]
1315
- class ListAliasesRequest < Struct.new(
1316
- :limit,
1317
- :marker)
1318
- include Aws::Structure
1319
- end
1234
+ # Contains metadata about a customer master key (CMK).
1235
+ #
1236
+ # This data type is used as a response element for the CreateKey and
1237
+ # DescribeKey operations.
1238
+ #
1239
+ # @!attribute [rw] aws_account_id
1240
+ # The twelve-digit account ID of the AWS account that owns the CMK.
1241
+ # @return [String]
1242
+ #
1243
+ # @!attribute [rw] key_id
1244
+ # The globally unique identifier for the CMK.
1245
+ # @return [String]
1246
+ #
1247
+ # @!attribute [rw] arn
1248
+ # The Amazon Resource Name (ARN) of the CMK. For examples, see [AWS
1249
+ # Key Management Service (AWS KMS)][1] in the Example ARNs section of
1250
+ # the *AWS General Reference*.
1251
+ #
1252
+ #
1253
+ #
1254
+ # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-kms
1255
+ # @return [String]
1256
+ #
1257
+ # @!attribute [rw] creation_date
1258
+ # The date and time when the CMK was created.
1259
+ # @return [Time]
1260
+ #
1261
+ # @!attribute [rw] enabled
1262
+ # Specifies whether the CMK is enabled. When `KeyState` is `Enabled`
1263
+ # this value is true, otherwise it is false.
1264
+ # @return [Boolean]
1265
+ #
1266
+ # @!attribute [rw] description
1267
+ # The description of the CMK.
1268
+ # @return [String]
1269
+ #
1270
+ # @!attribute [rw] key_usage
1271
+ # The cryptographic operations for which you can use the CMK.
1272
+ # Currently the only allowed value is `ENCRYPT_DECRYPT`, which means
1273
+ # you can use the CMK for the Encrypt and Decrypt operations.
1274
+ # @return [String]
1275
+ #
1276
+ # @!attribute [rw] key_state
1277
+ # The state of the CMK.
1278
+ #
1279
+ # For more information about how key state affects the use of a CMK,
1280
+ # see [How Key State Affects the Use of a Customer Master Key][1] in
1281
+ # the *AWS Key Management Service Developer Guide*.
1282
+ #
1283
+ #
1284
+ #
1285
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
1286
+ # @return [String]
1287
+ #
1288
+ # @!attribute [rw] deletion_date
1289
+ # The date and time after which AWS KMS deletes the CMK. This value is
1290
+ # present only when `KeyState` is `PendingDeletion`, otherwise this
1291
+ # value is omitted.
1292
+ # @return [Time]
1293
+ #
1294
+ # @!attribute [rw] valid_to
1295
+ # The time at which the imported key material expires. When the key
1296
+ # material expires, AWS KMS deletes the key material and the CMK
1297
+ # becomes unusable. This value is present only for CMKs whose `Origin`
1298
+ # is `EXTERNAL` and whose `ExpirationModel` is `KEY_MATERIAL_EXPIRES`,
1299
+ # otherwise this value is omitted.
1300
+ # @return [Time]
1301
+ #
1302
+ # @!attribute [rw] origin
1303
+ # The source of the CMK's key material. When this value is `AWS_KMS`,
1304
+ # AWS KMS created the key material. When this value is `EXTERNAL`, the
1305
+ # key material was imported from your existing key management
1306
+ # infrastructure or the CMK lacks key material.
1307
+ # @return [String]
1308
+ #
1309
+ # @!attribute [rw] expiration_model
1310
+ # Specifies whether the CMK's key material expires. This value is
1311
+ # present only when `Origin` is `EXTERNAL`, otherwise this value is
1312
+ # omitted.
1313
+ # @return [String]
1314
+ #
1315
+ class KeyMetadata < Struct.new(
1316
+ :aws_account_id,
1317
+ :key_id,
1318
+ :arn,
1319
+ :creation_date,
1320
+ :enabled,
1321
+ :description,
1322
+ :key_usage,
1323
+ :key_state,
1324
+ :deletion_date,
1325
+ :valid_to,
1326
+ :origin,
1327
+ :expiration_model)
1328
+ include Aws::Structure
1329
+ end
1320
1330
 
1321
- # @!attribute [rw] aliases
1322
- # A list of key aliases in the user's account.
1323
- # @return [Array<Types::AliasListEntry>]
1324
- #
1325
- # @!attribute [rw] next_marker
1326
- # When `Truncated` is true, this value is present and contains the
1327
- # value to use for the `Marker` parameter in a subsequent pagination
1328
- # request.
1329
- # @return [String]
1330
- #
1331
- # @!attribute [rw] truncated
1332
- # A flag that indicates whether there are more items in the list. If
1333
- # your results were truncated, you can use the `Marker` parameter to
1334
- # make a subsequent pagination request to retrieve more items in the
1335
- # list.
1336
- # @return [Boolean]
1337
- class ListAliasesResponse < Struct.new(
1338
- :aliases,
1339
- :next_marker,
1340
- :truncated)
1341
- include Aws::Structure
1342
- end
1331
+ # @note When making an API call, you may pass ListAliasesRequest
1332
+ # data as a hash:
1333
+ #
1334
+ # {
1335
+ # limit: 1,
1336
+ # marker: "MarkerType",
1337
+ # }
1338
+ #
1339
+ # @!attribute [rw] limit
1340
+ # When paginating results, specify the maximum number of items to
1341
+ # return in the response. If additional items exist beyond the number
1342
+ # you specify, the `Truncated` element in the response is set to true.
1343
+ #
1344
+ # This value is optional. If you include a value, it must be between 1
1345
+ # and 100, inclusive. If you do not include a value, it defaults to
1346
+ # 50.
1347
+ # @return [Integer]
1348
+ #
1349
+ # @!attribute [rw] marker
1350
+ # Use this parameter only when paginating results and only in a
1351
+ # subsequent request after you receive a response with truncated
1352
+ # results. Set it to the value of `NextMarker` from the response you
1353
+ # just received.
1354
+ # @return [String]
1355
+ #
1356
+ class ListAliasesRequest < Struct.new(
1357
+ :limit,
1358
+ :marker)
1359
+ include Aws::Structure
1360
+ end
1343
1361
 
1344
- # @note When making an API call, pass ListGrantsRequest
1345
- # data as a hash:
1346
- #
1347
- # {
1348
- # limit: 1,
1349
- # marker: "MarkerType",
1350
- # key_id: "KeyIdType", # required
1351
- # }
1352
- # @!attribute [rw] limit
1353
- # When paginating results, specify the maximum number of items to
1354
- # return in the response. If additional items exist beyond the number
1355
- # you specify, the `Truncated` element in the response is set to true.
1356
- #
1357
- # This value is optional. If you include a value, it must be between 1
1358
- # and 100, inclusive. If you do not include a value, it defaults to
1359
- # 50.
1360
- # @return [Integer]
1361
- #
1362
- # @!attribute [rw] marker
1363
- # Use this parameter only when paginating results and only in a
1364
- # subsequent request after you receive a response with truncated
1365
- # results. Set it to the value of `NextMarker` from the response you
1366
- # just received.
1367
- # @return [String]
1368
- #
1369
- # @!attribute [rw] key_id
1370
- # A unique identifier for the customer master key. This value can be a
1371
- # globally unique identifier or the fully specified ARN to a key.
1372
- #
1373
- # * Key ARN Example -
1374
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1375
- #
1376
- # * Globally Unique Key ID Example -
1377
- # 12345678-1234-1234-1234-123456789012
1378
- # @return [String]
1379
- class ListGrantsRequest < Struct.new(
1380
- :limit,
1381
- :marker,
1382
- :key_id)
1383
- include Aws::Structure
1384
- end
1362
+ # @!attribute [rw] aliases
1363
+ # A list of key aliases in the user's account.
1364
+ # @return [Array<Types::AliasListEntry>]
1365
+ #
1366
+ # @!attribute [rw] next_marker
1367
+ # When `Truncated` is true, this value is present and contains the
1368
+ # value to use for the `Marker` parameter in a subsequent pagination
1369
+ # request.
1370
+ # @return [String]
1371
+ #
1372
+ # @!attribute [rw] truncated
1373
+ # A flag that indicates whether there are more items in the list. If
1374
+ # your results were truncated, you can use the `Marker` parameter to
1375
+ # make a subsequent pagination request to retrieve more items in the
1376
+ # list.
1377
+ # @return [Boolean]
1378
+ #
1379
+ class ListAliasesResponse < Struct.new(
1380
+ :aliases,
1381
+ :next_marker,
1382
+ :truncated)
1383
+ include Aws::Structure
1384
+ end
1385
1385
 
1386
- # @!attribute [rw] grants
1387
- # A list of grants.
1388
- # @return [Array<Types::GrantListEntry>]
1389
- #
1390
- # @!attribute [rw] next_marker
1391
- # When `Truncated` is true, this value is present and contains the
1392
- # value to use for the `Marker` parameter in a subsequent pagination
1393
- # request.
1394
- # @return [String]
1395
- #
1396
- # @!attribute [rw] truncated
1397
- # A flag that indicates whether there are more items in the list. If
1398
- # your results were truncated, you can use the `Marker` parameter to
1399
- # make a subsequent pagination request to retrieve more items in the
1400
- # list.
1401
- # @return [Boolean]
1402
- class ListGrantsResponse < Struct.new(
1403
- :grants,
1404
- :next_marker,
1405
- :truncated)
1406
- include Aws::Structure
1407
- end
1386
+ # @note When making an API call, you may pass ListGrantsRequest
1387
+ # data as a hash:
1388
+ #
1389
+ # {
1390
+ # limit: 1,
1391
+ # marker: "MarkerType",
1392
+ # key_id: "KeyIdType", # required
1393
+ # }
1394
+ #
1395
+ # @!attribute [rw] limit
1396
+ # When paginating results, specify the maximum number of items to
1397
+ # return in the response. If additional items exist beyond the number
1398
+ # you specify, the `Truncated` element in the response is set to true.
1399
+ #
1400
+ # This value is optional. If you include a value, it must be between 1
1401
+ # and 100, inclusive. If you do not include a value, it defaults to
1402
+ # 50.
1403
+ # @return [Integer]
1404
+ #
1405
+ # @!attribute [rw] marker
1406
+ # Use this parameter only when paginating results and only in a
1407
+ # subsequent request after you receive a response with truncated
1408
+ # results. Set it to the value of `NextMarker` from the response you
1409
+ # just received.
1410
+ # @return [String]
1411
+ #
1412
+ # @!attribute [rw] key_id
1413
+ # A unique identifier for the customer master key. This value can be a
1414
+ # globally unique identifier or the fully specified ARN to a key.
1415
+ #
1416
+ # * Key ARN Example -
1417
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1418
+ #
1419
+ # * Globally Unique Key ID Example -
1420
+ # 12345678-1234-1234-1234-123456789012
1421
+ # @return [String]
1422
+ #
1423
+ class ListGrantsRequest < Struct.new(
1424
+ :limit,
1425
+ :marker,
1426
+ :key_id)
1427
+ include Aws::Structure
1428
+ end
1408
1429
 
1409
- # @note When making an API call, pass ListKeyPoliciesRequest
1410
- # data as a hash:
1411
- #
1412
- # {
1413
- # key_id: "KeyIdType", # required
1414
- # limit: 1,
1415
- # marker: "MarkerType",
1416
- # }
1417
- # @!attribute [rw] key_id
1418
- # A unique identifier for the customer master key. This value can be a
1419
- # globally unique identifier, a fully specified ARN to either an alias
1420
- # or a key, or an alias name prefixed by "alias/".
1421
- #
1422
- # * Key ARN Example -
1423
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1424
- #
1425
- # * Alias ARN Example -
1426
- # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
1427
- #
1428
- # * Globally Unique Key ID Example -
1429
- # 12345678-1234-1234-1234-123456789012
1430
- #
1431
- # * Alias Name Example - alias/MyAliasName
1432
- # @return [String]
1433
- #
1434
- # @!attribute [rw] limit
1435
- # When paginating results, specify the maximum number of items to
1436
- # return in the response. If additional items exist beyond the number
1437
- # you specify, the `Truncated` element in the response is set to true.
1438
- #
1439
- # This value is optional. If you include a value, it must be between 1
1440
- # and 1000, inclusive. If you do not include a value, it defaults to
1441
- # 100.
1442
- #
1443
- # Currently only 1 policy can be attached to a key.
1444
- # @return [Integer]
1445
- #
1446
- # @!attribute [rw] marker
1447
- # Use this parameter only when paginating results and only in a
1448
- # subsequent request after you receive a response with truncated
1449
- # results. Set it to the value of `NextMarker` from the response you
1450
- # just received.
1451
- # @return [String]
1452
- class ListKeyPoliciesRequest < Struct.new(
1453
- :key_id,
1454
- :limit,
1455
- :marker)
1456
- include Aws::Structure
1457
- end
1430
+ # @!attribute [rw] grants
1431
+ # A list of grants.
1432
+ # @return [Array<Types::GrantListEntry>]
1433
+ #
1434
+ # @!attribute [rw] next_marker
1435
+ # When `Truncated` is true, this value is present and contains the
1436
+ # value to use for the `Marker` parameter in a subsequent pagination
1437
+ # request.
1438
+ # @return [String]
1439
+ #
1440
+ # @!attribute [rw] truncated
1441
+ # A flag that indicates whether there are more items in the list. If
1442
+ # your results were truncated, you can use the `Marker` parameter to
1443
+ # make a subsequent pagination request to retrieve more items in the
1444
+ # list.
1445
+ # @return [Boolean]
1446
+ #
1447
+ class ListGrantsResponse < Struct.new(
1448
+ :grants,
1449
+ :next_marker,
1450
+ :truncated)
1451
+ include Aws::Structure
1452
+ end
1458
1453
 
1459
- # @!attribute [rw] policy_names
1460
- # A list of policy names. Currently, there is only one policy and it
1461
- # is named "Default".
1462
- # @return [Array<String>]
1463
- #
1464
- # @!attribute [rw] next_marker
1465
- # When `Truncated` is true, this value is present and contains the
1466
- # value to use for the `Marker` parameter in a subsequent pagination
1467
- # request.
1468
- # @return [String]
1469
- #
1470
- # @!attribute [rw] truncated
1471
- # A flag that indicates whether there are more items in the list. If
1472
- # your results were truncated, you can use the `Marker` parameter to
1473
- # make a subsequent pagination request to retrieve more items in the
1474
- # list.
1475
- # @return [Boolean]
1476
- class ListKeyPoliciesResponse < Struct.new(
1477
- :policy_names,
1478
- :next_marker,
1479
- :truncated)
1480
- include Aws::Structure
1481
- end
1454
+ # @note When making an API call, you may pass ListKeyPoliciesRequest
1455
+ # data as a hash:
1456
+ #
1457
+ # {
1458
+ # key_id: "KeyIdType", # required
1459
+ # limit: 1,
1460
+ # marker: "MarkerType",
1461
+ # }
1462
+ #
1463
+ # @!attribute [rw] key_id
1464
+ # A unique identifier for the customer master key (CMK). You can use
1465
+ # the unique key ID or the Amazon Resource Name (ARN) of the CMK.
1466
+ # Examples:
1467
+ #
1468
+ # * Unique key ID: `1234abcd-12ab-34cd-56ef-1234567890ab`
1469
+ #
1470
+ # * Key ARN:
1471
+ # `arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab`
1472
+ # @return [String]
1473
+ #
1474
+ # @!attribute [rw] limit
1475
+ # When paginating results, specify the maximum number of items to
1476
+ # return in the response. If additional items exist beyond the number
1477
+ # you specify, the `Truncated` element in the response is set to true.
1478
+ #
1479
+ # This value is optional. If you include a value, it must be between 1
1480
+ # and 1000, inclusive. If you do not include a value, it defaults to
1481
+ # 100.
1482
+ #
1483
+ # Currently only 1 policy can be attached to a key.
1484
+ # @return [Integer]
1485
+ #
1486
+ # @!attribute [rw] marker
1487
+ # Use this parameter only when paginating results and only in a
1488
+ # subsequent request after you receive a response with truncated
1489
+ # results. Set it to the value of `NextMarker` from the response you
1490
+ # just received.
1491
+ # @return [String]
1492
+ #
1493
+ class ListKeyPoliciesRequest < Struct.new(
1494
+ :key_id,
1495
+ :limit,
1496
+ :marker)
1497
+ include Aws::Structure
1498
+ end
1482
1499
 
1483
- # @note When making an API call, pass ListKeysRequest
1484
- # data as a hash:
1485
- #
1486
- # {
1487
- # limit: 1,
1488
- # marker: "MarkerType",
1489
- # }
1490
- # @!attribute [rw] limit
1491
- # When paginating results, specify the maximum number of items to
1492
- # return in the response. If additional items exist beyond the number
1493
- # you specify, the `Truncated` element in the response is set to true.
1494
- #
1495
- # This value is optional. If you include a value, it must be between 1
1496
- # and 1000, inclusive. If you do not include a value, it defaults to
1497
- # 100.
1498
- # @return [Integer]
1499
- #
1500
- # @!attribute [rw] marker
1501
- # Use this parameter only when paginating results and only in a
1502
- # subsequent request after you receive a response with truncated
1503
- # results. Set it to the value of `NextMarker` from the response you
1504
- # just received.
1505
- # @return [String]
1506
- class ListKeysRequest < Struct.new(
1507
- :limit,
1508
- :marker)
1509
- include Aws::Structure
1510
- end
1500
+ # @!attribute [rw] policy_names
1501
+ # A list of policy names. Currently, there is only one policy and it
1502
+ # is named "Default".
1503
+ # @return [Array<String>]
1504
+ #
1505
+ # @!attribute [rw] next_marker
1506
+ # When `Truncated` is true, this value is present and contains the
1507
+ # value to use for the `Marker` parameter in a subsequent pagination
1508
+ # request.
1509
+ # @return [String]
1510
+ #
1511
+ # @!attribute [rw] truncated
1512
+ # A flag that indicates whether there are more items in the list. If
1513
+ # your results were truncated, you can use the `Marker` parameter to
1514
+ # make a subsequent pagination request to retrieve more items in the
1515
+ # list.
1516
+ # @return [Boolean]
1517
+ #
1518
+ class ListKeyPoliciesResponse < Struct.new(
1519
+ :policy_names,
1520
+ :next_marker,
1521
+ :truncated)
1522
+ include Aws::Structure
1523
+ end
1511
1524
 
1512
- # @!attribute [rw] keys
1513
- # A list of keys.
1514
- # @return [Array<Types::KeyListEntry>]
1515
- #
1516
- # @!attribute [rw] next_marker
1517
- # When `Truncated` is true, this value is present and contains the
1518
- # value to use for the `Marker` parameter in a subsequent pagination
1519
- # request.
1520
- # @return [String]
1521
- #
1522
- # @!attribute [rw] truncated
1523
- # A flag that indicates whether there are more items in the list. If
1524
- # your results were truncated, you can use the `Marker` parameter to
1525
- # make a subsequent pagination request to retrieve more items in the
1526
- # list.
1527
- # @return [Boolean]
1528
- class ListKeysResponse < Struct.new(
1529
- :keys,
1530
- :next_marker,
1531
- :truncated)
1532
- include Aws::Structure
1533
- end
1525
+ # @note When making an API call, you may pass ListKeysRequest
1526
+ # data as a hash:
1527
+ #
1528
+ # {
1529
+ # limit: 1,
1530
+ # marker: "MarkerType",
1531
+ # }
1532
+ #
1533
+ # @!attribute [rw] limit
1534
+ # When paginating results, specify the maximum number of items to
1535
+ # return in the response. If additional items exist beyond the number
1536
+ # you specify, the `Truncated` element in the response is set to true.
1537
+ #
1538
+ # This value is optional. If you include a value, it must be between 1
1539
+ # and 1000, inclusive. If you do not include a value, it defaults to
1540
+ # 100.
1541
+ # @return [Integer]
1542
+ #
1543
+ # @!attribute [rw] marker
1544
+ # Use this parameter only when paginating results and only in a
1545
+ # subsequent request after you receive a response with truncated
1546
+ # results. Set it to the value of `NextMarker` from the response you
1547
+ # just received.
1548
+ # @return [String]
1549
+ #
1550
+ class ListKeysRequest < Struct.new(
1551
+ :limit,
1552
+ :marker)
1553
+ include Aws::Structure
1554
+ end
1534
1555
 
1535
- # @note When making an API call, pass ListRetirableGrantsRequest
1536
- # data as a hash:
1537
- #
1538
- # {
1539
- # limit: 1,
1540
- # marker: "MarkerType",
1541
- # retiring_principal: "PrincipalIdType", # required
1542
- # }
1543
- # @!attribute [rw] limit
1544
- # When paginating results, specify the maximum number of items to
1545
- # return in the response. If additional items exist beyond the number
1546
- # you specify, the `Truncated` element in the response is set to true.
1547
- #
1548
- # This value is optional. If you include a value, it must be between 1
1549
- # and 100, inclusive. If you do not include a value, it defaults to
1550
- # 50.
1551
- # @return [Integer]
1552
- #
1553
- # @!attribute [rw] marker
1554
- # Use this parameter only when paginating results and only in a
1555
- # subsequent request after you receive a response with truncated
1556
- # results. Set it to the value of `NextMarker` from the response you
1557
- # just received.
1558
- # @return [String]
1559
- #
1560
- # @!attribute [rw] retiring_principal
1561
- # The retiring principal for which to list grants.
1562
- #
1563
- # To specify the retiring principal, use the [Amazon Resource Name
1564
- # (ARN)][1] of an AWS principal. Valid AWS principals include AWS
1565
- # accounts (root), IAM users, federated users, and assumed role users.
1566
- # For examples of the ARN syntax for specifying a principal, see [AWS
1567
- # Identity and Access Management (IAM)][2] in the Example ARNs section
1568
- # of the *Amazon Web Services General Reference*.
1569
- #
1570
- #
1571
- #
1572
- # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
1573
- # [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam
1574
- # @return [String]
1575
- class ListRetirableGrantsRequest < Struct.new(
1576
- :limit,
1577
- :marker,
1578
- :retiring_principal)
1579
- include Aws::Structure
1580
- end
1556
+ # @!attribute [rw] keys
1557
+ # A list of keys.
1558
+ # @return [Array<Types::KeyListEntry>]
1559
+ #
1560
+ # @!attribute [rw] next_marker
1561
+ # When `Truncated` is true, this value is present and contains the
1562
+ # value to use for the `Marker` parameter in a subsequent pagination
1563
+ # request.
1564
+ # @return [String]
1565
+ #
1566
+ # @!attribute [rw] truncated
1567
+ # A flag that indicates whether there are more items in the list. If
1568
+ # your results were truncated, you can use the `Marker` parameter to
1569
+ # make a subsequent pagination request to retrieve more items in the
1570
+ # list.
1571
+ # @return [Boolean]
1572
+ #
1573
+ class ListKeysResponse < Struct.new(
1574
+ :keys,
1575
+ :next_marker,
1576
+ :truncated)
1577
+ include Aws::Structure
1578
+ end
1581
1579
 
1582
- # @note When making an API call, pass PutKeyPolicyRequest
1583
- # data as a hash:
1584
- #
1585
- # {
1586
- # key_id: "KeyIdType", # required
1587
- # policy_name: "PolicyNameType", # required
1588
- # policy: "PolicyType", # required
1589
- # bypass_policy_lockout_safety_check: false,
1590
- # }
1591
- # @!attribute [rw] key_id
1592
- # A unique identifier for the CMK.
1593
- #
1594
- # Use the CMK's unique identifier or its Amazon Resource Name (ARN).
1595
- # For example:
1596
- #
1597
- # * Unique ID: 1234abcd-12ab-34cd-56ef-1234567890ab
1598
- #
1599
- # * ARN:
1600
- # arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
1601
- # @return [String]
1602
- #
1603
- # @!attribute [rw] policy_name
1604
- # The name of the key policy.
1605
- #
1606
- # This value must be `default`.
1607
- # @return [String]
1608
- #
1609
- # @!attribute [rw] policy
1610
- # The key policy to attach to the CMK.
1611
- #
1612
- # If you do not set `BypassPolicyLockoutSafetyCheck` to true, the
1613
- # policy must meet the following criteria:
1614
- #
1615
- # * It must allow the principal making the `PutKeyPolicy` request to
1616
- # make a subsequent `PutKeyPolicy` request on the CMK. This reduces
1617
- # the likelihood that the CMK becomes unmanageable. For more
1618
- # information, refer to the scenario in the [Default Key Policy][1]
1619
- # section in the *AWS Key Management Service Developer Guide*.
1620
- #
1621
- # * The principal(s) specified in the key policy must exist and be
1622
- # visible to AWS KMS. When you create a new AWS principal (for
1623
- # example, an IAM user or role), you might need to enforce a delay
1624
- # before specifying the new principal in a key policy because the
1625
- # new principal might not immediately be visible to AWS KMS. For
1626
- # more information, see [Changes that I make are not always
1627
- # immediately visible][2] in the *IAM User Guide*.
1628
- #
1629
- # The policy size limit is 32 KiB (32768 bytes).
1630
- #
1631
- #
1632
- #
1633
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
1634
- # [2]: http://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_eventual-consistency
1635
- # @return [String]
1636
- #
1637
- # @!attribute [rw] bypass_policy_lockout_safety_check
1638
- # A flag to indicate whether to bypass the key policy lockout safety
1639
- # check.
1640
- #
1641
- # Setting this value to true increases the likelihood that the CMK
1642
- # becomes unmanageable. Do not set this value to true
1643
- # indiscriminately.
1644
- #
1645
- # For more information, refer to the scenario in the [Default Key
1646
- # Policy][1] section in the *AWS Key Management Service Developer
1647
- # Guide*.
1648
- #
1649
- # Use this parameter only when you intend to prevent the principal
1650
- # making the request from making a subsequent `PutKeyPolicy` request
1651
- # on the CMK.
1652
- #
1653
- # The default value is false.
1654
- #
1655
- #
1656
- #
1657
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
1658
- # @return [Boolean]
1659
- class PutKeyPolicyRequest < Struct.new(
1660
- :key_id,
1661
- :policy_name,
1662
- :policy,
1663
- :bypass_policy_lockout_safety_check)
1664
- include Aws::Structure
1665
- end
1580
+ # @note When making an API call, you may pass ListRetirableGrantsRequest
1581
+ # data as a hash:
1582
+ #
1583
+ # {
1584
+ # limit: 1,
1585
+ # marker: "MarkerType",
1586
+ # retiring_principal: "PrincipalIdType", # required
1587
+ # }
1588
+ #
1589
+ # @!attribute [rw] limit
1590
+ # When paginating results, specify the maximum number of items to
1591
+ # return in the response. If additional items exist beyond the number
1592
+ # you specify, the `Truncated` element in the response is set to true.
1593
+ #
1594
+ # This value is optional. If you include a value, it must be between 1
1595
+ # and 100, inclusive. If you do not include a value, it defaults to
1596
+ # 50.
1597
+ # @return [Integer]
1598
+ #
1599
+ # @!attribute [rw] marker
1600
+ # Use this parameter only when paginating results and only in a
1601
+ # subsequent request after you receive a response with truncated
1602
+ # results. Set it to the value of `NextMarker` from the response you
1603
+ # just received.
1604
+ # @return [String]
1605
+ #
1606
+ # @!attribute [rw] retiring_principal
1607
+ # The retiring principal for which to list grants.
1608
+ #
1609
+ # To specify the retiring principal, use the [Amazon Resource Name
1610
+ # (ARN)][1] of an AWS principal. Valid AWS principals include AWS
1611
+ # accounts (root), IAM users, federated users, and assumed role users.
1612
+ # For examples of the ARN syntax for specifying a principal, see [AWS
1613
+ # Identity and Access Management (IAM)][2] in the Example ARNs section
1614
+ # of the *Amazon Web Services General Reference*.
1615
+ #
1616
+ #
1617
+ #
1618
+ # [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
1619
+ # [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam
1620
+ # @return [String]
1621
+ #
1622
+ class ListRetirableGrantsRequest < Struct.new(
1623
+ :limit,
1624
+ :marker,
1625
+ :retiring_principal)
1626
+ include Aws::Structure
1627
+ end
1666
1628
 
1667
- # @note When making an API call, pass ReEncryptRequest
1668
- # data as a hash:
1669
- #
1670
- # {
1671
- # ciphertext_blob: "data", # required
1672
- # source_encryption_context: {
1673
- # "EncryptionContextKey" => "EncryptionContextValue",
1674
- # },
1675
- # destination_key_id: "KeyIdType", # required
1676
- # destination_encryption_context: {
1677
- # "EncryptionContextKey" => "EncryptionContextValue",
1678
- # },
1679
- # grant_tokens: ["GrantTokenType"],
1680
- # }
1681
- # @!attribute [rw] ciphertext_blob
1682
- # Ciphertext of the data to re-encrypt.
1683
- # @return [String]
1684
- #
1685
- # @!attribute [rw] source_encryption_context
1686
- # Encryption context used to encrypt and decrypt the data specified in
1687
- # the `CiphertextBlob` parameter.
1688
- # @return [Hash<String,String>]
1689
- #
1690
- # @!attribute [rw] destination_key_id
1691
- # A unique identifier for the customer master key used to re-encrypt
1692
- # the data. This value can be a globally unique identifier, a fully
1693
- # specified ARN to either an alias or a key, or an alias name prefixed
1694
- # by "alias/".
1695
- #
1696
- # * Key ARN Example -
1697
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1698
- #
1699
- # * Alias ARN Example -
1700
- # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
1701
- #
1702
- # * Globally Unique Key ID Example -
1703
- # 12345678-1234-1234-1234-123456789012
1704
- #
1705
- # * Alias Name Example - alias/MyAliasName
1706
- # @return [String]
1707
- #
1708
- # @!attribute [rw] destination_encryption_context
1709
- # Encryption context to be used when the data is re-encrypted.
1710
- # @return [Hash<String,String>]
1711
- #
1712
- # @!attribute [rw] grant_tokens
1713
- # A list of grant tokens.
1714
- #
1715
- # For more information, see [Grant Tokens][1] in the *AWS Key
1716
- # Management Service Developer Guide*.
1717
- #
1718
- #
1719
- #
1720
- # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
1721
- # @return [Array<String>]
1722
- class ReEncryptRequest < Struct.new(
1723
- :ciphertext_blob,
1724
- :source_encryption_context,
1725
- :destination_key_id,
1726
- :destination_encryption_context,
1727
- :grant_tokens)
1728
- include Aws::Structure
1729
- end
1629
+ # @note When making an API call, you may pass PutKeyPolicyRequest
1630
+ # data as a hash:
1631
+ #
1632
+ # {
1633
+ # key_id: "KeyIdType", # required
1634
+ # policy_name: "PolicyNameType", # required
1635
+ # policy: "PolicyType", # required
1636
+ # bypass_policy_lockout_safety_check: false,
1637
+ # }
1638
+ #
1639
+ # @!attribute [rw] key_id
1640
+ # A unique identifier for the CMK.
1641
+ #
1642
+ # Use the CMK's unique identifier or its Amazon Resource Name (ARN).
1643
+ # For example:
1644
+ #
1645
+ # * Unique ID: 1234abcd-12ab-34cd-56ef-1234567890ab
1646
+ #
1647
+ # * ARN:
1648
+ # arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
1649
+ # @return [String]
1650
+ #
1651
+ # @!attribute [rw] policy_name
1652
+ # The name of the key policy.
1653
+ #
1654
+ # This value must be `default`.
1655
+ # @return [String]
1656
+ #
1657
+ # @!attribute [rw] policy
1658
+ # The key policy to attach to the CMK.
1659
+ #
1660
+ # If you do not set `BypassPolicyLockoutSafetyCheck` to true, the
1661
+ # policy must meet the following criteria:
1662
+ #
1663
+ # * It must allow the principal making the `PutKeyPolicy` request to
1664
+ # make a subsequent `PutKeyPolicy` request on the CMK. This reduces
1665
+ # the likelihood that the CMK becomes unmanageable. For more
1666
+ # information, refer to the scenario in the [Default Key Policy][1]
1667
+ # section in the *AWS Key Management Service Developer Guide*.
1668
+ #
1669
+ # * The principal(s) specified in the key policy must exist and be
1670
+ # visible to AWS KMS. When you create a new AWS principal (for
1671
+ # example, an IAM user or role), you might need to enforce a delay
1672
+ # before specifying the new principal in a key policy because the
1673
+ # new principal might not immediately be visible to AWS KMS. For
1674
+ # more information, see [Changes that I make are not always
1675
+ # immediately visible][2] in the *IAM User Guide*.
1676
+ #
1677
+ # The policy size limit is 32 KiB (32768 bytes).
1678
+ #
1679
+ #
1680
+ #
1681
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
1682
+ # [2]: http://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_eventual-consistency
1683
+ # @return [String]
1684
+ #
1685
+ # @!attribute [rw] bypass_policy_lockout_safety_check
1686
+ # A flag to indicate whether to bypass the key policy lockout safety
1687
+ # check.
1688
+ #
1689
+ # Setting this value to true increases the likelihood that the CMK
1690
+ # becomes unmanageable. Do not set this value to true
1691
+ # indiscriminately.
1692
+ #
1693
+ # For more information, refer to the scenario in the [Default Key
1694
+ # Policy][1] section in the *AWS Key Management Service Developer
1695
+ # Guide*.
1696
+ #
1697
+ # Use this parameter only when you intend to prevent the principal
1698
+ # making the request from making a subsequent `PutKeyPolicy` request
1699
+ # on the CMK.
1700
+ #
1701
+ # The default value is false.
1702
+ #
1703
+ #
1704
+ #
1705
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam
1706
+ # @return [Boolean]
1707
+ #
1708
+ class PutKeyPolicyRequest < Struct.new(
1709
+ :key_id,
1710
+ :policy_name,
1711
+ :policy,
1712
+ :bypass_policy_lockout_safety_check)
1713
+ include Aws::Structure
1714
+ end
1730
1715
 
1731
- # @!attribute [rw] ciphertext_blob
1732
- # The re-encrypted data. If you are using the CLI, the value is Base64
1733
- # encoded. Otherwise, it is not encoded.
1734
- # @return [String]
1735
- #
1736
- # @!attribute [rw] source_key_id
1737
- # Unique identifier of the key used to originally encrypt the data.
1738
- # @return [String]
1739
- #
1740
- # @!attribute [rw] key_id
1741
- # Unique identifier of the key used to re-encrypt the data.
1742
- # @return [String]
1743
- class ReEncryptResponse < Struct.new(
1744
- :ciphertext_blob,
1745
- :source_key_id,
1746
- :key_id)
1747
- include Aws::Structure
1748
- end
1716
+ # @note When making an API call, you may pass ReEncryptRequest
1717
+ # data as a hash:
1718
+ #
1719
+ # {
1720
+ # ciphertext_blob: "data", # required
1721
+ # source_encryption_context: {
1722
+ # "EncryptionContextKey" => "EncryptionContextValue",
1723
+ # },
1724
+ # destination_key_id: "KeyIdType", # required
1725
+ # destination_encryption_context: {
1726
+ # "EncryptionContextKey" => "EncryptionContextValue",
1727
+ # },
1728
+ # grant_tokens: ["GrantTokenType"],
1729
+ # }
1730
+ #
1731
+ # @!attribute [rw] ciphertext_blob
1732
+ # Ciphertext of the data to reencrypt.
1733
+ # @return [String]
1734
+ #
1735
+ # @!attribute [rw] source_encryption_context
1736
+ # Encryption context used to encrypt and decrypt the data specified in
1737
+ # the `CiphertextBlob` parameter.
1738
+ # @return [Hash<String,String>]
1739
+ #
1740
+ # @!attribute [rw] destination_key_id
1741
+ # A unique identifier for the CMK to use to reencrypt the data. This
1742
+ # value can be a globally unique identifier, a fully specified ARN to
1743
+ # either an alias or a key, or an alias name prefixed by "alias/".
1744
+ #
1745
+ # * Key ARN Example -
1746
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1747
+ #
1748
+ # * Alias ARN Example -
1749
+ # arn:aws:kms:us-east-1:123456789012:alias/MyAliasName
1750
+ #
1751
+ # * Globally Unique Key ID Example -
1752
+ # 12345678-1234-1234-1234-123456789012
1753
+ #
1754
+ # * Alias Name Example - alias/MyAliasName
1755
+ # @return [String]
1756
+ #
1757
+ # @!attribute [rw] destination_encryption_context
1758
+ # Encryption context to use when the data is reencrypted.
1759
+ # @return [Hash<String,String>]
1760
+ #
1761
+ # @!attribute [rw] grant_tokens
1762
+ # A list of grant tokens.
1763
+ #
1764
+ # For more information, see [Grant Tokens][1] in the *AWS Key
1765
+ # Management Service Developer Guide*.
1766
+ #
1767
+ #
1768
+ #
1769
+ # [1]: http://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#grant_token
1770
+ # @return [Array<String>]
1771
+ #
1772
+ class ReEncryptRequest < Struct.new(
1773
+ :ciphertext_blob,
1774
+ :source_encryption_context,
1775
+ :destination_key_id,
1776
+ :destination_encryption_context,
1777
+ :grant_tokens)
1778
+ include Aws::Structure
1779
+ end
1749
1780
 
1750
- # @note When making an API call, pass RetireGrantRequest
1751
- # data as a hash:
1752
- #
1753
- # {
1754
- # grant_token: "GrantTokenType",
1755
- # key_id: "KeyIdType",
1756
- # grant_id: "GrantIdType",
1757
- # }
1758
- # @!attribute [rw] grant_token
1759
- # Token that identifies the grant to be retired.
1760
- # @return [String]
1761
- #
1762
- # @!attribute [rw] key_id
1763
- # A unique identifier for the customer master key associated with the
1764
- # grant. This value can be a globally unique identifier or a fully
1765
- # specified ARN of the key.
1766
- #
1767
- # * Key ARN Example -
1768
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1769
- #
1770
- # * Globally Unique Key ID Example -
1771
- # 12345678-1234-1234-1234-123456789012
1772
- # @return [String]
1773
- #
1774
- # @!attribute [rw] grant_id
1775
- # Unique identifier of the grant to be retired. The grant ID is
1776
- # returned by the `CreateGrant` function.
1777
- #
1778
- # * Grant ID Example -
1779
- # 0123456789012345678901234567890123456789012345678901234567890123
1780
- #
1781
- # ^
1782
- # @return [String]
1783
- class RetireGrantRequest < Struct.new(
1784
- :grant_token,
1785
- :key_id,
1786
- :grant_id)
1787
- include Aws::Structure
1788
- end
1781
+ # @!attribute [rw] ciphertext_blob
1782
+ # The reencrypted data.
1783
+ # @return [String]
1784
+ #
1785
+ # @!attribute [rw] source_key_id
1786
+ # Unique identifier of the CMK used to originally encrypt the data.
1787
+ # @return [String]
1788
+ #
1789
+ # @!attribute [rw] key_id
1790
+ # Unique identifier of the CMK used to reencrypt the data.
1791
+ # @return [String]
1792
+ #
1793
+ class ReEncryptResponse < Struct.new(
1794
+ :ciphertext_blob,
1795
+ :source_key_id,
1796
+ :key_id)
1797
+ include Aws::Structure
1798
+ end
1789
1799
 
1790
- # @note When making an API call, pass RevokeGrantRequest
1791
- # data as a hash:
1792
- #
1793
- # {
1794
- # key_id: "KeyIdType", # required
1795
- # grant_id: "GrantIdType", # required
1796
- # }
1797
- # @!attribute [rw] key_id
1798
- # A unique identifier for the customer master key associated with the
1799
- # grant. This value can be a globally unique identifier or the fully
1800
- # specified ARN to a key.
1801
- #
1802
- # * Key ARN Example -
1803
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1804
- #
1805
- # * Globally Unique Key ID Example -
1806
- # 12345678-1234-1234-1234-123456789012
1807
- # @return [String]
1808
- #
1809
- # @!attribute [rw] grant_id
1810
- # Identifier of the grant to be revoked.
1811
- # @return [String]
1812
- class RevokeGrantRequest < Struct.new(
1813
- :key_id,
1814
- :grant_id)
1815
- include Aws::Structure
1816
- end
1800
+ # @note When making an API call, you may pass RetireGrantRequest
1801
+ # data as a hash:
1802
+ #
1803
+ # {
1804
+ # grant_token: "GrantTokenType",
1805
+ # key_id: "KeyIdType",
1806
+ # grant_id: "GrantIdType",
1807
+ # }
1808
+ #
1809
+ # @!attribute [rw] grant_token
1810
+ # Token that identifies the grant to be retired.
1811
+ # @return [String]
1812
+ #
1813
+ # @!attribute [rw] key_id
1814
+ # The Amazon Resource Name of the CMK associated with the grant.
1815
+ # Example:
1816
+ #
1817
+ # * arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab
1818
+ #
1819
+ # ^
1820
+ # @return [String]
1821
+ #
1822
+ # @!attribute [rw] grant_id
1823
+ # Unique identifier of the grant to retire. The grant ID is returned
1824
+ # in the response to a `CreateGrant` operation.
1825
+ #
1826
+ # * Grant ID Example -
1827
+ # 0123456789012345678901234567890123456789012345678901234567890123
1828
+ #
1829
+ # ^
1830
+ # @return [String]
1831
+ #
1832
+ class RetireGrantRequest < Struct.new(
1833
+ :grant_token,
1834
+ :key_id,
1835
+ :grant_id)
1836
+ include Aws::Structure
1837
+ end
1817
1838
 
1818
- # @note When making an API call, pass ScheduleKeyDeletionRequest
1819
- # data as a hash:
1820
- #
1821
- # {
1822
- # key_id: "KeyIdType", # required
1823
- # pending_window_in_days: 1,
1824
- # }
1825
- # @!attribute [rw] key_id
1826
- # The unique identifier for the customer master key (CMK) to delete.
1827
- #
1828
- # To specify this value, use the unique key ID or the Amazon Resource
1829
- # Name (ARN) of the CMK. Examples:
1830
- #
1831
- # * Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab
1832
- #
1833
- # * Key ARN:
1834
- # arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
1835
- #
1836
- # To obtain the unique key ID and key ARN for a given CMK, use
1837
- # ListKeys or DescribeKey.
1838
- # @return [String]
1839
- #
1840
- # @!attribute [rw] pending_window_in_days
1841
- # The waiting period, specified in number of days. After the waiting
1842
- # period ends, AWS KMS deletes the customer master key (CMK).
1843
- #
1844
- # This value is optional. If you include a value, it must be between 7
1845
- # and 30, inclusive. If you do not include a value, it defaults to 30.
1846
- # @return [Integer]
1847
- class ScheduleKeyDeletionRequest < Struct.new(
1848
- :key_id,
1849
- :pending_window_in_days)
1850
- include Aws::Structure
1851
- end
1839
+ # @note When making an API call, you may pass RevokeGrantRequest
1840
+ # data as a hash:
1841
+ #
1842
+ # {
1843
+ # key_id: "KeyIdType", # required
1844
+ # grant_id: "GrantIdType", # required
1845
+ # }
1846
+ #
1847
+ # @!attribute [rw] key_id
1848
+ # A unique identifier for the customer master key associated with the
1849
+ # grant. This value can be a globally unique identifier or the fully
1850
+ # specified ARN to a key.
1851
+ #
1852
+ # * Key ARN Example -
1853
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1854
+ #
1855
+ # * Globally Unique Key ID Example -
1856
+ # 12345678-1234-1234-1234-123456789012
1857
+ # @return [String]
1858
+ #
1859
+ # @!attribute [rw] grant_id
1860
+ # Identifier of the grant to be revoked.
1861
+ # @return [String]
1862
+ #
1863
+ class RevokeGrantRequest < Struct.new(
1864
+ :key_id,
1865
+ :grant_id)
1866
+ include Aws::Structure
1867
+ end
1852
1868
 
1853
- # @!attribute [rw] key_id
1854
- # The unique identifier of the customer master key (CMK) for which
1855
- # deletion is scheduled.
1856
- # @return [String]
1857
- #
1858
- # @!attribute [rw] deletion_date
1859
- # The date and time after which AWS KMS deletes the customer master
1860
- # key (CMK).
1861
- # @return [Time]
1862
- class ScheduleKeyDeletionResponse < Struct.new(
1863
- :key_id,
1864
- :deletion_date)
1865
- include Aws::Structure
1866
- end
1869
+ # @note When making an API call, you may pass ScheduleKeyDeletionRequest
1870
+ # data as a hash:
1871
+ #
1872
+ # {
1873
+ # key_id: "KeyIdType", # required
1874
+ # pending_window_in_days: 1,
1875
+ # }
1876
+ #
1877
+ # @!attribute [rw] key_id
1878
+ # The unique identifier for the customer master key (CMK) to delete.
1879
+ #
1880
+ # To specify this value, use the unique key ID or the Amazon Resource
1881
+ # Name (ARN) of the CMK. Examples:
1882
+ #
1883
+ # * Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab
1884
+ #
1885
+ # * Key ARN:
1886
+ # arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
1887
+ #
1888
+ # To obtain the unique key ID and key ARN for a given CMK, use
1889
+ # ListKeys or DescribeKey.
1890
+ # @return [String]
1891
+ #
1892
+ # @!attribute [rw] pending_window_in_days
1893
+ # The waiting period, specified in number of days. After the waiting
1894
+ # period ends, AWS KMS deletes the customer master key (CMK).
1895
+ #
1896
+ # This value is optional. If you include a value, it must be between 7
1897
+ # and 30, inclusive. If you do not include a value, it defaults to 30.
1898
+ # @return [Integer]
1899
+ #
1900
+ class ScheduleKeyDeletionRequest < Struct.new(
1901
+ :key_id,
1902
+ :pending_window_in_days)
1903
+ include Aws::Structure
1904
+ end
1867
1905
 
1868
- # @note When making an API call, pass UpdateAliasRequest
1869
- # data as a hash:
1870
- #
1871
- # {
1872
- # alias_name: "AliasNameType", # required
1873
- # target_key_id: "KeyIdType", # required
1874
- # }
1875
- # @!attribute [rw] alias_name
1876
- # String that contains the name of the alias to be modified. The name
1877
- # must start with the word "alias" followed by a forward slash
1878
- # (alias/). Aliases that begin with "alias/aws" are reserved.
1879
- # @return [String]
1880
- #
1881
- # @!attribute [rw] target_key_id
1882
- # Unique identifier of the customer master key to be mapped to the
1883
- # alias. This value can be a globally unique identifier or the fully
1884
- # specified ARN of a key.
1885
- #
1886
- # * Key ARN Example -
1887
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1888
- #
1889
- # * Globally Unique Key ID Example -
1890
- # 12345678-1234-1234-1234-123456789012
1891
- #
1892
- # You can call ListAliases to verify that the alias is mapped to the
1893
- # correct `TargetKeyId`.
1894
- # @return [String]
1895
- class UpdateAliasRequest < Struct.new(
1896
- :alias_name,
1897
- :target_key_id)
1898
- include Aws::Structure
1899
- end
1906
+ # @!attribute [rw] key_id
1907
+ # The unique identifier of the customer master key (CMK) for which
1908
+ # deletion is scheduled.
1909
+ # @return [String]
1910
+ #
1911
+ # @!attribute [rw] deletion_date
1912
+ # The date and time after which AWS KMS deletes the customer master
1913
+ # key (CMK).
1914
+ # @return [Time]
1915
+ #
1916
+ class ScheduleKeyDeletionResponse < Struct.new(
1917
+ :key_id,
1918
+ :deletion_date)
1919
+ include Aws::Structure
1920
+ end
1900
1921
 
1901
- # @note When making an API call, pass UpdateKeyDescriptionRequest
1902
- # data as a hash:
1903
- #
1904
- # {
1905
- # key_id: "KeyIdType", # required
1906
- # description: "DescriptionType", # required
1907
- # }
1908
- # @!attribute [rw] key_id
1909
- # A unique identifier for the customer master key. This value can be a
1910
- # globally unique identifier or the fully specified ARN to a key.
1911
- #
1912
- # * Key ARN Example -
1913
- # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1914
- #
1915
- # * Globally Unique Key ID Example -
1916
- # 12345678-1234-1234-1234-123456789012
1917
- # @return [String]
1918
- #
1919
- # @!attribute [rw] description
1920
- # New description for the key.
1921
- # @return [String]
1922
- class UpdateKeyDescriptionRequest < Struct.new(
1923
- :key_id,
1924
- :description)
1925
- include Aws::Structure
1926
- end
1922
+ # @note When making an API call, you may pass UpdateAliasRequest
1923
+ # data as a hash:
1924
+ #
1925
+ # {
1926
+ # alias_name: "AliasNameType", # required
1927
+ # target_key_id: "KeyIdType", # required
1928
+ # }
1929
+ #
1930
+ # @!attribute [rw] alias_name
1931
+ # String that contains the name of the alias to be modified. The name
1932
+ # must start with the word "alias" followed by a forward slash
1933
+ # (alias/). Aliases that begin with "alias/aws" are reserved.
1934
+ # @return [String]
1935
+ #
1936
+ # @!attribute [rw] target_key_id
1937
+ # Unique identifier of the customer master key to be mapped to the
1938
+ # alias. This value can be a globally unique identifier or the fully
1939
+ # specified ARN of a key.
1940
+ #
1941
+ # * Key ARN Example -
1942
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1943
+ #
1944
+ # * Globally Unique Key ID Example -
1945
+ # 12345678-1234-1234-1234-123456789012
1946
+ #
1947
+ # You can call ListAliases to verify that the alias is mapped to the
1948
+ # correct `TargetKeyId`.
1949
+ # @return [String]
1950
+ #
1951
+ class UpdateAliasRequest < Struct.new(
1952
+ :alias_name,
1953
+ :target_key_id)
1954
+ include Aws::Structure
1955
+ end
1927
1956
 
1957
+ # @note When making an API call, you may pass UpdateKeyDescriptionRequest
1958
+ # data as a hash:
1959
+ #
1960
+ # {
1961
+ # key_id: "KeyIdType", # required
1962
+ # description: "DescriptionType", # required
1963
+ # }
1964
+ #
1965
+ # @!attribute [rw] key_id
1966
+ # A unique identifier for the CMK. This value can be a globally unique
1967
+ # identifier or the fully specified ARN to a key.
1968
+ #
1969
+ # * Key ARN Example -
1970
+ # arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
1971
+ #
1972
+ # * Globally Unique Key ID Example -
1973
+ # 12345678-1234-1234-1234-123456789012
1974
+ # @return [String]
1975
+ #
1976
+ # @!attribute [rw] description
1977
+ # New description for the CMK.
1978
+ # @return [String]
1979
+ #
1980
+ class UpdateKeyDescriptionRequest < Struct.new(
1981
+ :key_id,
1982
+ :description)
1983
+ include Aws::Structure
1928
1984
  end
1985
+
1929
1986
  end
1930
1987
  end