cdk-lambda-subminute 2.0.286 → 2.0.288
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/.jsii +3 -3
- package/lib/cdk-lambda-subminute.js +3 -3
- package/node_modules/aws-sdk/CHANGELOG.md +16 -1
- package/node_modules/aws-sdk/README.md +1 -1
- package/node_modules/aws-sdk/apis/apprunner-2020-05-15.min.json +35 -34
- package/node_modules/aws-sdk/apis/connect-2017-08-08.min.json +310 -277
- package/node_modules/aws-sdk/apis/gamelift-2015-10-01.min.json +283 -227
- package/node_modules/aws-sdk/apis/glue-2017-03-31.min.json +359 -318
- package/node_modules/aws-sdk/apis/iotwireless-2020-11-22.min.json +1 -0
- package/node_modules/aws-sdk/apis/launch-wizard-2018-05-10.examples.json +5 -0
- package/node_modules/aws-sdk/apis/launch-wizard-2018-05-10.min.json +312 -0
- package/node_modules/aws-sdk/apis/launch-wizard-2018-05-10.paginators.json +28 -0
- package/node_modules/aws-sdk/apis/metadata.json +4 -0
- package/node_modules/aws-sdk/apis/network-firewall-2020-11-12.min.json +40 -17
- package/node_modules/aws-sdk/apis/quicksight-2018-04-01.min.json +353 -325
- package/node_modules/aws-sdk/clients/all.d.ts +1 -0
- package/node_modules/aws-sdk/clients/all.js +2 -1
- package/node_modules/aws-sdk/clients/apprunner.d.ts +5 -0
- package/node_modules/aws-sdk/clients/configservice.d.ts +1 -1
- package/node_modules/aws-sdk/clients/connect.d.ts +37 -1
- package/node_modules/aws-sdk/clients/gamelift.d.ts +33 -22
- package/node_modules/aws-sdk/clients/glue.d.ts +45 -0
- package/node_modules/aws-sdk/clients/iotwireless.d.ts +8 -4
- package/node_modules/aws-sdk/clients/launchwizard.d.ts +450 -0
- package/node_modules/aws-sdk/clients/launchwizard.js +18 -0
- package/node_modules/aws-sdk/clients/networkfirewall.d.ts +44 -11
- package/node_modules/aws-sdk/clients/quicksight.d.ts +41 -2
- package/node_modules/aws-sdk/dist/aws-sdk-core-react-native.js +2 -2
- package/node_modules/aws-sdk/dist/aws-sdk-react-native.js +48 -11
- package/node_modules/aws-sdk/dist/aws-sdk.js +600 -507
- package/node_modules/aws-sdk/dist/aws-sdk.min.js +81 -81
- package/node_modules/aws-sdk/lib/config_service_placeholders.d.ts +2 -0
- package/node_modules/aws-sdk/lib/core.js +1 -1
- package/node_modules/aws-sdk/lib/credentials/ec2_metadata_credentials.d.ts +14 -0
- package/node_modules/aws-sdk/lib/credentials/ec2_metadata_credentials.js +1 -0
- package/node_modules/aws-sdk/lib/metadata_service.d.ts +16 -1
- package/node_modules/aws-sdk/lib/metadata_service.js +36 -0
- package/node_modules/aws-sdk/package.json +1 -1
- package/package.json +3 -3
@@ -358,6 +358,7 @@ export abstract class ConfigurationServicePlaceholders {
|
|
358
358
|
bedrock?: AWS.Bedrock.Types.ClientConfiguration;
|
359
359
|
bedrockruntime?: AWS.BedrockRuntime.Types.ClientConfiguration;
|
360
360
|
datazone?: AWS.DataZone.Types.ClientConfiguration;
|
361
|
+
launchwizard?: AWS.LaunchWizard.Types.ClientConfiguration;
|
361
362
|
}
|
362
363
|
export interface ConfigurationServiceApiVersions {
|
363
364
|
acm?: AWS.ACM.Types.apiVersion;
|
@@ -718,4 +719,5 @@ export interface ConfigurationServiceApiVersions {
|
|
718
719
|
bedrock?: AWS.Bedrock.Types.apiVersion;
|
719
720
|
bedrockruntime?: AWS.BedrockRuntime.Types.apiVersion;
|
720
721
|
datazone?: AWS.DataZone.Types.apiVersion;
|
722
|
+
launchwizard?: AWS.LaunchWizard.Types.apiVersion;
|
721
723
|
}
|
@@ -28,4 +28,18 @@ interface EC2MetadataCredentialsOptions {
|
|
28
28
|
}
|
29
29
|
maxRetries?: number
|
30
30
|
logger?: Logger
|
31
|
+
/**
|
32
|
+
* Prevent IMDSv1 fallback.
|
33
|
+
*/
|
34
|
+
ec2MetadataV1Disabled?: boolean
|
35
|
+
|
36
|
+
/**
|
37
|
+
* profile name to check for IMDSv1 settings.
|
38
|
+
*/
|
39
|
+
profile?: string
|
40
|
+
|
41
|
+
/**
|
42
|
+
* optional file from which to to get config.
|
43
|
+
*/
|
44
|
+
filename?: string
|
31
45
|
}
|
@@ -20,6 +20,7 @@ require('../metadata_service');
|
|
20
20
|
* maxRetries: 10, // retry 10 times
|
21
21
|
* retryDelayOptions: { base: 200 }, // see AWS.Config for information
|
22
22
|
* logger: console // see AWS.Config for information
|
23
|
+
* ec2MetadataV1Disabled: false // whether to block IMDS v1 fallback.
|
23
24
|
* });
|
24
25
|
* ```
|
25
26
|
*
|
@@ -54,4 +54,19 @@ interface MetadataServiceOptions {
|
|
54
54
|
* A set of options to configure the retry delay on retryable errors. See AWS.Config for details.
|
55
55
|
*/
|
56
56
|
retryDelayOptions?: any
|
57
|
-
|
57
|
+
|
58
|
+
/**
|
59
|
+
* Prevent IMDSv1 fallback.
|
60
|
+
*/
|
61
|
+
ec2MetadataV1Disabled?: boolean
|
62
|
+
|
63
|
+
/**
|
64
|
+
* profile name to check for IMDSv1 settings.
|
65
|
+
*/
|
66
|
+
profile?: string
|
67
|
+
|
68
|
+
/**
|
69
|
+
* optional file from which to to get config.
|
70
|
+
*/
|
71
|
+
filename?: string
|
72
|
+
}
|
@@ -58,12 +58,18 @@ AWS.MetadataService = inherit({
|
|
58
58
|
* perform for timeout errors
|
59
59
|
* @option options retryDelayOptions [map] A set of options to configure the
|
60
60
|
* retry delay on retryable errors. See AWS.Config for details.
|
61
|
+
* @option options ec2MetadataV1Disabled [boolean] Whether to block IMDS v1 fallback.
|
62
|
+
* @option options profile [string] A profile to check for IMDSv1 fallback settings.
|
63
|
+
* @option options filename [string] Optional filename for the config file.
|
61
64
|
*/
|
62
65
|
constructor: function MetadataService(options) {
|
63
66
|
if (options && options.host) {
|
64
67
|
options.endpoint = 'http://' + options.host;
|
65
68
|
delete options.host;
|
66
69
|
}
|
70
|
+
this.profile = options && options.profile || process.env.AWS_PROFILE || AWS.util.defaultProfile;
|
71
|
+
this.ec2MetadataV1Disabled = !!(options && options.ec2MetadataV1Disabled);
|
72
|
+
this.filename = options && options.filename;
|
67
73
|
AWS.util.update(this, options);
|
68
74
|
},
|
69
75
|
|
@@ -146,6 +152,36 @@ AWS.MetadataService = inherit({
|
|
146
152
|
var self = this;
|
147
153
|
var basePath = '/latest/meta-data/iam/security-credentials/';
|
148
154
|
|
155
|
+
var isImdsV1Fallback = self.disableFetchToken
|
156
|
+
|| !(options && options.headers && options.headers['x-aws-ec2-metadata-token']);
|
157
|
+
|
158
|
+
if (isImdsV1Fallback && !(process.env.AWS_EC2_METADATA_DISABLED)) {
|
159
|
+
try {
|
160
|
+
var profiles = AWS.util.getProfilesFromSharedConfig(AWS.util.iniLoader, this.filename);
|
161
|
+
var profileSettings = profiles[this.profile] || {};
|
162
|
+
} catch (e) {
|
163
|
+
profileSettings = {};
|
164
|
+
}
|
165
|
+
|
166
|
+
if (profileSettings.ec2_metadata_v1_disabled && profileSettings.ec2_metadata_v1_disabled !== 'false') {
|
167
|
+
return cb(AWS.util.error(
|
168
|
+
new Error('AWS EC2 Metadata v1 fallback has been blocked by AWS config file profile.')
|
169
|
+
));
|
170
|
+
}
|
171
|
+
|
172
|
+
if (self.ec2MetadataV1Disabled) {
|
173
|
+
return cb(AWS.util.error(
|
174
|
+
new Error('AWS EC2 Metadata v1 fallback has been blocked by AWS.MetadataService::options.ec2MetadataV1Disabled=true.')
|
175
|
+
));
|
176
|
+
}
|
177
|
+
|
178
|
+
if (process.env.AWS_EC2_METADATA_V1_DISABLED && process.env.AWS_EC2_METADATA_V1_DISABLED !== 'false') {
|
179
|
+
return cb(AWS.util.error(
|
180
|
+
new Error('AWS EC2 Metadata v1 fallback has been blocked by process.env.AWS_EC2_METADATA_V1_DISABLED.')
|
181
|
+
));
|
182
|
+
}
|
183
|
+
}
|
184
|
+
|
149
185
|
self.request(basePath, options, function (err, roleName) {
|
150
186
|
if (err) {
|
151
187
|
self.disableFetchToken = !(err.statusCode === 401);
|
package/package.json
CHANGED
@@ -57,7 +57,7 @@
|
|
57
57
|
"jsii-pacmak": "^1.91.0",
|
58
58
|
"jsii-rosetta": "1.x",
|
59
59
|
"npm-check-updates": "^16",
|
60
|
-
"projen": "^0.76.
|
60
|
+
"projen": "^0.76.18",
|
61
61
|
"source-map-support": "^0.5.21",
|
62
62
|
"standard-version": "^9",
|
63
63
|
"ts-jest": "^27",
|
@@ -69,7 +69,7 @@
|
|
69
69
|
},
|
70
70
|
"dependencies": {
|
71
71
|
"aws-cdk-lib": "^2.95.0",
|
72
|
-
"aws-sdk": "^2.
|
72
|
+
"aws-sdk": "^2.1488.0",
|
73
73
|
"constructs": "^10.0.5"
|
74
74
|
},
|
75
75
|
"bundledDependencies": [
|
@@ -91,7 +91,7 @@
|
|
91
91
|
],
|
92
92
|
"main": "lib/index.js",
|
93
93
|
"license": "Apache-2.0",
|
94
|
-
"version": "2.0.
|
94
|
+
"version": "2.0.288",
|
95
95
|
"jest": {
|
96
96
|
"testMatch": [
|
97
97
|
"<rootDir>/src/**/__tests__/**/*.ts?(x)",
|