@blamejs/blamejs-shop 0.5.12 → 0.5.14

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 (522) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/lib/asset-manifest.json +1 -1
  3. package/lib/sales-tax-filings.js +143 -0
  4. package/lib/vendor/MANIFEST.json +632 -416
  5. package/lib/vendor/blamejs/.clusterfuzzlite/Dockerfile +21 -10
  6. package/lib/vendor/blamejs/.clusterfuzzlite/build.sh +30 -9
  7. package/lib/vendor/blamejs/.github/dependabot.yml +8 -0
  8. package/lib/vendor/blamejs/.github/workflows/actions-lint.yml +3 -3
  9. package/lib/vendor/blamejs/.github/workflows/cflite_batch.yml +7 -2
  10. package/lib/vendor/blamejs/.github/workflows/cflite_pr.yml +7 -2
  11. package/lib/vendor/blamejs/.github/workflows/ci.yml +21 -21
  12. package/lib/vendor/blamejs/.github/workflows/codeql.yml +3 -3
  13. package/lib/vendor/blamejs/.github/workflows/npm-publish.yml +4 -4
  14. package/lib/vendor/blamejs/.github/workflows/release-container.yml +7 -7
  15. package/lib/vendor/blamejs/.github/workflows/scorecard.yml +3 -3
  16. package/lib/vendor/blamejs/.github/workflows/sha-to-tag-verify.yml +1 -1
  17. package/lib/vendor/blamejs/.gitignore +2 -0
  18. package/lib/vendor/blamejs/CHANGELOG.md +122 -0
  19. package/lib/vendor/blamejs/NOTICE +26 -1
  20. package/lib/vendor/blamejs/SECURITY.md +1 -1
  21. package/lib/vendor/blamejs/api-snapshot.json +207 -5
  22. package/lib/vendor/blamejs/docker/keycloak/realm-blamejs-test.json +29 -0
  23. package/lib/vendor/blamejs/examples/wiki/DEPLOY.md +1 -0
  24. package/lib/vendor/blamejs/examples/wiki/lib/build-app.js +31 -0
  25. package/lib/vendor/blamejs/examples/wiki/lib/source-comment-block-validator.js +109 -0
  26. package/lib/vendor/blamejs/examples/wiki/nginx.conf +106 -0
  27. package/lib/vendor/blamejs/examples/wiki/package-lock.json +1 -1
  28. package/lib/vendor/blamejs/examples/wiki/test/e2e.js +92 -0
  29. package/lib/vendor/blamejs/fuzz/asn1-der.fuzz.js +28 -0
  30. package/lib/vendor/blamejs/fuzz/cms-codec.fuzz.js +17 -0
  31. package/lib/vendor/blamejs/fuzz/link-header.fuzz.js +18 -0
  32. package/lib/vendor/blamejs/index.js +6 -0
  33. package/lib/vendor/blamejs/lib/a2a.js +4 -4
  34. package/lib/vendor/blamejs/lib/agent-idempotency.js +18 -2
  35. package/lib/vendor/blamejs/lib/agent-saga.js +36 -8
  36. package/lib/vendor/blamejs/lib/agent-snapshot.js +63 -6
  37. package/lib/vendor/blamejs/lib/app-shutdown.js +23 -20
  38. package/lib/vendor/blamejs/lib/archive-read.js +8 -0
  39. package/lib/vendor/blamejs/lib/archive-tar.js +12 -2
  40. package/lib/vendor/blamejs/lib/arg-parser.js +49 -5
  41. package/lib/vendor/blamejs/lib/asn1-der.js +12 -0
  42. package/lib/vendor/blamejs/lib/audit-sign.js +47 -1
  43. package/lib/vendor/blamejs/lib/audit.js +71 -8
  44. package/lib/vendor/blamejs/lib/auth/ciba.js +14 -2
  45. package/lib/vendor/blamejs/lib/auth/fido-mds3.js +58 -47
  46. package/lib/vendor/blamejs/lib/auth/jwt.js +34 -0
  47. package/lib/vendor/blamejs/lib/auth/oauth.js +90 -13
  48. package/lib/vendor/blamejs/lib/auth/oid4vci.js +20 -17
  49. package/lib/vendor/blamejs/lib/auth/openid-federation.js +214 -23
  50. package/lib/vendor/blamejs/lib/auth/saml.js +38 -20
  51. package/lib/vendor/blamejs/lib/auth/sd-jwt-vc.js +10 -4
  52. package/lib/vendor/blamejs/lib/backup/bundle.js +13 -3
  53. package/lib/vendor/blamejs/lib/backup/index.js +16 -5
  54. package/lib/vendor/blamejs/lib/backup/manifest.js +18 -5
  55. package/lib/vendor/blamejs/lib/base32.js +21 -0
  56. package/lib/vendor/blamejs/lib/break-glass.js +19 -10
  57. package/lib/vendor/blamejs/lib/bundler.js +5 -1
  58. package/lib/vendor/blamejs/lib/cache-status.js +3 -7
  59. package/lib/vendor/blamejs/lib/calendar.js +21 -1
  60. package/lib/vendor/blamejs/lib/cbor.js +12 -1
  61. package/lib/vendor/blamejs/lib/cert.js +29 -11
  62. package/lib/vendor/blamejs/lib/cli.js +94 -24
  63. package/lib/vendor/blamejs/lib/cloud-events.js +2 -2
  64. package/lib/vendor/blamejs/lib/cluster-provider-db.js +13 -3
  65. package/lib/vendor/blamejs/lib/codepoint-class.js +85 -0
  66. package/lib/vendor/blamejs/lib/compliance-ai-act-prohibited.js +8 -4
  67. package/lib/vendor/blamejs/lib/compliance-ai-act-transparency.js +19 -4
  68. package/lib/vendor/blamejs/lib/compliance-ai-act.js +6 -8
  69. package/lib/vendor/blamejs/lib/content-credentials.js +1 -1
  70. package/lib/vendor/blamejs/lib/content-digest.js +2 -1
  71. package/lib/vendor/blamejs/lib/cookies.js +13 -3
  72. package/lib/vendor/blamejs/lib/cose.js +31 -16
  73. package/lib/vendor/blamejs/lib/crypto-field.js +32 -0
  74. package/lib/vendor/blamejs/lib/crypto-oprf.js +11 -2
  75. package/lib/vendor/blamejs/lib/crypto-xwing.js +22 -4
  76. package/lib/vendor/blamejs/lib/crypto.js +314 -19
  77. package/lib/vendor/blamejs/lib/csp.js +11 -3
  78. package/lib/vendor/blamejs/lib/daemon.js +270 -24
  79. package/lib/vendor/blamejs/lib/dark-patterns.js +5 -2
  80. package/lib/vendor/blamejs/lib/db-declare-view.js +2 -2
  81. package/lib/vendor/blamejs/lib/db-query.js +34 -7
  82. package/lib/vendor/blamejs/lib/db.js +18 -6
  83. package/lib/vendor/blamejs/lib/dbsc.js +17 -0
  84. package/lib/vendor/blamejs/lib/dev.js +21 -2
  85. package/lib/vendor/blamejs/lib/dsr.js +157 -102
  86. package/lib/vendor/blamejs/lib/external-db.js +41 -2
  87. package/lib/vendor/blamejs/lib/file-upload.js +25 -7
  88. package/lib/vendor/blamejs/lib/flag-providers.js +27 -15
  89. package/lib/vendor/blamejs/lib/forms.js +113 -27
  90. package/lib/vendor/blamejs/lib/gate-contract.js +23 -10
  91. package/lib/vendor/blamejs/lib/gdpr-ropa.js +8 -1
  92. package/lib/vendor/blamejs/lib/guard-agent-registry.js +1 -1
  93. package/lib/vendor/blamejs/lib/guard-archive.js +2 -2
  94. package/lib/vendor/blamejs/lib/guard-cidr.js +27 -1
  95. package/lib/vendor/blamejs/lib/guard-graphql.js +30 -11
  96. package/lib/vendor/blamejs/lib/guard-html.js +26 -53
  97. package/lib/vendor/blamejs/lib/guard-image.js +24 -5
  98. package/lib/vendor/blamejs/lib/guard-imap-command.js +10 -2
  99. package/lib/vendor/blamejs/lib/guard-jmap.js +19 -3
  100. package/lib/vendor/blamejs/lib/guard-jwt.js +18 -2
  101. package/lib/vendor/blamejs/lib/guard-list-unsubscribe.js +2 -2
  102. package/lib/vendor/blamejs/lib/guard-managesieve-command.js +10 -2
  103. package/lib/vendor/blamejs/lib/guard-markdown.js +11 -24
  104. package/lib/vendor/blamejs/lib/guard-pdf.js +18 -2
  105. package/lib/vendor/blamejs/lib/guard-pop3-command.js +10 -2
  106. package/lib/vendor/blamejs/lib/guard-regex.js +8 -5
  107. package/lib/vendor/blamejs/lib/guard-svg.js +31 -32
  108. package/lib/vendor/blamejs/lib/guard-time.js +1 -1
  109. package/lib/vendor/blamejs/lib/guard-uuid.js +2 -2
  110. package/lib/vendor/blamejs/lib/html-balance.js +3 -3
  111. package/lib/vendor/blamejs/lib/http-client-cache.js +82 -4
  112. package/lib/vendor/blamejs/lib/http-client-cookie-jar.js +16 -1
  113. package/lib/vendor/blamejs/lib/http-client.js +39 -7
  114. package/lib/vendor/blamejs/lib/http-message-signature.js +35 -1
  115. package/lib/vendor/blamejs/lib/i18n-messageformat.js +31 -6
  116. package/lib/vendor/blamejs/lib/i18n.js +35 -21
  117. package/lib/vendor/blamejs/lib/incident-report.js +8 -1
  118. package/lib/vendor/blamejs/lib/ip-utils.js +11 -1
  119. package/lib/vendor/blamejs/lib/json-path.js +23 -1
  120. package/lib/vendor/blamejs/lib/jwk.js +20 -3
  121. package/lib/vendor/blamejs/lib/link-header.js +2 -1
  122. package/lib/vendor/blamejs/lib/log-stream-otlp-grpc.js +5 -1
  123. package/lib/vendor/blamejs/lib/log-stream-otlp.js +5 -1
  124. package/lib/vendor/blamejs/lib/log-stream.js +8 -3
  125. package/lib/vendor/blamejs/lib/mail-auth.js +123 -22
  126. package/lib/vendor/blamejs/lib/mail-bimi.js +1 -1
  127. package/lib/vendor/blamejs/lib/mail-bounce.js +8 -0
  128. package/lib/vendor/blamejs/lib/mail-crypto-pgp.js +46 -10
  129. package/lib/vendor/blamejs/lib/mail-dav.js +22 -3
  130. package/lib/vendor/blamejs/lib/mail-dkim.js +96 -30
  131. package/lib/vendor/blamejs/lib/mail-helo.js +6 -1
  132. package/lib/vendor/blamejs/lib/mail-scan.js +23 -16
  133. package/lib/vendor/blamejs/lib/mail-send-deliver.js +34 -8
  134. package/lib/vendor/blamejs/lib/mail-server-imap.js +3 -4
  135. package/lib/vendor/blamejs/lib/mail-server-managesieve.js +7 -11
  136. package/lib/vendor/blamejs/lib/mail-server-mx.js +93 -7
  137. package/lib/vendor/blamejs/lib/mail-server-registry.js +8 -2
  138. package/lib/vendor/blamejs/lib/mail.js +15 -5
  139. package/lib/vendor/blamejs/lib/metrics.js +268 -63
  140. package/lib/vendor/blamejs/lib/middleware/age-gate.js +7 -1
  141. package/lib/vendor/blamejs/lib/middleware/asyncapi-serve.js +1 -1
  142. package/lib/vendor/blamejs/lib/middleware/body-parser.js +19 -4
  143. package/lib/vendor/blamejs/lib/middleware/bot-guard.js +5 -9
  144. package/lib/vendor/blamejs/lib/middleware/csp-report.js +40 -8
  145. package/lib/vendor/blamejs/lib/middleware/csrf-protect.js +24 -10
  146. package/lib/vendor/blamejs/lib/middleware/dpop.js +10 -5
  147. package/lib/vendor/blamejs/lib/middleware/index.js +6 -1
  148. package/lib/vendor/blamejs/lib/middleware/nel.js +1 -1
  149. package/lib/vendor/blamejs/lib/middleware/openapi-serve.js +1 -1
  150. package/lib/vendor/blamejs/lib/middleware/rate-limit.js +12 -1
  151. package/lib/vendor/blamejs/lib/middleware/require-bound-key.js +1 -1
  152. package/lib/vendor/blamejs/lib/middleware/scim-server.js +1 -1
  153. package/lib/vendor/blamejs/lib/middleware/tus-upload.js +6 -2
  154. package/lib/vendor/blamejs/lib/mtls-ca.js +18 -2
  155. package/lib/vendor/blamejs/lib/network-dns-resolver.js +11 -1
  156. package/lib/vendor/blamejs/lib/network-dns.js +21 -2
  157. package/lib/vendor/blamejs/lib/network-tls.js +69 -7
  158. package/lib/vendor/blamejs/lib/nonce-store.js +9 -1
  159. package/lib/vendor/blamejs/lib/object-store/gcs.js +7 -0
  160. package/lib/vendor/blamejs/lib/object-store/sigv4.js +31 -0
  161. package/lib/vendor/blamejs/lib/observability-otlp-exporter.js +1 -1
  162. package/lib/vendor/blamejs/lib/outbox.js +1 -1
  163. package/lib/vendor/blamejs/lib/parsers/safe-ini.js +9 -1
  164. package/lib/vendor/blamejs/lib/parsers/safe-toml.js +10 -1
  165. package/lib/vendor/blamejs/lib/permissions.js +6 -3
  166. package/lib/vendor/blamejs/lib/pid-probe.js +55 -0
  167. package/lib/vendor/blamejs/lib/pqc-agent.js +8 -1
  168. package/lib/vendor/blamejs/lib/pqc-software.js +3 -3
  169. package/lib/vendor/blamejs/lib/pubsub.js +20 -9
  170. package/lib/vendor/blamejs/lib/queue-local.js +8 -1
  171. package/lib/vendor/blamejs/lib/queue-redis.js +5 -0
  172. package/lib/vendor/blamejs/lib/redact.js +54 -0
  173. package/lib/vendor/blamejs/lib/restore-bundle.js +10 -2
  174. package/lib/vendor/blamejs/lib/restore.js +19 -0
  175. package/lib/vendor/blamejs/lib/retention.js +12 -4
  176. package/lib/vendor/blamejs/lib/router.js +60 -6
  177. package/lib/vendor/blamejs/lib/safe-buffer.js +69 -0
  178. package/lib/vendor/blamejs/lib/safe-decompress.js +8 -2
  179. package/lib/vendor/blamejs/lib/safe-dns.js +25 -20
  180. package/lib/vendor/blamejs/lib/safe-ical.js +7 -3
  181. package/lib/vendor/blamejs/lib/safe-mime.js +12 -1
  182. package/lib/vendor/blamejs/lib/safe-object.js +80 -0
  183. package/lib/vendor/blamejs/lib/safe-path.js +52 -4
  184. package/lib/vendor/blamejs/lib/safe-redirect.js +10 -2
  185. package/lib/vendor/blamejs/lib/safe-schema.js +4 -1
  186. package/lib/vendor/blamejs/lib/safe-sieve.js +33 -1
  187. package/lib/vendor/blamejs/lib/safe-sql.js +88 -0
  188. package/lib/vendor/blamejs/lib/safe-vcard.js +7 -3
  189. package/lib/vendor/blamejs/lib/scheduler.js +8 -1
  190. package/lib/vendor/blamejs/lib/security-assert.js +6 -6
  191. package/lib/vendor/blamejs/lib/self-update-standalone-verifier.js +74 -27
  192. package/lib/vendor/blamejs/lib/self-update.js +517 -87
  193. package/lib/vendor/blamejs/lib/server-timing.js +2 -4
  194. package/lib/vendor/blamejs/lib/session.js +34 -12
  195. package/lib/vendor/blamejs/lib/sql.js +15 -1
  196. package/lib/vendor/blamejs/lib/ssrf-guard.js +52 -0
  197. package/lib/vendor/blamejs/lib/static.js +55 -13
  198. package/lib/vendor/blamejs/lib/storage.js +8 -2
  199. package/lib/vendor/blamejs/lib/subject.js +6 -1
  200. package/lib/vendor/blamejs/lib/tenant-quota.js +52 -13
  201. package/lib/vendor/blamejs/lib/tls-exporter.js +3 -3
  202. package/lib/vendor/blamejs/lib/tsa.js +34 -13
  203. package/lib/vendor/blamejs/lib/uri-template.js +8 -1
  204. package/lib/vendor/blamejs/lib/vault/index.js +13 -0
  205. package/lib/vendor/blamejs/lib/vc.js +44 -5
  206. package/lib/vendor/blamejs/lib/vendor/MANIFEST.json +26 -26
  207. package/lib/vendor/blamejs/lib/vendor/noble-ciphers.cjs +792 -1
  208. package/lib/vendor/blamejs/lib/vendor/noble-curves.cjs +3443 -1
  209. package/lib/vendor/blamejs/lib/vendor/noble-post-quantum.cjs +2737 -1
  210. package/lib/vendor/blamejs/lib/vendor/pki.cjs +39550 -13
  211. package/lib/vendor/blamejs/lib/vendor/public-suffix-list.dat +55 -53
  212. package/lib/vendor/blamejs/lib/vendor/public-suffix-list.data.js +5551 -5554
  213. package/lib/vendor/blamejs/lib/vendor/simplewebauthn-server.cjs +22459 -32
  214. package/lib/vendor/blamejs/lib/watcher.js +89 -17
  215. package/lib/vendor/blamejs/lib/webhook-dispatcher.js +25 -3
  216. package/lib/vendor/blamejs/lib/webhook.js +12 -2
  217. package/lib/vendor/blamejs/lib/ws-client.js +32 -1
  218. package/lib/vendor/blamejs/lib/xml-c14n.js +29 -1
  219. package/lib/vendor/blamejs/oss-fuzz/projects/blamejs/Dockerfile +1 -1
  220. package/lib/vendor/blamejs/package-lock.json +2 -2
  221. package/lib/vendor/blamejs/package.json +1 -1
  222. package/lib/vendor/blamejs/release-notes/v0.16.x.json +1462 -0
  223. package/lib/vendor/blamejs/release-notes/v0.17.0.json +31 -0
  224. package/lib/vendor/blamejs/release-notes/v0.17.1.json +31 -0
  225. package/lib/vendor/blamejs/release-notes/v0.17.10.json +30 -0
  226. package/lib/vendor/blamejs/release-notes/v0.17.11.json +22 -0
  227. package/lib/vendor/blamejs/release-notes/v0.17.12.json +18 -0
  228. package/lib/vendor/blamejs/release-notes/v0.17.13.json +77 -0
  229. package/lib/vendor/blamejs/release-notes/v0.17.14.json +40 -0
  230. package/lib/vendor/blamejs/release-notes/v0.17.15.json +18 -0
  231. package/lib/vendor/blamejs/release-notes/v0.17.16.json +27 -0
  232. package/lib/vendor/blamejs/release-notes/v0.17.17.json +31 -0
  233. package/lib/vendor/blamejs/release-notes/v0.17.18.json +18 -0
  234. package/lib/vendor/blamejs/release-notes/v0.17.19.json +18 -0
  235. package/lib/vendor/blamejs/release-notes/v0.17.2.json +26 -0
  236. package/lib/vendor/blamejs/release-notes/v0.17.20.json +43 -0
  237. package/lib/vendor/blamejs/release-notes/v0.17.21.json +26 -0
  238. package/lib/vendor/blamejs/release-notes/v0.17.22.json +18 -0
  239. package/lib/vendor/blamejs/release-notes/v0.17.3.json +43 -0
  240. package/lib/vendor/blamejs/release-notes/v0.17.4.json +35 -0
  241. package/lib/vendor/blamejs/release-notes/v0.17.5.json +26 -0
  242. package/lib/vendor/blamejs/release-notes/v0.17.6.json +26 -0
  243. package/lib/vendor/blamejs/release-notes/v0.17.7.json +35 -0
  244. package/lib/vendor/blamejs/release-notes/v0.17.8.json +22 -0
  245. package/lib/vendor/blamejs/release-notes/v0.17.9.json +26 -0
  246. package/lib/vendor/blamejs/scripts/validate-source-comment-blocks.js +4 -0
  247. package/lib/vendor/blamejs/scripts/vendor-update.sh +293 -9
  248. package/lib/vendor/blamejs/socket.yml +94 -0
  249. package/lib/vendor/blamejs/test/00-primitives.js +605 -0
  250. package/lib/vendor/blamejs/test/helpers/drivers.js +12 -9
  251. package/lib/vendor/blamejs/test/integration/audit-stack-mysql.test.js +90 -1
  252. package/lib/vendor/blamejs/test/integration/audit-stack-postgres.test.js +122 -1
  253. package/lib/vendor/blamejs/test/integration/data-layer-mysql.test.js +30 -0
  254. package/lib/vendor/blamejs/test/integration/data-layer-pg.test.js +29 -0
  255. package/lib/vendor/blamejs/test/integration/dsr-cluster-mysql.test.js +479 -0
  256. package/lib/vendor/blamejs/test/integration/dsr-cluster-pg.test.js +487 -0
  257. package/lib/vendor/blamejs/test/integration/federation-auth.test.js +313 -5
  258. package/lib/vendor/blamejs/test/integration/mail-dkim.test.js +80 -0
  259. package/lib/vendor/blamejs/test/integration/openid-federation-chain.test.js +275 -0
  260. package/lib/vendor/blamejs/test/integration/webhook-dispatcher-pg.test.js +96 -0
  261. package/lib/vendor/blamejs/test/layer-0-primitives/a2a-tasks.test.js +401 -0
  262. package/lib/vendor/blamejs/test/layer-0-primitives/acme.test.js +1649 -2
  263. package/lib/vendor/blamejs/test/layer-0-primitives/age-gate.test.js +33 -0
  264. package/lib/vendor/blamejs/test/layer-0-primitives/agent-idempotency.test.js +0 -0
  265. package/lib/vendor/blamejs/test/layer-0-primitives/agent-saga.test.js +60 -0
  266. package/lib/vendor/blamejs/test/layer-0-primitives/agent-snapshot.test.js +524 -0
  267. package/lib/vendor/blamejs/test/layer-0-primitives/api-encrypt.test.js +891 -0
  268. package/lib/vendor/blamejs/test/layer-0-primitives/app-shutdown.test.js +128 -1
  269. package/lib/vendor/blamejs/test/layer-0-primitives/archive-adapters.test.js +271 -0
  270. package/lib/vendor/blamejs/test/layer-0-primitives/archive-read.test.js +628 -1
  271. package/lib/vendor/blamejs/test/layer-0-primitives/archive-tar-read.test.js +0 -0
  272. package/lib/vendor/blamejs/test/layer-0-primitives/archive-wrap.test.js +227 -0
  273. package/lib/vendor/blamejs/test/layer-0-primitives/arg-parser.test.js +15 -0
  274. package/lib/vendor/blamejs/test/layer-0-primitives/asn1-der.test.js +73 -0
  275. package/lib/vendor/blamejs/test/layer-0-primitives/atomic-file.test.js +114 -0
  276. package/lib/vendor/blamejs/test/layer-0-primitives/audit-sign-anchor.test.js +141 -0
  277. package/lib/vendor/blamejs/test/layer-0-primitives/audit-tools.test.js +624 -0
  278. package/lib/vendor/blamejs/test/layer-0-primitives/audit.test.js +769 -0
  279. package/lib/vendor/blamejs/test/layer-0-primitives/auth-jwt-defenses.test.js +436 -0
  280. package/lib/vendor/blamejs/test/layer-0-primitives/auth-oauth.test.js +1697 -0
  281. package/lib/vendor/blamejs/test/layer-0-primitives/auth-oid4vp.test.js +495 -0
  282. package/lib/vendor/blamejs/test/layer-0-primitives/auth-password.test.js +500 -0
  283. package/lib/vendor/blamejs/test/layer-0-primitives/auth-saml.test.js +1809 -0
  284. package/lib/vendor/blamejs/test/layer-0-primitives/auth-status-list.test.js +243 -1
  285. package/lib/vendor/blamejs/test/layer-0-primitives/backup-index.test.js +2226 -0
  286. package/lib/vendor/blamejs/test/layer-0-primitives/backup-manifest-signature.test.js +183 -0
  287. package/lib/vendor/blamejs/test/layer-0-primitives/base32.test.js +105 -0
  288. package/lib/vendor/blamejs/test/layer-0-primitives/break-glass.test.js +693 -0
  289. package/lib/vendor/blamejs/test/layer-0-primitives/cache.test.js +603 -0
  290. package/lib/vendor/blamejs/test/layer-0-primitives/calendar.test.js +557 -0
  291. package/lib/vendor/blamejs/test/layer-0-primitives/case-insensitive-security-token-guard.test.js +214 -0
  292. package/lib/vendor/blamejs/test/layer-0-primitives/cbor.test.js +25 -0
  293. package/lib/vendor/blamejs/test/layer-0-primitives/cert.test.js +843 -6
  294. package/lib/vendor/blamejs/test/layer-0-primitives/ciba-authreqid-binding.test.js +77 -2
  295. package/lib/vendor/blamejs/test/layer-0-primitives/ciba.test.js +866 -0
  296. package/lib/vendor/blamejs/test/layer-0-primitives/clear-site-data.test.js +18 -0
  297. package/lib/vendor/blamejs/test/layer-0-primitives/cli-erase.test.js +19 -0
  298. package/lib/vendor/blamejs/test/layer-0-primitives/cli.test.js +2790 -0
  299. package/lib/vendor/blamejs/test/layer-0-primitives/cluster-lease-renewal-ttl.test.js +114 -0
  300. package/lib/vendor/blamejs/test/layer-0-primitives/cluster.test.js +1032 -0
  301. package/lib/vendor/blamejs/test/layer-0-primitives/cms-codec.test.js +575 -0
  302. package/lib/vendor/blamejs/test/layer-0-primitives/codebase-patterns.test.js +739 -1
  303. package/lib/vendor/blamejs/test/layer-0-primitives/codepoint-class.test.js +8 -0
  304. package/lib/vendor/blamejs/test/layer-0-primitives/compliance-ai-act.test.js +194 -0
  305. package/lib/vendor/blamejs/test/layer-0-primitives/compliance-lifecycle-proto-key.test.js +104 -0
  306. package/lib/vendor/blamejs/test/layer-0-primitives/compliance-sanctions.test.js +254 -0
  307. package/lib/vendor/blamejs/test/layer-0-primitives/content-credentials.test.js +613 -3
  308. package/lib/vendor/blamejs/test/layer-0-primitives/cookies.test.js +140 -0
  309. package/lib/vendor/blamejs/test/layer-0-primitives/cose.test.js +407 -0
  310. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-adversarial.test.js +352 -0
  311. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-field-derived-hash.test.js +32 -0
  312. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-field.test.js +575 -0
  313. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-hash-files-parallel.test.js +10 -0
  314. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-hash-stream.test.js +24 -0
  315. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-oprf.test.js +17 -0
  316. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-spki-pin.test.js +183 -0
  317. package/lib/vendor/blamejs/test/layer-0-primitives/crypto-xwing.test.js +48 -0
  318. package/lib/vendor/blamejs/test/layer-0-primitives/crypto.test.js +345 -0
  319. package/lib/vendor/blamejs/test/layer-0-primitives/csp-report.test.js +58 -0
  320. package/lib/vendor/blamejs/test/layer-0-primitives/csv.test.js +48 -0
  321. package/lib/vendor/blamejs/test/layer-0-primitives/daemon.test.js +459 -1
  322. package/lib/vendor/blamejs/test/layer-0-primitives/dark-patterns.test.js +19 -0
  323. package/lib/vendor/blamejs/test/layer-0-primitives/db-query.test.js +1019 -0
  324. package/lib/vendor/blamejs/test/layer-0-primitives/db-raw-residency-gate.test.js +77 -0
  325. package/lib/vendor/blamejs/test/layer-0-primitives/db.test.js +1621 -0
  326. package/lib/vendor/blamejs/test/layer-0-primitives/ddl-change-control.test.js +462 -3
  327. package/lib/vendor/blamejs/test/layer-0-primitives/dnssec.test.js +323 -0
  328. package/lib/vendor/blamejs/test/layer-0-primitives/dpop-middleware-verify.test.js +562 -0
  329. package/lib/vendor/blamejs/test/layer-0-primitives/dsr.test.js +901 -1
  330. package/lib/vendor/blamejs/test/layer-0-primitives/dual-control.test.js +249 -0
  331. package/lib/vendor/blamejs/test/layer-0-primitives/external-db-migrate.test.js +561 -0
  332. package/lib/vendor/blamejs/test/layer-0-primitives/external-db.test.js +1214 -0
  333. package/lib/vendor/blamejs/test/layer-0-primitives/fal.test.js +21 -0
  334. package/lib/vendor/blamejs/test/layer-0-primitives/fedcm-dbsc.test.js +46 -20
  335. package/lib/vendor/blamejs/test/layer-0-primitives/federation-vc-suite.test.js +147 -3
  336. package/lib/vendor/blamejs/test/layer-0-primitives/fido-mds3.test.js +907 -38
  337. package/lib/vendor/blamejs/test/layer-0-primitives/file-upload-content-safety-skip-audit.test.js +29 -0
  338. package/lib/vendor/blamejs/test/layer-0-primitives/file-upload.test.js +1135 -0
  339. package/lib/vendor/blamejs/test/layer-0-primitives/flag.test.js +30 -0
  340. package/lib/vendor/blamejs/test/layer-0-primitives/forms.test.js +747 -0
  341. package/lib/vendor/blamejs/test/layer-0-primitives/gate-contract.test.js +1855 -0
  342. package/lib/vendor/blamejs/test/layer-0-primitives/gdpr-ropa.test.js +30 -0
  343. package/lib/vendor/blamejs/test/layer-0-primitives/guard-archive.test.js +86 -0
  344. package/lib/vendor/blamejs/test/layer-0-primitives/guard-auth.test.js +117 -0
  345. package/lib/vendor/blamejs/test/layer-0-primitives/guard-cidr.test.js +151 -0
  346. package/lib/vendor/blamejs/test/layer-0-primitives/guard-domain.test.js +422 -0
  347. package/lib/vendor/blamejs/test/layer-0-primitives/guard-filename.test.js +424 -0
  348. package/lib/vendor/blamejs/test/layer-0-primitives/{guard-gate-disposition-coverage.test.js → guard-gate-disposition.test.js} +1 -1
  349. package/lib/vendor/blamejs/test/layer-0-primitives/guard-graphql.test.js +340 -0
  350. package/lib/vendor/blamejs/test/layer-0-primitives/guard-html.test.js +29 -0
  351. package/lib/vendor/blamejs/test/layer-0-primitives/guard-idempotency-key.test.js +28 -0
  352. package/lib/vendor/blamejs/test/layer-0-primitives/guard-image.test.js +519 -45
  353. package/lib/vendor/blamejs/test/layer-0-primitives/guard-imap-command.test.js +0 -0
  354. package/lib/vendor/blamejs/test/layer-0-primitives/guard-jmap.test.js +51 -0
  355. package/lib/vendor/blamejs/test/layer-0-primitives/guard-jsonpath.test.js +66 -0
  356. package/lib/vendor/blamejs/test/layer-0-primitives/guard-jwt.test.js +436 -0
  357. package/lib/vendor/blamejs/test/layer-0-primitives/guard-managesieve-command.test.js +25 -0
  358. package/lib/vendor/blamejs/test/layer-0-primitives/guard-markdown.test.js +16 -0
  359. package/lib/vendor/blamejs/test/layer-0-primitives/guard-mime.test.js +86 -0
  360. package/lib/vendor/blamejs/test/layer-0-primitives/guard-oauth.test.js +140 -0
  361. package/lib/vendor/blamejs/test/layer-0-primitives/guard-pdf.test.js +80 -0
  362. package/lib/vendor/blamejs/test/layer-0-primitives/guard-pop3-command.test.js +27 -0
  363. package/lib/vendor/blamejs/test/layer-0-primitives/guard-regex.test.js +99 -0
  364. package/lib/vendor/blamejs/test/layer-0-primitives/guard-shell.test.js +76 -0
  365. package/lib/vendor/blamejs/test/layer-0-primitives/{guard-sql-coverage.test.js → guard-sql.test.js} +3 -3
  366. package/lib/vendor/blamejs/test/layer-0-primitives/guard-svg.test.js +524 -0
  367. package/lib/vendor/blamejs/test/layer-0-primitives/guard-template.test.js +71 -0
  368. package/lib/vendor/blamejs/test/layer-0-primitives/guard-time.test.js +92 -0
  369. package/lib/vendor/blamejs/test/layer-0-primitives/guard-uuid.test.js +86 -0
  370. package/lib/vendor/blamejs/test/layer-0-primitives/html-balance.test.js +38 -0
  371. package/lib/vendor/blamejs/test/layer-0-primitives/http-client-cache-authorization.test.js +347 -0
  372. package/lib/vendor/blamejs/test/layer-0-primitives/http-client-cache.test.js +908 -0
  373. package/lib/vendor/blamejs/test/layer-0-primitives/http-client.test.js +2874 -0
  374. package/lib/vendor/blamejs/test/layer-0-primitives/http-message-signature.test.js +643 -0
  375. package/lib/vendor/blamejs/test/layer-0-primitives/i18n-messageformat.test.js +38 -0
  376. package/lib/vendor/blamejs/test/layer-0-primitives/i18n.test.js +1153 -1
  377. package/lib/vendor/blamejs/test/layer-0-primitives/idempotency-key.test.js +494 -0
  378. package/lib/vendor/blamejs/test/layer-0-primitives/ip-utils.test.js +30 -0
  379. package/lib/vendor/blamejs/test/layer-0-primitives/jsdoc-example-execution.test.js +177 -0
  380. package/lib/vendor/blamejs/test/layer-0-primitives/json-path.test.js +103 -0
  381. package/lib/vendor/blamejs/test/layer-0-primitives/json-schema.test.js +214 -0
  382. package/lib/vendor/blamejs/test/layer-0-primitives/jwk.test.js +41 -0
  383. package/lib/vendor/blamejs/test/layer-0-primitives/jwt-external.test.js +276 -0
  384. package/lib/vendor/blamejs/test/layer-0-primitives/keychain.test.js +0 -0
  385. package/lib/vendor/blamejs/test/layer-0-primitives/log-stream.test.js +241 -0
  386. package/lib/vendor/blamejs/test/layer-0-primitives/log.test.js +106 -0
  387. package/lib/vendor/blamejs/test/layer-0-primitives/mail-agent.test.js +441 -0
  388. package/lib/vendor/blamejs/test/layer-0-primitives/mail-auth.test.js +2136 -4
  389. package/lib/vendor/blamejs/test/layer-0-primitives/mail-bimi.test.js +759 -12
  390. package/lib/vendor/blamejs/test/layer-0-primitives/mail-bounce.test.js +811 -1
  391. package/lib/vendor/blamejs/test/layer-0-primitives/mail-crypto-pgp-experimental.test.js +401 -3
  392. package/lib/vendor/blamejs/test/layer-0-primitives/mail-crypto-pgp.test.js +751 -8
  393. package/lib/vendor/blamejs/test/layer-0-primitives/mail-crypto-smime.test.js +864 -0
  394. package/lib/vendor/blamejs/test/layer-0-primitives/mail-crypto.test.js +110 -0
  395. package/lib/vendor/blamejs/test/layer-0-primitives/mail-dav.test.js +830 -1
  396. package/lib/vendor/blamejs/test/layer-0-primitives/mail-deploy.test.js +635 -86
  397. package/lib/vendor/blamejs/test/layer-0-primitives/mail-dkim.test.js +818 -0
  398. package/lib/vendor/blamejs/test/layer-0-primitives/mail-helo.test.js +27 -0
  399. package/lib/vendor/blamejs/test/layer-0-primitives/mail-scan.test.js +199 -0
  400. package/lib/vendor/blamejs/test/layer-0-primitives/mail-send-deliver.test.js +686 -2
  401. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-imap.test.js +778 -0
  402. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-jmap.test.js +1438 -0
  403. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-managesieve.test.js +449 -6
  404. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-mx.test.js +773 -2
  405. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-pop3.test.js +623 -3
  406. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-rate-limit.test.js +55 -0
  407. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-registry.test.js +13 -0
  408. package/lib/vendor/blamejs/test/layer-0-primitives/mail-server-submission.test.js +877 -1
  409. package/lib/vendor/blamejs/test/layer-0-primitives/mail-sieve.test.js +326 -0
  410. package/lib/vendor/blamejs/test/layer-0-primitives/mail-store-fts.test.js +55 -0
  411. package/lib/vendor/blamejs/test/layer-0-primitives/mail-store.test.js +242 -0
  412. package/lib/vendor/blamejs/test/layer-0-primitives/mail.test.js +1596 -2
  413. package/lib/vendor/blamejs/test/layer-0-primitives/mcp.test.js +440 -4
  414. package/lib/vendor/blamejs/test/layer-0-primitives/metrics-snapshot.test.js +89 -0
  415. package/lib/vendor/blamejs/test/layer-0-primitives/metrics.test.js +1230 -0
  416. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-assetlinks.test.js +113 -0
  417. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-body-parser.test.js +1169 -0
  418. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-bot-disclose.test.js +123 -0
  419. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-cookies.test.js +108 -0
  420. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-gpc.test.js +121 -0
  421. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-headers.test.js +163 -0
  422. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-host-allowlist.test.js +154 -0
  423. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-require-content-type.test.js +127 -0
  424. package/lib/vendor/blamejs/test/layer-0-primitives/{middleware-tus-upload-coverage.test.js → middleware-tus-upload.test.js} +45 -0
  425. package/lib/vendor/blamejs/test/layer-0-primitives/middleware-web-app-manifest.test.js +132 -0
  426. package/lib/vendor/blamejs/test/layer-0-primitives/mtls-ca-crl-fingerprint-only.test.js +92 -0
  427. package/lib/vendor/blamejs/test/layer-0-primitives/network-dns-resolver.test.js +65 -0
  428. package/lib/vendor/blamejs/test/layer-0-primitives/network-dns.test.js +1727 -1
  429. package/lib/vendor/blamejs/test/layer-0-primitives/network-nts.test.js +699 -0
  430. package/lib/vendor/blamejs/test/layer-0-primitives/network-smtp-policy.test.js +1181 -0
  431. package/lib/vendor/blamejs/test/layer-0-primitives/network-tls.test.js +1876 -3
  432. package/lib/vendor/blamejs/test/layer-0-primitives/network.test.js +32 -0
  433. package/lib/vendor/blamejs/test/layer-0-primitives/nonce-store-enforce-replay-nonboolean.test.js +81 -0
  434. package/lib/vendor/blamejs/test/layer-0-primitives/ntp-check.test.js +122 -0
  435. package/lib/vendor/blamejs/test/layer-0-primitives/observability-tracing.test.js +378 -0
  436. package/lib/vendor/blamejs/test/layer-0-primitives/observability.test.js +77 -0
  437. package/lib/vendor/blamejs/test/layer-0-primitives/oid4vci.test.js +1016 -0
  438. package/lib/vendor/blamejs/test/layer-0-primitives/openid-federation.test.js +946 -0
  439. package/lib/vendor/blamejs/test/layer-0-primitives/outbox.test.js +818 -0
  440. package/lib/vendor/blamejs/test/layer-0-primitives/own-property-membership-guards.test.js +109 -0
  441. package/lib/vendor/blamejs/test/layer-0-primitives/parsers-safe-toml.test.js +543 -0
  442. package/lib/vendor/blamejs/test/layer-0-primitives/{parsers-safe-yaml-coverage.test.js → parsers-safe-yaml.test.js} +2 -2
  443. package/lib/vendor/blamejs/test/layer-0-primitives/parsers-standalone.test.js +73 -0
  444. package/lib/vendor/blamejs/test/layer-0-primitives/passkey.test.js +649 -0
  445. package/lib/vendor/blamejs/test/layer-0-primitives/permissions.test.js +524 -0
  446. package/lib/vendor/blamejs/test/layer-0-primitives/pqc-agent-curve.test.js +22 -0
  447. package/lib/vendor/blamejs/test/layer-0-primitives/pubsub.test.js +295 -0
  448. package/lib/vendor/blamejs/test/layer-0-primitives/queue-flow-repeat.test.js +36 -0
  449. package/lib/vendor/blamejs/test/layer-0-primitives/queue.test.js +83 -0
  450. package/lib/vendor/blamejs/test/layer-0-primitives/rate-limit-xff-spoofing.test.js +34 -0
  451. package/lib/vendor/blamejs/test/layer-0-primitives/redact.test.js +1031 -0
  452. package/lib/vendor/blamejs/test/layer-0-primitives/request-helpers.test.js +94 -0
  453. package/lib/vendor/blamejs/test/layer-0-primitives/require-bound-key.test.js +401 -0
  454. package/lib/vendor/blamejs/test/layer-0-primitives/restore-empty-manifest-wipe.test.js +154 -0
  455. package/lib/vendor/blamejs/test/layer-0-primitives/retention.test.js +600 -0
  456. package/lib/vendor/blamejs/test/layer-0-primitives/router-host-path-injection.test.js +231 -0
  457. package/lib/vendor/blamejs/test/layer-0-primitives/router-tls0rtt.test.js +21 -0
  458. package/lib/vendor/blamejs/test/layer-0-primitives/router.test.js +1277 -0
  459. package/lib/vendor/blamejs/test/layer-0-primitives/safe-async.test.js +133 -0
  460. package/lib/vendor/blamejs/test/layer-0-primitives/safe-buffer-linear-scans.test.js +14 -0
  461. package/lib/vendor/blamejs/test/layer-0-primitives/safe-buffer.test.js +80 -0
  462. package/lib/vendor/blamejs/test/layer-0-primitives/safe-decompress.test.js +28 -0
  463. package/lib/vendor/blamejs/test/layer-0-primitives/safe-dns.test.js +245 -0
  464. package/lib/vendor/blamejs/test/layer-0-primitives/safe-ical.test.js +32 -0
  465. package/lib/vendor/blamejs/test/layer-0-primitives/safe-ini.test.js +376 -0
  466. package/lib/vendor/blamejs/test/layer-0-primitives/safe-json.test.js +175 -0
  467. package/lib/vendor/blamejs/test/layer-0-primitives/safe-mime.test.js +518 -0
  468. package/lib/vendor/blamejs/test/layer-0-primitives/safe-object.test.js +62 -0
  469. package/lib/vendor/blamejs/test/layer-0-primitives/safe-path.test.js +30 -0
  470. package/lib/vendor/blamejs/test/layer-0-primitives/safe-schema.test.js +104 -0
  471. package/lib/vendor/blamejs/test/layer-0-primitives/safe-sql.test.js +142 -0
  472. package/lib/vendor/blamejs/test/layer-0-primitives/safe-url.test.js +112 -0
  473. package/lib/vendor/blamejs/test/layer-0-primitives/safe-vcard.test.js +26 -0
  474. package/lib/vendor/blamejs/test/layer-0-primitives/scheduler.test.js +157 -0
  475. package/lib/vendor/blamejs/test/layer-0-primitives/scim-server.test.js +396 -0
  476. package/lib/vendor/blamejs/test/layer-0-primitives/sd-jwt-vc.test.js +930 -0
  477. package/lib/vendor/blamejs/test/layer-0-primitives/security-assert.test.js +755 -82
  478. package/lib/vendor/blamejs/test/layer-0-primitives/self-update.test.js +1053 -0
  479. package/lib/vendor/blamejs/test/layer-0-primitives/session-device-binding.test.js +200 -0
  480. package/lib/vendor/blamejs/test/layer-0-primitives/session-strict-binding-missing-failclosed.test.js +110 -0
  481. package/lib/vendor/blamejs/test/layer-0-primitives/sigv4-bucket-ops.test.js +636 -0
  482. package/lib/vendor/blamejs/test/layer-0-primitives/sql-offset-without-limit.test.js +94 -0
  483. package/lib/vendor/blamejs/test/layer-0-primitives/sql.test.js +1190 -0
  484. package/lib/vendor/blamejs/test/layer-0-primitives/ssrf-guard.test.js +21 -0
  485. package/lib/vendor/blamejs/test/layer-0-primitives/static.test.js +850 -0
  486. package/lib/vendor/blamejs/test/layer-0-primitives/storage-presigned-url.test.js +146 -0
  487. package/lib/vendor/blamejs/test/layer-0-primitives/storage.test.js +621 -0
  488. package/lib/vendor/blamejs/test/layer-0-primitives/subject.test.js +47 -0
  489. package/lib/vendor/blamejs/test/layer-0-primitives/template.test.js +582 -0
  490. package/lib/vendor/blamejs/test/layer-0-primitives/tenant-quota.test.js +587 -25
  491. package/lib/vendor/blamejs/test/layer-0-primitives/time.test.js +11 -0
  492. package/lib/vendor/blamejs/test/layer-0-primitives/tsa.test.js +524 -63
  493. package/lib/vendor/blamejs/test/layer-0-primitives/uri-template.test.js +27 -0
  494. package/lib/vendor/blamejs/test/layer-0-primitives/vault-rotate.test.js +866 -0
  495. package/lib/vendor/blamejs/test/layer-0-primitives/vault.test.js +74 -0
  496. package/lib/vendor/blamejs/test/layer-0-primitives/vc.test.js +215 -0
  497. package/lib/vendor/blamejs/test/layer-0-primitives/watcher.test.js +550 -0
  498. package/lib/vendor/blamejs/test/layer-0-primitives/webhook-dispatcher.test.js +388 -0
  499. package/lib/vendor/blamejs/test/layer-0-primitives/webhook.test.js +262 -0
  500. package/lib/vendor/blamejs/test/layer-0-primitives/websocket.test.js +1294 -0
  501. package/lib/vendor/blamejs/test/layer-0-primitives/ws-client.test.js +629 -0
  502. package/lib/vendor/blamejs/test/layer-0-primitives/xml-c14n-attr-normalization.test.js +164 -0
  503. package/lib/vendor/blamejs/test/smoke.js +2 -0
  504. package/package.json +1 -1
  505. package/lib/vendor/blamejs/release-notes/v0.16.0.json +0 -44
  506. package/lib/vendor/blamejs/release-notes/v0.16.1.json +0 -36
  507. package/lib/vendor/blamejs/release-notes/v0.16.2.json +0 -71
  508. package/lib/vendor/blamejs/release-notes/v0.16.3.json +0 -71
  509. package/lib/vendor/blamejs/test/layer-0-primitives/acme-coverage.test.js +0 -441
  510. package/lib/vendor/blamejs/test/layer-0-primitives/auth-oauth-coverage.test.js +0 -482
  511. package/lib/vendor/blamejs/test/layer-0-primitives/auth-saml-coverage.test.js +0 -671
  512. package/lib/vendor/blamejs/test/layer-0-primitives/backup-index-coverage.test.js +0 -690
  513. package/lib/vendor/blamejs/test/layer-0-primitives/cli-coverage.test.js +0 -238
  514. package/lib/vendor/blamejs/test/layer-0-primitives/content-credentials-coverage.test.js +0 -319
  515. package/lib/vendor/blamejs/test/layer-0-primitives/keychain-coverage.test.js +0 -0
  516. package/lib/vendor/blamejs/test/layer-0-primitives/mail-auth-coverage.test.js +0 -437
  517. package/lib/vendor/blamejs/test/layer-0-primitives/mcp-coverage.test.js +0 -443
  518. package/lib/vendor/blamejs/test/layer-0-primitives/metrics-coverage.test.js +0 -395
  519. package/lib/vendor/blamejs/test/layer-0-primitives/network-smtp-policy-coverage.test.js +0 -565
  520. package/lib/vendor/blamejs/test/layer-0-primitives/router-coverage.test.js +0 -592
  521. package/lib/vendor/blamejs/test/layer-0-primitives/sql-coverage.test.js +0 -422
  522. package/lib/vendor/blamejs/test/layer-0-primitives/test-coverage.test.js +0 -573
@@ -1,7 +1,798 @@
1
1
  // XChaCha20-Poly1305 — vendored from @noble/ciphers v2.2.0 by Paul Miller
2
2
  // License: MIT — https://github.com/paulmillr/noble-ciphers
3
3
  // Bundled with esbuild. Exports: xchacha20poly1305
4
- var st=Object.defineProperty;var Ut=Object.getOwnPropertyDescriptor;var At=Object.getOwnPropertyNames;var Tt=Object.prototype.hasOwnProperty;var _t=(e,t)=>{for(var i in t)st(e,i,{get:t[i],enumerable:!0})},Ot=(e,t,i,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of At(t))!Tt.call(e,s)&&s!==i&&st(e,s,{get:()=>t[s],enumerable:!(n=Ut(t,s))||n.enumerable});return e};var Rt=e=>Ot(st({},"__esModule",{value:!0}),e);var Vt={};_t(Vt,{xchacha20poly1305:()=>Bt});module.exports=Rt(Vt);function Ct(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in e&&e.BYTES_PER_ELEMENT===1}function ft(e){if(typeof e!="boolean")throw new TypeError(`boolean expected, not ${e}`)}function tt(e){if(typeof e!="number")throw new TypeError("number expected, got "+typeof e);if(!Number.isSafeInteger(e)||e<0)throw new RangeError("positive integer expected, got "+e)}function j(e,t,i=""){let n=Ct(e),s=e?.length,o=t!==void 0;if(!n||o&&s!==t){let f=i&&`"${i}" `,r=o?` of length ${t}`:"",c=n?`length=${s}`:`type=${typeof e}`,u=f+"expected Uint8Array"+r+", got "+c;throw n?new RangeError(u):new TypeError(u)}return e}function it(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function at(e,t,i=!1){j(e,void 0,"output");let n=t.outputLen;if(e.length<n)throw new RangeError("digestInto() expects output buffer of length at least "+n);if(i&&!et(e))throw new Error("invalid output, must be aligned")}function q(e){return new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4))}function V(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function It(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}var W=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68,lt=e=>e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255,k=W?e=>e:e=>lt(e)>>>0,St=e=>{for(let t=0;t<e.length;t++)e[t]=lt(e[t]);return e},F=W?e=>e:St;function ut(e,t){if(t==null||typeof t!="object")throw new Error("options must be defined");return Object.assign(e,t)}function pt(e,t){if(e.length!==t.length)return!1;let i=0;for(let n=0;n<e.length;n++)i|=e[n]^t[n];return i===0}function yt(e,t,i){let n=t,s=i||(()=>[]),o=(r,c)=>n(c,...s(r)).update(r).digest(),f=n(new Uint8Array(e),...s(new Uint8Array(0)));return o.outputLen=f.outputLen,o.blockLen=f.blockLen,o.create=(r,...c)=>n(r,...c),o}var gt=(e,t)=>{function i(n,...s){if(j(n,void 0,"key"),e.nonceLength!==void 0){let l=s[0];j(l,e.varSizeNonce?void 0:e.nonceLength,"nonce")}let o=e.tagLength;o&&s[1]!==void 0&&j(s[1],void 0,"AAD");let f=t(n,...s),r=(l,y)=>{if(y!==void 0){if(l!==2)throw new Error("cipher output not supported");j(y,void 0,"output")}},c=!1;return{encrypt(l,y){if(c)throw new Error("cannot encrypt() twice with same key + nonce");return c=!0,j(l),r(f.encrypt.length,y),f.encrypt(l,y)},decrypt(l,y){if(j(l),o&&l.length<o)throw new Error('"ciphertext" expected length bigger than tagLength='+o);return r(f.decrypt.length,y),f.decrypt(l,y)}}}return Object.assign(i,e),i};function rt(e,t,i=!0){if(t===void 0)return new Uint8Array(e);if(j(t,void 0,"output"),t.length!==e)throw new Error('"output" expected Uint8Array of length '+e+", got: "+t.length);if(i&&!et(t))throw new Error("invalid output, must be aligned");return t}function xt(e,t,i){tt(e),tt(t),ft(i);let n=new Uint8Array(16),s=It(n);return s.setBigUint64(0,BigInt(t),i),s.setBigUint64(8,BigInt(e),i),n}function et(e){return e.byteOffset%4===0}function nt(e){return Uint8Array.from(j(e))}var wt=e=>Uint8Array.from(e.split(""),t=>t.charCodeAt(0)),vt=F(q(wt("expand 16-byte k"))),Nt=F(q(wt("expand 32-byte k")));function h(e,t){return e<<t|e>>>32-t}var ot=64,Mt=16,ct=2**32-1,dt=Uint32Array.of();function jt(e,t,i,n,s,o,f,r){let c=s.length,u=new Uint8Array(ot),l=q(u),y=W&&et(s)&&et(o),b=y?q(s):dt,w=y?q(o):dt;if(!W){for(let g=0;g<c;f++){if(e(t,i,n,l,f,r),F(l),f>=ct)throw new Error("arx: counter overflow");let x=Math.min(ot,c-g);for(let p=0,d;p<x;p++)d=g+p,o[d]=s[d]^u[p];g+=x}return}for(let g=0;g<c;f++){if(e(t,i,n,l,f,r),f>=ct)throw new Error("arx: counter overflow");let x=Math.min(ot,c-g);if(y&&x===ot){let p=g/4;if(g%4!==0)throw new Error("arx: invalid block position");for(let d=0,L;d<Mt;d++)L=p+d,w[L]=b[L]^l[d];g+=ot;continue}for(let p=0,d;p<x;p++)d=g+p,o[d]=s[d]^u[p];g+=x}}function bt(e,t){let{allowShortKeys:i,extendNonceFn:n,counterLength:s,counterRight:o,rounds:f}=ut({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},t);if(typeof e!="function")throw new Error("core must be a function");return tt(s),tt(f),ft(o),ft(i),(r,c,u,l,y=0)=>{j(r,void 0,"key"),j(c,void 0,"nonce"),j(u,void 0,"data");let b=u.length;if(l=rt(b,l,!1),tt(y),y<0||y>=ct)throw new Error("arx: counter overflow");let w=[],g=r.length,x,p;if(g===32)w.push(x=nt(r)),p=Nt;else if(g===16&&i)x=new Uint8Array(32),x.set(r),x.set(r,16),p=vt,w.push(x);else throw j(r,32,"arx key"),new Error("invalid key size");(!W||!et(c))&&w.push(c=nt(c));let d=q(x);if(n){if(c.length!==24)throw new Error("arx: extended nonce must be 24 bytes");let M=c.subarray(0,16);if(W)n(p,d,q(M),d);else{let $=F(Uint32Array.from(p));n($,d,q(M),d),V($),F(d)}c=c.subarray(16)}else W||F(d);let L=16-s;if(L!==c.length)throw new Error(`arx: nonce must be ${L} or 16 bytes`);if(L!==12){let M=new Uint8Array(12);M.set(c,o?0:12-c.length),c=M,w.push(c)}let v=F(q(c));try{return jt(e,p,d,v,u,l,y,f),l}finally{V(...w)}}}function P(e,t){return e[t++]&255|(e[t++]&255)<<8}var ht=class{blockLen=16;outputLen=16;buffer=new Uint8Array(16);r=new Uint16Array(10);h=new Uint16Array(10);pad=new Uint16Array(8);pos=0;finished=!1;destroyed=!1;constructor(t){t=nt(j(t,32,"key"));let i=P(t,0),n=P(t,2),s=P(t,4),o=P(t,6),f=P(t,8),r=P(t,10),c=P(t,12),u=P(t,14);this.r[0]=i&8191,this.r[1]=(i>>>13|n<<3)&8191,this.r[2]=(n>>>10|s<<6)&7939,this.r[3]=(s>>>7|o<<9)&8191,this.r[4]=(o>>>4|f<<12)&255,this.r[5]=f>>>1&8190,this.r[6]=(f>>>14|r<<2)&8191,this.r[7]=(r>>>11|c<<5)&8065,this.r[8]=(c>>>8|u<<8)&8191,this.r[9]=u>>>5&127;for(let l=0;l<8;l++)this.pad[l]=P(t,16+2*l)}process(t,i,n=!1){let s=n?0:2048,{h:o,r:f}=this,r=f[0],c=f[1],u=f[2],l=f[3],y=f[4],b=f[5],w=f[6],g=f[7],x=f[8],p=f[9],d=P(t,i+0),L=P(t,i+2),v=P(t,i+4),M=P(t,i+6),$=P(t,i+8),z=P(t,i+10),H=P(t,i+12),K=P(t,i+14),m=o[0]+(d&8191),E=o[1]+((d>>>13|L<<3)&8191),B=o[2]+((L>>>10|v<<6)&8191),U=o[3]+((v>>>7|M<<9)&8191),A=o[4]+((M>>>4|$<<12)&8191),T=o[5]+($>>>1&8191),_=o[6]+(($>>>14|z<<2)&8191),O=o[7]+((z>>>11|H<<5)&8191),R=o[8]+((H>>>8|K<<8)&8191),C=o[9]+(K>>>5|s),a=0,S=a+m*r+E*(5*p)+B*(5*x)+U*(5*g)+A*(5*w);a=S>>>13,S&=8191,S+=T*(5*b)+_*(5*y)+O*(5*l)+R*(5*u)+C*(5*c),a+=S>>>13,S&=8191;let N=a+m*c+E*r+B*(5*p)+U*(5*x)+A*(5*g);a=N>>>13,N&=8191,N+=T*(5*w)+_*(5*b)+O*(5*y)+R*(5*l)+C*(5*u),a+=N>>>13,N&=8191;let I=a+m*u+E*c+B*r+U*(5*p)+A*(5*x);a=I>>>13,I&=8191,I+=T*(5*g)+_*(5*w)+O*(5*b)+R*(5*y)+C*(5*l),a+=I>>>13,I&=8191;let Y=a+m*l+E*u+B*c+U*r+A*(5*p);a=Y>>>13,Y&=8191,Y+=T*(5*x)+_*(5*g)+O*(5*w)+R*(5*b)+C*(5*y),a+=Y>>>13,Y&=8191;let Z=a+m*y+E*l+B*u+U*c+A*r;a=Z>>>13,Z&=8191,Z+=T*(5*p)+_*(5*x)+O*(5*g)+R*(5*w)+C*(5*b),a+=Z>>>13,Z&=8191;let G=a+m*b+E*y+B*l+U*u+A*c;a=G>>>13,G&=8191,G+=T*r+_*(5*p)+O*(5*x)+R*(5*g)+C*(5*w),a+=G>>>13,G&=8191;let Q=a+m*w+E*b+B*y+U*l+A*u;a=Q>>>13,Q&=8191,Q+=T*c+_*r+O*(5*p)+R*(5*x)+C*(5*g),a+=Q>>>13,Q&=8191;let J=a+m*g+E*w+B*b+U*y+A*l;a=J>>>13,J&=8191,J+=T*u+_*c+O*r+R*(5*p)+C*(5*x),a+=J>>>13,J&=8191;let X=a+m*x+E*g+B*w+U*b+A*y;a=X>>>13,X&=8191,X+=T*l+_*u+O*c+R*r+C*(5*p),a+=X>>>13,X&=8191;let D=a+m*p+E*x+B*g+U*w+A*b;a=D>>>13,D&=8191,D+=T*y+_*l+O*u+R*c+C*r,a+=D>>>13,D&=8191,a=(a<<2)+a|0,a=a+S|0,S=a&8191,a=a>>>13,N+=a,o[0]=S,o[1]=N,o[2]=I,o[3]=Y,o[4]=Z,o[5]=G,o[6]=Q,o[7]=J,o[8]=X,o[9]=D}finalize(){let{h:t,pad:i}=this,n=new Uint16Array(10),s=t[1]>>>13;t[1]&=8191;for(let r=2;r<10;r++)t[r]+=s,s=t[r]>>>13,t[r]&=8191;t[0]+=s*5,s=t[0]>>>13,t[0]&=8191,t[1]+=s,s=t[1]>>>13,t[1]&=8191,t[2]+=s,n[0]=t[0]+5,s=n[0]>>>13,n[0]&=8191;for(let r=1;r<10;r++)n[r]=t[r]+s,s=n[r]>>>13,n[r]&=8191;n[9]-=8192;let o=(s^1)-1;for(let r=0;r<10;r++)n[r]&=o;o=~o;for(let r=0;r<10;r++)t[r]=t[r]&o|n[r];t[0]=(t[0]|t[1]<<13)&65535,t[1]=(t[1]>>>3|t[2]<<10)&65535,t[2]=(t[2]>>>6|t[3]<<7)&65535,t[3]=(t[3]>>>9|t[4]<<4)&65535,t[4]=(t[4]>>>12|t[5]<<1|t[6]<<14)&65535,t[5]=(t[6]>>>2|t[7]<<11)&65535,t[6]=(t[7]>>>5|t[8]<<8)&65535,t[7]=(t[8]>>>8|t[9]<<5)&65535;let f=t[0]+i[0];t[0]=f&65535;for(let r=1;r<8;r++)f=(t[r]+i[r]|0)+(f>>>16)|0,t[r]=f&65535;V(n)}update(t){it(this),j(t),t=nt(t);let{buffer:i,blockLen:n}=this,s=t.length;for(let o=0;o<s;){let f=Math.min(n-this.pos,s-o);if(f===n){for(;n<=s-o;o+=n)this.process(t,o);continue}i.set(t.subarray(o,o+f),this.pos),this.pos+=f,o+=f,this.pos===n&&(this.process(i,0,!1),this.pos=0)}return this}destroy(){this.destroyed=!0,V(this.h,this.r,this.buffer,this.pad)}digestInto(t){it(this),at(t,this),this.finished=!0;let{buffer:i,h:n}=this,{pos:s}=this;if(s){for(i[s++]=1;s<16;s++)i[s]=0;this.process(i,0,!0)}this.finalize();let o=0;for(let f=0;f<8;f++)t[o++]=n[f]>>>0,t[o++]=n[f]>>>8}digest(){let{buffer:t,outputLen:i}=this;this.digestInto(t);let n=t.slice(0,i);return this.destroy(),n}},Lt=yt(32,e=>new ht(e));function kt(e,t,i,n,s,o=20){let f=e[0],r=e[1],c=e[2],u=e[3],l=t[0],y=t[1],b=t[2],w=t[3],g=t[4],x=t[5],p=t[6],d=t[7],L=s,v=i[0],M=i[1],$=i[2],z=f,H=r,K=c,m=u,E=l,B=y,U=b,A=w,T=g,_=x,O=p,R=d,C=L,a=v,S=M,N=$;for(let Y=0;Y<o;Y+=2)z=z+E|0,C=h(C^z,16),T=T+C|0,E=h(E^T,12),z=z+E|0,C=h(C^z,8),T=T+C|0,E=h(E^T,7),H=H+B|0,a=h(a^H,16),_=_+a|0,B=h(B^_,12),H=H+B|0,a=h(a^H,8),_=_+a|0,B=h(B^_,7),K=K+U|0,S=h(S^K,16),O=O+S|0,U=h(U^O,12),K=K+U|0,S=h(S^K,8),O=O+S|0,U=h(U^O,7),m=m+A|0,N=h(N^m,16),R=R+N|0,A=h(A^R,12),m=m+A|0,N=h(N^m,8),R=R+N|0,A=h(A^R,7),z=z+B|0,N=h(N^z,16),O=O+N|0,B=h(B^O,12),z=z+B|0,N=h(N^z,8),O=O+N|0,B=h(B^O,7),H=H+U|0,C=h(C^H,16),R=R+C|0,U=h(U^R,12),H=H+U|0,C=h(C^H,8),R=R+C|0,U=h(U^R,7),K=K+A|0,a=h(a^K,16),T=T+a|0,A=h(A^T,12),K=K+A|0,a=h(a^K,8),T=T+a|0,A=h(A^T,7),m=m+E|0,S=h(S^m,16),_=_+S|0,E=h(E^_,12),m=m+E|0,S=h(S^m,8),_=_+S|0,E=h(E^_,7);let I=0;n[I++]=f+z|0,n[I++]=r+H|0,n[I++]=c+K|0,n[I++]=u+m|0,n[I++]=l+E|0,n[I++]=y+B|0,n[I++]=b+U|0,n[I++]=w+A|0,n[I++]=g+T|0,n[I++]=x+_|0,n[I++]=p+O|0,n[I++]=d+R|0,n[I++]=L+C|0,n[I++]=v+a|0,n[I++]=M+S|0,n[I++]=$+N|0}function Pt(e,t,i,n){let s=k(e[0]),o=k(e[1]),f=k(e[2]),r=k(e[3]),c=k(t[0]),u=k(t[1]),l=k(t[2]),y=k(t[3]),b=k(t[4]),w=k(t[5]),g=k(t[6]),x=k(t[7]),p=k(i[0]),d=k(i[1]),L=k(i[2]),v=k(i[3]);for(let $=0;$<20;$+=2)s=s+c|0,p=h(p^s,16),b=b+p|0,c=h(c^b,12),s=s+c|0,p=h(p^s,8),b=b+p|0,c=h(c^b,7),o=o+u|0,d=h(d^o,16),w=w+d|0,u=h(u^w,12),o=o+u|0,d=h(d^o,8),w=w+d|0,u=h(u^w,7),f=f+l|0,L=h(L^f,16),g=g+L|0,l=h(l^g,12),f=f+l|0,L=h(L^f,8),g=g+L|0,l=h(l^g,7),r=r+y|0,v=h(v^r,16),x=x+v|0,y=h(y^x,12),r=r+y|0,v=h(v^r,8),x=x+v|0,y=h(y^x,7),s=s+u|0,v=h(v^s,16),g=g+v|0,u=h(u^g,12),s=s+u|0,v=h(v^s,8),g=g+v|0,u=h(u^g,7),o=o+l|0,p=h(p^o,16),x=x+p|0,l=h(l^x,12),o=o+l|0,p=h(p^o,8),x=x+p|0,l=h(l^x,7),f=f+y|0,d=h(d^f,16),b=b+d|0,y=h(y^b,12),f=f+y|0,d=h(d^f,8),b=b+d|0,y=h(y^b,7),r=r+c|0,L=h(L^r,16),w=w+L|0,c=h(c^w,12),r=r+c|0,L=h(L^r,8),w=w+L|0,c=h(c^w,7);let M=0;n[M++]=s,n[M++]=o,n[M++]=f,n[M++]=r,n[M++]=p,n[M++]=d,n[M++]=L,n[M++]=v,F(n)}var zt=bt(kt,{counterRight:!1,counterLength:8,extendNonceFn:Pt,allowShortKeys:!1});var Ht=new Uint8Array(16),mt=(e,t)=>{e.update(t);let i=t.length%16;i&&e.update(Ht.subarray(i))},Kt=new Uint8Array(32);function Et(e,t,i,n,s){s!==void 0&&j(s,void 0,"AAD");let o=e(t,i,Kt),f=xt(n.length,s?s.length:0,!0),r=Lt.create(o);s&&mt(r,s),mt(r,n),r.update(f);let c=r.digest();return V(o,f),c}var $t=e=>(t,i,n)=>({encrypt(o,f){let r=o.length;f=rt(r+16,f,!1),f.set(o);let c=f.subarray(0,-16);e(t,i,c,c,1);let u=Et(e,t,i,c,n);return f.set(u,r),V(u),f},decrypt(o,f){f=rt(o.length-16,f,!1);let r=o.subarray(0,-16),c=o.subarray(-16),u=Et(e,t,i,r,n);if(!pt(c,u))throw V(u),new Error("invalid tag");return f.set(o.subarray(0,-16)),e(t,i,f,f,1),V(u),f}});var Bt=gt({blockSize:64,nonceLength:24,tagLength:16},$t(zt));0&&(module.exports={xchacha20poly1305});
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
21
+
22
+ // _entry.mjs
23
+ var entry_exports = {};
24
+ __export(entry_exports, {
25
+ xchacha20poly1305: () => xchacha20poly1305
26
+ });
27
+ module.exports = __toCommonJS(entry_exports);
28
+
29
+ // node_modules/@noble/ciphers/utils.js
30
+ function isBytes(a) {
31
+ return a instanceof Uint8Array || ArrayBuffer.isView(a) && a.constructor.name === "Uint8Array" && "BYTES_PER_ELEMENT" in a && a.BYTES_PER_ELEMENT === 1;
32
+ }
33
+ function abool(b) {
34
+ if (typeof b !== "boolean")
35
+ throw new TypeError(`boolean expected, not ${b}`);
36
+ }
37
+ function anumber(n) {
38
+ if (typeof n !== "number")
39
+ throw new TypeError("number expected, got " + typeof n);
40
+ if (!Number.isSafeInteger(n) || n < 0)
41
+ throw new RangeError("positive integer expected, got " + n);
42
+ }
43
+ function abytes(value, length, title = "") {
44
+ const bytes = isBytes(value);
45
+ const len = value?.length;
46
+ const needsLen = length !== void 0;
47
+ if (!bytes || needsLen && len !== length) {
48
+ const prefix = title && `"${title}" `;
49
+ const ofLen = needsLen ? ` of length ${length}` : "";
50
+ const got = bytes ? `length=${len}` : `type=${typeof value}`;
51
+ const message = prefix + "expected Uint8Array" + ofLen + ", got " + got;
52
+ if (!bytes)
53
+ throw new TypeError(message);
54
+ throw new RangeError(message);
55
+ }
56
+ return value;
57
+ }
58
+ function aexists(instance, checkFinished = true) {
59
+ if (instance.destroyed)
60
+ throw new Error("Hash instance has been destroyed");
61
+ if (checkFinished && instance.finished)
62
+ throw new Error("Hash#digest() has already been called");
63
+ }
64
+ function aoutput(out, instance, onlyAligned = false) {
65
+ abytes(out, void 0, "output");
66
+ const min = instance.outputLen;
67
+ if (out.length < min) {
68
+ throw new RangeError("digestInto() expects output buffer of length at least " + min);
69
+ }
70
+ if (onlyAligned && !isAligned32(out))
71
+ throw new Error("invalid output, must be aligned");
72
+ }
73
+ function u32(arr) {
74
+ return new Uint32Array(arr.buffer, arr.byteOffset, Math.floor(arr.byteLength / 4));
75
+ }
76
+ function clean(...arrays) {
77
+ for (let i = 0; i < arrays.length; i++) {
78
+ arrays[i].fill(0);
79
+ }
80
+ }
81
+ function createView(arr) {
82
+ return new DataView(arr.buffer, arr.byteOffset, arr.byteLength);
83
+ }
84
+ var isLE = /* @__PURE__ */ (() => new Uint8Array(new Uint32Array([287454020]).buffer)[0] === 68)();
85
+ var byteSwap = (word) => word << 24 & 4278190080 | word << 8 & 16711680 | word >>> 8 & 65280 | word >>> 24 & 255;
86
+ var swap8IfBE = isLE ? (n) => n : (n) => byteSwap(n) >>> 0;
87
+ var byteSwap32 = (arr) => {
88
+ for (let i = 0; i < arr.length; i++)
89
+ arr[i] = byteSwap(arr[i]);
90
+ return arr;
91
+ };
92
+ var swap32IfBE = isLE ? (u) => u : byteSwap32;
93
+ function checkOpts(defaults, opts) {
94
+ if (opts == null || typeof opts !== "object")
95
+ throw new Error("options must be defined");
96
+ const merged = Object.assign(defaults, opts);
97
+ return merged;
98
+ }
99
+ function equalBytes(a, b) {
100
+ if (a.length !== b.length)
101
+ return false;
102
+ let diff = 0;
103
+ for (let i = 0; i < a.length; i++)
104
+ diff |= a[i] ^ b[i];
105
+ return diff === 0;
106
+ }
107
+ function wrapMacConstructor(keyLen, macCons, fromMsg) {
108
+ const mac = macCons;
109
+ const getArgs = fromMsg || (() => []);
110
+ const macC = (msg, key) => mac(key, ...getArgs(msg)).update(msg).digest();
111
+ const tmp = mac(new Uint8Array(keyLen), ...getArgs(new Uint8Array(0)));
112
+ macC.outputLen = tmp.outputLen;
113
+ macC.blockLen = tmp.blockLen;
114
+ macC.create = (key, ...args) => mac(key, ...args);
115
+ return macC;
116
+ }
117
+ var wrapCipher = /* @__NO_SIDE_EFFECTS__ */ (params, constructor) => {
118
+ function wrappedCipher(key, ...args) {
119
+ abytes(key, void 0, "key");
120
+ if (params.nonceLength !== void 0) {
121
+ const nonce = args[0];
122
+ abytes(nonce, params.varSizeNonce ? void 0 : params.nonceLength, "nonce");
123
+ }
124
+ const tagl = params.tagLength;
125
+ if (tagl && args[1] !== void 0)
126
+ abytes(args[1], void 0, "AAD");
127
+ const cipher = constructor(key, ...args);
128
+ const checkOutput = (fnLength, output) => {
129
+ if (output !== void 0) {
130
+ if (fnLength !== 2)
131
+ throw new Error("cipher output not supported");
132
+ abytes(output, void 0, "output");
133
+ }
134
+ };
135
+ let called = false;
136
+ const wrCipher = {
137
+ encrypt(data, output) {
138
+ if (called)
139
+ throw new Error("cannot encrypt() twice with same key + nonce");
140
+ called = true;
141
+ abytes(data);
142
+ checkOutput(cipher.encrypt.length, output);
143
+ return cipher.encrypt(data, output);
144
+ },
145
+ decrypt(data, output) {
146
+ abytes(data);
147
+ if (tagl && data.length < tagl)
148
+ throw new Error('"ciphertext" expected length bigger than tagLength=' + tagl);
149
+ checkOutput(cipher.decrypt.length, output);
150
+ return cipher.decrypt(data, output);
151
+ }
152
+ };
153
+ return wrCipher;
154
+ }
155
+ Object.assign(wrappedCipher, params);
156
+ return wrappedCipher;
157
+ };
158
+ function getOutput(expectedLength, out, onlyAligned = true) {
159
+ if (out === void 0)
160
+ return new Uint8Array(expectedLength);
161
+ abytes(out, void 0, "output");
162
+ if (out.length !== expectedLength)
163
+ throw new Error('"output" expected Uint8Array of length ' + expectedLength + ", got: " + out.length);
164
+ if (onlyAligned && !isAligned32(out))
165
+ throw new Error("invalid output, must be aligned");
166
+ return out;
167
+ }
168
+ function u64Lengths(dataLength, aadLength, isLE2) {
169
+ anumber(dataLength);
170
+ anumber(aadLength);
171
+ abool(isLE2);
172
+ const num = new Uint8Array(16);
173
+ const view = createView(num);
174
+ view.setBigUint64(0, BigInt(aadLength), isLE2);
175
+ view.setBigUint64(8, BigInt(dataLength), isLE2);
176
+ return num;
177
+ }
178
+ function isAligned32(bytes) {
179
+ return bytes.byteOffset % 4 === 0;
180
+ }
181
+ function copyBytes(bytes) {
182
+ return Uint8Array.from(abytes(bytes));
183
+ }
184
+
185
+ // node_modules/@noble/ciphers/_arx.js
186
+ var encodeStr = (str) => Uint8Array.from(str.split(""), (c) => c.charCodeAt(0));
187
+ var sigma16_32 = /* @__PURE__ */ (() => swap32IfBE(u32(encodeStr("expand 16-byte k"))))();
188
+ var sigma32_32 = /* @__PURE__ */ (() => swap32IfBE(u32(encodeStr("expand 32-byte k"))))();
189
+ function rotl(a, b) {
190
+ return a << b | a >>> 32 - b;
191
+ }
192
+ var BLOCK_LEN = 64;
193
+ var BLOCK_LEN32 = 16;
194
+ var MAX_COUNTER = /* @__PURE__ */ (() => 2 ** 32 - 1)();
195
+ var U32_EMPTY = /* @__PURE__ */ Uint32Array.of();
196
+ function runCipher(core, sigma, key, nonce, data, output, counter, rounds) {
197
+ const len = data.length;
198
+ const block = new Uint8Array(BLOCK_LEN);
199
+ const b32 = u32(block);
200
+ const isAligned = isLE && isAligned32(data) && isAligned32(output);
201
+ const d32 = isAligned ? u32(data) : U32_EMPTY;
202
+ const o32 = isAligned ? u32(output) : U32_EMPTY;
203
+ if (!isLE) {
204
+ for (let pos = 0; pos < len; counter++) {
205
+ core(sigma, key, nonce, b32, counter, rounds);
206
+ swap32IfBE(b32);
207
+ if (counter >= MAX_COUNTER)
208
+ throw new Error("arx: counter overflow");
209
+ const take = Math.min(BLOCK_LEN, len - pos);
210
+ for (let j = 0, posj; j < take; j++) {
211
+ posj = pos + j;
212
+ output[posj] = data[posj] ^ block[j];
213
+ }
214
+ pos += take;
215
+ }
216
+ return;
217
+ }
218
+ for (let pos = 0; pos < len; counter++) {
219
+ core(sigma, key, nonce, b32, counter, rounds);
220
+ if (counter >= MAX_COUNTER)
221
+ throw new Error("arx: counter overflow");
222
+ const take = Math.min(BLOCK_LEN, len - pos);
223
+ if (isAligned && take === BLOCK_LEN) {
224
+ const pos32 = pos / 4;
225
+ if (pos % 4 !== 0)
226
+ throw new Error("arx: invalid block position");
227
+ for (let j = 0, posj; j < BLOCK_LEN32; j++) {
228
+ posj = pos32 + j;
229
+ o32[posj] = d32[posj] ^ b32[j];
230
+ }
231
+ pos += BLOCK_LEN;
232
+ continue;
233
+ }
234
+ for (let j = 0, posj; j < take; j++) {
235
+ posj = pos + j;
236
+ output[posj] = data[posj] ^ block[j];
237
+ }
238
+ pos += take;
239
+ }
240
+ }
241
+ function createCipher(core, opts) {
242
+ const { allowShortKeys, extendNonceFn, counterLength, counterRight, rounds } = checkOpts({ allowShortKeys: false, counterLength: 8, counterRight: false, rounds: 20 }, opts);
243
+ if (typeof core !== "function")
244
+ throw new Error("core must be a function");
245
+ anumber(counterLength);
246
+ anumber(rounds);
247
+ abool(counterRight);
248
+ abool(allowShortKeys);
249
+ return (key, nonce, data, output, counter = 0) => {
250
+ abytes(key, void 0, "key");
251
+ abytes(nonce, void 0, "nonce");
252
+ abytes(data, void 0, "data");
253
+ const len = data.length;
254
+ output = getOutput(len, output, false);
255
+ anumber(counter);
256
+ if (counter < 0 || counter >= MAX_COUNTER)
257
+ throw new Error("arx: counter overflow");
258
+ const toClean = [];
259
+ let l = key.length;
260
+ let k;
261
+ let sigma;
262
+ if (l === 32) {
263
+ toClean.push(k = copyBytes(key));
264
+ sigma = sigma32_32;
265
+ } else if (l === 16 && allowShortKeys) {
266
+ k = new Uint8Array(32);
267
+ k.set(key);
268
+ k.set(key, 16);
269
+ sigma = sigma16_32;
270
+ toClean.push(k);
271
+ } else {
272
+ abytes(key, 32, "arx key");
273
+ throw new Error("invalid key size");
274
+ }
275
+ if (!isLE || !isAligned32(nonce))
276
+ toClean.push(nonce = copyBytes(nonce));
277
+ let k32 = u32(k);
278
+ if (extendNonceFn) {
279
+ if (nonce.length !== 24)
280
+ throw new Error(`arx: extended nonce must be 24 bytes`);
281
+ const n16 = nonce.subarray(0, 16);
282
+ if (isLE)
283
+ extendNonceFn(sigma, k32, u32(n16), k32);
284
+ else {
285
+ const sigmaRaw = swap32IfBE(Uint32Array.from(sigma));
286
+ extendNonceFn(sigmaRaw, k32, u32(n16), k32);
287
+ clean(sigmaRaw);
288
+ swap32IfBE(k32);
289
+ }
290
+ nonce = nonce.subarray(16);
291
+ } else if (!isLE)
292
+ swap32IfBE(k32);
293
+ const nonceNcLen = 16 - counterLength;
294
+ if (nonceNcLen !== nonce.length)
295
+ throw new Error(`arx: nonce must be ${nonceNcLen} or 16 bytes`);
296
+ if (nonceNcLen !== 12) {
297
+ const nc = new Uint8Array(12);
298
+ nc.set(nonce, counterRight ? 0 : 12 - nonce.length);
299
+ nonce = nc;
300
+ toClean.push(nonce);
301
+ }
302
+ const n32 = swap32IfBE(u32(nonce));
303
+ try {
304
+ runCipher(core, sigma, k32, n32, data, output, counter, rounds);
305
+ return output;
306
+ } finally {
307
+ clean(...toClean);
308
+ }
309
+ };
310
+ }
311
+
312
+ // node_modules/@noble/ciphers/_poly1305.js
313
+ function u8to16(a, i) {
314
+ return a[i++] & 255 | (a[i++] & 255) << 8;
315
+ }
316
+ var Poly1305 = class {
317
+ blockLen = 16;
318
+ outputLen = 16;
319
+ buffer = new Uint8Array(16);
320
+ r = new Uint16Array(10);
321
+ // Allocating 1 array with .subarray() here is slower than 3
322
+ h = new Uint16Array(10);
323
+ pad = new Uint16Array(8);
324
+ pos = 0;
325
+ finished = false;
326
+ destroyed = false;
327
+ // Can be speed-up using BigUint64Array, at the cost of complexity
328
+ constructor(key) {
329
+ key = copyBytes(abytes(key, 32, "key"));
330
+ const t0 = u8to16(key, 0);
331
+ const t1 = u8to16(key, 2);
332
+ const t2 = u8to16(key, 4);
333
+ const t3 = u8to16(key, 6);
334
+ const t4 = u8to16(key, 8);
335
+ const t5 = u8to16(key, 10);
336
+ const t6 = u8to16(key, 12);
337
+ const t7 = u8to16(key, 14);
338
+ this.r[0] = t0 & 8191;
339
+ this.r[1] = (t0 >>> 13 | t1 << 3) & 8191;
340
+ this.r[2] = (t1 >>> 10 | t2 << 6) & 7939;
341
+ this.r[3] = (t2 >>> 7 | t3 << 9) & 8191;
342
+ this.r[4] = (t3 >>> 4 | t4 << 12) & 255;
343
+ this.r[5] = t4 >>> 1 & 8190;
344
+ this.r[6] = (t4 >>> 14 | t5 << 2) & 8191;
345
+ this.r[7] = (t5 >>> 11 | t6 << 5) & 8065;
346
+ this.r[8] = (t6 >>> 8 | t7 << 8) & 8191;
347
+ this.r[9] = t7 >>> 5 & 127;
348
+ for (let i = 0; i < 8; i++)
349
+ this.pad[i] = u8to16(key, 16 + 2 * i);
350
+ }
351
+ process(data, offset, isLast = false) {
352
+ const hibit = isLast ? 0 : 1 << 11;
353
+ const { h, r } = this;
354
+ const r0 = r[0];
355
+ const r1 = r[1];
356
+ const r2 = r[2];
357
+ const r3 = r[3];
358
+ const r4 = r[4];
359
+ const r5 = r[5];
360
+ const r6 = r[6];
361
+ const r7 = r[7];
362
+ const r8 = r[8];
363
+ const r9 = r[9];
364
+ const t0 = u8to16(data, offset + 0);
365
+ const t1 = u8to16(data, offset + 2);
366
+ const t2 = u8to16(data, offset + 4);
367
+ const t3 = u8to16(data, offset + 6);
368
+ const t4 = u8to16(data, offset + 8);
369
+ const t5 = u8to16(data, offset + 10);
370
+ const t6 = u8to16(data, offset + 12);
371
+ const t7 = u8to16(data, offset + 14);
372
+ let h0 = h[0] + (t0 & 8191);
373
+ let h1 = h[1] + ((t0 >>> 13 | t1 << 3) & 8191);
374
+ let h2 = h[2] + ((t1 >>> 10 | t2 << 6) & 8191);
375
+ let h3 = h[3] + ((t2 >>> 7 | t3 << 9) & 8191);
376
+ let h4 = h[4] + ((t3 >>> 4 | t4 << 12) & 8191);
377
+ let h5 = h[5] + (t4 >>> 1 & 8191);
378
+ let h6 = h[6] + ((t4 >>> 14 | t5 << 2) & 8191);
379
+ let h7 = h[7] + ((t5 >>> 11 | t6 << 5) & 8191);
380
+ let h8 = h[8] + ((t6 >>> 8 | t7 << 8) & 8191);
381
+ let h9 = h[9] + (t7 >>> 5 | hibit);
382
+ let c = 0;
383
+ let d0 = c + h0 * r0 + h1 * (5 * r9) + h2 * (5 * r8) + h3 * (5 * r7) + h4 * (5 * r6);
384
+ c = d0 >>> 13;
385
+ d0 &= 8191;
386
+ d0 += h5 * (5 * r5) + h6 * (5 * r4) + h7 * (5 * r3) + h8 * (5 * r2) + h9 * (5 * r1);
387
+ c += d0 >>> 13;
388
+ d0 &= 8191;
389
+ let d1 = c + h0 * r1 + h1 * r0 + h2 * (5 * r9) + h3 * (5 * r8) + h4 * (5 * r7);
390
+ c = d1 >>> 13;
391
+ d1 &= 8191;
392
+ d1 += h5 * (5 * r6) + h6 * (5 * r5) + h7 * (5 * r4) + h8 * (5 * r3) + h9 * (5 * r2);
393
+ c += d1 >>> 13;
394
+ d1 &= 8191;
395
+ let d2 = c + h0 * r2 + h1 * r1 + h2 * r0 + h3 * (5 * r9) + h4 * (5 * r8);
396
+ c = d2 >>> 13;
397
+ d2 &= 8191;
398
+ d2 += h5 * (5 * r7) + h6 * (5 * r6) + h7 * (5 * r5) + h8 * (5 * r4) + h9 * (5 * r3);
399
+ c += d2 >>> 13;
400
+ d2 &= 8191;
401
+ let d3 = c + h0 * r3 + h1 * r2 + h2 * r1 + h3 * r0 + h4 * (5 * r9);
402
+ c = d3 >>> 13;
403
+ d3 &= 8191;
404
+ d3 += h5 * (5 * r8) + h6 * (5 * r7) + h7 * (5 * r6) + h8 * (5 * r5) + h9 * (5 * r4);
405
+ c += d3 >>> 13;
406
+ d3 &= 8191;
407
+ let d4 = c + h0 * r4 + h1 * r3 + h2 * r2 + h3 * r1 + h4 * r0;
408
+ c = d4 >>> 13;
409
+ d4 &= 8191;
410
+ d4 += h5 * (5 * r9) + h6 * (5 * r8) + h7 * (5 * r7) + h8 * (5 * r6) + h9 * (5 * r5);
411
+ c += d4 >>> 13;
412
+ d4 &= 8191;
413
+ let d5 = c + h0 * r5 + h1 * r4 + h2 * r3 + h3 * r2 + h4 * r1;
414
+ c = d5 >>> 13;
415
+ d5 &= 8191;
416
+ d5 += h5 * r0 + h6 * (5 * r9) + h7 * (5 * r8) + h8 * (5 * r7) + h9 * (5 * r6);
417
+ c += d5 >>> 13;
418
+ d5 &= 8191;
419
+ let d6 = c + h0 * r6 + h1 * r5 + h2 * r4 + h3 * r3 + h4 * r2;
420
+ c = d6 >>> 13;
421
+ d6 &= 8191;
422
+ d6 += h5 * r1 + h6 * r0 + h7 * (5 * r9) + h8 * (5 * r8) + h9 * (5 * r7);
423
+ c += d6 >>> 13;
424
+ d6 &= 8191;
425
+ let d7 = c + h0 * r7 + h1 * r6 + h2 * r5 + h3 * r4 + h4 * r3;
426
+ c = d7 >>> 13;
427
+ d7 &= 8191;
428
+ d7 += h5 * r2 + h6 * r1 + h7 * r0 + h8 * (5 * r9) + h9 * (5 * r8);
429
+ c += d7 >>> 13;
430
+ d7 &= 8191;
431
+ let d8 = c + h0 * r8 + h1 * r7 + h2 * r6 + h3 * r5 + h4 * r4;
432
+ c = d8 >>> 13;
433
+ d8 &= 8191;
434
+ d8 += h5 * r3 + h6 * r2 + h7 * r1 + h8 * r0 + h9 * (5 * r9);
435
+ c += d8 >>> 13;
436
+ d8 &= 8191;
437
+ let d9 = c + h0 * r9 + h1 * r8 + h2 * r7 + h3 * r6 + h4 * r5;
438
+ c = d9 >>> 13;
439
+ d9 &= 8191;
440
+ d9 += h5 * r4 + h6 * r3 + h7 * r2 + h8 * r1 + h9 * r0;
441
+ c += d9 >>> 13;
442
+ d9 &= 8191;
443
+ c = (c << 2) + c | 0;
444
+ c = c + d0 | 0;
445
+ d0 = c & 8191;
446
+ c = c >>> 13;
447
+ d1 += c;
448
+ h[0] = d0;
449
+ h[1] = d1;
450
+ h[2] = d2;
451
+ h[3] = d3;
452
+ h[4] = d4;
453
+ h[5] = d5;
454
+ h[6] = d6;
455
+ h[7] = d7;
456
+ h[8] = d8;
457
+ h[9] = d9;
458
+ }
459
+ finalize() {
460
+ const { h, pad } = this;
461
+ const g = new Uint16Array(10);
462
+ let c = h[1] >>> 13;
463
+ h[1] &= 8191;
464
+ for (let i = 2; i < 10; i++) {
465
+ h[i] += c;
466
+ c = h[i] >>> 13;
467
+ h[i] &= 8191;
468
+ }
469
+ h[0] += c * 5;
470
+ c = h[0] >>> 13;
471
+ h[0] &= 8191;
472
+ h[1] += c;
473
+ c = h[1] >>> 13;
474
+ h[1] &= 8191;
475
+ h[2] += c;
476
+ g[0] = h[0] + 5;
477
+ c = g[0] >>> 13;
478
+ g[0] &= 8191;
479
+ for (let i = 1; i < 10; i++) {
480
+ g[i] = h[i] + c;
481
+ c = g[i] >>> 13;
482
+ g[i] &= 8191;
483
+ }
484
+ g[9] -= 1 << 13;
485
+ let mask = (c ^ 1) - 1;
486
+ for (let i = 0; i < 10; i++)
487
+ g[i] &= mask;
488
+ mask = ~mask;
489
+ for (let i = 0; i < 10; i++)
490
+ h[i] = h[i] & mask | g[i];
491
+ h[0] = (h[0] | h[1] << 13) & 65535;
492
+ h[1] = (h[1] >>> 3 | h[2] << 10) & 65535;
493
+ h[2] = (h[2] >>> 6 | h[3] << 7) & 65535;
494
+ h[3] = (h[3] >>> 9 | h[4] << 4) & 65535;
495
+ h[4] = (h[4] >>> 12 | h[5] << 1 | h[6] << 14) & 65535;
496
+ h[5] = (h[6] >>> 2 | h[7] << 11) & 65535;
497
+ h[6] = (h[7] >>> 5 | h[8] << 8) & 65535;
498
+ h[7] = (h[8] >>> 8 | h[9] << 5) & 65535;
499
+ let f = h[0] + pad[0];
500
+ h[0] = f & 65535;
501
+ for (let i = 1; i < 8; i++) {
502
+ f = (h[i] + pad[i] | 0) + (f >>> 16) | 0;
503
+ h[i] = f & 65535;
504
+ }
505
+ clean(g);
506
+ }
507
+ update(data) {
508
+ aexists(this);
509
+ abytes(data);
510
+ data = copyBytes(data);
511
+ const { buffer, blockLen } = this;
512
+ const len = data.length;
513
+ for (let pos = 0; pos < len; ) {
514
+ const take = Math.min(blockLen - this.pos, len - pos);
515
+ if (take === blockLen) {
516
+ for (; blockLen <= len - pos; pos += blockLen)
517
+ this.process(data, pos);
518
+ continue;
519
+ }
520
+ buffer.set(data.subarray(pos, pos + take), this.pos);
521
+ this.pos += take;
522
+ pos += take;
523
+ if (this.pos === blockLen) {
524
+ this.process(buffer, 0, false);
525
+ this.pos = 0;
526
+ }
527
+ }
528
+ return this;
529
+ }
530
+ destroy() {
531
+ this.destroyed = true;
532
+ clean(this.h, this.r, this.buffer, this.pad);
533
+ }
534
+ digestInto(out) {
535
+ aexists(this);
536
+ aoutput(out, this);
537
+ this.finished = true;
538
+ const { buffer, h } = this;
539
+ let { pos } = this;
540
+ if (pos) {
541
+ buffer[pos++] = 1;
542
+ for (; pos < 16; pos++)
543
+ buffer[pos] = 0;
544
+ this.process(buffer, 0, true);
545
+ }
546
+ this.finalize();
547
+ let opos = 0;
548
+ for (let i = 0; i < 8; i++) {
549
+ out[opos++] = h[i] >>> 0;
550
+ out[opos++] = h[i] >>> 8;
551
+ }
552
+ }
553
+ digest() {
554
+ const { buffer, outputLen } = this;
555
+ this.digestInto(buffer);
556
+ const res = buffer.slice(0, outputLen);
557
+ this.destroy();
558
+ return res;
559
+ }
560
+ };
561
+ var poly1305 = /* @__PURE__ */ wrapMacConstructor(32, (key) => new Poly1305(key));
562
+
563
+ // node_modules/@noble/ciphers/chacha.js
564
+ function chachaCore(s, k, n, out, cnt, rounds = 20) {
565
+ let y00 = s[0], y01 = s[1], y02 = s[2], y03 = s[3], y04 = k[0], y05 = k[1], y06 = k[2], y07 = k[3], y08 = k[4], y09 = k[5], y10 = k[6], y11 = k[7], y12 = cnt, y13 = n[0], y14 = n[1], y15 = n[2];
566
+ let x00 = y00, x01 = y01, x02 = y02, x03 = y03, x04 = y04, x05 = y05, x06 = y06, x07 = y07, x08 = y08, x09 = y09, x10 = y10, x11 = y11, x12 = y12, x13 = y13, x14 = y14, x15 = y15;
567
+ for (let r = 0; r < rounds; r += 2) {
568
+ x00 = x00 + x04 | 0;
569
+ x12 = rotl(x12 ^ x00, 16);
570
+ x08 = x08 + x12 | 0;
571
+ x04 = rotl(x04 ^ x08, 12);
572
+ x00 = x00 + x04 | 0;
573
+ x12 = rotl(x12 ^ x00, 8);
574
+ x08 = x08 + x12 | 0;
575
+ x04 = rotl(x04 ^ x08, 7);
576
+ x01 = x01 + x05 | 0;
577
+ x13 = rotl(x13 ^ x01, 16);
578
+ x09 = x09 + x13 | 0;
579
+ x05 = rotl(x05 ^ x09, 12);
580
+ x01 = x01 + x05 | 0;
581
+ x13 = rotl(x13 ^ x01, 8);
582
+ x09 = x09 + x13 | 0;
583
+ x05 = rotl(x05 ^ x09, 7);
584
+ x02 = x02 + x06 | 0;
585
+ x14 = rotl(x14 ^ x02, 16);
586
+ x10 = x10 + x14 | 0;
587
+ x06 = rotl(x06 ^ x10, 12);
588
+ x02 = x02 + x06 | 0;
589
+ x14 = rotl(x14 ^ x02, 8);
590
+ x10 = x10 + x14 | 0;
591
+ x06 = rotl(x06 ^ x10, 7);
592
+ x03 = x03 + x07 | 0;
593
+ x15 = rotl(x15 ^ x03, 16);
594
+ x11 = x11 + x15 | 0;
595
+ x07 = rotl(x07 ^ x11, 12);
596
+ x03 = x03 + x07 | 0;
597
+ x15 = rotl(x15 ^ x03, 8);
598
+ x11 = x11 + x15 | 0;
599
+ x07 = rotl(x07 ^ x11, 7);
600
+ x00 = x00 + x05 | 0;
601
+ x15 = rotl(x15 ^ x00, 16);
602
+ x10 = x10 + x15 | 0;
603
+ x05 = rotl(x05 ^ x10, 12);
604
+ x00 = x00 + x05 | 0;
605
+ x15 = rotl(x15 ^ x00, 8);
606
+ x10 = x10 + x15 | 0;
607
+ x05 = rotl(x05 ^ x10, 7);
608
+ x01 = x01 + x06 | 0;
609
+ x12 = rotl(x12 ^ x01, 16);
610
+ x11 = x11 + x12 | 0;
611
+ x06 = rotl(x06 ^ x11, 12);
612
+ x01 = x01 + x06 | 0;
613
+ x12 = rotl(x12 ^ x01, 8);
614
+ x11 = x11 + x12 | 0;
615
+ x06 = rotl(x06 ^ x11, 7);
616
+ x02 = x02 + x07 | 0;
617
+ x13 = rotl(x13 ^ x02, 16);
618
+ x08 = x08 + x13 | 0;
619
+ x07 = rotl(x07 ^ x08, 12);
620
+ x02 = x02 + x07 | 0;
621
+ x13 = rotl(x13 ^ x02, 8);
622
+ x08 = x08 + x13 | 0;
623
+ x07 = rotl(x07 ^ x08, 7);
624
+ x03 = x03 + x04 | 0;
625
+ x14 = rotl(x14 ^ x03, 16);
626
+ x09 = x09 + x14 | 0;
627
+ x04 = rotl(x04 ^ x09, 12);
628
+ x03 = x03 + x04 | 0;
629
+ x14 = rotl(x14 ^ x03, 8);
630
+ x09 = x09 + x14 | 0;
631
+ x04 = rotl(x04 ^ x09, 7);
632
+ }
633
+ let oi = 0;
634
+ out[oi++] = y00 + x00 | 0;
635
+ out[oi++] = y01 + x01 | 0;
636
+ out[oi++] = y02 + x02 | 0;
637
+ out[oi++] = y03 + x03 | 0;
638
+ out[oi++] = y04 + x04 | 0;
639
+ out[oi++] = y05 + x05 | 0;
640
+ out[oi++] = y06 + x06 | 0;
641
+ out[oi++] = y07 + x07 | 0;
642
+ out[oi++] = y08 + x08 | 0;
643
+ out[oi++] = y09 + x09 | 0;
644
+ out[oi++] = y10 + x10 | 0;
645
+ out[oi++] = y11 + x11 | 0;
646
+ out[oi++] = y12 + x12 | 0;
647
+ out[oi++] = y13 + x13 | 0;
648
+ out[oi++] = y14 + x14 | 0;
649
+ out[oi++] = y15 + x15 | 0;
650
+ }
651
+ function hchacha(s, k, i, out) {
652
+ let x00 = swap8IfBE(s[0]), x01 = swap8IfBE(s[1]), x02 = swap8IfBE(s[2]), x03 = swap8IfBE(s[3]), x04 = swap8IfBE(k[0]), x05 = swap8IfBE(k[1]), x06 = swap8IfBE(k[2]), x07 = swap8IfBE(k[3]), x08 = swap8IfBE(k[4]), x09 = swap8IfBE(k[5]), x10 = swap8IfBE(k[6]), x11 = swap8IfBE(k[7]), x12 = swap8IfBE(i[0]), x13 = swap8IfBE(i[1]), x14 = swap8IfBE(i[2]), x15 = swap8IfBE(i[3]);
653
+ for (let r = 0; r < 20; r += 2) {
654
+ x00 = x00 + x04 | 0;
655
+ x12 = rotl(x12 ^ x00, 16);
656
+ x08 = x08 + x12 | 0;
657
+ x04 = rotl(x04 ^ x08, 12);
658
+ x00 = x00 + x04 | 0;
659
+ x12 = rotl(x12 ^ x00, 8);
660
+ x08 = x08 + x12 | 0;
661
+ x04 = rotl(x04 ^ x08, 7);
662
+ x01 = x01 + x05 | 0;
663
+ x13 = rotl(x13 ^ x01, 16);
664
+ x09 = x09 + x13 | 0;
665
+ x05 = rotl(x05 ^ x09, 12);
666
+ x01 = x01 + x05 | 0;
667
+ x13 = rotl(x13 ^ x01, 8);
668
+ x09 = x09 + x13 | 0;
669
+ x05 = rotl(x05 ^ x09, 7);
670
+ x02 = x02 + x06 | 0;
671
+ x14 = rotl(x14 ^ x02, 16);
672
+ x10 = x10 + x14 | 0;
673
+ x06 = rotl(x06 ^ x10, 12);
674
+ x02 = x02 + x06 | 0;
675
+ x14 = rotl(x14 ^ x02, 8);
676
+ x10 = x10 + x14 | 0;
677
+ x06 = rotl(x06 ^ x10, 7);
678
+ x03 = x03 + x07 | 0;
679
+ x15 = rotl(x15 ^ x03, 16);
680
+ x11 = x11 + x15 | 0;
681
+ x07 = rotl(x07 ^ x11, 12);
682
+ x03 = x03 + x07 | 0;
683
+ x15 = rotl(x15 ^ x03, 8);
684
+ x11 = x11 + x15 | 0;
685
+ x07 = rotl(x07 ^ x11, 7);
686
+ x00 = x00 + x05 | 0;
687
+ x15 = rotl(x15 ^ x00, 16);
688
+ x10 = x10 + x15 | 0;
689
+ x05 = rotl(x05 ^ x10, 12);
690
+ x00 = x00 + x05 | 0;
691
+ x15 = rotl(x15 ^ x00, 8);
692
+ x10 = x10 + x15 | 0;
693
+ x05 = rotl(x05 ^ x10, 7);
694
+ x01 = x01 + x06 | 0;
695
+ x12 = rotl(x12 ^ x01, 16);
696
+ x11 = x11 + x12 | 0;
697
+ x06 = rotl(x06 ^ x11, 12);
698
+ x01 = x01 + x06 | 0;
699
+ x12 = rotl(x12 ^ x01, 8);
700
+ x11 = x11 + x12 | 0;
701
+ x06 = rotl(x06 ^ x11, 7);
702
+ x02 = x02 + x07 | 0;
703
+ x13 = rotl(x13 ^ x02, 16);
704
+ x08 = x08 + x13 | 0;
705
+ x07 = rotl(x07 ^ x08, 12);
706
+ x02 = x02 + x07 | 0;
707
+ x13 = rotl(x13 ^ x02, 8);
708
+ x08 = x08 + x13 | 0;
709
+ x07 = rotl(x07 ^ x08, 7);
710
+ x03 = x03 + x04 | 0;
711
+ x14 = rotl(x14 ^ x03, 16);
712
+ x09 = x09 + x14 | 0;
713
+ x04 = rotl(x04 ^ x09, 12);
714
+ x03 = x03 + x04 | 0;
715
+ x14 = rotl(x14 ^ x03, 8);
716
+ x09 = x09 + x14 | 0;
717
+ x04 = rotl(x04 ^ x09, 7);
718
+ }
719
+ let oi = 0;
720
+ out[oi++] = x00;
721
+ out[oi++] = x01;
722
+ out[oi++] = x02;
723
+ out[oi++] = x03;
724
+ out[oi++] = x12;
725
+ out[oi++] = x13;
726
+ out[oi++] = x14;
727
+ out[oi++] = x15;
728
+ swap32IfBE(out);
729
+ }
730
+ var xchacha20 = /* @__PURE__ */ createCipher(chachaCore, {
731
+ counterRight: false,
732
+ counterLength: 8,
733
+ extendNonceFn: hchacha,
734
+ allowShortKeys: false
735
+ });
736
+ var ZEROS16 = /* @__PURE__ */ new Uint8Array(16);
737
+ var updatePadded = (h, msg) => {
738
+ h.update(msg);
739
+ const leftover = msg.length % 16;
740
+ if (leftover)
741
+ h.update(ZEROS16.subarray(leftover));
742
+ };
743
+ var ZEROS32 = /* @__PURE__ */ new Uint8Array(32);
744
+ function computeTag(fn, key, nonce, ciphertext, AAD) {
745
+ if (AAD !== void 0)
746
+ abytes(AAD, void 0, "AAD");
747
+ const authKey = fn(key, nonce, ZEROS32);
748
+ const lengths = u64Lengths(ciphertext.length, AAD ? AAD.length : 0, true);
749
+ const h = poly1305.create(authKey);
750
+ if (AAD)
751
+ updatePadded(h, AAD);
752
+ updatePadded(h, ciphertext);
753
+ h.update(lengths);
754
+ const res = h.digest();
755
+ clean(authKey, lengths);
756
+ return res;
757
+ }
758
+ var _poly1305_aead = (xorStream) => (key, nonce, AAD) => {
759
+ const tagLength = 16;
760
+ return {
761
+ encrypt(plaintext, output) {
762
+ const plength = plaintext.length;
763
+ output = getOutput(plength + tagLength, output, false);
764
+ output.set(plaintext);
765
+ const oPlain = output.subarray(0, -tagLength);
766
+ xorStream(key, nonce, oPlain, oPlain, 1);
767
+ const tag = computeTag(xorStream, key, nonce, oPlain, AAD);
768
+ output.set(tag, plength);
769
+ clean(tag);
770
+ return output;
771
+ },
772
+ decrypt(ciphertext, output) {
773
+ output = getOutput(ciphertext.length - tagLength, output, false);
774
+ const data = ciphertext.subarray(0, -tagLength);
775
+ const passedTag = ciphertext.subarray(-tagLength);
776
+ const tag = computeTag(xorStream, key, nonce, data, AAD);
777
+ if (!equalBytes(passedTag, tag)) {
778
+ clean(tag);
779
+ throw new Error("invalid tag");
780
+ }
781
+ output.set(ciphertext.subarray(0, -tagLength));
782
+ xorStream(key, nonce, output, output, 1);
783
+ clean(tag);
784
+ return output;
785
+ }
786
+ };
787
+ };
788
+ var xchacha20poly1305 = /* @__PURE__ */ wrapCipher(
789
+ { blockSize: 64, nonceLength: 24, tagLength: 16 },
790
+ /* @__PURE__ */ _poly1305_aead(xchacha20)
791
+ );
792
+ // Annotate the CommonJS export names for ESM import in node:
793
+ 0 && (module.exports = {
794
+ xchacha20poly1305
795
+ });
5
796
  /*! Bundled license information:
6
797
 
7
798
  @noble/ciphers/utils.js: