@farukada/aws-langgraph-dynamodb-ts 0.7.0 → 0.8.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.
Files changed (169) hide show
  1. package/README.md +52 -9
  2. package/dist/checkpointer/actions/delete-thread.d.ts +3 -4
  3. package/dist/checkpointer/actions/delete-thread.d.ts.map +1 -1
  4. package/dist/checkpointer/actions/delete-thread.js +21 -41
  5. package/dist/checkpointer/actions/delete-thread.js.map +1 -1
  6. package/dist/checkpointer/actions/list.d.ts.map +1 -1
  7. package/dist/checkpointer/actions/list.js +31 -4
  8. package/dist/checkpointer/actions/list.js.map +1 -1
  9. package/dist/checkpointer/actions/put-writes.d.ts.map +1 -1
  10. package/dist/checkpointer/actions/put-writes.js +14 -24
  11. package/dist/checkpointer/actions/put-writes.js.map +1 -1
  12. package/dist/checkpointer/internal/item-reader.d.ts +31 -0
  13. package/dist/checkpointer/internal/item-reader.d.ts.map +1 -1
  14. package/dist/checkpointer/internal/item-reader.js +49 -1
  15. package/dist/checkpointer/internal/item-reader.js.map +1 -1
  16. package/dist/checkpointer/internal/item-writer.d.ts +0 -8
  17. package/dist/checkpointer/internal/item-writer.d.ts.map +1 -1
  18. package/dist/checkpointer/internal/item-writer.js +15 -21
  19. package/dist/checkpointer/internal/item-writer.js.map +1 -1
  20. package/dist/checkpointer/internal/keys.d.ts +19 -3
  21. package/dist/checkpointer/internal/keys.d.ts.map +1 -1
  22. package/dist/checkpointer/internal/keys.js +41 -6
  23. package/dist/checkpointer/internal/keys.js.map +1 -1
  24. package/dist/checkpointer/internal/validation.d.ts +8 -4
  25. package/dist/checkpointer/internal/validation.d.ts.map +1 -1
  26. package/dist/checkpointer/internal/validation.js +12 -10
  27. package/dist/checkpointer/internal/validation.js.map +1 -1
  28. package/dist/checkpointer/internal/write-guard.d.ts +21 -0
  29. package/dist/checkpointer/internal/write-guard.d.ts.map +1 -0
  30. package/dist/checkpointer/internal/write-guard.js +48 -0
  31. package/dist/checkpointer/internal/write-guard.js.map +1 -0
  32. package/dist/checkpointer/internal/write-index.d.ts +29 -0
  33. package/dist/checkpointer/internal/write-index.d.ts.map +1 -0
  34. package/dist/checkpointer/internal/write-index.js +38 -0
  35. package/dist/checkpointer/internal/write-index.js.map +1 -0
  36. package/dist/checkpointer/types.d.ts +2 -0
  37. package/dist/checkpointer/types.d.ts.map +1 -1
  38. package/dist/history/actions/add-messages.d.ts.map +1 -1
  39. package/dist/history/actions/add-messages.js +24 -4
  40. package/dist/history/actions/add-messages.js.map +1 -1
  41. package/dist/history/actions/clear.d.ts +4 -6
  42. package/dist/history/actions/clear.d.ts.map +1 -1
  43. package/dist/history/actions/clear.js +18 -33
  44. package/dist/history/actions/clear.js.map +1 -1
  45. package/dist/history/actions/get-messages.d.ts +2 -1
  46. package/dist/history/actions/get-messages.d.ts.map +1 -1
  47. package/dist/history/actions/get-messages.js +28 -2
  48. package/dist/history/actions/get-messages.js.map +1 -1
  49. package/dist/history/actions/list-sessions.d.ts +2 -1
  50. package/dist/history/actions/list-sessions.d.ts.map +1 -1
  51. package/dist/history/actions/list-sessions.js +21 -2
  52. package/dist/history/actions/list-sessions.js.map +1 -1
  53. package/dist/history/actions/reconcile-count.d.ts.map +1 -1
  54. package/dist/history/actions/reconcile-count.js +2 -2
  55. package/dist/history/actions/reconcile-count.js.map +1 -1
  56. package/dist/history/internal/append-saga.d.ts.map +1 -1
  57. package/dist/history/internal/append-saga.js +2 -78
  58. package/dist/history/internal/append-saga.js.map +1 -1
  59. package/dist/history/internal/compensation.d.ts +21 -0
  60. package/dist/history/internal/compensation.d.ts.map +1 -0
  61. package/dist/history/internal/compensation.js +84 -0
  62. package/dist/history/internal/compensation.js.map +1 -0
  63. package/dist/history/internal/keys.d.ts +9 -1
  64. package/dist/history/internal/keys.d.ts.map +1 -1
  65. package/dist/history/internal/keys.js +21 -4
  66. package/dist/history/internal/keys.js.map +1 -1
  67. package/dist/history/internal/message-chunker.d.ts.map +1 -1
  68. package/dist/history/internal/message-chunker.js +13 -5
  69. package/dist/history/internal/message-chunker.js.map +1 -1
  70. package/dist/history/internal/session-count.d.ts +21 -0
  71. package/dist/history/internal/session-count.d.ts.map +1 -1
  72. package/dist/history/internal/session-count.js +51 -0
  73. package/dist/history/internal/session-count.js.map +1 -1
  74. package/dist/history/internal/session-title.d.ts +20 -0
  75. package/dist/history/internal/session-title.d.ts.map +1 -0
  76. package/dist/history/internal/session-title.js +44 -0
  77. package/dist/history/internal/session-title.js.map +1 -0
  78. package/dist/history/internal/setup.d.ts +2 -1
  79. package/dist/history/internal/setup.d.ts.map +1 -1
  80. package/dist/history/internal/setup.js +1 -0
  81. package/dist/history/internal/setup.js.map +1 -1
  82. package/dist/history/internal/title-generator.d.ts +8 -2
  83. package/dist/history/internal/title-generator.d.ts.map +1 -1
  84. package/dist/history/internal/title-generator.js +12 -3
  85. package/dist/history/internal/title-generator.js.map +1 -1
  86. package/dist/history/internal/validation.d.ts +9 -0
  87. package/dist/history/internal/validation.d.ts.map +1 -0
  88. package/dist/history/internal/validation.js +16 -0
  89. package/dist/history/internal/validation.js.map +1 -0
  90. package/dist/history/types.d.ts +12 -0
  91. package/dist/history/types.d.ts.map +1 -1
  92. package/dist/index.d.ts +1 -1
  93. package/dist/index.d.ts.map +1 -1
  94. package/dist/index.js.map +1 -1
  95. package/dist/shared/codec/s3/offloader.d.ts +7 -1
  96. package/dist/shared/codec/s3/offloader.d.ts.map +1 -1
  97. package/dist/shared/codec/s3/offloader.js +14 -1
  98. package/dist/shared/codec/s3/offloader.js.map +1 -1
  99. package/dist/shared/dynamodb/partition-delete.d.ts +33 -0
  100. package/dist/shared/dynamodb/partition-delete.d.ts.map +1 -0
  101. package/dist/shared/dynamodb/partition-delete.js +70 -0
  102. package/dist/shared/dynamodb/partition-delete.js.map +1 -0
  103. package/dist/shared/dynamodb/retry-classifier.d.ts.map +1 -1
  104. package/dist/shared/dynamodb/retry-classifier.js +9 -1
  105. package/dist/shared/dynamodb/retry-classifier.js.map +1 -1
  106. package/dist/shared/logging/redaction-walk.d.ts +23 -0
  107. package/dist/shared/logging/redaction-walk.d.ts.map +1 -0
  108. package/dist/shared/logging/redaction-walk.js +92 -0
  109. package/dist/shared/logging/redaction-walk.js.map +1 -0
  110. package/dist/shared/logging/redaction.d.ts +22 -17
  111. package/dist/shared/logging/redaction.d.ts.map +1 -1
  112. package/dist/shared/logging/redaction.js +24 -48
  113. package/dist/shared/logging/redaction.js.map +1 -1
  114. package/dist/shared/logging/secret-patterns.d.ts +41 -0
  115. package/dist/shared/logging/secret-patterns.d.ts.map +1 -0
  116. package/dist/shared/logging/secret-patterns.js +74 -0
  117. package/dist/shared/logging/secret-patterns.js.map +1 -0
  118. package/dist/shared/validation/primitives.d.ts +9 -1
  119. package/dist/shared/validation/primitives.d.ts.map +1 -1
  120. package/dist/shared/validation/primitives.js +13 -0
  121. package/dist/shared/validation/primitives.js.map +1 -1
  122. package/dist/store/actions/get.d.ts.map +1 -1
  123. package/dist/store/actions/get.js +15 -1
  124. package/dist/store/actions/get.js.map +1 -1
  125. package/dist/store/actions/list-namespaces.d.ts.map +1 -1
  126. package/dist/store/actions/list-namespaces.js +1 -0
  127. package/dist/store/actions/list-namespaces.js.map +1 -1
  128. package/dist/store/actions/put.d.ts.map +1 -1
  129. package/dist/store/actions/put.js +20 -2
  130. package/dist/store/actions/put.js.map +1 -1
  131. package/dist/store/actions/search.d.ts.map +1 -1
  132. package/dist/store/actions/search.js +4 -35
  133. package/dist/store/actions/search.js.map +1 -1
  134. package/dist/store/internal/backend-search.d.ts +5 -0
  135. package/dist/store/internal/backend-search.d.ts.map +1 -0
  136. package/dist/store/internal/backend-search.js +67 -0
  137. package/dist/store/internal/backend-search.js.map +1 -0
  138. package/dist/store/internal/filter.d.ts.map +1 -1
  139. package/dist/store/internal/filter.js +26 -5
  140. package/dist/store/internal/filter.js.map +1 -1
  141. package/dist/store/internal/index-reconcile.d.ts.map +1 -1
  142. package/dist/store/internal/index-reconcile.js +33 -3
  143. package/dist/store/internal/index-reconcile.js.map +1 -1
  144. package/dist/store/internal/keys.d.ts +1 -1
  145. package/dist/store/internal/keys.d.ts.map +1 -1
  146. package/dist/store/internal/keys.js +8 -2
  147. package/dist/store/internal/keys.js.map +1 -1
  148. package/dist/store/internal/persist.d.ts.map +1 -1
  149. package/dist/store/internal/persist.js +1 -5
  150. package/dist/store/internal/persist.js.map +1 -1
  151. package/dist/store/internal/search-filter.d.ts +4 -0
  152. package/dist/store/internal/search-filter.d.ts.map +1 -0
  153. package/dist/store/internal/search-filter.js +11 -0
  154. package/dist/store/internal/search-filter.js.map +1 -0
  155. package/dist/store/internal/setup.d.ts +11 -1
  156. package/dist/store/internal/setup.d.ts.map +1 -1
  157. package/dist/store/internal/setup.js +17 -1
  158. package/dist/store/internal/setup.js.map +1 -1
  159. package/dist/store/internal/validation.d.ts +8 -2
  160. package/dist/store/internal/validation.d.ts.map +1 -1
  161. package/dist/store/internal/validation.js +15 -6
  162. package/dist/store/internal/validation.js.map +1 -1
  163. package/dist/store/internal/write-verify.d.ts +12 -0
  164. package/dist/store/internal/write-verify.d.ts.map +1 -1
  165. package/dist/store/internal/write-verify.js +27 -0
  166. package/dist/store/internal/write-verify.js.map +1 -1
  167. package/dist/store/vector-backend.d.ts +17 -0
  168. package/dist/store/vector-backend.d.ts.map +1 -1
  169. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"retry-classifier.js","sourceRoot":"","sources":["../../../src/shared/dynamodb/retry-classifier.ts"],"names":[],"mappings":";;;;AAAA,iDAAwD;AAExD,MAAM,eAAe,GAAG,EAAE,CAAC;AAE3B;;;;GAIG;AACU,QAAA,wBAAwB,GAAsB;IACzD,wCAAwC;IACxC,qBAAqB;IACrB,sBAAsB;IACtB,qBAAqB;IACrB,oBAAoB;IACpB,8BAA8B;IAC9B,gCAAgC;IAChC,gBAAgB;IAChB,yBAAyB;IACzB,YAAY;IACZ,cAAc;IACd,WAAW;IACX,OAAO;IACP,WAAW;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AAC,CAAC,CAAC;IAClD,CAAC,CAAC;IACF,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC;IACf,OAAO,OAAO,CAAC;AACjB,CAAC;AAED,gFAAgF;AAChF,0BAAiC,KAAY,EAAE,eAAkC;IAC/E,MAAM,YAAY,GAAG,gCAAgC,CAAC,KAAK,CAAC,CAAC;IAC7D,IAAI,YAAY,KAAK,SAAS;QAAE,OAAO,YAAY,CAAC;IACpD,MAAM,OAAO,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC;IACtC,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;AACnG,CAAC"}
1
+ {"version":3,"file":"retry-classifier.js","sourceRoot":"","sources":["../../../src/shared/dynamodb/retry-classifier.ts"],"names":[],"mappings":";;;;AAAA,iDAAwD;AAExD,MAAM,eAAe,GAAG,EAAE,CAAC;AAE3B;;;;GAIG;AACU,QAAA,wBAAwB,GAAsB;IACzD,wCAAwC;IACxC,qBAAqB;IACrB,sBAAsB;IACtB,qBAAqB;IACrB,oBAAoB;IACpB,8BAA8B;IAC9B,gCAAgC;IAChC,gBAAgB;IAChB,yBAAyB;IACzB,YAAY;IACZ,cAAc;IACd,WAAW;IACX,OAAO;IACP,WAAW;IACX,iBAAiB;IACjB,cAAc;CACf,CAAC;AAEF;;;;GAIG;AACH,MAAM,8BAA8B,GAAsB;IACxD,MAAM;IACN,qBAAqB;IACrB,iBAAiB;IACjB,+BAA+B;CAChC,CAAC;AAEF;;;;GAIG;AACH,SAAS,gCAAgC,CAAC,KAAY;IACpD,MAAM,OAAO,GAAG,IAAA,qCAAsB,EAAC,KAAK,CAAC,CAAC;IAC9C,IAAI,CAAC,OAAO;QAAE,OAAO,SAAS,CAAC;IAC/B;;;;;;OAMG;IACH,OAAO,CACL,O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ACpD,MAAM,OAAO,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC;IACtC,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;AACnG,CAAC"}
@@ -0,0 +1,23 @@
1
+ /** A value that {@link redactSecrets} can recurse through. */
2
+ export type Redactable = string | number | boolean | null | undefined | Redactable[] | {
3
+ [key: string]: Redactable;
4
+ };
5
+ /** Any `Redactable` that is a non-null object — what the walk dispatches on. */
6
+ export type RedactableObject = Redactable[] | {
7
+ [key: string]: Redactable;
8
+ };
9
+ /** One step of the recursive walk, threaded into the entry helpers. */
10
+ export type Walk = (value: Redactable) => Redactable;
11
+ /** Collaborators threaded through the recursive walk. */
12
+ export interface WalkDeps {
13
+ keyPatterns: readonly string[];
14
+ valuePatterns: readonly RegExp[];
15
+ walk: Walk;
16
+ }
17
+ /**
18
+ * Dispatch one non-null object by its shape: arrays and plain objects recurse,
19
+ * binary views collapse to a label, `Date`/`RegExp` pass through by reference,
20
+ * `Set`/`Map` render as their contents, and an Error takes the path above.
21
+ */
22
+ export declare function walkObject(current: RedactableObject, deps: WalkDeps): Redactable;
23
+ //# sourceMappingURL=redaction-walk.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"redaction-walk.d.ts","sourceRoot":"","sources":["../../../src/shared/logging/redaction-walk.ts"],"names":[],"mappings":"AAEA,8DAA8D;AAC9D,MAAM,MAAM,UAAU,GACpB,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,GAAG,SAAS,GAAG,UAAU,EAAE,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAA;CAAE,CAAC;AAE9F,gFAAgF;AAChF,MAAM,MAAM,gBAAgB,GAAG,UAAU,EAAE,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAA;CAAE,CAAC;AAE5E,uEAAuE;AACvE,MAAM,MAAM,IAAI,GAAG,CAAC,KAAK,EAAE,UAAU,KAAK,UAAU,CAAC;AAErD,yDAAyD;AACzD,MAAM,WAAW,QAAQ;IACvB,WAAW,EAAE,SAAS,MAAM,EAAE,CAAC;IAC/B,aAAa,EAAE,SAAS,MAAM,EAAE,CAAC;IACjC,IAAI,EAAE,IAAI,CAAC;CACZ;AAiFD;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,gBAAgB,EAAE,IAAI,EAAE,QAAQ,GAAG,UAAU,CAShF"}
@@ -0,0 +1,92 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.walkObject = walkObject;
4
+ const secret_patterns_1 = require("./secret-patterns");
5
+ /** True when `value` is a Set, tested by tag so a cross-realm Set still matches. */
6
+ function isSetValue(value) {
7
+ return Object.prototype.toString.call(value) === '[object Set]';
8
+ }
9
+ /** True when `value` is a Map, tested by tag so a cross-realm Map still matches. */
10
+ function isMapValue(value) {
11
+ return Object.prototype.toString.call(value) === '[object Map]';
12
+ }
13
+ /** True when `value` is an Error (or subclass), tested by tag not `instanceof`. */
14
+ function isErrorValue(value) {
15
+ return Object.prototype.toString.call(value) === '[object Error]';
16
+ }
17
+ /**
18
+ * True for a value whose identity matters more than its own properties.
19
+ * `Date` and `RegExp` have none, so recursing either would yield a bare `{}`.
20
+ */
21
+ function isOpaqueValue(value) {
22
+ const tag = Object.prototype.toString.call(value);
23
+ return tag === '[object Date]' || tag === '[object RegExp]';
24
+ }
25
+ /** Rebuild entries into a plain object, redacting values at secret-looking keys. */
26
+ function redactEntries(entries, keyPatterns, walk) {
27
+ const out = {};
28
+ for (const [key, value] of entries) {
29
+ out[key] = (0, secret_patterns_1.isSecretKey)(key, keyPatterns) ? secret_patterns_1.REDACTED : walk(value);
30
+ }
31
+ return out;
32
+ }
33
+ /**
34
+ * A Map's entries as an object. Keys are stringified so a non-string key is
35
+ * still reported rather than dropped, and each is checked against the
36
+ * secret-key patterns exactly as a plain object's own keys are.
37
+ */
38
+ function redactMap(value, deps) {
39
+ const entries = [...value].map(([key, entry]) => [String(key), entry]);
40
+ return redactEntries(entries, deps.keyPatterns, deps.walk);
41
+ }
42
+ /**
43
+ * Rebuild an Error as a plain object carrying its redacted text alongside its
44
+ * redacted own properties. The one exception is an Error with no own
45
+ * enumerable data whose text holds no secret: it is returned by reference so
46
+ * its identity and stack trace survive, which is what keeps a caught error
47
+ * useful in a log.
48
+ *
49
+ * `cause` is copied explicitly because `new Error(msg, { cause })` defines it
50
+ * as *non-enumerable* per spec, so `Object.entries` never sees it. Without
51
+ * this the whole chain vanished on every rebuild — and the rebuild always
52
+ * fires for this library's own error types, since each attaches an enumerable
53
+ * `code`/`context`. A redacted `RetryExhaustedError` would then no longer say
54
+ * whether the underlying failure was a throttle, a validation error or a
55
+ * network fault, which is the entire reason it carries a cause. Recursing it
56
+ * through `walk` redacts the chain too, and the cycle guard handles a cause
57
+ * that points back at its own wrapper.
58
+ */
59
+ function redactError(current, entries, deps) {
60
+ const text = (0, secret_patterns_1.redactErrorText)(current, deps.valuePatterns);
61
+ if (entries.length === 0 && !text.changed)
62
+ return current;
63
+ const out = redactEntries(entries, deps.keyPatterns, deps.walk);
64
+ out.name = text.name;
65
+ out.message = text.message;
66
+ out.stack = text.stack;
67
+ if (current.cause !== undefined)
68
+ out.cause = deps.walk(current.cause);
69
+ return out;
70
+ }
71
+ /**
72
+ * Dispatch one non-null object by its shape: arrays and plain objects recurse,
73
+ * binary views collapse to a label, `Date`/`RegExp` pass through by reference,
74
+ * `Set`/`Map` render as their contents, and an Error takes the path above.
75
+ */
76
+ function walkObject(current, deps) {
77
+ if (Array.isArray(current))
78
+ return current.map(deps.walk);
79
+ if (ArrayBuffer.isView(current))
80
+ return (0, secret_patterns_1.binaryLabel)(current);
81
+ if (isOpaqueValue(current))
82
+ return current;
83
+ if (isSetValue(current))
84
+ return [...current].map(deps.walk);
85
+ if (isMapValue(current))
86
+ return redactMap(current, deps);
87
+ const entries = Object.entries(current);
88
+ if (isErrorValue(current))
89
+ return redactError(current, entries, deps);
90
+ return redactEntries(entries, deps.keyPatterns, deps.walk);
91
+ }
92
+ //# sourceMappingURL=redaction-walk.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"redaction-walk.js","sourceRoot":"","sources":["../../../src/shared/logging/redaction-walk.ts"],"names":[],"mappings":";;;AAAA,uDAAwF;AAmBxF,oFAAoF;AACpF,SAAS,UAAU,CAAC,KAAa;IAC/B,OAAO,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,cAAc,CAAC;AAClE,CAAC;AAED,oFAAoF;AACpF,SAAS,UAAU,CAAC,KAAa;IAC/B,OAAO,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,cAAc,CAAC;AAClE,CAAC;AAED,mFAAmF;AACnF,SAAS,YAAY,CAAC,KAAa;IACjC,OAAO,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,gBAAgB,CAAC;AACpE,CAAC;AAED;;;GAGG;AACH,SAAS,aAAa,CAAC,KAAa;IAClC,MAAM,GAAG,GAAG,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAClD,OAAO,GAAG,KAAK,eAAe,IAAI,GAAG,KAAK,iBAAiB,CAAC;AAC9D,CAAC;AAED,oFAAoF;AACpF,SAAS,aAAa,CACpB,OAAmD,EACnD,WAA8B,EAC9B,IAAU;IAEV,MAAM,GAAG,GAAkC,EAAE,CAAC;IAC9C,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,OAAO,EAAE,CAAC;QACnC,GAAG,CAAC,GAAG,CAAC,GAAG,IAAA,6BAAW,EAAC,GAAG,EAAE,WAAW,CAAC,CAAC,CA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AC,OAAO,CAAC;QAAE,OAAO,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC1D,IAAI,WAAW,CAAC,MAAM,CAAC,OAAO,CAAC;QAAE,OAAO,IAAA,6BAAW,EAAC,OAAO,CAAC,CAAC;IAC7D,IAAI,aAAa,CAAC,OAAO,CAAC;QAAE,OAAO,OAAO,CAAC;IAC3C,IAAI,UAAU,CAAC,OAAO,CAAC;QAAE,OAAO,CAAC,GAAG,OAAO,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC5D,IAAI,UAAU,CAAC,OAAO,CAAC;QAAE,OAAO,SAAS,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IACzD,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;IACxC,IAAI,YAAY,CAAC,OAAO,CAAC;QAAE,OAAO,WAAW,CAAC,OAAO,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC;IACtE,OAAO,aAAa,CAAC,OAAO,EAAE,IAAI,CAAC,WAAW,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;AAC7D,CAAC"}
@@ -1,26 +1,31 @@
1
1
  import type { Logger } from './logger';
2
- /** A value that {@link redactSecrets} can recurse through. */
3
- export type Redactable = string | number | boolean | null | undefined | Redactable[] | {
4
- [key: string]: Redactable;
5
- };
2
+ import { type Redactable } from './redaction-walk';
6
3
  /**
7
4
  * Recursively clone `value`, replacing any value at a secret-looking key with
8
- * `[REDACTED]`. Cycles become `[Circular]`. An Error (or subclass) with no own
9
- * enumerable properties — a bare `new Error()`, since `message`/`stack` are
10
- * non-enumerable by spec — is passed through by reference unchanged, so its
11
- * stack trace and identity survive. A subclass carrying its own enumerable
12
- * data (this library's own error types all attach `code`/`context`/payload
13
- * fields this way) is rebuilt instead: `name`/`message`/`stack` are preserved
14
- * verbatim and every other own property is redacted/recursed exactly like a
15
- * plain object — otherwise a secret buried in a caught error's own fields
16
- * would ride straight through unredacted. Does not mutate the input.
5
+ * `[REDACTED]` and any recognised secret *shape* inside a string — including an
6
+ * error's `message`/`stack` text, which key-name matching cannot reach — with
7
+ * the same marker. Cycles become `[Circular]`.
8
+ *
9
+ * An Error with no own enumerable properties whose text holds no secret is
10
+ * passed through by reference, so its identity and stack trace survive; one
11
+ * carrying own data (this library's error types all attach `code`/`context`
12
+ * this way) or a secret in its text is rebuilt instead, with `name`/`message`/
13
+ * `stack` redacted and every other own property recursed like a plain object.
14
+ * `Date`/`RegExp` keep their identity rather than collapsing to `{}`,
15
+ * `Set`/`Map` render as their contents, and binary views become a short label.
16
+ * Does not mutate the input.
17
17
  */
18
- export declare function redactSecrets(value: Redactable, patterns?: readonly string[]): Redactable;
18
+ export declare function redactSecrets(value: Redactable, patterns?: readonly string[], valuePatterns?: readonly RegExp[]): Redactable;
19
+ /** Options controlling {@link redactLogger}. */
20
+ export interface RedactLoggerOptions {
21
+ /** Additional key names (matched case-insensitively as substrings) to redact. */
22
+ extraKeys?: readonly string[];
23
+ /** Additional secret shapes to redact wherever they appear inside a string. */
24
+ extraValuePatterns?: readonly RegExp[];
25
+ }
19
26
  /**
20
27
  * Wrap a logger so object args are redacted before delegation. The message
21
28
  * string is passed through unchanged (never interpolate secrets into it).
22
29
  */
23
- export declare function redactLogger(inner: Logger, options?: {
24
- extraKeys?: readonly string[];
25
- }): Logger;
30
+ export declare function redactLogger(inner: Logger, options?: RedactLoggerOptions): Logger;
26
31
  //# sourceMappingURL=redaction.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"redaction.d.ts","sourceRoot":"","sources":["../../../src/shared/logging/redaction.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAe,MAAM,EAAE,MAAM,UAAU,CAAC;AAEpD,8DAA8D;AAC9D,MAAM,MAAM,UAAU,GACpB,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,GAAG,SAAS,GAAG,UAAU,EAAE,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAA;CAAE,CAAC;AA2B9F;;;;;;;;;;;GAWG;AACH,wBAAgB,aAAa,CAC3B,KAAK,EAAE,UAAU,EACjB,QAAQ,GAAE,SAAS,MAAM,EAAgC,GACxD,UAAU,CAwBZ;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,MAAM,EACb,OAAO,GAAE;IAAE,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAA;CAAO,GAC9C,MAAM,CAYR"}
1
+ {"version":3,"file":"redaction.d.ts","sourceRoot":"","sources":["../../../src/shared/logging/redaction.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAe,MAAM,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,KAAK,UAAU,EAAc,MAAM,kBAAkB,CAAC;AAO/D;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,aAAa,CAC3B,KAAK,EAAE,UAAU,EACjB,QAAQ,GAAE,SAAS,MAAM,EAAgC,EACzD,aAAa,GAAE,SAAS,MAAM,EAAkC,GAC/D,UAAU,CAcZ;AAED,gDAAgD;AAChD,MAAM,WAAW,mBAAmB;IAClC,iFAAiF;IACjF,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9B,+EAA+E;IAC/E,kBAAkB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CACxC;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,GAAE,mBAAwB,GAAG,MAAM,CAerF"}
@@ -2,62 +2,35 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.redactSecrets = redactSecrets;
4
4
  exports.redactLogger = redactLogger;
5
- const DEFAULT_SECRET_KEY_PATTERNS = [
6
- 'accesskey',
7
- 'secretkey',
8
- 'secret',
9
- 'sessiontoken',
10
- 'securitytoken',
11
- 'authorization',
12
- 'password',
13
- 'apikey',
14
- 'bearer',
15
- 'token',
16
- 'privatekey',
17
- ];
18
- const REDACTED = '[REDACTED]';
19
- function isSecretKey(key, patterns) {
20
- const lower = key.toLowerCase();
21
- return patterns.some((pattern) => lower.includes(pattern));
22
- }
23
- function isErrorShaped(value) {
24
- return Object.prototype.toString.call(value) === '[object Error]';
25
- }
5
+ const redaction_walk_1 = require("./redaction-walk");
6
+ const secret_patterns_1 = require("./secret-patterns");
26
7
  /**
27
8
  * Recursively clone `value`, replacing any value at a secret-looking key with
28
- * `[REDACTED]`. Cycles become `[Circular]`. An Error (or subclass) with no own
29
- * enumerable properties — a bare `new Error()`, since `message`/`stack` are
30
- * non-enumerable by spec — is passed through by reference unchanged, so its
31
- * stack trace and identity survive. A subclass carrying its own enumerable
32
- * data (this library's own error types all attach `code`/`context`/payload
33
- * fields this way) is rebuilt instead: `name`/`message`/`stack` are preserved
34
- * verbatim and every other own property is redacted/recursed exactly like a
35
- * plain object — otherwise a secret buried in a caught error's own fields
36
- * would ride straight through unredacted. Does not mutate the input.
9
+ * `[REDACTED]` and any recognised secret *shape* inside a string — including an
10
+ * error's `message`/`stack` text, which key-name matching cannot reach — with
11
+ * the same marker. Cycles become `[Circular]`.
12
+ *
13
+ * An Error with no own enumerable properties whose text holds no secret is
14
+ * passed through by reference, so its identity and stack trace survive; one
15
+ * carrying own data (this library's error types all attach `code`/`context`
16
+ * this way) or a secret in its text is rebuilt instead, with `name`/`message`/
17
+ * `stack` redacted and every other own property recursed like a plain object.
18
+ * `Date`/`RegExp` keep their identity rather than collapsing to `{}`,
19
+ * `Set`/`Map` render as their contents, and binary views become a short label.
20
+ * Does not mutate the input.
37
21
  */
38
- function redactSecrets(value, patterns = DEFAULT_SECRET_KEY_PATTERNS) {
22
+ function redactSecrets(value, patterns = secret_patterns_1.DEFAULT_SECRET_KEY_PATTERNS, valuePatterns = secret_patterns_1.DEFAULT_SECRET_VALUE_PATTERNS) {
39
23
  const seen = new WeakSet();
40
24
  const walk = (current) => {
25
+ if (typeof current === 'string')
26
+ return (0, secret_patterns_1.redactText)(current, valuePatterns);
41
27
  if (current === null || typeof current !== 'object')
42
28
  return current;
43
29
  if (seen.has(current))
44
30
  return '[Circular]';
45
31
  seen.add(current);
46
32
  try {
47
- if (Array.isArray(current))
48
- return current.map(walk);
49
- if (isErrorShaped(current) && Object.keys(current).length === 0)
50
- return current;
51
- const out = {};
52
- for (const [key, val] of Object.entries(current)) {
53
- out[key] = isSecretKey(key, patterns) ? REDACTED : walk(val);
54
- }
55
- if (isErrorShaped(current)) {
56
- out.name = current.name;
57
- out.message = current.message;
58
- out.stack = current.stack;
59
- }
60
- return out;
33
+ return (0, redaction_walk_1.walkObject)(current, { keyPatterns: patterns, valuePatterns, walk });
61
34
  }
62
35
  finally {
63
36
  seen.delete(current);
@@ -71,9 +44,12 @@ function redactSecrets(value, patterns = DEFAULT_SECRET_KEY_PATTERNS) {
71
44
  */
72
45
  function redactLogger(inner, options = {}) {
73
46
  const patterns = options.extraKeys
74
- ? [...DEFAULT_SECRET_KEY_PATTERNS, ...options.extraKeys.map((key) => key.toLowerCase())]
75
- : DEFAULT_SECRET_KEY_PATTERNS;
76
- const wrap = (args) => args.map((arg) => redactSecrets(arg, patterns));
47
+ ? [...secret_patterns_1.DEFAULT_SECRET_KEY_PATTERNS, ...options.extraKeys.map((key) => key.toLowerCase())]
48
+ : secret_patterns_1.DEFAULT_SECRET_KEY_PATTERNS;
49
+ const valuePatterns = options.extraValuePatterns
50
+ ? [...secret_patterns_1.DEFAULT_SECRET_VALUE_PATTERNS, ...options.extraValuePatterns]
51
+ : secret_patterns_1.DEFAULT_SECRET_VALUE_PATTERNS;
52
+ const wrap = (args) => args.map((arg) => redactSecrets(arg, patterns, valuePatterns));
77
53
  return {
78
54
  info: (message, ...args) => inner.info(message, ...wrap(args)),
79
55
  warn: (message, ...args) => inner.warn(message, ...wrap(args)),
@@ -1 +1 @@
1
- {"version":3,"file":"redaction.js","sourceRoot":"","sources":["../../../src/shared/logging/redaction.ts"],"names":[],"mappings":";;;;AAMA,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AAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC;KACjE,CAAC;AACJ,CAAC"}
@@ -0,0 +1,41 @@
1
+ /** Marker substituted for anything recognised as secret. */
2
+ export declare const REDACTED = "[REDACTED]";
3
+ /** Key names (matched case-insensitively as substrings) whose value is a secret. */
4
+ export declare const DEFAULT_SECRET_KEY_PATTERNS: readonly string[];
5
+ /**
6
+ * Secret shapes recognisable in free text, where key-name matching cannot
7
+ * reach: an error's `message`/`stack`, or any other string value. Deliberately
8
+ * high-confidence — each pattern describes a credential *format* rather than a
9
+ * word that merely sounds sensitive — so ordinary operational text survives
10
+ * redaction unchanged.
11
+ */
12
+ export declare const DEFAULT_SECRET_VALUE_PATTERNS: readonly RegExp[];
13
+ /** True when `key` matches any secret-key pattern. */
14
+ export declare function isSecretKey(key: string, patterns: readonly string[]): boolean;
15
+ /**
16
+ * Replace every recognised secret shape inside `value` with {@link REDACTED},
17
+ * leaving the surrounding text intact so a redacted message stays readable.
18
+ * Each pattern is rebuilt per call so a `g` flag's `lastIndex` never leaks
19
+ * between invocations.
20
+ */
21
+ export declare function redactText(value: string, patterns: readonly RegExp[]): string;
22
+ /**
23
+ * A short label for a binary view. Recursing one would explode it into a
24
+ * per-index numeric map, both unreadable and far larger than the value itself.
25
+ */
26
+ export declare function binaryLabel(value: ArrayBufferView): string;
27
+ /** An Error's redacted non-enumerable text, plus whether redaction changed it. */
28
+ export interface RedactedErrorText {
29
+ name: string;
30
+ message: string;
31
+ stack: string | undefined;
32
+ changed: boolean;
33
+ }
34
+ /**
35
+ * Redact an Error's `name`/`message`/`stack`. `changed` reports whether any
36
+ * secret was actually found, which is what decides between passing a bare
37
+ * Error through by reference (preserving its identity and stack trace) and
38
+ * rebuilding it so the secret cannot escape.
39
+ */
40
+ export declare function redactErrorText(error: Error, patterns: readonly RegExp[]): RedactedErrorText;
41
+ //# sourceMappingURL=secret-patterns.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"secret-patterns.d.ts","sourceRoot":"","sources":["../../../src/shared/logging/secret-patterns.ts"],"names":[],"mappings":"AAAA,4DAA4D;AAC5D,eAAO,MAAM,QAAQ,eAAe,CAAC;AAErC,oFAAoF;AACpF,eAAO,MAAM,2BAA2B,EAAE,SAAS,MAAM,EAYxD,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,6BAA6B,EAAE,SAAS,MAAM,EAK1D,CAAC;AAEF,sDAAsD;AACtD,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,SAAS,MAAM,EAAE,GAAG,OAAO,CAG7E;AAED;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,CAK7E;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,eAAe,GAAG,MAAM,CAE1D;AAED,kFAAkF;AAClF,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;IAC1B,OAAO,EAAE,OAAO,CAAC;CAClB;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,MAAM,EAAE,GAAG,iBAAiB,CAS5F"}
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DEFAULT_SECRET_VALUE_PATTERNS = exports.DEFAULT_SECRET_KEY_PATTERNS = exports.REDACTED = void 0;
4
+ exports.isSecretKey = isSecretKey;
5
+ exports.redactText = redactText;
6
+ exports.binaryLabel = binaryLabel;
7
+ exports.redactErrorText = redactErrorText;
8
+ /** Marker substituted for anything recognised as secret. */
9
+ exports.REDACTED = '[REDACTED]';
10
+ /** Key names (matched case-insensitively as substrings) whose value is a secret. */
11
+ exports.DEFAULT_SECRET_KEY_PATTERNS = [
12
+ 'accesskey',
13
+ 'secretkey',
14
+ 'secret',
15
+ 'sessiontoken',
16
+ 'securitytoken',
17
+ 'authorization',
18
+ 'password',
19
+ 'apikey',
20
+ 'bearer',
21
+ 'token',
22
+ 'privatekey',
23
+ ];
24
+ /**
25
+ * Secret shapes recognisable in free text, where key-name matching cannot
26
+ * reach: an error's `message`/`stack`, or any other string value. Deliberately
27
+ * high-confidence — each pattern describes a credential *format* rather than a
28
+ * word that merely sounds sensitive — so ordinary operational text survives
29
+ * redaction unchanged.
30
+ */
31
+ exports.DEFAULT_SECRET_VALUE_PATTERNS = [
32
+ /\b(?:AKIA|ASIA)[0-9A-Z]{16}\b/g,
33
+ /\bBearer\s+[A-Za-z0-9._~+/-]+=*/gi,
34
+ /\beyJ[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\b/g,
35
+ /(?:aws_)?(?:secret_access_key|secretaccesskey|password|passwd|api_?key|token)\s*[=:]\s*\S+/gi,
36
+ ];
37
+ /** True when `key` matches any secret-key pattern. */
38
+ function isSecretKey(key, patterns) {
39
+ const lower = key.toLowerCase();
40
+ return patterns.some((pattern) => lower.includes(pattern));
41
+ }
42
+ /**
43
+ * Replace every recognised secret shape inside `value` with {@link REDACTED},
44
+ * leaving the surrounding text intact so a redacted message stays readable.
45
+ * Each pattern is rebuilt per call so a `g` flag's `lastIndex` never leaks
46
+ * between invocations.
47
+ */
48
+ function redactText(value, patterns) {
49
+ return patterns.reduce((text, pattern) => text.replace(new RegExp(pattern.source, pattern.flags), exports.REDACTED), value);
50
+ }
51
+ /**
52
+ * A short label for a binary view. Recursing one would explode it into a
53
+ * per-index numeric map, both unreadable and far larger than the value itself.
54
+ */
55
+ function binaryLabel(value) {
56
+ return `[${value.constructor.name}(${value.byteLength})]`;
57
+ }
58
+ /**
59
+ * Redact an Error's `name`/`message`/`stack`. `changed` reports whether any
60
+ * secret was actually found, which is what decides between passing a bare
61
+ * Error through by reference (preserving its identity and stack trace) and
62
+ * rebuilding it so the secret cannot escape.
63
+ */
64
+ function redactErrorText(error, patterns) {
65
+ const message = redactText(error.message, patterns);
66
+ const stack = error.stack === undefined ? undefined : redactText(error.stack, patterns);
67
+ return {
68
+ name: error.name,
69
+ message,
70
+ stack,
71
+ changed: message !== error.message || stack !== error.stack,
72
+ };
73
+ }
74
+ //# sourceMappingURL=secret-patterns.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"secret-patterns.js","sourceRoot":"","sources":["../../../src/shared/logging/secret-patterns.ts"],"names":[],"mappings":";;;;;;;AAAA,4DAA4D;AAC/C,QAAA,QAAQ,GAAG,YAAY,CAAC;AAErC,oFAAoF;AACvE,QAAA,2BAA2B,GAAsB;IAC5D,WAAW;IACX,WAAW;IACX,QAAQ;IACR,cAAc;IACd,eAAe;IACf,eAAe;IACf,UAAU;IACV,QAAQ;IACR,QAAQ;IACR,OAAO;IACP,YAAY;CACb,CAAC;AAEF;;;;;;GAMG;AACU,QAAA,6BAA6B,GAAsB;IAC9D,gCAAgC;IAChC,mCAAmC;IACnC,wDAAwD;IACxD,8FAA8F;CAC/F,CAAC;AAEF,sDAAsD;AACtD,qBAA4B,GAAW,EAAE,QAA2B;IAClE,MAAM,KAAK,GAAG,GAAG,CAAC,WAAW,EAAE,CAAC;IAChC,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;AAC7D,CAAC;AAED;;;;;GAKG;AACH,oBAA2B,KAAa,EAAE,QAA2B;IACnE,OAAO,QAAQ,CAAC,MAAM,CACpB,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,QAAA,QAAQ,CAAC,EACpF,KAAK,CACN,CAAC;AACJ,CAAC;AAED;;;GAGG;AACH,qBAA4B,KAAsB;IAChD,OAAO,IAAI,KAAK,CAAC,WAAW,CAAC,IAAI,IAAI,KAAK,CAAC,UAAU,IAAI,CAAC;AAC5D,CAAC;AAUD;;;;;GAKG;AACH,yBAAgC,KAAY,EAAE,QAA2B;IACvE,MAAM,OAAO,GAAG,UAAU,CAAC,KAAK,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC;IACpD,MAAM,KAAK,GAAG,KAAK,CAAC,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,UAAU,CAAC,KAAK,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;IACxF,OAAO;QACL,IAAI,EAAE,KAAK,CAAC,IAAI;QAChB,OAAO;QACP,KAAK;QACL,OAAO,EAAE,OAAO,KAAK,KAAK,CAAC,OAAO,IAAI,KAAK,KAAK,KAAK,CAAC,KAAK;KAC5D,CAAC;AACJ,CAAC"}
@@ -1,4 +1,4 @@
1
- import type { Redactable } from '../logging/redaction';
1
+ import type { Redactable } from '../logging/redaction-walk';
2
2
  /** Throw {@link ValidationError} unless `value` is a non-empty string. */
3
3
  export declare function validateNonEmptyString(value: string, field: string): void;
4
4
  /** Throw {@link ValidationError} unless `value` is an integer within bounds. */
@@ -12,6 +12,14 @@ export declare function validateNonEmptyArray<T>(value: T[], field: string): voi
12
12
  export declare function assertNoControlChars(value: string, field: string): void;
13
13
  /** Throw {@link ValidationError} if `value` contains the reserved `separator`. */
14
14
  export declare function assertNoSeparator(value: string, separator: string, field: string): void;
15
+ /**
16
+ * Validate a caller-supplied identifier that reaches a DynamoDB key: non-empty,
17
+ * free of the reserved `separator`, and free of control characters. The last
18
+ * rule matters even though DynamoDB itself accepts control characters — an
19
+ * identifier is echoed into logs, so an unvalidated ANSI escape is a
20
+ * log/terminal-injection surface for any app that writes these values out.
21
+ */
22
+ export declare function validateIdentifier(value: string, separator: string, field: string): void;
15
23
  /** Throw {@link ValidationError} if nested-array depth exceeds `maxDepth`. */
16
24
  export declare function validateArrayMaxDepth(value: Redactable[], field: string, maxDepth: number): void;
17
25
  //# sourceMappingURL=primitives.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"primitives.d.ts","sourceRoot":"","sources":["../../../src/shared/validation/primitives.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAEvD,0EAA0E;AAC1E,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIzE;AAED,gFAAgF;AAChF,wBAAgB,eAAe,CAC7B,KAAK,EAAE,MAAM,EACb,KAAK,EAAE,MAAM,EACb,MAAM,GAAE;IAAE,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAO,GAC1C,IAAI,CAUN;AAED,yEAAyE;AACzE,wBAAgB,qBAAqB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIxE;AAaD,oFAAoF;AACpF,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIvE;AAED,kFAAkF;AAClF,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAOvF;AAED,8EAA8E;AAC9E,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,UAAU,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,CAahG"}
1
+ {"version":3,"file":"primitives.d.ts","sourceRoot":"","sources":["../../../src/shared/validation/primitives.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAE5D,0EAA0E;AAC1E,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIzE;AAED,gFAAgF;AAChF,wBAAgB,eAAe,CAC7B,KAAK,EAAE,MAAM,EACb,KAAK,EAAE,MAAM,EACb,MAAM,GAAE;IAAE,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAO,GAC1C,IAAI,CAUN;AAED,yEAAyE;AACzE,wBAAgB,qBAAqB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIxE;AAaD,oFAAoF;AACpF,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIvE;AAED,kFAAkF;AAClF,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAOvF;AAED;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAIxF;AAED,8EAA8E;AAC9E,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,UAAU,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,CAahG"}
@@ -5,6 +5,7 @@ exports.validateInteger = validateInteger;
5
5
  exports.validateNonEmptyArray = validateNonEmptyArray;
6
6
  exports.assertNoControlChars = assertNoControlChars;
7
7
  exports.assertNoSeparator = assertNoSeparator;
8
+ exports.validateIdentifier = validateIdentifier;
8
9
  exports.validateArrayMaxDepth = validateArrayMaxDepth;
9
10
  const errors_1 = require("../errors/errors");
10
11
  /** Throw {@link ValidationError} unless `value` is a non-empty string. */
@@ -53,6 +54,18 @@ function assertNoSeparator(value, separator, field) {
53
54
  throw new errors_1.ValidationError(`${field} must not contain the reserved "${separator}" separator`, field);
54
55
  }
55
56
  }
57
+ /**
58
+ * Validate a caller-supplied identifier that reaches a DynamoDB key: non-empty,
59
+ * free of the reserved `separator`, and free of control characters. The last
60
+ * rule matters even though DynamoDB itself accepts control characters — an
61
+ * identifier is echoed into logs, so an unvalidated ANSI escape is a
62
+ * log/terminal-injection surface for any app that writes these values out.
63
+ */
64
+ function validateIdentifier(value, separator, field) {
65
+ validateNonEmptyString(value, field);
66
+ assertNoSeparator(value, separator, field);
67
+ assertNoControlChars(value, field);
68
+ }
56
69
  /** Throw {@link ValidationError} if nested-array depth exceeds `maxDepth`. */
57
70
  function validateArrayMaxDepth(value, field, maxDepth) {
58
71
  const depthOf = (node, depth) => {
@@ -1 +1 @@
1
- {"version":3,"file":"primitives.js","sourceRoot":"","sources":["../../../src/shared/validation/primitives.ts"],"names":[],"mappings":";;;;;;;;AAAA,6CAAmD;AAGnD,0EAA0E;AAC1E,gCAAuC,KAAa,EAAE,KAAa;IACjE,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACpD,MAAM,IAAI,wBAAe,CAAC,GAAG,KAAK,6BAA6B,EAAE,KAAK,CAAC,CAAC;IAC1E,CAAC;AACH,CAAC;AAED,gFAAgF;AAChF,yBACE,KAAa,EACb,KAAa,EACb,MAAM,GAAmC,EAAE;IAE3C,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC;QAC1D,MAAM,IAAI,wBAAe,CAAC,GAAG,KAAK,qBAAqB,EAAE,KAAK,CAAC,CAAC;IAClE,CAAC;IACD,IAAI,MAAM,CAAC,GAAG,KAAK,SAAS,IAAI,KAAK,GAAG,MAAM,CAAC,GAAG,EAAE,CAAC;QACnD,MAAM,IAAI,wBAAe,CAAC,GAAG,KAAK,eAAe,MAAM,CAAC,GAAG,EAAE,EAAE,KAAK,C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
@@ -1 +1 @@
1
- {"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/store/actions/get.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,iCAAiC,CAAC;AAK5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAItD,kFAAkF;AAClF,wBAAsB,OAAO,CAC3B,OAAO,EAAE,YAAY,EACrB,SAAS,EAAE,MAAM,EAAE,EACnB,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC,CAYtB"}
1
+ {"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/store/actions/get.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,iCAAiC,CAAC;AAK5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAGtD,kFAAkF;AAClF,wBAAsB,OAAO,CAC3B,OAAO,EAAE,YAAY,EACrB,SAAS,EAAE,MAAM,EAAE,EACnB,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC,CA0BtB"}
@@ -16,6 +16,20 @@ async function getItem(context, namespace, key) {
16
16
  }));
17
17
  if (!result.Item)
18
18
  return null;
19
- return (0, item_mapper_1.readStoreItem)(context, result.Item);
19
+ /**
20
+ * Narrow rather than cast. A foreign row sharing this key has no
21
+ * `namespace`, and one carrying a `value` PayloadDescriptor in the same
22
+ * shape a store item uses (a checkpointer WRITE row) would otherwise decode
23
+ * cleanly and be handed back as the caller's own value.
24
+ */
25
+ const record = (0, item_mapper_1.narrowStoreRecord)(result.Item);
26
+ if (!record) {
27
+ context.logger.warn('store.get: ignored a row that is not a store item', {
28
+ partitionKey: (0, keys_1.partitionKey)(namespace),
29
+ sortKey: (0, keys_1.sortKey)(namespace, key),
30
+ });
31
+ return null;
32
+ }
33
+ return (0, item_mapper_1.readStoreItem)(context, record);
20
34
  }
21
35
  //# sourceMappingURL=get.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/store/actions/get.ts"],"names":[],"mappings":";;;AAEA,uDAAgE;AAChE,yDAAwD;AACxD,2CAAyD;AAEzD,uDAAwE;AAGxE,kFAAkF;AAC3E,KAAK,kBACV,OAAqB,EACrB,SAAmB,EACnB,GAAW;IAEX,IAAA,8BAAiB,EAAC,SAAS,CAAC,CAAC;IAC7B,IAAA,wBAAW,EAAC,GAAG,CAAC,CAAC;IACjB,MAAM,MAAM,GAAG,MAAM,IAAA,yBAAiB,EAAC,GAAG,EAAE,CAC1C,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC;QACjB,SAAS,EAAE,OAAO,CAAC,SAAS;QAC5B,GAAG,EAAE,EAAE,EAAE,EAAE,IAAA,mBAAY,EAAC,SAAS,CAAC,EAAE,EAAE,EAAE,IAAA,cAAO,EAAC,SAAS,EAAE,GAAG,CAAC,EAAE;QACjE,cAAc,EAAE,IAAI;KACrB,CAAC,CACH,CAAC;IACF,IAAI,CAAC,MAAM,CAAC,IAAI;QAAE,OAAO,IAAI,CAAC;IAC9B,OAAO,IAAA,2BAAa,EAAC,OAAO,EAAE,MAAM,CAAC,IAAuB,CAAC,CAAC;AAChE,CAAC"}
1
+ {"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/store/actions/get.ts"],"names":[],"mappings":";;;AAEA,uDAAgE;AAChE,yDAA2E;AAC3E,2CAAyD;AAEzD,uDAAwE;AAExE,kFAAkF;AAC3E,KAAK,kBACV,OAAqB,EACrB,SAAmB,EACnB,GAAW;IAEX,IAAA,8BAAiB,EAAC,SAAS,CAAC,CAAC;IAC7B,IAAA,wBAAW,EAAC,GAAG,CAAC,CAAC;IACjB,MAAM,MAAM,GAAG,MAAM,IAAA,yBAAiB,EAAC,GAAG,EAAE,CAC1C,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC;QACjB,SAAS,EAAE,OAAO,CAAC,SAAS;QAC5B,GAAG,EAAE,EAAE,EAAE,EAAE,IAAA,mBAAY,EAAC,SAAS,CAAC,EAAE,EAAE,EAAE,IAAA,cAAO,EAAC,SAAS,EAAE,GAAG,CAAC,EAAE;QACjE,cAAc,EAAE,IAAI;KACrB,CAAC,CACH,CAAC;IACF,IAAI,CAAC,MAAM,CAAC,IAAI;QAAE,OAAO,IAAI,CAAC;IAC9B;;;;;OAKG;IACH,MAAM,MAAM,GAAG,IAAA,+BAAiB,EAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IAC9C,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,mDAAmD,EAAE;YACvE,YAAY,EAAE,IAAA,mBAAY,EAAC,SAAS,CAAC;YACrC,OAAO,EAAE,IAAA,cAAO,EAAC,SAAS,EAAE,GAAG,CAAC;SACjC,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO,IAAA,2BAAa,EAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AACxC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"list-namespaces.d.ts","sourceRoot":"","sources":["../../../src/store/actions/list-namespaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAQ/E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAmBtD;;;;GAIG;AACH,wBAAsB,cAAc,CAClC,OAAO,EAAE,YAAY,EACrB,EAAE,EAAE,uBAAuB,GAC1B,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAsBrB"}
1
+ {"version":3,"file":"list-namespaces.d.ts","sourceRoot":"","sources":["../../../src/store/actions/list-namespaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAQ/E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAmBtD;;;;GAIG;AACH,wBAAsB,cAAc,CAClC,OAAO,EAAE,YAAY,EACrB,EAAE,EAAE,uBAAuB,GAC1B,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAuBrB"}
@@ -30,6 +30,7 @@ function namespaceSource(context, op) {
30
30
  */
31
31
  async function listNamespaces(context, op) {
32
32
  (0, validation_1.validatePaging)(op.offset, op.limit);
33
+ (0, validation_1.validateMaxDepth)(op.maxDepth);
33
34
  const seen = new Set();
34
35
  const namespaces = [];
35
36
  for await (const raw of namespaceSource(context, op)) {
@@ -1 +1 @@
1
- {"version":3,"file":"list-namespaces.js","sourceRoot":"","sources":["../../../src/store/actions/list-namespaces.ts"],"names":[],"mappings":";;;AAEA,6DAA+D;AAC/D,qDAA0D;AAC1D,yDAA4D;AAC5D,2CAAuD;AACvD,iEAAwF;AACxF,6CAA2D;AAE3D,uDAAwD;AAExD,SAAS,eAAe,CAAC,OAAqB,EAAE,EAA2B;IACzE,MAAM,IAAI,GAAG,IAAA,4BAAU,EAAC,EAAE,CAAC,eAAe,CAAC,CAAC;IAC5C,IAAI,IAAI,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACpB,OAAO,IAAA,wBAAa,EAAC;YACnB,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,MAAM,EAAE,IAAA,mBAAW,EAAC,OAAO,CAAC,SAAS,EAAE,IAAI,CAAC;YAC5C,QAAQ,EAAE,OAAO,CAAC,YAAY;SAC/B,CAAC,CAAC;IACL,CAAC;IACD,OAAO,IAAA,mBAAY,EAAC;QAClB,MAAM,EAAE,OAAO,CAAC,MAAM;QACtB,MAAM,EAAE,IAAA,iBAAS,EAAC,OAAO,CAAC,SAAS,CAAC;QACpC,QAAQ,EAAE,OAAO,CAAC,YAAY;KAC/B,CAAC,CAAC;AACL,CAAC;AAED;;;;GAIG;AACI,KAAK,yBACV,OAAqB,EACrB,EAA2B;IAE3B,IAAA,2BAAc,EAAC,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,KAAK,C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AC,eAAe;YAClB,CAAC,EAAE,CAAC,eAAe,CAAC,KAAK,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,IAAA,gCAAc,EAAC,SAAS,EAAE,SAAS,CAAC,CAAC,EAC9E,CAAC;YACD,SAAS;QACX,CAAC;QACD,MAAM,SAAS,GAAG,IAAA,+BAAa,EAAC,SAAS,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC;QACxD,MAAM,SAAS,GAAG,SAAS,CAAC,IAAI,CAAC,0BAAmB,CAAC,CAAC;QACtD,IAAI,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC;YAAE,SAAS;QAClC,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;QACpB,UAAU,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;IAC7B,CAAC;IACD,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,0BAAmB,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,0BAAmB,CAAC,CAAC,CAAC,CAAC;IAClG,OAAO,UAAU,CAAC,KAAK,CAAC,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,GAAG,EAAE,CAAC,KAAK,CAAC,CAAC;AAC3D,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"put.d.ts","sourceRoot":"","sources":["../../../src/store/actions/put.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAcpE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AA+DtD;;;;;;GAMG;AACH,wBAAsB,OAAO,CAAC,OAAO,EAAE,YAAY,EAAE,EAAE,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAyBpF"}
1
+ {"version":3,"file":"put.d.ts","sourceRoot":"","sources":["../../../src/store/actions/put.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAcpE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAgFtD;;;;;;GAMG;AACH,wBAAsB,OAAO,CAAC,OAAO,EAAE,YAAY,EAAE,EAAE,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAyBpF"}