@cdk8s/awscdk-resolver 0.0.347 → 0.0.349

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.
Files changed (79) hide show
  1. package/.jsii +3 -3
  2. package/lib/resolve.js +1 -1
  3. package/node_modules/@aws-sdk/client-cloudformation/package.json +6 -6
  4. package/node_modules/@aws-sdk/client-sso/package.json +5 -5
  5. package/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +81 -48
  6. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsJsonRpcProtocol.js +12 -8
  7. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsRestJsonProtocol.js +12 -8
  8. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/query/AwsQueryProtocol.js +14 -10
  9. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/xml/AwsRestXmlProtocol.js +12 -15
  10. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/xml/XmlShapeSerializer.js +3 -3
  11. package/node_modules/@aws-sdk/core/package.json +1 -1
  12. package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
  13. package/node_modules/@aws-sdk/credential-provider-http/package.json +2 -2
  14. package/node_modules/@aws-sdk/credential-provider-ini/package.json +8 -8
  15. package/node_modules/@aws-sdk/credential-provider-node/package.json +7 -7
  16. package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
  17. package/node_modules/@aws-sdk/credential-provider-sso/package.json +4 -4
  18. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +3 -3
  19. package/node_modules/@aws-sdk/middleware-logger/dist-types/loggerMiddleware.d.ts +1 -1
  20. package/node_modules/@aws-sdk/middleware-logger/package.json +1 -1
  21. package/node_modules/@aws-sdk/middleware-user-agent/package.json +2 -2
  22. package/node_modules/@aws-sdk/nested-clients/package.json +5 -5
  23. package/node_modules/@aws-sdk/token-providers/package.json +3 -3
  24. package/node_modules/@aws-sdk/util-user-agent-node/package.json +2 -2
  25. package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +44 -15
  26. package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +261 -0
  27. package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +129 -39
  28. package/node_modules/@smithy/core/dist-cjs/submodules/schema/index.js +25 -0
  29. package/node_modules/@smithy/core/dist-es/submodules/cbor/SmithyRpcV2CborProtocol.js +36 -15
  30. package/node_modules/@smithy/core/dist-es/submodules/event-streams/EventStreamSerde.js +200 -0
  31. package/node_modules/@smithy/core/dist-es/submodules/event-streams/index.js +1 -0
  32. package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpBindingProtocol.js +11 -26
  33. package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +36 -0
  34. package/node_modules/@smithy/core/dist-es/submodules/protocols/RpcProtocol.js +36 -10
  35. package/node_modules/@smithy/core/dist-es/submodules/protocols/index.js +1 -0
  36. package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/NormalizedSchema.js +17 -0
  37. package/node_modules/@smithy/core/dist-types/submodules/cbor/CborCodec.d.ts +6 -2
  38. package/node_modules/@smithy/core/dist-types/submodules/cbor/SmithyRpcV2CborProtocol.d.ts +1 -0
  39. package/node_modules/@smithy/core/dist-types/submodules/cbor/parseCborBody.d.ts +1 -1
  40. package/node_modules/@smithy/core/dist-types/submodules/event-streams/EventStreamSerde.d.ts +60 -0
  41. package/node_modules/@smithy/core/dist-types/submodules/event-streams/index.d.ts +1 -0
  42. package/node_modules/@smithy/core/dist-types/submodules/protocols/HttpBindingProtocol.d.ts +1 -1
  43. package/node_modules/@smithy/core/dist-types/submodules/protocols/HttpProtocol.d.ts +39 -1
  44. package/node_modules/@smithy/core/dist-types/submodules/protocols/RpcProtocol.d.ts +1 -1
  45. package/node_modules/@smithy/core/dist-types/submodules/protocols/index.d.ts +1 -0
  46. package/node_modules/@smithy/core/dist-types/submodules/protocols/serde/FromStringShapeDeserializer.d.ts +1 -1
  47. package/node_modules/@smithy/core/dist-types/submodules/protocols/serde/HttpInterceptingShapeDeserializer.d.ts +1 -1
  48. package/node_modules/@smithy/core/dist-types/submodules/protocols/serde/HttpInterceptingShapeSerializer.d.ts +1 -1
  49. package/node_modules/@smithy/core/dist-types/submodules/protocols/serde/ToStringShapeSerializer.d.ts +1 -1
  50. package/node_modules/@smithy/core/dist-types/submodules/protocols/serde/determineTimestampFormat.d.ts +1 -1
  51. package/node_modules/@smithy/core/dist-types/submodules/schema/middleware/getSchemaSerdePlugin.d.ts +1 -1
  52. package/node_modules/@smithy/core/dist-types/submodules/schema/middleware/schemaDeserializationMiddleware.d.ts +1 -1
  53. package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/NormalizedSchema.d.ts +10 -0
  54. package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/SimpleSchema.d.ts +1 -1
  55. package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/sentinels.d.ts +1 -1
  56. package/node_modules/@smithy/core/dist-types/submodules/serde/copyDocumentWithTransform.d.ts +1 -1
  57. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/cbor/CborCodec.d.ts +5 -1
  58. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/cbor/SmithyRpcV2CborProtocol.d.ts +1 -0
  59. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/event-streams/EventStreamSerde.d.ts +60 -0
  60. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/event-streams/index.d.ts +1 -0
  61. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/HttpProtocol.d.ts +39 -1
  62. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/index.d.ts +1 -0
  63. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/serde/determineTimestampFormat.d.ts +1 -1
  64. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/NormalizedSchema.d.ts +10 -0
  65. package/node_modules/@smithy/core/event-streams.d.ts +7 -0
  66. package/node_modules/@smithy/core/event-streams.js +6 -0
  67. package/node_modules/@smithy/core/package.json +11 -1
  68. package/node_modules/@smithy/middleware-endpoint/package.json +2 -2
  69. package/node_modules/@smithy/middleware-retry/package.json +4 -4
  70. package/node_modules/@smithy/smithy-client/dist-cjs/index.js +43 -6
  71. package/node_modules/@smithy/smithy-client/dist-cjs/schemaLogFilter.js +1 -0
  72. package/node_modules/@smithy/smithy-client/dist-es/command.js +7 -4
  73. package/node_modules/@smithy/smithy-client/dist-es/schemaLogFilter.js +34 -0
  74. package/node_modules/@smithy/smithy-client/dist-types/schemaLogFilter.d.ts +9 -0
  75. package/node_modules/@smithy/smithy-client/dist-types/ts3.4/schemaLogFilter.d.ts +9 -0
  76. package/node_modules/@smithy/smithy-client/package.json +3 -3
  77. package/node_modules/@smithy/util-defaults-mode-browser/package.json +2 -2
  78. package/node_modules/@smithy/util-defaults-mode-node/package.json +2 -2
  79. package/package.json +5 -5
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/middleware-retry",
3
- "version": "4.1.19",
3
+ "version": "4.1.20",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline middleware-retry",
@@ -13,9 +13,9 @@
13
13
  "format": "prettier --config ../../prettier.config.js --ignore-path ../../.prettierignore --write \"**/*.{ts,md,json}\"",
14
14
  "extract:docs": "api-extractor run --local",
15
15
  "test": "yarn g:vitest run",
16
- "test:integration": "yarn g:vitest run -c vitest.config.integ.ts",
16
+ "test:integration": "yarn g:vitest run -c vitest.config.integ.mts",
17
17
  "test:watch": "yarn g:vitest watch",
18
- "test:integration:watch": "yarn g:vitest watch -c vitest.config.integ.ts"
18
+ "test:integration:watch": "yarn g:vitest watch -c vitest.config.integ.mts"
19
19
  },
20
20
  "main": "./dist-cjs/index.js",
21
21
  "module": "./dist-es/index.js",
@@ -36,7 +36,7 @@
36
36
  "@smithy/node-config-provider": "^4.1.4",
37
37
  "@smithy/protocol-http": "^5.1.3",
38
38
  "@smithy/service-error-classification": "^4.0.7",
39
- "@smithy/smithy-client": "^4.4.10",
39
+ "@smithy/smithy-client": "^4.5.0",
40
40
  "@smithy/types": "^4.3.2",
41
41
  "@smithy/util-middleware": "^4.0.5",
42
42
  "@smithy/util-retry": "^4.0.7",
@@ -24,7 +24,7 @@ __export(src_exports, {
24
24
  Client: () => Client,
25
25
  Command: () => Command,
26
26
  NoOpLogger: () => NoOpLogger,
27
- SENSITIVE_STRING: () => SENSITIVE_STRING,
27
+ SENSITIVE_STRING: () => SENSITIVE_STRING2,
28
28
  ServiceException: () => ServiceException,
29
29
  _json: () => _json,
30
30
  collectBody: () => import_protocols.collectBody,
@@ -106,6 +106,43 @@ var import_protocols = require("@smithy/core/protocols");
106
106
  // src/command.ts
107
107
 
108
108
  var import_types = require("@smithy/types");
109
+
110
+ // src/schemaLogFilter.ts
111
+ var import_schema = require("@smithy/core/schema");
112
+ var SENSITIVE_STRING = "***SensitiveInformation***";
113
+ function schemaLogFilter(schema, data) {
114
+ if (data == null) {
115
+ return data;
116
+ }
117
+ const ns = import_schema.NormalizedSchema.of(schema);
118
+ if (ns.getMergedTraits().sensitive) {
119
+ return SENSITIVE_STRING;
120
+ }
121
+ if (ns.isListSchema()) {
122
+ const isSensitive = !!ns.getValueSchema().getMergedTraits().sensitive;
123
+ if (isSensitive) {
124
+ return SENSITIVE_STRING;
125
+ }
126
+ } else if (ns.isMapSchema()) {
127
+ const isSensitive = !!ns.getKeySchema().getMergedTraits().sensitive || !!ns.getValueSchema().getMergedTraits().sensitive;
128
+ if (isSensitive) {
129
+ return SENSITIVE_STRING;
130
+ }
131
+ } else if (ns.isStructSchema() && typeof data === "object") {
132
+ const object = data;
133
+ const newObject = {};
134
+ for (const [member, memberNs] of ns.structIterator()) {
135
+ if (object[member] != null) {
136
+ newObject[member] = schemaLogFilter(memberNs, object[member]);
137
+ }
138
+ }
139
+ return newObject;
140
+ }
141
+ return data;
142
+ }
143
+ __name(schemaLogFilter, "schemaLogFilter");
144
+
145
+ // src/command.ts
109
146
  var Command = class {
110
147
  constructor() {
111
148
  this.middlewareStack = (0, import_middleware_stack.constructStack)();
@@ -167,8 +204,8 @@ var ClassBuilder = class {
167
204
  this._clientName = "";
168
205
  this._additionalContext = {};
169
206
  this._smithyContext = {};
170
- this._inputFilterSensitiveLog = (_) => _;
171
- this._outputFilterSensitiveLog = (_) => _;
207
+ this._inputFilterSensitiveLog = void 0;
208
+ this._outputFilterSensitiveLog = void 0;
172
209
  this._serializer = null;
173
210
  this._deserializer = null;
174
211
  }
@@ -295,8 +332,8 @@ var ClassBuilder = class {
295
332
  middlewareFn: closure._middlewareFn,
296
333
  clientName: closure._clientName,
297
334
  commandName: closure._commandName,
298
- inputFilterSensitiveLog: closure._inputFilterSensitiveLog,
299
- outputFilterSensitiveLog: closure._outputFilterSensitiveLog,
335
+ inputFilterSensitiveLog: closure._inputFilterSensitiveLog ?? (closure._operationSchema ? schemaLogFilter.bind(null, closure._operationSchema.input) : (_) => _),
336
+ outputFilterSensitiveLog: closure._outputFilterSensitiveLog ?? (closure._operationSchema ? schemaLogFilter.bind(null, closure._operationSchema.output) : (_) => _),
300
337
  smithyContext: closure._smithyContext,
301
338
  additionalContext: closure._additionalContext
302
339
  });
@@ -306,7 +343,7 @@ var ClassBuilder = class {
306
343
  };
307
344
 
308
345
  // src/constants.ts
309
- var SENSITIVE_STRING = "***SensitiveInformation***";
346
+ var SENSITIVE_STRING2 = "***SensitiveInformation***";
310
347
 
311
348
  // src/create-aggregated-client.ts
312
349
  var createAggregatedClient = /* @__PURE__ */ __name((commands, Client2) => {
@@ -0,0 +1 @@
1
+ module.exports = require("./index.js");
@@ -1,5 +1,6 @@
1
1
  import { constructStack } from "@smithy/middleware-stack";
2
2
  import { SMITHY_CONTEXT_KEY } from "@smithy/types";
3
+ import { schemaLogFilter } from "./schemaLogFilter";
3
4
  export class Command {
4
5
  constructor() {
5
6
  this.middlewareStack = constructStack();
@@ -38,8 +39,8 @@ class ClassBuilder {
38
39
  this._clientName = "";
39
40
  this._additionalContext = {};
40
41
  this._smithyContext = {};
41
- this._inputFilterSensitiveLog = (_) => _;
42
- this._outputFilterSensitiveLog = (_) => _;
42
+ this._inputFilterSensitiveLog = undefined;
43
+ this._outputFilterSensitiveLog = undefined;
43
44
  this._serializer = null;
44
45
  this._deserializer = null;
45
46
  }
@@ -110,8 +111,10 @@ class ClassBuilder {
110
111
  middlewareFn: closure._middlewareFn,
111
112
  clientName: closure._clientName,
112
113
  commandName: closure._commandName,
113
- inputFilterSensitiveLog: closure._inputFilterSensitiveLog,
114
- outputFilterSensitiveLog: closure._outputFilterSensitiveLog,
114
+ inputFilterSensitiveLog: closure._inputFilterSensitiveLog ??
115
+ (closure._operationSchema ? schemaLogFilter.bind(null, closure._operationSchema.input) : (_) => _),
116
+ outputFilterSensitiveLog: closure._outputFilterSensitiveLog ??
117
+ (closure._operationSchema ? schemaLogFilter.bind(null, closure._operationSchema.output) : (_) => _),
115
118
  smithyContext: closure._smithyContext,
116
119
  additionalContext: closure._additionalContext,
117
120
  });
@@ -0,0 +1,34 @@
1
+ import { NormalizedSchema } from "@smithy/core/schema";
2
+ const SENSITIVE_STRING = "***SensitiveInformation***";
3
+ export function schemaLogFilter(schema, data) {
4
+ if (data == null) {
5
+ return data;
6
+ }
7
+ const ns = NormalizedSchema.of(schema);
8
+ if (ns.getMergedTraits().sensitive) {
9
+ return SENSITIVE_STRING;
10
+ }
11
+ if (ns.isListSchema()) {
12
+ const isSensitive = !!ns.getValueSchema().getMergedTraits().sensitive;
13
+ if (isSensitive) {
14
+ return SENSITIVE_STRING;
15
+ }
16
+ }
17
+ else if (ns.isMapSchema()) {
18
+ const isSensitive = !!ns.getKeySchema().getMergedTraits().sensitive || !!ns.getValueSchema().getMergedTraits().sensitive;
19
+ if (isSensitive) {
20
+ return SENSITIVE_STRING;
21
+ }
22
+ }
23
+ else if (ns.isStructSchema() && typeof data === "object") {
24
+ const object = data;
25
+ const newObject = {};
26
+ for (const [member, memberNs] of ns.structIterator()) {
27
+ if (object[member] != null) {
28
+ newObject[member] = schemaLogFilter(memberNs, object[member]);
29
+ }
30
+ }
31
+ return newObject;
32
+ }
33
+ return data;
34
+ }
@@ -0,0 +1,9 @@
1
+ import type { SchemaRef } from "@smithy/types";
2
+ /**
3
+ * Redacts sensitive parts of any data object using its schema, for logging.
4
+ *
5
+ * @internal
6
+ * @param schema - with filtering traits.
7
+ * @param data - to be logged.
8
+ */
9
+ export declare function schemaLogFilter(schema: SchemaRef, data: unknown): any;
@@ -0,0 +1,9 @@
1
+ import { SchemaRef } from "@smithy/types";
2
+ /**
3
+ * Redacts sensitive parts of any data object using its schema, for logging.
4
+ *
5
+ * @internal
6
+ * @param schema - with filtering traits.
7
+ * @param data - to be logged.
8
+ */
9
+ export declare function schemaLogFilter(schema: SchemaRef, data: unknown): any;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/smithy-client",
3
- "version": "4.4.10",
3
+ "version": "4.5.0",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline smithy-client",
@@ -24,8 +24,8 @@
24
24
  },
25
25
  "license": "Apache-2.0",
26
26
  "dependencies": {
27
- "@smithy/core": "^3.8.0",
28
- "@smithy/middleware-endpoint": "^4.1.18",
27
+ "@smithy/core": "^3.9.0",
28
+ "@smithy/middleware-endpoint": "^4.1.19",
29
29
  "@smithy/middleware-stack": "^4.0.5",
30
30
  "@smithy/protocol-http": "^5.1.3",
31
31
  "@smithy/types": "^4.3.2",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/util-defaults-mode-browser",
3
- "version": "4.0.26",
3
+ "version": "4.0.27",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline util-defaults-mode-browser",
@@ -24,7 +24,7 @@
24
24
  "license": "Apache-2.0",
25
25
  "dependencies": {
26
26
  "@smithy/property-provider": "^4.0.5",
27
- "@smithy/smithy-client": "^4.4.10",
27
+ "@smithy/smithy-client": "^4.5.0",
28
28
  "@smithy/types": "^4.3.2",
29
29
  "bowser": "^2.11.0",
30
30
  "tslib": "^2.6.2"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/util-defaults-mode-node",
3
- "version": "4.0.26",
3
+ "version": "4.0.27",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline util-defaults-mode-node",
@@ -27,7 +27,7 @@
27
27
  "@smithy/credential-provider-imds": "^4.0.7",
28
28
  "@smithy/node-config-provider": "^4.1.4",
29
29
  "@smithy/property-provider": "^4.0.5",
30
- "@smithy/smithy-client": "^4.4.10",
30
+ "@smithy/smithy-client": "^4.5.0",
31
31
  "@smithy/types": "^4.3.2",
32
32
  "tslib": "^2.6.2"
33
33
  },
package/package.json CHANGED
@@ -42,17 +42,17 @@
42
42
  "organization": false
43
43
  },
44
44
  "devDependencies": {
45
- "@cdk8s/projen-common": "0.0.617",
45
+ "@cdk8s/projen-common": "0.0.618",
46
46
  "@stylistic/eslint-plugin": "^2",
47
47
  "@types/fs-extra": "^11.0.4",
48
48
  "@types/jest": "^27",
49
49
  "@types/node": "16.18.78",
50
50
  "@typescript-eslint/eslint-plugin": "^8",
51
51
  "@typescript-eslint/parser": "^8",
52
- "aws-cdk": "^2.1026.0",
52
+ "aws-cdk": "^2.1027.0",
53
53
  "aws-cdk-lib": "2.195.0",
54
54
  "cdk8s": "2.68.91",
55
- "cdk8s-cli": "^2.201.6",
55
+ "cdk8s-cli": "^2.201.8",
56
56
  "commit-and-tag-version": "^12",
57
57
  "constructs": "10.3.0",
58
58
  "eslint": "^9",
@@ -77,7 +77,7 @@
77
77
  "constructs": "^10.3.0"
78
78
  },
79
79
  "dependencies": {
80
- "@aws-sdk/client-cloudformation": "^3.873.0"
80
+ "@aws-sdk/client-cloudformation": "^3.876.0"
81
81
  },
82
82
  "bundledDependencies": [
83
83
  "@aws-sdk/client-cloudformation"
@@ -93,7 +93,7 @@
93
93
  "publishConfig": {
94
94
  "access": "public"
95
95
  },
96
- "version": "0.0.347",
96
+ "version": "0.0.349",
97
97
  "jest": {
98
98
  "coverageProvider": "v8",
99
99
  "testMatch": [