@aws-sdk/client-kms 3.42.0 → 3.47.0
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.
- package/CHANGELOG.md +48 -0
- package/dist-cjs/endpoints.js +8 -103
- package/dist-cjs/models/models_0.js +3 -201
- package/dist-cjs/runtimeConfig.browser.js +7 -2
- package/dist-cjs/runtimeConfig.js +9 -3
- package/dist-es/endpoints.js +8 -103
- package/dist-es/models/models_0.js +0 -132
- package/dist-es/runtimeConfig.browser.js +12 -3
- package/dist-es/runtimeConfig.js +13 -6
- package/dist-types/KMSClient.d.ts +5 -1
- package/dist-types/models/models_0.d.ts +0 -198
- package/dist-types/runtimeConfig.browser.d.ts +3 -2
- package/dist-types/runtimeConfig.d.ts +4 -3
- package/dist-types/runtimeConfig.native.d.ts +1 -0
- package/dist-types/ts3.4/KMSClient.d.ts +3 -1
- package/dist-types/ts3.4/models/models_0.d.ts +0 -132
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -2
- package/dist-types/ts3.4/runtimeConfig.d.ts +4 -3
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -0
- package/package.json +38 -45
|
@@ -16,14 +16,17 @@ const util_user_agent_node_1 = require("@aws-sdk/util-user-agent-node");
|
|
|
16
16
|
const util_utf8_node_1 = require("@aws-sdk/util-utf8-node");
|
|
17
17
|
const runtimeConfig_shared_1 = require("./runtimeConfig.shared");
|
|
18
18
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
19
|
+
const util_defaults_mode_node_1 = require("@aws-sdk/util-defaults-mode-node");
|
|
19
20
|
const getRuntimeConfig = (config) => {
|
|
20
21
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
21
|
-
|
|
22
|
+
const defaultsMode = util_defaults_mode_node_1.resolveDefaultsModeConfig(config);
|
|
23
|
+
const defaultConfigProvider = () => defaultsMode().then(smithy_client_1.loadConfigsForDefaultMode);
|
|
22
24
|
const clientSharedValues = runtimeConfig_shared_1.getRuntimeConfig(config);
|
|
23
25
|
return {
|
|
24
26
|
...clientSharedValues,
|
|
25
27
|
...config,
|
|
26
28
|
runtime: "node",
|
|
29
|
+
defaultsMode,
|
|
27
30
|
base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : util_base64_node_1.fromBase64,
|
|
28
31
|
base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : util_base64_node_1.toBase64,
|
|
29
32
|
bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : util_body_length_node_1.calculateBodyLength,
|
|
@@ -31,8 +34,11 @@ const getRuntimeConfig = (config) => {
|
|
|
31
34
|
defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : util_user_agent_node_1.defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
|
|
32
35
|
maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : node_config_provider_1.loadConfig(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS),
|
|
33
36
|
region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : node_config_provider_1.loadConfig(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS),
|
|
34
|
-
requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new node_http_handler_1.NodeHttpHandler(),
|
|
35
|
-
retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : node_config_provider_1.loadConfig(
|
|
37
|
+
requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new node_http_handler_1.NodeHttpHandler(defaultConfigProvider),
|
|
38
|
+
retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : node_config_provider_1.loadConfig({
|
|
39
|
+
...middleware_retry_1.NODE_RETRY_MODE_CONFIG_OPTIONS,
|
|
40
|
+
default: async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE,
|
|
41
|
+
}),
|
|
36
42
|
sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : hash_node_1.Hash.bind(null, "sha256"),
|
|
37
43
|
streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : node_http_handler_1.streamCollector,
|
|
38
44
|
useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : node_config_provider_1.loadConfig(config_resolver_1.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS),
|
package/dist-es/endpoints.js
CHANGED
|
@@ -3,10 +3,6 @@ import { getRegionInfo } from "@aws-sdk/config-resolver";
|
|
|
3
3
|
var regionHash = {
|
|
4
4
|
"af-south-1": {
|
|
5
5
|
variants: [
|
|
6
|
-
{
|
|
7
|
-
hostname: "kms.af-south-1.amazonaws.com",
|
|
8
|
-
tags: [],
|
|
9
|
-
},
|
|
10
6
|
{
|
|
11
7
|
hostname: "kms-fips.af-south-1.amazonaws.com",
|
|
12
8
|
tags: ["fips"],
|
|
@@ -15,10 +11,6 @@ var regionHash = {
|
|
|
15
11
|
},
|
|
16
12
|
"ap-east-1": {
|
|
17
13
|
variants: [
|
|
18
|
-
{
|
|
19
|
-
hostname: "kms.ap-east-1.amazonaws.com",
|
|
20
|
-
tags: [],
|
|
21
|
-
},
|
|
22
14
|
{
|
|
23
15
|
hostname: "kms-fips.ap-east-1.amazonaws.com",
|
|
24
16
|
tags: ["fips"],
|
|
@@ -27,10 +19,6 @@ var regionHash = {
|
|
|
27
19
|
},
|
|
28
20
|
"ap-northeast-1": {
|
|
29
21
|
variants: [
|
|
30
|
-
{
|
|
31
|
-
hostname: "kms.ap-northeast-1.amazonaws.com",
|
|
32
|
-
tags: [],
|
|
33
|
-
},
|
|
34
22
|
{
|
|
35
23
|
hostname: "kms-fips.ap-northeast-1.amazonaws.com",
|
|
36
24
|
tags: ["fips"],
|
|
@@ -39,10 +27,6 @@ var regionHash = {
|
|
|
39
27
|
},
|
|
40
28
|
"ap-northeast-2": {
|
|
41
29
|
variants: [
|
|
42
|
-
{
|
|
43
|
-
hostname: "kms.ap-northeast-2.amazonaws.com",
|
|
44
|
-
tags: [],
|
|
45
|
-
},
|
|
46
30
|
{
|
|
47
31
|
hostname: "kms-fips.ap-northeast-2.amazonaws.com",
|
|
48
32
|
tags: ["fips"],
|
|
@@ -51,10 +35,6 @@ var regionHash = {
|
|
|
51
35
|
},
|
|
52
36
|
"ap-northeast-3": {
|
|
53
37
|
variants: [
|
|
54
|
-
{
|
|
55
|
-
hostname: "kms.ap-northeast-3.amazonaws.com",
|
|
56
|
-
tags: [],
|
|
57
|
-
},
|
|
58
38
|
{
|
|
59
39
|
hostname: "kms-fips.ap-northeast-3.amazonaws.com",
|
|
60
40
|
tags: ["fips"],
|
|
@@ -63,10 +43,6 @@ var regionHash = {
|
|
|
63
43
|
},
|
|
64
44
|
"ap-south-1": {
|
|
65
45
|
variants: [
|
|
66
|
-
{
|
|
67
|
-
hostname: "kms.ap-south-1.amazonaws.com",
|
|
68
|
-
tags: [],
|
|
69
|
-
},
|
|
70
46
|
{
|
|
71
47
|
hostname: "kms-fips.ap-south-1.amazonaws.com",
|
|
72
48
|
tags: ["fips"],
|
|
@@ -75,10 +51,6 @@ var regionHash = {
|
|
|
75
51
|
},
|
|
76
52
|
"ap-southeast-1": {
|
|
77
53
|
variants: [
|
|
78
|
-
{
|
|
79
|
-
hostname: "kms.ap-southeast-1.amazonaws.com",
|
|
80
|
-
tags: [],
|
|
81
|
-
},
|
|
82
54
|
{
|
|
83
55
|
hostname: "kms-fips.ap-southeast-1.amazonaws.com",
|
|
84
56
|
tags: ["fips"],
|
|
@@ -87,22 +59,22 @@ var regionHash = {
|
|
|
87
59
|
},
|
|
88
60
|
"ap-southeast-2": {
|
|
89
61
|
variants: [
|
|
90
|
-
{
|
|
91
|
-
hostname: "kms.ap-southeast-2.amazonaws.com",
|
|
92
|
-
tags: [],
|
|
93
|
-
},
|
|
94
62
|
{
|
|
95
63
|
hostname: "kms-fips.ap-southeast-2.amazonaws.com",
|
|
96
64
|
tags: ["fips"],
|
|
97
65
|
},
|
|
98
66
|
],
|
|
99
67
|
},
|
|
100
|
-
"
|
|
68
|
+
"ap-southeast-3": {
|
|
101
69
|
variants: [
|
|
102
70
|
{
|
|
103
|
-
hostname: "kms.
|
|
104
|
-
tags: [],
|
|
71
|
+
hostname: "kms-fips.ap-southeast-3.amazonaws.com",
|
|
72
|
+
tags: ["fips"],
|
|
105
73
|
},
|
|
74
|
+
],
|
|
75
|
+
},
|
|
76
|
+
"ca-central-1": {
|
|
77
|
+
variants: [
|
|
106
78
|
{
|
|
107
79
|
hostname: "kms-fips.ca-central-1.amazonaws.com",
|
|
108
80
|
tags: ["fips"],
|
|
@@ -111,10 +83,6 @@ var regionHash = {
|
|
|
111
83
|
},
|
|
112
84
|
"eu-central-1": {
|
|
113
85
|
variants: [
|
|
114
|
-
{
|
|
115
|
-
hostname: "kms.eu-central-1.amazonaws.com",
|
|
116
|
-
tags: [],
|
|
117
|
-
},
|
|
118
86
|
{
|
|
119
87
|
hostname: "kms-fips.eu-central-1.amazonaws.com",
|
|
120
88
|
tags: ["fips"],
|
|
@@ -123,10 +91,6 @@ var regionHash = {
|
|
|
123
91
|
},
|
|
124
92
|
"eu-north-1": {
|
|
125
93
|
variants: [
|
|
126
|
-
{
|
|
127
|
-
hostname: "kms.eu-north-1.amazonaws.com",
|
|
128
|
-
tags: [],
|
|
129
|
-
},
|
|
130
94
|
{
|
|
131
95
|
hostname: "kms-fips.eu-north-1.amazonaws.com",
|
|
132
96
|
tags: ["fips"],
|
|
@@ -135,10 +99,6 @@ var regionHash = {
|
|
|
135
99
|
},
|
|
136
100
|
"eu-south-1": {
|
|
137
101
|
variants: [
|
|
138
|
-
{
|
|
139
|
-
hostname: "kms.eu-south-1.amazonaws.com",
|
|
140
|
-
tags: [],
|
|
141
|
-
},
|
|
142
102
|
{
|
|
143
103
|
hostname: "kms-fips.eu-south-1.amazonaws.com",
|
|
144
104
|
tags: ["fips"],
|
|
@@ -147,10 +107,6 @@ var regionHash = {
|
|
|
147
107
|
},
|
|
148
108
|
"eu-west-1": {
|
|
149
109
|
variants: [
|
|
150
|
-
{
|
|
151
|
-
hostname: "kms.eu-west-1.amazonaws.com",
|
|
152
|
-
tags: [],
|
|
153
|
-
},
|
|
154
110
|
{
|
|
155
111
|
hostname: "kms-fips.eu-west-1.amazonaws.com",
|
|
156
112
|
tags: ["fips"],
|
|
@@ -159,10 +115,6 @@ var regionHash = {
|
|
|
159
115
|
},
|
|
160
116
|
"eu-west-2": {
|
|
161
117
|
variants: [
|
|
162
|
-
{
|
|
163
|
-
hostname: "kms.eu-west-2.amazonaws.com",
|
|
164
|
-
tags: [],
|
|
165
|
-
},
|
|
166
118
|
{
|
|
167
119
|
hostname: "kms-fips.eu-west-2.amazonaws.com",
|
|
168
120
|
tags: ["fips"],
|
|
@@ -171,10 +123,6 @@ var regionHash = {
|
|
|
171
123
|
},
|
|
172
124
|
"eu-west-3": {
|
|
173
125
|
variants: [
|
|
174
|
-
{
|
|
175
|
-
hostname: "kms.eu-west-3.amazonaws.com",
|
|
176
|
-
tags: [],
|
|
177
|
-
},
|
|
178
126
|
{
|
|
179
127
|
hostname: "kms-fips.eu-west-3.amazonaws.com",
|
|
180
128
|
tags: ["fips"],
|
|
@@ -183,10 +131,6 @@ var regionHash = {
|
|
|
183
131
|
},
|
|
184
132
|
"me-south-1": {
|
|
185
133
|
variants: [
|
|
186
|
-
{
|
|
187
|
-
hostname: "kms.me-south-1.amazonaws.com",
|
|
188
|
-
tags: [],
|
|
189
|
-
},
|
|
190
134
|
{
|
|
191
135
|
hostname: "kms-fips.me-south-1.amazonaws.com",
|
|
192
136
|
tags: ["fips"],
|
|
@@ -195,10 +139,6 @@ var regionHash = {
|
|
|
195
139
|
},
|
|
196
140
|
"sa-east-1": {
|
|
197
141
|
variants: [
|
|
198
|
-
{
|
|
199
|
-
hostname: "kms.sa-east-1.amazonaws.com",
|
|
200
|
-
tags: [],
|
|
201
|
-
},
|
|
202
142
|
{
|
|
203
143
|
hostname: "kms-fips.sa-east-1.amazonaws.com",
|
|
204
144
|
tags: ["fips"],
|
|
@@ -207,10 +147,6 @@ var regionHash = {
|
|
|
207
147
|
},
|
|
208
148
|
"us-east-1": {
|
|
209
149
|
variants: [
|
|
210
|
-
{
|
|
211
|
-
hostname: "kms.us-east-1.amazonaws.com",
|
|
212
|
-
tags: [],
|
|
213
|
-
},
|
|
214
150
|
{
|
|
215
151
|
hostname: "kms-fips.us-east-1.amazonaws.com",
|
|
216
152
|
tags: ["fips"],
|
|
@@ -219,10 +155,6 @@ var regionHash = {
|
|
|
219
155
|
},
|
|
220
156
|
"us-east-2": {
|
|
221
157
|
variants: [
|
|
222
|
-
{
|
|
223
|
-
hostname: "kms.us-east-2.amazonaws.com",
|
|
224
|
-
tags: [],
|
|
225
|
-
},
|
|
226
158
|
{
|
|
227
159
|
hostname: "kms-fips.us-east-2.amazonaws.com",
|
|
228
160
|
tags: ["fips"],
|
|
@@ -231,10 +163,6 @@ var regionHash = {
|
|
|
231
163
|
},
|
|
232
164
|
"us-gov-east-1": {
|
|
233
165
|
variants: [
|
|
234
|
-
{
|
|
235
|
-
hostname: "kms.us-gov-east-1.amazonaws.com",
|
|
236
|
-
tags: [],
|
|
237
|
-
},
|
|
238
166
|
{
|
|
239
167
|
hostname: "kms-fips.us-gov-east-1.amazonaws.com",
|
|
240
168
|
tags: ["fips"],
|
|
@@ -243,10 +171,6 @@ var regionHash = {
|
|
|
243
171
|
},
|
|
244
172
|
"us-gov-west-1": {
|
|
245
173
|
variants: [
|
|
246
|
-
{
|
|
247
|
-
hostname: "kms.us-gov-west-1.amazonaws.com",
|
|
248
|
-
tags: [],
|
|
249
|
-
},
|
|
250
174
|
{
|
|
251
175
|
hostname: "kms-fips.us-gov-west-1.amazonaws.com",
|
|
252
176
|
tags: ["fips"],
|
|
@@ -255,10 +179,6 @@ var regionHash = {
|
|
|
255
179
|
},
|
|
256
180
|
"us-iso-east-1": {
|
|
257
181
|
variants: [
|
|
258
|
-
{
|
|
259
|
-
hostname: "kms.us-iso-east-1.c2s.ic.gov",
|
|
260
|
-
tags: [],
|
|
261
|
-
},
|
|
262
182
|
{
|
|
263
183
|
hostname: "kms-fips.us-iso-east-1.c2s.ic.gov",
|
|
264
184
|
tags: ["fips"],
|
|
@@ -267,10 +187,6 @@ var regionHash = {
|
|
|
267
187
|
},
|
|
268
188
|
"us-iso-west-1": {
|
|
269
189
|
variants: [
|
|
270
|
-
{
|
|
271
|
-
hostname: "kms.us-iso-west-1.c2s.ic.gov",
|
|
272
|
-
tags: [],
|
|
273
|
-
},
|
|
274
190
|
{
|
|
275
191
|
hostname: "kms-fips.us-iso-west-1.c2s.ic.gov",
|
|
276
192
|
tags: ["fips"],
|
|
@@ -279,10 +195,6 @@ var regionHash = {
|
|
|
279
195
|
},
|
|
280
196
|
"us-isob-east-1": {
|
|
281
197
|
variants: [
|
|
282
|
-
{
|
|
283
|
-
hostname: "kms.us-isob-east-1.sc2s.sgov.gov",
|
|
284
|
-
tags: [],
|
|
285
|
-
},
|
|
286
198
|
{
|
|
287
199
|
hostname: "kms-fips.us-isob-east-1.sc2s.sgov.gov",
|
|
288
200
|
tags: ["fips"],
|
|
@@ -291,10 +203,6 @@ var regionHash = {
|
|
|
291
203
|
},
|
|
292
204
|
"us-west-1": {
|
|
293
205
|
variants: [
|
|
294
|
-
{
|
|
295
|
-
hostname: "kms.us-west-1.amazonaws.com",
|
|
296
|
-
tags: [],
|
|
297
|
-
},
|
|
298
206
|
{
|
|
299
207
|
hostname: "kms-fips.us-west-1.amazonaws.com",
|
|
300
208
|
tags: ["fips"],
|
|
@@ -303,10 +211,6 @@ var regionHash = {
|
|
|
303
211
|
},
|
|
304
212
|
"us-west-2": {
|
|
305
213
|
variants: [
|
|
306
|
-
{
|
|
307
|
-
hostname: "kms.us-west-2.amazonaws.com",
|
|
308
|
-
tags: [],
|
|
309
|
-
},
|
|
310
214
|
{
|
|
311
215
|
hostname: "kms-fips.us-west-2.amazonaws.com",
|
|
312
216
|
tags: ["fips"],
|
|
@@ -333,6 +237,7 @@ var partitionHash = {
|
|
|
333
237
|
"ap-southeast-1-fips",
|
|
334
238
|
"ap-southeast-2",
|
|
335
239
|
"ap-southeast-2-fips",
|
|
240
|
+
"ap-southeast-3",
|
|
336
241
|
"ap-southeast-3-fips",
|
|
337
242
|
"ca-central-1",
|
|
338
243
|
"ca-central-1-fips",
|
|
@@ -10,10 +10,6 @@ export var AliasListEntry;
|
|
|
10
10
|
(function (AliasListEntry) {
|
|
11
11
|
AliasListEntry.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
12
12
|
})(AliasListEntry || (AliasListEntry = {}));
|
|
13
|
-
export var AlreadyExistsException;
|
|
14
|
-
(function (AlreadyExistsException) {
|
|
15
|
-
AlreadyExistsException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
16
|
-
})(AlreadyExistsException || (AlreadyExistsException = {}));
|
|
17
13
|
export var CancelKeyDeletionRequest;
|
|
18
14
|
(function (CancelKeyDeletionRequest) {
|
|
19
15
|
CancelKeyDeletionRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -22,46 +18,6 @@ export var CancelKeyDeletionResponse;
|
|
|
22
18
|
(function (CancelKeyDeletionResponse) {
|
|
23
19
|
CancelKeyDeletionResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
24
20
|
})(CancelKeyDeletionResponse || (CancelKeyDeletionResponse = {}));
|
|
25
|
-
export var DependencyTimeoutException;
|
|
26
|
-
(function (DependencyTimeoutException) {
|
|
27
|
-
DependencyTimeoutException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
28
|
-
})(DependencyTimeoutException || (DependencyTimeoutException = {}));
|
|
29
|
-
export var InvalidArnException;
|
|
30
|
-
(function (InvalidArnException) {
|
|
31
|
-
InvalidArnException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
32
|
-
})(InvalidArnException || (InvalidArnException = {}));
|
|
33
|
-
export var KMSInternalException;
|
|
34
|
-
(function (KMSInternalException) {
|
|
35
|
-
KMSInternalException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
36
|
-
})(KMSInternalException || (KMSInternalException = {}));
|
|
37
|
-
export var KMSInvalidStateException;
|
|
38
|
-
(function (KMSInvalidStateException) {
|
|
39
|
-
KMSInvalidStateException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
40
|
-
})(KMSInvalidStateException || (KMSInvalidStateException = {}));
|
|
41
|
-
export var NotFoundException;
|
|
42
|
-
(function (NotFoundException) {
|
|
43
|
-
NotFoundException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
44
|
-
})(NotFoundException || (NotFoundException = {}));
|
|
45
|
-
export var CloudHsmClusterInUseException;
|
|
46
|
-
(function (CloudHsmClusterInUseException) {
|
|
47
|
-
CloudHsmClusterInUseException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
48
|
-
})(CloudHsmClusterInUseException || (CloudHsmClusterInUseException = {}));
|
|
49
|
-
export var CloudHsmClusterInvalidConfigurationException;
|
|
50
|
-
(function (CloudHsmClusterInvalidConfigurationException) {
|
|
51
|
-
CloudHsmClusterInvalidConfigurationException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
52
|
-
})(CloudHsmClusterInvalidConfigurationException || (CloudHsmClusterInvalidConfigurationException = {}));
|
|
53
|
-
export var CloudHsmClusterNotActiveException;
|
|
54
|
-
(function (CloudHsmClusterNotActiveException) {
|
|
55
|
-
CloudHsmClusterNotActiveException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
56
|
-
})(CloudHsmClusterNotActiveException || (CloudHsmClusterNotActiveException = {}));
|
|
57
|
-
export var CloudHsmClusterNotFoundException;
|
|
58
|
-
(function (CloudHsmClusterNotFoundException) {
|
|
59
|
-
CloudHsmClusterNotFoundException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
60
|
-
})(CloudHsmClusterNotFoundException || (CloudHsmClusterNotFoundException = {}));
|
|
61
|
-
export var CloudHsmClusterNotRelatedException;
|
|
62
|
-
(function (CloudHsmClusterNotRelatedException) {
|
|
63
|
-
CloudHsmClusterNotRelatedException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
64
|
-
})(CloudHsmClusterNotRelatedException || (CloudHsmClusterNotRelatedException = {}));
|
|
65
21
|
export var ConnectCustomKeyStoreRequest;
|
|
66
22
|
(function (ConnectCustomKeyStoreRequest) {
|
|
67
23
|
ConnectCustomKeyStoreRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -70,14 +26,6 @@ export var ConnectCustomKeyStoreResponse;
|
|
|
70
26
|
(function (ConnectCustomKeyStoreResponse) {
|
|
71
27
|
ConnectCustomKeyStoreResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
72
28
|
})(ConnectCustomKeyStoreResponse || (ConnectCustomKeyStoreResponse = {}));
|
|
73
|
-
export var CustomKeyStoreInvalidStateException;
|
|
74
|
-
(function (CustomKeyStoreInvalidStateException) {
|
|
75
|
-
CustomKeyStoreInvalidStateException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
76
|
-
})(CustomKeyStoreInvalidStateException || (CustomKeyStoreInvalidStateException = {}));
|
|
77
|
-
export var CustomKeyStoreNotFoundException;
|
|
78
|
-
(function (CustomKeyStoreNotFoundException) {
|
|
79
|
-
CustomKeyStoreNotFoundException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
80
|
-
})(CustomKeyStoreNotFoundException || (CustomKeyStoreNotFoundException = {}));
|
|
81
29
|
export var ConnectionErrorCodeType;
|
|
82
30
|
(function (ConnectionErrorCodeType) {
|
|
83
31
|
ConnectionErrorCodeType["CLUSTER_NOT_FOUND"] = "CLUSTER_NOT_FOUND";
|
|
@@ -102,14 +50,6 @@ export var CreateAliasRequest;
|
|
|
102
50
|
(function (CreateAliasRequest) {
|
|
103
51
|
CreateAliasRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
104
52
|
})(CreateAliasRequest || (CreateAliasRequest = {}));
|
|
105
|
-
export var InvalidAliasNameException;
|
|
106
|
-
(function (InvalidAliasNameException) {
|
|
107
|
-
InvalidAliasNameException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
108
|
-
})(InvalidAliasNameException || (InvalidAliasNameException = {}));
|
|
109
|
-
export var LimitExceededException;
|
|
110
|
-
(function (LimitExceededException) {
|
|
111
|
-
LimitExceededException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
112
|
-
})(LimitExceededException || (LimitExceededException = {}));
|
|
113
53
|
export var CreateCustomKeyStoreRequest;
|
|
114
54
|
(function (CreateCustomKeyStoreRequest) {
|
|
115
55
|
CreateCustomKeyStoreRequest.filterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.KeyStorePassword && { KeyStorePassword: SENSITIVE_STRING }))); };
|
|
@@ -118,14 +58,6 @@ export var CreateCustomKeyStoreResponse;
|
|
|
118
58
|
(function (CreateCustomKeyStoreResponse) {
|
|
119
59
|
CreateCustomKeyStoreResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
120
60
|
})(CreateCustomKeyStoreResponse || (CreateCustomKeyStoreResponse = {}));
|
|
121
|
-
export var CustomKeyStoreNameInUseException;
|
|
122
|
-
(function (CustomKeyStoreNameInUseException) {
|
|
123
|
-
CustomKeyStoreNameInUseException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
124
|
-
})(CustomKeyStoreNameInUseException || (CustomKeyStoreNameInUseException = {}));
|
|
125
|
-
export var IncorrectTrustAnchorException;
|
|
126
|
-
(function (IncorrectTrustAnchorException) {
|
|
127
|
-
IncorrectTrustAnchorException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
128
|
-
})(IncorrectTrustAnchorException || (IncorrectTrustAnchorException = {}));
|
|
129
61
|
export var GrantConstraints;
|
|
130
62
|
(function (GrantConstraints) {
|
|
131
63
|
GrantConstraints.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -155,14 +87,6 @@ export var CreateGrantResponse;
|
|
|
155
87
|
(function (CreateGrantResponse) {
|
|
156
88
|
CreateGrantResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
157
89
|
})(CreateGrantResponse || (CreateGrantResponse = {}));
|
|
158
|
-
export var DisabledException;
|
|
159
|
-
(function (DisabledException) {
|
|
160
|
-
DisabledException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
161
|
-
})(DisabledException || (DisabledException = {}));
|
|
162
|
-
export var InvalidGrantTokenException;
|
|
163
|
-
(function (InvalidGrantTokenException) {
|
|
164
|
-
InvalidGrantTokenException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
165
|
-
})(InvalidGrantTokenException || (InvalidGrantTokenException = {}));
|
|
166
90
|
export var CustomerMasterKeySpec;
|
|
167
91
|
(function (CustomerMasterKeySpec) {
|
|
168
92
|
CustomerMasterKeySpec["ECC_NIST_P256"] = "ECC_NIST_P256";
|
|
@@ -264,22 +188,6 @@ export var CreateKeyResponse;
|
|
|
264
188
|
(function (CreateKeyResponse) {
|
|
265
189
|
CreateKeyResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
266
190
|
})(CreateKeyResponse || (CreateKeyResponse = {}));
|
|
267
|
-
export var MalformedPolicyDocumentException;
|
|
268
|
-
(function (MalformedPolicyDocumentException) {
|
|
269
|
-
MalformedPolicyDocumentException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
270
|
-
})(MalformedPolicyDocumentException || (MalformedPolicyDocumentException = {}));
|
|
271
|
-
export var TagException;
|
|
272
|
-
(function (TagException) {
|
|
273
|
-
TagException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
274
|
-
})(TagException || (TagException = {}));
|
|
275
|
-
export var UnsupportedOperationException;
|
|
276
|
-
(function (UnsupportedOperationException) {
|
|
277
|
-
UnsupportedOperationException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
278
|
-
})(UnsupportedOperationException || (UnsupportedOperationException = {}));
|
|
279
|
-
export var CustomKeyStoreHasCMKsException;
|
|
280
|
-
(function (CustomKeyStoreHasCMKsException) {
|
|
281
|
-
CustomKeyStoreHasCMKsException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
282
|
-
})(CustomKeyStoreHasCMKsException || (CustomKeyStoreHasCMKsException = {}));
|
|
283
191
|
export var CustomKeyStoresListEntry;
|
|
284
192
|
(function (CustomKeyStoresListEntry) {
|
|
285
193
|
CustomKeyStoresListEntry.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -307,22 +215,6 @@ export var DecryptResponse;
|
|
|
307
215
|
(function (DecryptResponse) {
|
|
308
216
|
DecryptResponse.filterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.Plaintext && { Plaintext: SENSITIVE_STRING }))); };
|
|
309
217
|
})(DecryptResponse || (DecryptResponse = {}));
|
|
310
|
-
export var IncorrectKeyException;
|
|
311
|
-
(function (IncorrectKeyException) {
|
|
312
|
-
IncorrectKeyException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
313
|
-
})(IncorrectKeyException || (IncorrectKeyException = {}));
|
|
314
|
-
export var InvalidCiphertextException;
|
|
315
|
-
(function (InvalidCiphertextException) {
|
|
316
|
-
InvalidCiphertextException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
317
|
-
})(InvalidCiphertextException || (InvalidCiphertextException = {}));
|
|
318
|
-
export var InvalidKeyUsageException;
|
|
319
|
-
(function (InvalidKeyUsageException) {
|
|
320
|
-
InvalidKeyUsageException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
321
|
-
})(InvalidKeyUsageException || (InvalidKeyUsageException = {}));
|
|
322
|
-
export var KeyUnavailableException;
|
|
323
|
-
(function (KeyUnavailableException) {
|
|
324
|
-
KeyUnavailableException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
325
|
-
})(KeyUnavailableException || (KeyUnavailableException = {}));
|
|
326
218
|
export var DeleteAliasRequest;
|
|
327
219
|
(function (DeleteAliasRequest) {
|
|
328
220
|
DeleteAliasRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -347,10 +239,6 @@ export var DescribeCustomKeyStoresResponse;
|
|
|
347
239
|
(function (DescribeCustomKeyStoresResponse) {
|
|
348
240
|
DescribeCustomKeyStoresResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
349
241
|
})(DescribeCustomKeyStoresResponse || (DescribeCustomKeyStoresResponse = {}));
|
|
350
|
-
export var InvalidMarkerException;
|
|
351
|
-
(function (InvalidMarkerException) {
|
|
352
|
-
InvalidMarkerException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
353
|
-
})(InvalidMarkerException || (InvalidMarkerException = {}));
|
|
354
242
|
export var DescribeKeyRequest;
|
|
355
243
|
(function (DescribeKeyRequest) {
|
|
356
244
|
DescribeKeyRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -391,10 +279,6 @@ export var EncryptResponse;
|
|
|
391
279
|
(function (EncryptResponse) {
|
|
392
280
|
EncryptResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
393
281
|
})(EncryptResponse || (EncryptResponse = {}));
|
|
394
|
-
export var ExpiredImportTokenException;
|
|
395
|
-
(function (ExpiredImportTokenException) {
|
|
396
|
-
ExpiredImportTokenException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
397
|
-
})(ExpiredImportTokenException || (ExpiredImportTokenException = {}));
|
|
398
282
|
export var GenerateDataKeyRequest;
|
|
399
283
|
(function (GenerateDataKeyRequest) {
|
|
400
284
|
GenerateDataKeyRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -483,26 +367,10 @@ export var ImportKeyMaterialResponse;
|
|
|
483
367
|
(function (ImportKeyMaterialResponse) {
|
|
484
368
|
ImportKeyMaterialResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
485
369
|
})(ImportKeyMaterialResponse || (ImportKeyMaterialResponse = {}));
|
|
486
|
-
export var IncorrectKeyMaterialException;
|
|
487
|
-
(function (IncorrectKeyMaterialException) {
|
|
488
|
-
IncorrectKeyMaterialException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
489
|
-
})(IncorrectKeyMaterialException || (IncorrectKeyMaterialException = {}));
|
|
490
|
-
export var InvalidImportTokenException;
|
|
491
|
-
(function (InvalidImportTokenException) {
|
|
492
|
-
InvalidImportTokenException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
493
|
-
})(InvalidImportTokenException || (InvalidImportTokenException = {}));
|
|
494
|
-
export var InvalidGrantIdException;
|
|
495
|
-
(function (InvalidGrantIdException) {
|
|
496
|
-
InvalidGrantIdException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
497
|
-
})(InvalidGrantIdException || (InvalidGrantIdException = {}));
|
|
498
370
|
export var KeyListEntry;
|
|
499
371
|
(function (KeyListEntry) {
|
|
500
372
|
KeyListEntry.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
501
373
|
})(KeyListEntry || (KeyListEntry = {}));
|
|
502
|
-
export var KMSInvalidSignatureException;
|
|
503
|
-
(function (KMSInvalidSignatureException) {
|
|
504
|
-
KMSInvalidSignatureException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
505
|
-
})(KMSInvalidSignatureException || (KMSInvalidSignatureException = {}));
|
|
506
374
|
export var ListAliasesRequest;
|
|
507
375
|
(function (ListAliasesRequest) {
|
|
508
376
|
ListAliasesRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { __assign } from "tslib";
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import packageInfo from "../package.json";
|
|
3
3
|
import { Sha256 } from "@aws-crypto/sha256-browser";
|
|
4
4
|
import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
|
|
5
|
-
import { FetchHttpHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
5
|
+
import { FetchHttpHandler as RequestHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
6
6
|
import { invalidProvider } from "@aws-sdk/invalid-dependency";
|
|
7
7
|
import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/middleware-retry";
|
|
8
8
|
import { fromBase64, toBase64 } from "@aws-sdk/util-base64-browser";
|
|
@@ -10,8 +10,17 @@ import { calculateBodyLength } from "@aws-sdk/util-body-length-browser";
|
|
|
10
10
|
import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
|
|
11
11
|
import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
|
|
12
12
|
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
13
|
+
import { loadConfigsForDefaultMode } from "@aws-sdk/smithy-client";
|
|
14
|
+
import { resolveDefaultsModeConfig } from "@aws-sdk/util-defaults-mode-browser";
|
|
13
15
|
export var getRuntimeConfig = function (config) {
|
|
14
16
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
17
|
+
var defaultsMode = resolveDefaultsModeConfig(config);
|
|
18
|
+
var defaultConfigProvider = function () { return defaultsMode().then(loadConfigsForDefaultMode); };
|
|
15
19
|
var clientSharedValues = getSharedRuntimeConfig(config);
|
|
16
|
-
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new
|
|
20
|
+
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", defaultsMode: defaultsMode, base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new RequestHandler(defaultConfigProvider), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (function () { return __awaiter(void 0, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
switch (_a.label) {
|
|
22
|
+
case 0: return [4, defaultConfigProvider()];
|
|
23
|
+
case 1: return [2, (_a.sent()).retryMode || DEFAULT_RETRY_MODE];
|
|
24
|
+
}
|
|
25
|
+
}); }); }), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Sha256, streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (function () { return Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT); }), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : (function () { return Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT); }), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
|
|
17
26
|
};
|
package/dist-es/runtimeConfig.js
CHANGED
|
@@ -1,21 +1,28 @@
|
|
|
1
|
-
import { __assign } from "tslib";
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import packageInfo from "../package.json";
|
|
3
3
|
import { decorateDefaultCredentialProvider } from "@aws-sdk/client-sts";
|
|
4
4
|
import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, } from "@aws-sdk/config-resolver";
|
|
5
5
|
import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
|
|
6
6
|
import { Hash } from "@aws-sdk/hash-node";
|
|
7
|
-
import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@aws-sdk/middleware-retry";
|
|
7
|
+
import { DEFAULT_RETRY_MODE, NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS, } from "@aws-sdk/middleware-retry";
|
|
8
8
|
import { loadConfig as loadNodeConfig } from "@aws-sdk/node-config-provider";
|
|
9
|
-
import { NodeHttpHandler, streamCollector } from "@aws-sdk/node-http-handler";
|
|
9
|
+
import { NodeHttpHandler as RequestHandler, streamCollector } from "@aws-sdk/node-http-handler";
|
|
10
10
|
import { fromBase64, toBase64 } from "@aws-sdk/util-base64-node";
|
|
11
11
|
import { calculateBodyLength } from "@aws-sdk/util-body-length-node";
|
|
12
12
|
import { defaultUserAgent } from "@aws-sdk/util-user-agent-node";
|
|
13
13
|
import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
|
|
14
14
|
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
15
|
-
import {
|
|
15
|
+
import { loadConfigsForDefaultMode } from "@aws-sdk/smithy-client";
|
|
16
|
+
import { resolveDefaultsModeConfig } from "@aws-sdk/util-defaults-mode-node";
|
|
16
17
|
export var getRuntimeConfig = function (config) {
|
|
17
18
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
18
|
-
|
|
19
|
+
var defaultsMode = resolveDefaultsModeConfig(config);
|
|
20
|
+
var defaultConfigProvider = function () { return defaultsMode().then(loadConfigsForDefaultMode); };
|
|
19
21
|
var clientSharedValues = getSharedRuntimeConfig(config);
|
|
20
|
-
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new
|
|
22
|
+
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", defaultsMode: defaultsMode, base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new RequestHandler(defaultConfigProvider), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : loadNodeConfig(__assign(__assign({}, NODE_RETRY_MODE_CONFIG_OPTIONS), { default: function () { return __awaiter(void 0, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
23
|
+
switch (_a.label) {
|
|
24
|
+
case 0: return [4, defaultConfigProvider()];
|
|
25
|
+
case 1: return [2, (_a.sent()).retryMode || DEFAULT_RETRY_MODE];
|
|
26
|
+
}
|
|
27
|
+
}); }); } })), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Hash.bind(null, "sha256"), streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
|
|
21
28
|
};
|
|
@@ -4,7 +4,7 @@ import { RetryInputConfig, RetryResolvedConfig } from "@aws-sdk/middleware-retry
|
|
|
4
4
|
import { AwsAuthInputConfig, AwsAuthResolvedConfig } from "@aws-sdk/middleware-signing";
|
|
5
5
|
import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
|
|
6
6
|
import { HttpHandler as __HttpHandler } from "@aws-sdk/protocol-http";
|
|
7
|
-
import { Client as __Client, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@aws-sdk/smithy-client";
|
|
7
|
+
import { Client as __Client, DefaultsMode, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@aws-sdk/smithy-client";
|
|
8
8
|
import { Credentials as __Credentials, Decoder as __Decoder, Encoder as __Encoder, HashConstructor as __HashConstructor, HttpHandlerOptions as __HttpHandlerOptions, Logger as __Logger, Provider as __Provider, Provider, RegionInfoProvider, StreamCollector as __StreamCollector, UrlParser as __UrlParser, UserAgent as __UserAgent } from "@aws-sdk/types";
|
|
9
9
|
import { CancelKeyDeletionCommandInput, CancelKeyDeletionCommandOutput } from "./commands/CancelKeyDeletionCommand";
|
|
10
10
|
import { ConnectCustomKeyStoreCommandInput, ConnectCustomKeyStoreCommandOutput } from "./commands/ConnectCustomKeyStoreCommand";
|
|
@@ -156,6 +156,10 @@ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__
|
|
|
156
156
|
* @internal
|
|
157
157
|
*/
|
|
158
158
|
defaultUserAgentProvider?: Provider<__UserAgent>;
|
|
159
|
+
/**
|
|
160
|
+
* The {@link DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK.
|
|
161
|
+
*/
|
|
162
|
+
defaultsMode?: DefaultsMode | Provider<DefaultsMode>;
|
|
159
163
|
}
|
|
160
164
|
declare type KMSClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & RegionInputConfig & EndpointsInputConfig & RetryInputConfig & HostHeaderInputConfig & AwsAuthInputConfig & UserAgentInputConfig;
|
|
161
165
|
/**
|