@cdklabs/cdk-construct-connect-datalake 0.0.15 → 0.0.16

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 (295) hide show
  1. package/.jsii +9 -9
  2. package/lib/index.js +1 -1
  3. package/node_modules/@aws-sdk/client-cloudformation/package.json +3 -3
  4. package/node_modules/@aws-sdk/client-connect/package.json +3 -3
  5. package/node_modules/@aws-sdk/client-glue/package.json +3 -3
  6. package/node_modules/@aws-sdk/client-lakeformation/package.json +3 -3
  7. package/node_modules/@aws-sdk/client-ram/package.json +3 -3
  8. package/node_modules/@aws-sdk/client-sts/package.json +3 -3
  9. package/node_modules/@aws-sdk/core/account-id-endpoint.d.ts +1 -3
  10. package/node_modules/@aws-sdk/core/client.d.ts +1 -3
  11. package/node_modules/@aws-sdk/core/httpAuthSchemes.d.ts +1 -3
  12. package/node_modules/@aws-sdk/core/package.json +8 -14
  13. package/node_modules/@aws-sdk/core/protocols.d.ts +1 -3
  14. package/node_modules/@aws-sdk/core/util.d.ts +1 -3
  15. package/node_modules/@aws-sdk/credential-provider-env/package.json +5 -5
  16. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/index.js +172 -1
  17. package/node_modules/@aws-sdk/credential-provider-http/package.json +8 -10
  18. package/node_modules/@aws-sdk/credential-provider-ini/package.json +13 -13
  19. package/node_modules/@aws-sdk/credential-provider-login/package.json +6 -6
  20. package/node_modules/@aws-sdk/credential-provider-node/package.json +11 -11
  21. package/node_modules/@aws-sdk/credential-provider-process/package.json +5 -5
  22. package/node_modules/@aws-sdk/credential-provider-sso/package.json +7 -7
  23. package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/index.js +58 -3
  24. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +7 -8
  25. package/node_modules/@aws-sdk/nested-clients/cognito-identity.d.ts +1 -3
  26. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +1 -1
  27. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +1 -1
  28. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +1 -1
  29. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +1 -1
  30. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +1 -1
  31. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.browser.d.ts +1 -1
  32. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.d.ts +1 -1
  33. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.native.d.ts +1 -1
  34. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.browser.d.ts +1 -1
  35. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.d.ts +1 -1
  36. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.native.d.ts +1 -1
  37. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.browser.d.ts +1 -1
  38. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.d.ts +1 -1
  39. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.native.d.ts +1 -1
  40. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.browser.d.ts +1 -1
  41. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.d.ts +1 -1
  42. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.native.d.ts +1 -1
  43. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.browser.d.ts +1 -1
  44. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.d.ts +1 -1
  45. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.native.d.ts +1 -1
  46. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.browser.d.ts +7 -1
  47. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.d.ts +7 -1
  48. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.native.d.ts +7 -1
  49. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.browser.d.ts +7 -1
  50. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.d.ts +7 -1
  51. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.native.d.ts +7 -1
  52. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.browser.d.ts +7 -1
  53. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.d.ts +7 -1
  54. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.native.d.ts +7 -1
  55. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.browser.d.ts +7 -1
  56. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.d.ts +7 -1
  57. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.native.d.ts +7 -1
  58. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.browser.d.ts +7 -1
  59. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.d.ts +7 -1
  60. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.native.d.ts +7 -1
  61. package/node_modules/@aws-sdk/nested-clients/package.json +8 -8
  62. package/node_modules/@aws-sdk/nested-clients/signin.d.ts +1 -3
  63. package/node_modules/@aws-sdk/nested-clients/sso-oidc.d.ts +1 -3
  64. package/node_modules/@aws-sdk/nested-clients/sso.d.ts +1 -3
  65. package/node_modules/@aws-sdk/nested-clients/sts.d.ts +1 -3
  66. package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +4 -4
  67. package/node_modules/@aws-sdk/token-providers/package.json +6 -6
  68. package/node_modules/@aws-sdk/types/package.json +2 -2
  69. package/node_modules/@aws-sdk/xml-builder/dist-cjs/index.js +236 -3
  70. package/node_modules/@aws-sdk/xml-builder/dist-es/xml-parser.browser.js +1 -1
  71. package/node_modules/@aws-sdk/xml-builder/dist-es/xml-parser.js +233 -43
  72. package/node_modules/@aws-sdk/xml-builder/dist-types/ts3.4/xml-parser.d.ts +1 -1
  73. package/node_modules/@aws-sdk/xml-builder/dist-types/xml-parser.d.ts +2 -1
  74. package/node_modules/@aws-sdk/xml-builder/package.json +6 -7
  75. package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.browser.js +355 -145
  76. package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.js +456 -142
  77. package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.native.js +355 -145
  78. package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +5 -2
  79. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.browser.js +30 -36
  80. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.js +54 -110
  81. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.native.js +30 -36
  82. package/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Js.js +27 -0
  83. package/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Node.js +21 -0
  84. package/node_modules/@smithy/core/dist-es/submodules/checksum/index.browser.js +7 -1
  85. package/node_modules/@smithy/core/dist-es/submodules/checksum/index.js +7 -1
  86. package/node_modules/@smithy/core/dist-es/submodules/checksum/index.native.js +7 -1
  87. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5/Md5Js.js +92 -0
  88. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5/Md5Node.js +29 -0
  89. package/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256Js.js +179 -0
  90. package/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256Node.js +59 -0
  91. package/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256WebCrypto.js +71 -0
  92. package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +4 -1
  93. package/node_modules/@smithy/core/dist-es/submodules/serde/concatBytes.js +15 -0
  94. package/node_modules/@smithy/core/dist-es/submodules/serde/index.browser.js +2 -0
  95. package/node_modules/@smithy/core/dist-es/submodules/serde/index.js +2 -0
  96. package/node_modules/@smithy/core/dist-es/submodules/serde/index.native.js +2 -0
  97. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/checksum/ChecksumStream.js +4 -0
  98. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/headStream.js +2 -1
  99. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/stream-collector.browser.js +12 -38
  100. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/stream-collector.js +18 -33
  101. package/node_modules/@smithy/core/dist-es/submodules/serde/util-utf8/toUint8Array.browser.js +3 -0
  102. package/node_modules/@smithy/core/dist-es/submodules/serde/util-utf8/toUint8Array.js +3 -0
  103. package/node_modules/@smithy/core/dist-types/submodules/checksum/crc32/Crc32Js.d.ts +13 -0
  104. package/node_modules/@smithy/core/dist-types/submodules/checksum/crc32/Crc32Node.d.ts +13 -0
  105. package/node_modules/@smithy/core/dist-types/submodules/checksum/index.browser.d.ts +7 -1
  106. package/node_modules/@smithy/core/dist-types/submodules/checksum/index.d.ts +7 -1
  107. package/node_modules/@smithy/core/dist-types/submodules/checksum/index.native.d.ts +7 -1
  108. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5/Md5Js.d.ts +19 -0
  109. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5/Md5Node.d.ts +17 -0
  110. package/node_modules/@smithy/core/dist-types/submodules/checksum/sha256/Sha256Js.d.ts +28 -0
  111. package/node_modules/@smithy/core/dist-types/submodules/checksum/sha256/Sha256Node.d.ts +13 -0
  112. package/node_modules/@smithy/core/dist-types/submodules/checksum/sha256/Sha256WebCrypto.d.ts +22 -0
  113. package/node_modules/@smithy/core/dist-types/submodules/serde/concatBytes.d.ts +6 -0
  114. package/node_modules/@smithy/core/dist-types/submodules/serde/index.browser.d.ts +2 -0
  115. package/node_modules/@smithy/core/dist-types/submodules/serde/index.d.ts +2 -0
  116. package/node_modules/@smithy/core/dist-types/submodules/serde/index.native.d.ts +2 -0
  117. package/node_modules/@smithy/core/dist-types/submodules/serde/util-stream/checksum/ChecksumStream.d.ts +9 -0
  118. package/node_modules/@smithy/core/dist-types/submodules/serde/util-stream/stream-collector.browser.d.ts +8 -2
  119. package/node_modules/@smithy/core/dist-types/submodules/serde/util-stream/stream-collector.d.ts +4 -1
  120. package/node_modules/@smithy/core/package.json +4 -3
  121. package/node_modules/@smithy/credential-provider-imds/package.json +2 -2
  122. package/node_modules/@smithy/fetch-http-handler/dist-cjs/index.js +2 -55
  123. package/node_modules/@smithy/fetch-http-handler/dist-es/index.js +2 -2
  124. package/node_modules/@smithy/fetch-http-handler/dist-types/index.d.ts +2 -2
  125. package/node_modules/@smithy/fetch-http-handler/package.json +2 -2
  126. package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +3 -51
  127. package/node_modules/@smithy/node-http-handler/dist-es/index.js +3 -3
  128. package/node_modules/@smithy/node-http-handler/dist-types/index.d.ts +3 -3
  129. package/node_modules/@smithy/node-http-handler/package.json +2 -2
  130. package/node_modules/@smithy/signature-v4/package.json +2 -2
  131. package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/README.md +3 -0
  132. package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/dist/js-yaml.js +7 -1
  133. package/node_modules/aws-lambda/node_modules/js-yaml/dist/js-yaml.min.js +1 -0
  134. package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/loader.js +6 -0
  135. package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/package.json +4 -1
  136. package/package.json +10 -10
  137. package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.browser.js +0 -869
  138. package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.native.js +0 -862
  139. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/checkUrl.js +0 -42
  140. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/fromHttp.browser.js +0 -27
  141. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/fromHttp.js +0 -71
  142. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/requestHelpers.js +0 -49
  143. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/retry-wrapper.js +0 -13
  144. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/index.browser.js +0 -2
  145. package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/fromTokenFile.js +0 -29
  146. package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/fromWebToken.js +0 -25
  147. package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-external/nodable_entities.js +0 -333
  148. package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.browser.js +0 -57
  149. package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.js +0 -44
  150. package/node_modules/@aws-sdk/xml-builder/dist-es/xml-external/nodable_entities.js +0 -332
  151. package/node_modules/@aws-sdk/xml-builder/dist-types/ts3.4/xml-external/nodable_entities.d.ts +0 -66
  152. package/node_modules/@aws-sdk/xml-builder/dist-types/xml-external/nodable_entities.d.ts +0 -65
  153. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/CHANGELOG.md +0 -827
  154. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/LICENSE +0 -21
  155. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/README.md +0 -202
  156. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxbuilder.min.js +0 -2
  157. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxbuilder.min.js.map +0 -1
  158. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxp.cjs +0 -1
  159. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxp.d.cts +0 -770
  160. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxp.min.js +0 -2
  161. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxp.min.js.map +0 -1
  162. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxparser.min.js +0 -2
  163. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxparser.min.js.map +0 -1
  164. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxvalidator.min.js +0 -2
  165. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/lib/fxvalidator.min.js.map +0 -1
  166. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/package.json +0 -93
  167. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/cli/cli.js +0 -97
  168. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/cli/man.js +0 -17
  169. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/cli/read.js +0 -43
  170. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/fxp.d.ts +0 -739
  171. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/fxp.js +0 -14
  172. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/ignoreAttributes.js +0 -18
  173. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/util.js +0 -61
  174. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/CharsSymbol.js +0 -16
  175. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/EntitiesParser.js +0 -106
  176. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/OptionsBuilder.js +0 -61
  177. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/OutputBuilders/BaseOutputBuilder.js +0 -69
  178. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/OutputBuilders/JsArrBuilder.js +0 -103
  179. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/OutputBuilders/JsMinArrBuilder.js +0 -100
  180. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/OutputBuilders/JsObjBuilder.js +0 -154
  181. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/OutputBuilders/ParserOptionsBuilder.js +0 -94
  182. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/Report.js +0 -0
  183. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/TagPath.js +0 -81
  184. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/TagPathMatcher.js +0 -13
  185. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/XMLParser.js +0 -83
  186. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/Xml2JsParser.js +0 -235
  187. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/XmlPartReader.js +0 -210
  188. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/XmlSpecialTagsReader.js +0 -111
  189. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/inputSource/BufferSource.js +0 -116
  190. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/inputSource/StringSource.js +0 -121
  191. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/EntitiesParser.js +0 -105
  192. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/booleanParser.js +0 -22
  193. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/booleanParserExt.js +0 -19
  194. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/currency.js +0 -38
  195. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/join.js +0 -13
  196. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/number.js +0 -14
  197. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/v6/valueParsers/trim.js +0 -6
  198. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/validator.js +0 -425
  199. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js +0 -6
  200. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js +0 -407
  201. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js +0 -163
  202. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js +0 -840
  203. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlparser/XMLParser.js +0 -71
  204. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlparser/node2json.js +0 -177
  205. package/node_modules/@aws-sdk/xml-builder/node_modules/fast-xml-parser/src/xmlparser/xmlNode.js +0 -40
  206. package/node_modules/@aws-sdk/xml-builder/node_modules/strnum/CHANGELOG.md +0 -51
  207. package/node_modules/@aws-sdk/xml-builder/node_modules/strnum/LICENSE +0 -21
  208. package/node_modules/@aws-sdk/xml-builder/node_modules/strnum/README.md +0 -113
  209. package/node_modules/@aws-sdk/xml-builder/node_modules/strnum/package.json +0 -36
  210. package/node_modules/@aws-sdk/xml-builder/node_modules/strnum/strnum.js +0 -171
  211. package/node_modules/@nodable/entities/README.md +0 -41
  212. package/node_modules/@nodable/entities/package.json +0 -57
  213. package/node_modules/@nodable/entities/src/EntityDecoder.js +0 -644
  214. package/node_modules/@nodable/entities/src/EntityEncoder.js +0 -194
  215. package/node_modules/@nodable/entities/src/entities.js +0 -1159
  216. package/node_modules/@nodable/entities/src/entityTries.js +0 -49
  217. package/node_modules/@nodable/entities/src/index.d.ts +0 -341
  218. package/node_modules/@nodable/entities/src/index.js +0 -29
  219. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5-js/constants.js +0 -3
  220. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5-js/md5.js +0 -168
  221. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5-js/constants.d.ts +0 -12
  222. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5-js/md5.d.ts +0 -16
  223. package/node_modules/@smithy/fetch-http-handler/dist-es/stream-collector.js +0 -53
  224. package/node_modules/@smithy/fetch-http-handler/dist-types/stream-collector.d.ts +0 -2
  225. package/node_modules/@smithy/node-http-handler/dist-es/stream-collector/collector.js +0 -8
  226. package/node_modules/@smithy/node-http-handler/dist-es/stream-collector/index.js +0 -41
  227. package/node_modules/@smithy/node-http-handler/dist-types/stream-collector/collector.d.ts +0 -5
  228. package/node_modules/@smithy/node-http-handler/dist-types/stream-collector/index.d.ts +0 -7
  229. package/node_modules/anynum/LICENSE +0 -21
  230. package/node_modules/anynum/README.md +0 -142
  231. package/node_modules/anynum/anynum.js +0 -135
  232. package/node_modules/anynum/digitTable.js +0 -116
  233. package/node_modules/anynum/package.json +0 -42
  234. package/node_modules/fast-xml-builder/CHANGELOG.md +0 -40
  235. package/node_modules/fast-xml-builder/LICENSE +0 -21
  236. package/node_modules/fast-xml-builder/README.md +0 -74
  237. package/node_modules/fast-xml-builder/lib/fxb.cjs +0 -1
  238. package/node_modules/fast-xml-builder/lib/fxb.d.cts +0 -270
  239. package/node_modules/fast-xml-builder/lib/fxb.min.js +0 -2
  240. package/node_modules/fast-xml-builder/lib/fxb.min.js.map +0 -1
  241. package/node_modules/fast-xml-builder/package.json +0 -81
  242. package/node_modules/fast-xml-builder/src/fxb.d.ts +0 -270
  243. package/node_modules/fast-xml-builder/src/fxb.js +0 -599
  244. package/node_modules/fast-xml-builder/src/ignoreAttributes.js +0 -18
  245. package/node_modules/fast-xml-builder/src/orderedJs2Xml.js +0 -359
  246. package/node_modules/fast-xml-builder/src/prettifyJs2Xml.js +0 -0
  247. package/node_modules/fast-xml-builder/src/util.js +0 -16
  248. package/node_modules/js-yaml/dist/js-yaml.min.js +0 -1
  249. package/node_modules/path-expression-matcher/LICENSE +0 -21
  250. package/node_modules/path-expression-matcher/README.md +0 -947
  251. package/node_modules/path-expression-matcher/lib/pem.cjs +0 -1
  252. package/node_modules/path-expression-matcher/lib/pem.d.cts +0 -715
  253. package/node_modules/path-expression-matcher/lib/pem.min.js +0 -2
  254. package/node_modules/path-expression-matcher/lib/pem.min.js.map +0 -1
  255. package/node_modules/path-expression-matcher/package.json +0 -79
  256. package/node_modules/path-expression-matcher/src/Expression.js +0 -232
  257. package/node_modules/path-expression-matcher/src/ExpressionSet.js +0 -225
  258. package/node_modules/path-expression-matcher/src/Matcher.js +0 -660
  259. package/node_modules/path-expression-matcher/src/index.d.ts +0 -589
  260. package/node_modules/path-expression-matcher/src/index.js +0 -29
  261. package/node_modules/xml-naming/README.md +0 -189
  262. package/node_modules/xml-naming/package.json +0 -54
  263. package/node_modules/xml-naming/src/index.d.ts +0 -74
  264. package/node_modules/xml-naming/src/index.js +0 -270
  265. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/LICENSE +0 -0
  266. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/bin/js-yaml.js +0 -0
  267. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/index.js +0 -0
  268. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/common.js +0 -0
  269. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/dumper.js +0 -0
  270. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/exception.js +0 -0
  271. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/mark.js +0 -0
  272. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/schema/core.js +0 -0
  273. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/schema/default_full.js +0 -0
  274. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/schema/default_safe.js +0 -0
  275. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/schema/failsafe.js +0 -0
  276. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/schema/json.js +0 -0
  277. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/schema.js +0 -0
  278. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/binary.js +0 -0
  279. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/bool.js +0 -0
  280. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/float.js +0 -0
  281. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/int.js +0 -0
  282. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/js/function.js +0 -0
  283. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/js/regexp.js +0 -0
  284. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/js/undefined.js +0 -0
  285. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/map.js +0 -0
  286. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/merge.js +0 -0
  287. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/null.js +0 -0
  288. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/omap.js +0 -0
  289. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/pairs.js +0 -0
  290. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/seq.js +0 -0
  291. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/set.js +0 -0
  292. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/str.js +0 -0
  293. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type/timestamp.js +0 -0
  294. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml/type.js +0 -0
  295. /package/node_modules/{js-yaml → aws-lambda/node_modules/js-yaml}/lib/js-yaml.js +0 -0
@@ -1,42 +0,0 @@
1
- const { CredentialsProviderError } = require("@smithy/core/config");
2
- const LOOPBACK_CIDR_IPv4 = "127.0.0.0/8";
3
- const LOOPBACK_CIDR_IPv6 = "::1/128";
4
- const ECS_CONTAINER_HOST = "169.254.170.2";
5
- const EKS_CONTAINER_HOST_IPv4 = "169.254.170.23";
6
- const EKS_CONTAINER_HOST_IPv6 = "[fd00:ec2::23]";
7
- exports.checkUrl = (url, logger) => {
8
- if (url.protocol === "https:") {
9
- return;
10
- }
11
- if (url.hostname === ECS_CONTAINER_HOST ||
12
- url.hostname === EKS_CONTAINER_HOST_IPv4 ||
13
- url.hostname === EKS_CONTAINER_HOST_IPv6) {
14
- return;
15
- }
16
- if (url.hostname.includes("[")) {
17
- if (url.hostname === "[::1]" || url.hostname === "[0000:0000:0000:0000:0000:0000:0000:0001]") {
18
- return;
19
- }
20
- }
21
- else {
22
- if (url.hostname === "localhost") {
23
- return;
24
- }
25
- const ipComponents = url.hostname.split(".");
26
- const inRange = (component) => {
27
- const num = parseInt(component, 10);
28
- return 0 <= num && num <= 255;
29
- };
30
- if (ipComponents[0] === "127" &&
31
- inRange(ipComponents[1]) &&
32
- inRange(ipComponents[2]) &&
33
- inRange(ipComponents[3]) &&
34
- ipComponents.length === 4) {
35
- return;
36
- }
37
- }
38
- throw new CredentialsProviderError(`URL not accepted. It must either be HTTPS or match one of the following:
39
- - loopback CIDR 127.0.0.0/8 or [::1/128]
40
- - ECS container host 169.254.170.2
41
- - EKS container host 169.254.170.23 or [fd00:ec2::23]`, { logger });
42
- };
@@ -1,27 +0,0 @@
1
- const { CredentialsProviderError } = require("@smithy/core/config");
2
- const { FetchHttpHandler } = require("@smithy/fetch-http-handler");
3
- const { checkUrl } = require("./checkUrl");
4
- const { createGetRequest, getCredentials } = require("./requestHelpers");
5
- const { retryWrapper } = require("./retry-wrapper");
6
- exports.fromHttp = (options = {}) => {
7
- options.logger?.debug("@aws-sdk/credential-provider-http - fromHttp");
8
- let host;
9
- const full = options.credentialsFullUri;
10
- if (full) {
11
- host = full;
12
- }
13
- else {
14
- throw new CredentialsProviderError("No HTTP credential provider host provided.", { logger: options.logger });
15
- }
16
- const url = new URL(host);
17
- checkUrl(url, options.logger);
18
- const requestHandler = new FetchHttpHandler();
19
- return retryWrapper(async () => {
20
- const request = createGetRequest(url);
21
- if (options.authorizationToken) {
22
- request.headers.Authorization = options.authorizationToken;
23
- }
24
- const result = await requestHandler.handle(request);
25
- return getCredentials(result.response);
26
- }, options.maxRetries ?? 3, options.timeout ?? 1000);
27
- };
@@ -1,71 +0,0 @@
1
- const { setCredentialFeature } = require("@aws-sdk/core/client");
2
- const { CredentialsProviderError } = require("@smithy/core/config");
3
- const { NodeHttpHandler } = require("@smithy/node-http-handler");
4
- const fs = require("node:fs/promises");
5
- const { checkUrl } = require("./checkUrl");
6
- const { createGetRequest, getCredentials } = require("./requestHelpers");
7
- const { retryWrapper } = require("./retry-wrapper");
8
- const AWS_CONTAINER_CREDENTIALS_RELATIVE_URI = "AWS_CONTAINER_CREDENTIALS_RELATIVE_URI";
9
- const DEFAULT_LINK_LOCAL_HOST = "http://169.254.170.2";
10
- const AWS_CONTAINER_CREDENTIALS_FULL_URI = "AWS_CONTAINER_CREDENTIALS_FULL_URI";
11
- const AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE = "AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE";
12
- const AWS_CONTAINER_AUTHORIZATION_TOKEN = "AWS_CONTAINER_AUTHORIZATION_TOKEN";
13
- exports.fromHttp = (options = {}) => {
14
- options.logger?.debug("@aws-sdk/credential-provider-http - fromHttp");
15
- let host;
16
- const relative = options.awsContainerCredentialsRelativeUri ?? process.env[AWS_CONTAINER_CREDENTIALS_RELATIVE_URI];
17
- const full = options.awsContainerCredentialsFullUri ?? process.env[AWS_CONTAINER_CREDENTIALS_FULL_URI];
18
- const token = options.awsContainerAuthorizationToken ?? process.env[AWS_CONTAINER_AUTHORIZATION_TOKEN];
19
- const tokenFile = options.awsContainerAuthorizationTokenFile ?? process.env[AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE];
20
- const warn = options.logger?.constructor?.name === "NoOpLogger" || !options.logger?.warn
21
- ? console.warn
22
- : options.logger.warn.bind(options.logger);
23
- if (relative && full) {
24
- warn("@aws-sdk/credential-provider-http: " +
25
- "you have set both awsContainerCredentialsRelativeUri and awsContainerCredentialsFullUri.");
26
- warn("awsContainerCredentialsFullUri will take precedence.");
27
- }
28
- if (token && tokenFile) {
29
- warn("@aws-sdk/credential-provider-http: " +
30
- "you have set both awsContainerAuthorizationToken and awsContainerAuthorizationTokenFile.");
31
- warn("awsContainerAuthorizationToken will take precedence.");
32
- }
33
- if (full) {
34
- host = full;
35
- }
36
- else if (relative) {
37
- host = `${DEFAULT_LINK_LOCAL_HOST}${relative}`;
38
- }
39
- else {
40
- throw new CredentialsProviderError(`No HTTP credential provider host provided.
41
- Set AWS_CONTAINER_CREDENTIALS_FULL_URI or AWS_CONTAINER_CREDENTIALS_RELATIVE_URI.`, { logger: options.logger });
42
- }
43
- const url = new URL(host);
44
- checkUrl(url, options.logger);
45
- const requestHandler = NodeHttpHandler.create({ connectionTimeout: options.timeout ?? 1000 });
46
- const requestTimeout = options.timeout ?? 1000;
47
- const provider = retryWrapper(async () => {
48
- const request = createGetRequest(url);
49
- if (token) {
50
- request.headers.Authorization = token;
51
- }
52
- else if (tokenFile) {
53
- request.headers.Authorization = (await fs.readFile(tokenFile)).toString();
54
- }
55
- try {
56
- const result = await requestHandler.handle(request, { requestTimeout });
57
- return getCredentials(result.response).then((creds) => setCredentialFeature(creds, "CREDENTIALS_HTTP", "z"));
58
- }
59
- catch (e) {
60
- throw new CredentialsProviderError(String(e), { logger: options.logger });
61
- }
62
- }, options.maxRetries ?? 3, options.timeout ?? 1000);
63
- return async () => {
64
- try {
65
- return await provider();
66
- }
67
- finally {
68
- requestHandler.destroy?.();
69
- }
70
- };
71
- };
@@ -1,49 +0,0 @@
1
- const { CredentialsProviderError } = require("@smithy/core/config");
2
- const { HttpRequest } = require("@smithy/core/protocols");
3
- const { parseRfc3339DateTime } = require("@smithy/core/serde");
4
- const { sdkStreamMixin } = require("@smithy/core/serde");
5
- exports.createGetRequest = function createGetRequest(url) {
6
- return new HttpRequest({
7
- protocol: url.protocol,
8
- hostname: url.hostname,
9
- port: Number(url.port),
10
- path: url.pathname,
11
- query: Array.from(url.searchParams.entries()).reduce((acc, [k, v]) => {
12
- acc[k] = v;
13
- return acc;
14
- }, {}),
15
- fragment: url.hash,
16
- });
17
- };
18
- exports.getCredentials = async function getCredentials(response, logger) {
19
- const stream = sdkStreamMixin(response.body);
20
- const str = await stream.transformToString();
21
- if (response.statusCode === 200) {
22
- const parsed = JSON.parse(str);
23
- if (typeof parsed.AccessKeyId !== "string" ||
24
- typeof parsed.SecretAccessKey !== "string" ||
25
- typeof parsed.Token !== "string" ||
26
- typeof parsed.Expiration !== "string") {
27
- throw new CredentialsProviderError("HTTP credential provider response not of the required format, an object matching: " +
28
- "{ AccessKeyId: string, SecretAccessKey: string, Token: string, Expiration: string(rfc3339) }", { logger });
29
- }
30
- return {
31
- accessKeyId: parsed.AccessKeyId,
32
- secretAccessKey: parsed.SecretAccessKey,
33
- sessionToken: parsed.Token,
34
- expiration: parseRfc3339DateTime(parsed.Expiration),
35
- };
36
- }
37
- if (response.statusCode >= 400 && response.statusCode < 500) {
38
- let parsedBody = {};
39
- try {
40
- parsedBody = JSON.parse(str);
41
- }
42
- catch (e) { }
43
- throw Object.assign(new CredentialsProviderError(`Server responded with status: ${response.statusCode}`, { logger }), {
44
- Code: parsedBody.Code,
45
- Message: parsedBody.Message,
46
- });
47
- }
48
- throw new CredentialsProviderError(`Server responded with status: ${response.statusCode}`, { logger });
49
- };
@@ -1,13 +0,0 @@
1
- exports.retryWrapper = (toRetry, maxRetries, delayMs) => {
2
- return async () => {
3
- for (let i = 0; i < maxRetries; ++i) {
4
- try {
5
- return await toRetry();
6
- }
7
- catch (e) {
8
- await new Promise((resolve) => setTimeout(resolve, delayMs));
9
- }
10
- }
11
- return await toRetry();
12
- };
13
- };
@@ -1,2 +0,0 @@
1
- const { fromHttp } = require("./fromHttp/fromHttp.browser");
2
- exports.fromHttp = fromHttp;
@@ -1,29 +0,0 @@
1
- const { setCredentialFeature } = require("@aws-sdk/core/client");
2
- const { CredentialsProviderError, externalDataInterceptor } = require("@smithy/core/config");
3
- const { readFileSync } = require("node:fs");
4
- const { fromWebToken } = require("./fromWebToken");
5
- const ENV_TOKEN_FILE = "AWS_WEB_IDENTITY_TOKEN_FILE";
6
- const ENV_ROLE_ARN = "AWS_ROLE_ARN";
7
- const ENV_ROLE_SESSION_NAME = "AWS_ROLE_SESSION_NAME";
8
- exports.fromTokenFile = (init = {}) => async (awsIdentityProperties) => {
9
- init.logger?.debug("@aws-sdk/credential-provider-web-identity - fromTokenFile");
10
- const webIdentityTokenFile = init?.webIdentityTokenFile ?? process.env[ENV_TOKEN_FILE];
11
- const roleArn = init?.roleArn ?? process.env[ENV_ROLE_ARN];
12
- const roleSessionName = init?.roleSessionName ?? process.env[ENV_ROLE_SESSION_NAME];
13
- if (!webIdentityTokenFile || !roleArn) {
14
- throw new CredentialsProviderError("Web identity configuration not specified", {
15
- logger: init.logger,
16
- });
17
- }
18
- const credentials = await fromWebToken({
19
- ...init,
20
- webIdentityToken: externalDataInterceptor?.getTokenRecord?.()[webIdentityTokenFile] ??
21
- readFileSync(webIdentityTokenFile, { encoding: "ascii" }),
22
- roleArn,
23
- roleSessionName,
24
- })(awsIdentityProperties);
25
- if (webIdentityTokenFile === process.env[ENV_TOKEN_FILE]) {
26
- setCredentialFeature(credentials, "CREDENTIALS_ENV_VARS_STS_WEB_ID_TOKEN", "h");
27
- }
28
- return credentials;
29
- };
@@ -1,25 +0,0 @@
1
- exports.fromWebToken = (init) => async (awsIdentityProperties) => {
2
- init.logger?.debug("@aws-sdk/credential-provider-web-identity - fromWebToken");
3
- const { roleArn, roleSessionName, webIdentityToken, providerId, policyArns, policy, durationSeconds } = init;
4
- let { roleAssumerWithWebIdentity } = init;
5
- if (!roleAssumerWithWebIdentity) {
6
- const { getDefaultRoleAssumerWithWebIdentity } = require("@aws-sdk/nested-clients/sts");
7
- roleAssumerWithWebIdentity = getDefaultRoleAssumerWithWebIdentity({
8
- ...init.clientConfig,
9
- credentialProviderLogger: init.logger,
10
- parentClientConfig: {
11
- ...awsIdentityProperties?.callerClientConfig,
12
- ...init.parentClientConfig,
13
- },
14
- }, init.clientPlugins);
15
- }
16
- return roleAssumerWithWebIdentity({
17
- RoleArn: roleArn,
18
- RoleSessionName: roleSessionName ?? `aws-sdk-js-session-${Date.now()}`,
19
- WebIdentityToken: webIdentityToken,
20
- ProviderId: providerId,
21
- PolicyArns: policyArns,
22
- Policy: policy,
23
- DurationSeconds: durationSeconds,
24
- });
25
- };
@@ -1,333 +0,0 @@
1
- const XML = {
2
- amp: "&",
3
- apos: "'",
4
- gt: ">",
5
- lt: "<",
6
- quot: '"',
7
- };
8
- exports.XML = XML;
9
- exports.COMMON_HTML = {
10
- nbsp: "\u00a0",
11
- copy: "\u00a9",
12
- reg: "\u00ae",
13
- trade: "\u2122",
14
- mdash: "\u2014",
15
- ndash: "\u2013",
16
- hellip: "\u2026",
17
- laquo: "\u00ab",
18
- raquo: "\u00bb",
19
- lsquo: "\u2018",
20
- rsquo: "\u2019",
21
- ldquo: "\u201c",
22
- rdquo: "\u201d",
23
- bull: "\u2022",
24
- para: "\u00b6",
25
- sect: "\u00a7",
26
- deg: "\u00b0",
27
- frac12: "\u00bd",
28
- frac14: "\u00bc",
29
- frac34: "\u00be",
30
- };
31
- exports.CURRENCY = {
32
- cent: "\u00a2",
33
- pound: "\u00a3",
34
- curren: "\u00a4",
35
- yen: "\u00a5",
36
- euro: "\u20ac",
37
- dollar: "$",
38
- fnof: "\u0192",
39
- inr: "\u20b9",
40
- af: "\u060b",
41
- birr: "\u1265\u122d",
42
- peso: "\u20b1",
43
- rub: "\u20bd",
44
- won: "\u20a9",
45
- yuan: "\u00a5",
46
- cedil: "\u00b8",
47
- };
48
- const SPECIAL_CHARS = new Set("!?\\/[]$%{}^&*()<>|+");
49
- function validateEntityName(name) {
50
- if (name[0] === "#") {
51
- throw new Error(`[EntityReplacer] Invalid character '#' in entity name: "${name}"`);
52
- }
53
- for (const ch of name) {
54
- if (SPECIAL_CHARS.has(ch)) {
55
- throw new Error(`[EntityReplacer] Invalid character '${ch}' in entity name: "${name}"`);
56
- }
57
- }
58
- return name;
59
- }
60
- function mergeEntityMaps(...maps) {
61
- const out = Object.create(null);
62
- for (const map of maps) {
63
- if (!map) {
64
- continue;
65
- }
66
- for (const key of Object.keys(map)) {
67
- const raw = map[key];
68
- if (typeof raw === "string") {
69
- out[key] = raw;
70
- }
71
- else if (raw && typeof raw === "object" && raw.val !== undefined) {
72
- const val = raw.val;
73
- if (typeof val === "string") {
74
- out[key] = val;
75
- }
76
- }
77
- }
78
- }
79
- return out;
80
- }
81
- const LIMIT_TIER_EXTERNAL = "external";
82
- const LIMIT_TIER_BASE = "base";
83
- const LIMIT_TIER_ALL = "all";
84
- function parseLimitTiers(raw) {
85
- if (!raw || raw === LIMIT_TIER_EXTERNAL) {
86
- return new Set([LIMIT_TIER_EXTERNAL]);
87
- }
88
- if (raw === LIMIT_TIER_ALL) {
89
- return new Set([LIMIT_TIER_ALL]);
90
- }
91
- if (raw === LIMIT_TIER_BASE) {
92
- return new Set([LIMIT_TIER_BASE]);
93
- }
94
- if (Array.isArray(raw)) {
95
- return new Set(raw);
96
- }
97
- return new Set([LIMIT_TIER_EXTERNAL]);
98
- }
99
- const NCR_LEVEL = Object.freeze({ allow: 0, leave: 1, remove: 2, throw: 3 });
100
- const XML10_ALLOWED_C0 = new Set([0x09, 0x0a, 0x0d]);
101
- function parseNCRConfig(ncr) {
102
- if (!ncr) {
103
- return { xmlVersion: 1.0, onLevel: NCR_LEVEL.allow, nullLevel: NCR_LEVEL.remove };
104
- }
105
- const xmlVersion = ncr.xmlVersion === 1.1 ? 1.1 : 1.0;
106
- const onLevel = NCR_LEVEL[ncr.onNCR ?? "allow"] ?? NCR_LEVEL.allow;
107
- const nullLevel = NCR_LEVEL[ncr.nullNCR ?? "remove"] ?? NCR_LEVEL.remove;
108
- const clampedNull = Math.max(nullLevel, NCR_LEVEL.remove);
109
- return { xmlVersion, onLevel, nullLevel: clampedNull };
110
- }
111
- exports.EntityDecoderImpl = class EntityDecoderImpl {
112
- _limit;
113
- _maxTotalExpansions;
114
- _maxExpandedLength;
115
- _postCheck;
116
- _limitTiers;
117
- _numericAllowed;
118
- _baseMap;
119
- _externalMap;
120
- _inputMap;
121
- _totalExpansions;
122
- _expandedLength;
123
- _removeSet;
124
- _leaveSet;
125
- _ncrXmlVersion;
126
- _ncrOnLevel;
127
- _ncrNullLevel;
128
- constructor(options = {}) {
129
- this._limit = options.limit || {};
130
- this._maxTotalExpansions = this._limit.maxTotalExpansions || 0;
131
- this._maxExpandedLength = this._limit.maxExpandedLength || 0;
132
- this._postCheck = typeof options.postCheck === "function" ? options.postCheck : (r) => r;
133
- this._limitTiers = parseLimitTiers(this._limit.applyLimitsTo ?? LIMIT_TIER_EXTERNAL);
134
- this._numericAllowed = options.numericAllowed ?? true;
135
- this._baseMap = mergeEntityMaps(XML, options.namedEntities || null);
136
- this._externalMap = Object.create(null);
137
- this._inputMap = Object.create(null);
138
- this._totalExpansions = 0;
139
- this._expandedLength = 0;
140
- this._removeSet = new Set(options.remove && Array.isArray(options.remove) ? options.remove : []);
141
- this._leaveSet = new Set(options.leave && Array.isArray(options.leave) ? options.leave : []);
142
- const ncrCfg = parseNCRConfig(options.ncr);
143
- this._ncrXmlVersion = ncrCfg.xmlVersion;
144
- this._ncrOnLevel = ncrCfg.onLevel;
145
- this._ncrNullLevel = ncrCfg.nullLevel;
146
- }
147
- setExternalEntities(map) {
148
- if (map) {
149
- for (const key of Object.keys(map)) {
150
- validateEntityName(key);
151
- }
152
- }
153
- this._externalMap = mergeEntityMaps(map);
154
- }
155
- addExternalEntity(key, value) {
156
- validateEntityName(key);
157
- if (typeof value === "string" && value.indexOf("&") === -1) {
158
- this._externalMap[key] = value;
159
- }
160
- }
161
- addInputEntities(map) {
162
- this._totalExpansions = 0;
163
- this._expandedLength = 0;
164
- this._inputMap = mergeEntityMaps(map);
165
- }
166
- reset() {
167
- this._inputMap = Object.create(null);
168
- this._totalExpansions = 0;
169
- this._expandedLength = 0;
170
- return this;
171
- }
172
- setXmlVersion(version) {
173
- this._ncrXmlVersion = version === "1.1" || version === 1.1 ? 1.1 : 1.0;
174
- }
175
- decode(str) {
176
- if (typeof str !== "string" || str.length === 0) {
177
- return str;
178
- }
179
- const original = str;
180
- const chunks = [];
181
- const len = str.length;
182
- let last = 0;
183
- let i = 0;
184
- const limitExpansions = this._maxTotalExpansions > 0;
185
- const limitLength = this._maxExpandedLength > 0;
186
- const checkLimits = limitExpansions || limitLength;
187
- while (i < len) {
188
- if (str.charCodeAt(i) !== 38) {
189
- i++;
190
- continue;
191
- }
192
- let j = i + 1;
193
- while (j < len && str.charCodeAt(j) !== 59 && j - i <= 32) {
194
- j++;
195
- }
196
- if (j >= len || str.charCodeAt(j) !== 59) {
197
- i++;
198
- continue;
199
- }
200
- const token = str.slice(i + 1, j);
201
- if (token.length === 0) {
202
- i++;
203
- continue;
204
- }
205
- let replacement;
206
- let tier;
207
- if (this._removeSet.has(token)) {
208
- replacement = "";
209
- if (tier === undefined) {
210
- tier = LIMIT_TIER_EXTERNAL;
211
- }
212
- }
213
- else if (this._leaveSet.has(token)) {
214
- i++;
215
- continue;
216
- }
217
- else if (token.charCodeAt(0) === 35) {
218
- const ncrResult = this._resolveNCR(token);
219
- if (ncrResult === undefined) {
220
- i++;
221
- continue;
222
- }
223
- replacement = ncrResult;
224
- tier = LIMIT_TIER_BASE;
225
- }
226
- else {
227
- const resolved = this._resolveName(token);
228
- replacement = resolved?.value;
229
- tier = resolved?.tier;
230
- }
231
- if (replacement === undefined) {
232
- i++;
233
- continue;
234
- }
235
- if (i > last) {
236
- chunks.push(str.slice(last, i));
237
- }
238
- chunks.push(replacement);
239
- last = j + 1;
240
- i = last;
241
- if (checkLimits && this._tierCounts(tier)) {
242
- if (limitExpansions) {
243
- this._totalExpansions++;
244
- if (this._totalExpansions > this._maxTotalExpansions) {
245
- throw new Error(`[EntityReplacer] Entity expansion count limit exceeded: ` +
246
- `${this._totalExpansions} > ${this._maxTotalExpansions}`);
247
- }
248
- }
249
- if (limitLength) {
250
- const delta = replacement.length - (token.length + 2);
251
- if (delta > 0) {
252
- this._expandedLength += delta;
253
- if (this._expandedLength > this._maxExpandedLength) {
254
- throw new Error(`[EntityReplacer] Expanded content length limit exceeded: ` +
255
- `${this._expandedLength} > ${this._maxExpandedLength}`);
256
- }
257
- }
258
- }
259
- }
260
- }
261
- if (last < len) {
262
- chunks.push(str.slice(last));
263
- }
264
- const result = chunks.length === 0 ? str : chunks.join("");
265
- return this._postCheck(result, original);
266
- }
267
- _tierCounts(tier) {
268
- if (this._limitTiers.has(LIMIT_TIER_ALL)) {
269
- return true;
270
- }
271
- return this._limitTiers.has(tier);
272
- }
273
- _resolveName(name) {
274
- if (name in this._inputMap) {
275
- return { value: this._inputMap[name], tier: LIMIT_TIER_EXTERNAL };
276
- }
277
- if (name in this._externalMap) {
278
- return { value: this._externalMap[name], tier: LIMIT_TIER_EXTERNAL };
279
- }
280
- if (name in this._baseMap) {
281
- return { value: this._baseMap[name], tier: LIMIT_TIER_BASE };
282
- }
283
- return undefined;
284
- }
285
- _classifyNCR(cp) {
286
- if (cp === 0) {
287
- return this._ncrNullLevel;
288
- }
289
- if (cp >= 0xd800 && cp <= 0xdfff) {
290
- return NCR_LEVEL.remove;
291
- }
292
- if (this._ncrXmlVersion === 1.0) {
293
- if (cp >= 0x01 && cp <= 0x1f && !XML10_ALLOWED_C0.has(cp)) {
294
- return NCR_LEVEL.remove;
295
- }
296
- }
297
- return -1;
298
- }
299
- _applyNCRAction(action, token, cp) {
300
- switch (action) {
301
- case NCR_LEVEL.allow:
302
- return String.fromCodePoint(cp);
303
- case NCR_LEVEL.remove:
304
- return "";
305
- case NCR_LEVEL.leave:
306
- return undefined;
307
- case NCR_LEVEL.throw:
308
- throw new Error(`[EntityDecoder] Prohibited numeric character reference ` +
309
- `&${token}; (U+${cp.toString(16).toUpperCase().padStart(4, "0")})`);
310
- default:
311
- return String.fromCodePoint(cp);
312
- }
313
- }
314
- _resolveNCR(token) {
315
- const second = token.charCodeAt(1);
316
- let cp;
317
- if (second === 120 || second === 88) {
318
- cp = parseInt(token.slice(2), 16);
319
- }
320
- else {
321
- cp = parseInt(token.slice(1), 10);
322
- }
323
- if (Number.isNaN(cp) || cp < 0 || cp > 0x10ffff) {
324
- return undefined;
325
- }
326
- const minimum = this._classifyNCR(cp);
327
- if (!this._numericAllowed && minimum < NCR_LEVEL.remove) {
328
- return undefined;
329
- }
330
- const effective = minimum === -1 ? this._ncrOnLevel : Math.max(this._ncrOnLevel, minimum);
331
- return this._applyNCRAction(effective, token, cp);
332
- }
333
- };
@@ -1,57 +0,0 @@
1
- let parser;
2
- exports.parseXML = function parseXML(xmlString) {
3
- if (!parser) {
4
- parser = new DOMParser();
5
- }
6
- const xmlDocument = parser.parseFromString(xmlString, "application/xml");
7
- if (xmlDocument.getElementsByTagName("parsererror").length > 0) {
8
- throw new Error("DOMParser XML parsing error.");
9
- }
10
- const xmlToObj = (node) => {
11
- if (node.nodeType === Node.TEXT_NODE) {
12
- if (node.textContent?.trim()) {
13
- return node.textContent;
14
- }
15
- }
16
- if (node.nodeType === Node.ELEMENT_NODE) {
17
- const element = node;
18
- if (element.attributes.length === 0 && element.childNodes.length === 0) {
19
- return "";
20
- }
21
- const obj = {};
22
- const attributes = Array.from(element.attributes);
23
- for (const attr of attributes) {
24
- obj[`${attr.name}`] = attr.value;
25
- }
26
- const childNodes = Array.from(element.childNodes);
27
- for (const child of childNodes) {
28
- const childResult = xmlToObj(child);
29
- if (childResult != null) {
30
- const childName = child.nodeName;
31
- if (childNodes.length === 1 && attributes.length === 0 && childName === "#text") {
32
- return childResult;
33
- }
34
- if (obj[childName]) {
35
- if (Array.isArray(obj[childName])) {
36
- obj[childName].push(childResult);
37
- }
38
- else {
39
- obj[childName] = [obj[childName], childResult];
40
- }
41
- }
42
- else {
43
- obj[childName] = childResult;
44
- }
45
- }
46
- else if (childNodes.length === 1 && attributes.length === 0) {
47
- return element.textContent;
48
- }
49
- }
50
- return obj;
51
- }
52
- return null;
53
- };
54
- return {
55
- [xmlDocument.documentElement.nodeName]: xmlToObj(xmlDocument.documentElement),
56
- };
57
- };