diff --git a/.eslintrc b/.eslintrc index f9c43061..4e02df9b 100644 --- a/.eslintrc +++ b/.eslintrc @@ -14,7 +14,8 @@ "rules": { "no-console": 1, // Means warning "prettier/prettier": 2, // Means error - "@typescript-eslint/no-floating-promises": ["error"] + "@typescript-eslint/no-floating-promises": ["error"], + "@typescript-eslint/no-non-null-assertion": "off" }, "ignorePatterns": ["dist", "node_modules"] } diff --git a/package-lock.json b/package-lock.json index e7c74534..e9c8b2a7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -26,7 +26,6 @@ "ethers": "^5.7.2", "ffjavascript": "^0.2.57", "idb-keyval": "^6.2.0", - "ipfs-http-client": "56.0.3", "jsonld": "^8.1.1", "multiformats": "^9.6.5", "rfc4648": "^1.5.2", @@ -35,16 +34,18 @@ "uuid": "^9.0.0" }, "devDependencies": { - "@4c/fetch-mock": "^8.0.0", "@esbuild-plugins/node-globals-polyfill": "^0.1.1", "@esbuild-plugins/node-modules-polyfill": "^0.1.4", - "@microsoft/api-documenter": "^7.20.1", - "@microsoft/api-extractor": "^7.34.4", + "@gr2m/fetch-mock": "^9.11.0-pull-request-644.1", + "@microsoft/api-documenter": "^7.8.20", + "@microsoft/api-extractor": "^7.9.0", "@types/chai": "^4.3.4", "@types/chai-as-promised": "^7.1.5", - "@types/jsonld": "^1.4.8", + "@types/elliptic": "^6.4.14", + "@types/jsonld": "^1.5.9", "@types/mocha": "^10.0.1", "@types/node": "^18.16.19", + "@types/uuid": "^9.0.2", "@typescript-eslint/eslint-plugin": "^5.41.0", "chai": "^4.3.7", "chai-as-promised": "^7.1.1", @@ -64,22 +65,6 @@ "node": ">=18.16.0" } }, - "node_modules/@4c/fetch-mock": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@4c/fetch-mock/-/fetch-mock-8.0.0.tgz", - "integrity": "sha512-0ahu8gTQ1KVpwZFcQETVV/ED7UWdF9rEERPQdf2mEgzO8xzZvb6gw0B37HhM0g8wSenyN+/vwcyWXUsKVBwWuA==", - "dev": true, - "hasInstallScript": true, - "dependencies": { - "@babel/runtime-corejs3": "^7.4.5", - "glob-to-regexp": "^0.4.0", - "path-to-regexp": "^2.2.1", - "whatwg-url": "^6.5.0" - }, - "engines": { - "node": ">=4.0.0" - } - }, "node_modules/@aashutoshrathi/word-wrap": { "version": "1.2.6", "resolved": "https://registry.npmjs.org/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz", @@ -113,33 +98,33 @@ } }, "node_modules/@babel/compat-data": { - "version": "7.22.6", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.22.6.tgz", - "integrity": "sha512-29tfsWTq2Ftu7MXmimyC0C5FDZv5DYxOZkh3XD3+QW4V/BYuv/LyEsjj3c0hqedEaDt6DBfDvexMKU8YevdqFg==", + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.22.9.tgz", + "integrity": "sha512-5UamI7xkUcJ3i9qVDS+KFDEK8/7oJ55/sJMB1Ge7IEapr7KfdfV/HErR+koZwOfd+SgtFKOKRhRakdg++DcJpQ==", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/core": { - "version": "7.22.8", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.22.8.tgz", - "integrity": "sha512-75+KxFB4CZqYRXjx4NlR4J7yGvKumBuZTmV4NV6v09dVXXkuYVYLT68N6HCzLvfJ+fWCxQsntNzKwwIXL4bHnw==", + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.22.9.tgz", + "integrity": "sha512-G2EgeufBcYw27U4hhoIwFcgc1XU7TlXJ3mv04oOv1WCuo900U/anZSPzEqNjwdjgffkk2Gs0AN0dW1CKVLcG7w==", "dependencies": { "@ampproject/remapping": "^2.2.0", "@babel/code-frame": "^7.22.5", - "@babel/generator": "^7.22.7", - "@babel/helper-compilation-targets": "^7.22.6", - "@babel/helper-module-transforms": "^7.22.5", + "@babel/generator": "^7.22.9", + "@babel/helper-compilation-targets": "^7.22.9", + "@babel/helper-module-transforms": "^7.22.9", "@babel/helpers": "^7.22.6", "@babel/parser": "^7.22.7", "@babel/template": "^7.22.5", "@babel/traverse": "^7.22.8", "@babel/types": "^7.22.5", - "@nicolo-ribaudo/semver-v6": "^6.3.3", "convert-source-map": "^1.7.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", - "json5": "^2.2.2" + "json5": "^2.2.2", + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" @@ -149,15 +134,10 @@ "url": "https://opencollective.com/babel" } }, - "node_modules/@babel/core/node_modules/convert-source-map": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.9.0.tgz", - "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" - }, "node_modules/@babel/generator": { - "version": "7.22.7", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.22.7.tgz", - "integrity": "sha512-p+jPjMG+SI8yvIaxGgeW24u7q9+5+TGpZh8/CuB7RhBKd7RCy8FayNEFNNKrNK/eUcY/4ExQqLmyrvBXKsIcwQ==", + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.22.9.tgz", + "integrity": "sha512-KtLMbmicyuK2Ak/FTCJVbDnkN1SlT8/kceFTiuDiiRUUSMnHMidxSCdG4ndkTOHHpoomWe/4xkvHkEOncwjYIw==", "dependencies": { "@babel/types": "^7.22.5", "@jridgewell/gen-mapping": "^0.3.2", @@ -169,15 +149,15 @@ } }, "node_modules/@babel/helper-compilation-targets": { - "version": "7.22.6", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.6.tgz", - "integrity": "sha512-534sYEqWD9VfUm3IPn2SLcH4Q3P86XL+QvqdC7ZsFrzyyPF3T4XGiVghF6PTYNdWg6pXuoqXxNQAhbYeEInTzA==", + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.9.tgz", + "integrity": "sha512-7qYrNM6HjpnPHJbopxmb8hSPoZ0gsX8IvUS32JGVoy+pU9e5N0nLr1VjJoR6kA4d9dmGLxNYOjeB8sUDal2WMw==", "dependencies": { - "@babel/compat-data": "^7.22.6", + "@babel/compat-data": "^7.22.9", "@babel/helper-validator-option": "^7.22.5", - "@nicolo-ribaudo/semver-v6": "^6.3.3", "browserslist": "^4.21.9", - "lru-cache": "^5.1.1" + "lru-cache": "^5.1.1", + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" @@ -229,21 +209,21 @@ } }, "node_modules/@babel/helper-module-transforms": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.22.5.tgz", - "integrity": "sha512-+hGKDt/Ze8GFExiVHno/2dvG5IdstpzCq0y4Qc9OJ25D4q3pKfiIP/4Vp3/JvhDkLKsDK2api3q3fpIgiIF5bw==", + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.22.9.tgz", + "integrity": "sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==", "dependencies": { "@babel/helper-environment-visitor": "^7.22.5", "@babel/helper-module-imports": "^7.22.5", "@babel/helper-simple-access": "^7.22.5", - "@babel/helper-split-export-declaration": "^7.22.5", - "@babel/helper-validator-identifier": "^7.22.5", - "@babel/template": "^7.22.5", - "@babel/traverse": "^7.22.5", - "@babel/types": "^7.22.5" + "@babel/helper-split-export-declaration": "^7.22.6", + "@babel/helper-validator-identifier": "^7.22.5" }, "engines": { "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" } }, "node_modules/@babel/helper-plugin-utils": { @@ -326,70 +306,6 @@ "node": ">=6.9.0" } }, - "node_modules/@babel/highlight/node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dependencies": { - "color-convert": "^1.9.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/highlight/node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/highlight/node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dependencies": { - "color-name": "1.1.3" - } - }, - "node_modules/@babel/highlight/node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" - }, - "node_modules/@babel/highlight/node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/@babel/highlight/node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/highlight/node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dependencies": { - "has-flag": "^3.0.0" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/@babel/parser": { "version": "7.22.7", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.22.7.tgz", @@ -564,13 +480,12 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/runtime-corejs3": { + "node_modules/@babel/runtime": { "version": "7.22.6", - "resolved": "https://registry.npmjs.org/@babel/runtime-corejs3/-/runtime-corejs3-7.22.6.tgz", - "integrity": "sha512-M+37LLIRBTEVjktoJjbw4KVhupF0U/3PYUCbBwgAd9k17hoKhRu1n935QiG7Tuxv0LJOMrb2vuKEeYUlv0iyiw==", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.22.6.tgz", + "integrity": "sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ==", "dev": true, "dependencies": { - "core-js-pure": "^3.30.2", "regenerator-runtime": "^0.13.11" }, "engines": { @@ -610,14 +525,6 @@ "node": ">=6.9.0" } }, - "node_modules/@babel/traverse/node_modules/globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "engines": { - "node": ">=4" - } - }, "node_modules/@babel/types": { "version": "7.22.5", "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.22.5.tgz", @@ -799,6 +706,21 @@ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", "peer": true }, + "node_modules/@eslint/eslintrc/node_modules/globals": { + "version": "13.20.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", + "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", + "peer": true, + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/@eslint/eslintrc/node_modules/js-yaml": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", @@ -817,6 +739,18 @@ "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "peer": true }, + "node_modules/@eslint/eslintrc/node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "peer": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/@eslint/js": { "version": "8.44.0", "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.44.0.tgz", @@ -1502,6 +1436,39 @@ "@ethersproject/strings": "^5.7.0" } }, + "node_modules/@gr2m/fetch-mock": { + "version": "9.11.0-pull-request-644.1", + "resolved": "https://registry.npmjs.org/@gr2m/fetch-mock/-/fetch-mock-9.11.0-pull-request-644.1.tgz", + "integrity": "sha512-gTp6RCHzlOXS1qRb0APfuyz48Lw/JFPa4uiar+kEgL1STsDwth75HJZ4x30tBlXMJXV8XDTDzJ2Hz9w3RWiHJA==", + "dev": true, + "dependencies": { + "@babel/core": "^7.0.0", + "@babel/runtime": "^7.0.0", + "core-js": "^3.0.0", + "debug": "^4.1.1", + "glob-to-regexp": "^0.4.0", + "is-subset": "^0.1.1", + "lodash.isequal": "^4.5.0", + "path-to-regexp": "^2.2.1", + "querystring": "^0.2.0", + "whatwg-url": "^6.5.0" + }, + "engines": { + "node": ">=4.0.0" + }, + "funding": { + "type": "charity", + "url": "https://www.justgiving.com/refugee-support-europe" + }, + "peerDependencies": { + "node-fetch": "*" + }, + "peerDependenciesMeta": { + "node-fetch": { + "optional": true + } + } + }, "node_modules/@humanwhocodes/config-array": { "version": "0.11.10", "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.10.tgz", @@ -1670,32 +1637,6 @@ "idb-keyval": "^6.2.0" } }, - "node_modules/@ipld/dag-cbor": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/@ipld/dag-cbor/-/dag-cbor-7.0.3.tgz", - "integrity": "sha512-1VVh2huHsuohdXC1bGJNE8WR72slZ9XE2T3wbBBq31dm7ZBatmKLLxrB+XAqafxfRFjv08RZmj/W/ZqaM13AuA==", - "dependencies": { - "cborg": "^1.6.0", - "multiformats": "^9.5.4" - } - }, - "node_modules/@ipld/dag-json": { - "version": "8.0.11", - "resolved": "https://registry.npmjs.org/@ipld/dag-json/-/dag-json-8.0.11.tgz", - "integrity": "sha512-Pea7JXeYHTWXRTIhBqBlhw7G53PJ7yta3G/sizGEZyzdeEwhZRr0od5IQ0r2ZxOt1Do+2czddjeEPp+YTxDwCA==", - "dependencies": { - "cborg": "^1.5.4", - "multiformats": "^9.5.4" - } - }, - "node_modules/@ipld/dag-pb": { - "version": "2.1.18", - "resolved": "https://registry.npmjs.org/@ipld/dag-pb/-/dag-pb-2.1.18.tgz", - "integrity": "sha512-ZBnf2fuX9y3KccADURG5vb9FaOeMjFkCrNysB0PtftME/4iCTjxfaLoNq/IAh5fTqUOMXvryN6Jyka4ZGuMLIg==", - "dependencies": { - "multiformats": "^9.5.4" - } - }, "node_modules/@istanbuljs/load-nyc-config": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz", @@ -1791,6 +1732,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/@jest/console/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/console/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/console/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/console/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/@jest/console/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/console/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/@jest/core": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.6.1.tgz", @@ -1837,48 +1842,112 @@ } } }, - "node_modules/@jest/environment": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.6.1.tgz", - "integrity": "sha512-RMMXx4ws+Gbvw3DfLSuo2cfQlK7IwGbpuEWXCqyYDcqYTI+9Ju3a5hDnXaxjNsa6uKh9PQF2v+qg+RLe63tz5A==", + "node_modules/@jest/core/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dependencies": { - "@jest/fake-timers": "^29.6.1", - "@jest/types": "^29.6.1", - "@types/node": "*", - "jest-mock": "^29.6.1" + "color-convert": "^2.0.1" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/@jest/expect": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.6.1.tgz", - "integrity": "sha512-N5xlPrAYaRNyFgVf2s9Uyyvr795jnB6rObuPx4QFvNJz8aAjpZUDfO4bh5G/xuplMID8PrnuF1+SfSyDxhsgYg==", + "node_modules/@jest/core/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dependencies": { - "expect": "^29.6.1", - "jest-snapshot": "^29.6.1" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/@jest/expect-utils": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.6.1.tgz", - "integrity": "sha512-o319vIf5pEMx0LmzSxxkYYxo4wrRLKHq9dP1yJU7FoPTB0LfAKSz8SWD6D/6U3v/O52t9cF5t+MeJiRsfk7zMw==", + "node_modules/@jest/core/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dependencies": { - "jest-get-type": "^29.4.3" + "color-name": "~1.1.4" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=7.0.0" } }, - "node_modules/@jest/fake-timers": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.6.1.tgz", - "integrity": "sha512-RdgHgbXyosCDMVYmj7lLpUwXA4c69vcNzhrt69dJJdf8azUrpRh3ckFCaTPNjsEeRi27Cig0oKDGxy5j7hOgHg==", - "dependencies": { + "node_modules/@jest/core/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/@jest/core/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/core/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/environment": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.6.1.tgz", + "integrity": "sha512-RMMXx4ws+Gbvw3DfLSuo2cfQlK7IwGbpuEWXCqyYDcqYTI+9Ju3a5hDnXaxjNsa6uKh9PQF2v+qg+RLe63tz5A==", + "dependencies": { + "@jest/fake-timers": "^29.6.1", + "@jest/types": "^29.6.1", + "@types/node": "*", + "jest-mock": "^29.6.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.6.1.tgz", + "integrity": "sha512-N5xlPrAYaRNyFgVf2s9Uyyvr795jnB6rObuPx4QFvNJz8aAjpZUDfO4bh5G/xuplMID8PrnuF1+SfSyDxhsgYg==", + "dependencies": { + "expect": "^29.6.1", + "jest-snapshot": "^29.6.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.6.1.tgz", + "integrity": "sha512-o319vIf5pEMx0LmzSxxkYYxo4wrRLKHq9dP1yJU7FoPTB0LfAKSz8SWD6D/6U3v/O52t9cF5t+MeJiRsfk7zMw==", + "dependencies": { + "jest-get-type": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.6.1.tgz", + "integrity": "sha512-RdgHgbXyosCDMVYmj7lLpUwXA4c69vcNzhrt69dJJdf8azUrpRh3ckFCaTPNjsEeRi27Cig0oKDGxy5j7hOgHg==", + "dependencies": { "@jest/types": "^29.6.1", "@sinonjs/fake-timers": "^10.0.2", "@types/node": "*", @@ -1946,6 +2015,70 @@ } } }, + "node_modules/@jest/reporters/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/reporters/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/reporters/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/reporters/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/@jest/reporters/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/reporters/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/@jest/schemas": { "version": "29.6.0", "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.0.tgz", @@ -2023,6 +2156,75 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/@jest/transform/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/transform/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/transform/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/transform/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/@jest/transform/node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==" + }, + "node_modules/@jest/transform/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/transform/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/@jest/types": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.1.tgz", @@ -2039,6 +2241,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/@jest/types/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/types/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@jest/types/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/@jest/types/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/@jest/types/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/types/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.3", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", @@ -2115,9 +2381,9 @@ "integrity": "sha512-eHKfv4NzuqTYBk2Hn1IVb/vVUd5+g8xqcXZumwqp2FH5hwv02f9cyhpV8ZQRU9IOhBidddFktbB6r/ifKhWnlw==" }, "node_modules/@microsoft/api-documenter": { - "version": "7.22.26", - "resolved": "https://registry.npmjs.org/@microsoft/api-documenter/-/api-documenter-7.22.26.tgz", - "integrity": "sha512-Df//s/W9eXpUfOAP5f/KiBXWJM5vvjvXl1DnnEP73NQx5AACLSZWZzExwxJlpyaefcD7iYziFkK4I2oQhnVcFA==", + "version": "7.22.27", + "resolved": "https://registry.npmjs.org/@microsoft/api-documenter/-/api-documenter-7.22.27.tgz", + "integrity": "sha512-q/eyxqH321kA1BjK1Pj4mcnYpbEnbXJaxIIM/OH5ceZCSLEkDnSfa2zFxAHz1wvG6thSdU8k5gThfvuJM5wMVA==", "dev": true, "dependencies": { "@microsoft/api-extractor-model": "7.27.4", @@ -2166,20 +2432,53 @@ "@rushstack/node-core-library": "3.59.5" } }, - "node_modules/@microsoft/api-extractor/node_modules/typescript": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.4.tgz", - "integrity": "sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==", + "node_modules/@microsoft/api-extractor/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", "dev": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" + "dependencies": { + "yallist": "^4.0.0" }, "engines": { - "node": ">=12.20" + "node": ">=10" } }, - "node_modules/@microsoft/tsdoc": { + "node_modules/@microsoft/api-extractor/node_modules/semver": { + "version": "7.3.8", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", + "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@microsoft/api-extractor/node_modules/typescript": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.4.tgz", + "integrity": "sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=12.20" + } + }, + "node_modules/@microsoft/api-extractor/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, + "node_modules/@microsoft/tsdoc": { "version": "0.14.2", "resolved": "https://registry.npmjs.org/@microsoft/tsdoc/-/tsdoc-0.14.2.tgz", "integrity": "sha512-9b8mPpKrfeGRuhFH5iO1iwCLeIIsV6+H1sRfxbkoGXIyQE2BTsPd9zqSqQJ+pv5sJ/hT5M1zvOFL02MnEezFug==", @@ -2232,14 +2531,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@nicolo-ribaudo/semver-v6": { - "version": "6.3.3", - "resolved": "https://registry.npmjs.org/@nicolo-ribaudo/semver-v6/-/semver-v6-6.3.3.tgz", - "integrity": "sha512-3Yc1fUTs69MG/uZbJlLSI3JISMn2UV2rg+1D/vROUqZyh3l6iYHCs7GMp+M40ZD7yOdDbYjJcU1oTJhrc+dGKg==", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", @@ -2272,60 +2563,6 @@ "node": ">= 8" } }, - "node_modules/@protobufjs/aspromise": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz", - "integrity": "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==" - }, - "node_modules/@protobufjs/base64": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/base64/-/base64-1.1.2.tgz", - "integrity": "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg==" - }, - "node_modules/@protobufjs/codegen": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@protobufjs/codegen/-/codegen-2.0.4.tgz", - "integrity": "sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg==" - }, - "node_modules/@protobufjs/eventemitter": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz", - "integrity": "sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q==" - }, - "node_modules/@protobufjs/fetch": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/fetch/-/fetch-1.1.0.tgz", - "integrity": "sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==", - "dependencies": { - "@protobufjs/aspromise": "^1.1.1", - "@protobufjs/inquire": "^1.1.0" - } - }, - "node_modules/@protobufjs/float": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@protobufjs/float/-/float-1.0.2.tgz", - "integrity": "sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ==" - }, - "node_modules/@protobufjs/inquire": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/inquire/-/inquire-1.1.0.tgz", - "integrity": "sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q==" - }, - "node_modules/@protobufjs/path": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@protobufjs/path/-/path-1.1.2.tgz", - "integrity": "sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA==" - }, - "node_modules/@protobufjs/pool": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/pool/-/pool-1.1.0.tgz", - "integrity": "sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw==" - }, - "node_modules/@protobufjs/utf8": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.0.tgz", - "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==" - }, "node_modules/@rushstack/node-core-library": { "version": "3.59.5", "resolved": "https://registry.npmjs.org/@rushstack/node-core-library/-/node-core-library-3.59.5.tgz", @@ -2349,6 +2586,39 @@ } } }, + "node_modules/@rushstack/node-core-library/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@rushstack/node-core-library/node_modules/semver": { + "version": "7.3.8", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", + "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@rushstack/node-core-library/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, "node_modules/@rushstack/rig-package": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/@rushstack/rig-package/-/rig-package-0.4.0.tgz", @@ -2603,6 +2873,15 @@ "@babel/types": "^7.20.7" } }, + "node_modules/@types/bn.js": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-5.1.1.tgz", + "integrity": "sha512-qNrYbZqMx0uJAfKnKclPh+dTwK33KfLHYqtyODwd5HnXOjnkhc4qgn3BrK6RWyGZm5+sIFE7Q7Vz6QQtJB7w7g==", + "dev": true, + "dependencies": { + "@types/node": "*" + } + }, "node_modules/@types/chai": { "version": "4.3.5", "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.5.tgz", @@ -2618,6 +2897,15 @@ "@types/chai": "*" } }, + "node_modules/@types/elliptic": { + "version": "6.4.14", + "resolved": "https://registry.npmjs.org/@types/elliptic/-/elliptic-6.4.14.tgz", + "integrity": "sha512-z4OBcDAU0GVwDTuwJzQCiL6188QvZMkvoERgcVjq0/mPM8jCfdwZ3x5zQEVoL9WCAru3aG5wl3Z5Ww5wBWn7ZQ==", + "dev": true, + "dependencies": { + "@types/bn.js": "*" + } + }, "node_modules/@types/eslint": { "version": "8.44.0", "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.44.0.tgz", @@ -2699,16 +2987,6 @@ "integrity": "sha512-K76ImkErPYL2wGPZpNFSKp6wE+h/APecZLJrU7UfDaGqt/f+D9Rrg1aR7VdRrQ6k5DUNRZ2vn9yACwmpOr9QcA==", "dev": true }, - "node_modules/@types/long": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/@types/long/-/long-4.0.2.tgz", - "integrity": "sha512-MqTGEo5bj5t157U6fA/BiDynNkn0YknVdh48CMPkTSpFTVmvao5UQmm7uEF6xBEo7qIMAlY/JSleYaE6VOdpaA==" - }, - "node_modules/@types/minimatch": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.5.tgz", - "integrity": "sha512-Klz949h02Gz2uZCMGwDUSDS1YBlTdDDgbWHi+81l29tQALUtvz4rAYi5uoVhE5Lagoq6DeqAUlbrHvW/mXDgdQ==" - }, "node_modules/@types/mocha": { "version": "10.0.1", "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz", @@ -2735,6 +3013,12 @@ "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==" }, + "node_modules/@types/uuid": { + "version": "9.0.2", + "resolved": "https://registry.npmjs.org/@types/uuid/-/uuid-9.0.2.tgz", + "integrity": "sha512-kNnC1GFBLuhImSnV7w4njQkUiJi0ZXUycu1rUaouPqiKlXkh77JKgdRnTAp1x5eBwcIwbtI+3otwzuIDEuDoxQ==", + "dev": true + }, "node_modules/@types/yargs": { "version": "17.0.24", "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.24.tgz", @@ -2781,6 +3065,36 @@ } } }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, "node_modules/@typescript-eslint/parser": { "version": "5.62.0", "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.62.0.tgz", @@ -2888,6 +3202,36 @@ } } }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, "node_modules/@typescript-eslint/utils": { "version": "5.62.0", "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.62.0.tgz", @@ -2913,6 +3257,36 @@ "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, + "node_modules/@typescript-eslint/utils/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/utils/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/utils/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, "node_modules/@typescript-eslint/visitor-keys": { "version": "5.62.0", "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.62.0.tgz", @@ -3178,17 +3552,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/ansi-escapes/node_modules/type-fest": { - "version": "0.21.3", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", - "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", @@ -3198,17 +3561,14 @@ } }, "node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dependencies": { - "color-convert": "^2.0.1" + "color-convert": "^1.9.0" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": ">=4" } }, "node_modules/any-promise": { @@ -3217,11 +3577,6 @@ "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==", "dev": true }, - "node_modules/any-signal": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/any-signal/-/any-signal-3.0.1.tgz", - "integrity": "sha512-xgZgJtKEa9YmDqXodIgl7Fl1C8yNXr8w6gXjqK3LW4GcEiYT+6AQfJSE/8SPsEpLLmcvbv8YU+qet94UewHxqg==" - }, "node_modules/anymatch": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", @@ -3325,47 +3680,111 @@ "@babel/core": "^7.8.0" } }, - "node_modules/babel-plugin-istanbul": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", - "integrity": "sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==", + "node_modules/babel-jest/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dependencies": { - "@babel/helper-plugin-utils": "^7.0.0", - "@istanbuljs/load-nyc-config": "^1.0.0", - "@istanbuljs/schema": "^0.1.2", - "istanbul-lib-instrument": "^5.0.4", - "test-exclude": "^6.0.0" + "color-convert": "^2.0.1" }, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/babel-plugin-jest-hoist": { - "version": "29.5.0", - "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.5.0.tgz", - "integrity": "sha512-zSuuuAlTMT4mzLj2nPnUm6fsE6270vdOfnpbJ+RmruU75UhLFvL0N2NgI7xpeS7NaB6hGqmd5pVpGTDYvi4Q3w==", + "node_modules/babel-jest/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dependencies": { - "@babel/template": "^7.3.3", - "@babel/types": "^7.3.3", - "@types/babel__core": "^7.1.14", - "@types/babel__traverse": "^7.0.6" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/babel-preset-current-node-syntax": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz", - "integrity": "sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==", + "node_modules/babel-jest/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dependencies": { - "@babel/plugin-syntax-async-generators": "^7.8.4", - "@babel/plugin-syntax-bigint": "^7.8.3", - "@babel/plugin-syntax-class-properties": "^7.8.3", - "@babel/plugin-syntax-import-meta": "^7.8.3", - "@babel/plugin-syntax-json-strings": "^7.8.3", - "@babel/plugin-syntax-logical-assignment-operators": "^7.8.3", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/babel-jest/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/babel-jest/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-jest/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-istanbul": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", + "integrity": "sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==", + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-instrument": "^5.0.4", + "test-exclude": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-jest-hoist": { + "version": "29.5.0", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.5.0.tgz", + "integrity": "sha512-zSuuuAlTMT4mzLj2nPnUm6fsE6270vdOfnpbJ+RmruU75UhLFvL0N2NgI7xpeS7NaB6hGqmd5pVpGTDYvi4Q3w==", + "dependencies": { + "@babel/template": "^7.3.3", + "@babel/types": "^7.3.3", + "@types/babel__core": "^7.1.14", + "@types/babel__traverse": "^7.0.6" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/babel-preset-current-node-syntax": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz", + "integrity": "sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==", + "dependencies": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.8.3", + "@babel/plugin-syntax-import-meta": "^7.8.3", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.8.3", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", "@babel/plugin-syntax-numeric-separator": "^7.8.3", "@babel/plugin-syntax-object-rest-spread": "^7.8.3", "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", @@ -3474,14 +3893,6 @@ "nanoassert": "^2.0.0" } }, - "node_modules/blob-to-it": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/blob-to-it/-/blob-to-it-1.0.4.tgz", - "integrity": "sha512-iCmk0W4NdbrWgRRuxOriU8aM5ijeVLI61Zulsmg/lUHNr7pYjoj+U77opLefNagevtrrbMt3JQ5Qip7ar178kA==", - "dependencies": { - "browser-readablestream-to-it": "^1.0.3" - } - }, "node_modules/bluebird": { "version": "3.7.2", "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", @@ -3517,11 +3928,6 @@ "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" }, - "node_modules/browser-readablestream-to-it": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/browser-readablestream-to-it/-/browser-readablestream-to-it-1.0.3.tgz", - "integrity": "sha512-+12sHB+Br8HIh6VAMVEG5r3UXCyESIgDW7kzk3BjIXa43DVqVwL7GC5TW3jeh+72dtcH99pPVpw0X8i0jt+/kw==" - }, "node_modules/browser-stdout": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", @@ -3749,14 +4155,6 @@ "resolved": "https://registry.npmjs.org/canonicalize/-/canonicalize-2.0.0.tgz", "integrity": "sha512-ulDEYPv7asdKvqahuAY35c1selLdzDwHqugK92hfkzvlDCwXRRelDkR+Er33md/PtnpqHemgkuDPanZ4fiYZ8w==" }, - "node_modules/cborg": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/cborg/-/cborg-1.10.2.tgz", - "integrity": "sha512-b3tFPA9pUr2zCUiCfRd2+wok2/LBSNUMKOuRRok+WlvvAgEt/PlbgPTsZUcwCOs53IJvLgTp0eotwtosE6njug==", - "bin": { - "cborg": "cli.js" - } - }, "node_modules/chai": { "version": "4.3.7", "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz", @@ -3788,18 +4186,24 @@ } }, "node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": ">=4" + } + }, + "node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "engines": { + "node": ">=0.8.0" } }, "node_modules/char-regex": { @@ -3978,20 +4382,17 @@ "integrity": "sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q==" }, "node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" + "color-name": "1.1.3" } }, "node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" }, "node_modules/colors": { "version": "1.2.5", @@ -4023,14 +4424,14 @@ "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" }, "node_modules/convert-source-map": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", - "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==" + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.9.0.tgz", + "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" }, - "node_modules/core-js-pure": { + "node_modules/core-js": { "version": "3.31.1", - "resolved": "https://registry.npmjs.org/core-js-pure/-/core-js-pure-3.31.1.tgz", - "integrity": "sha512-w+C62kvWti0EPs4KPMCMVv9DriHSXfQOCQ94bGGBiEW5rrbtt/Rz8n5Krhfw9cpFyzXBjf3DB3QnPdEzGDY4Fw==", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.31.1.tgz", + "integrity": "sha512-2sKLtfq1eFST7l7v62zaqXacPc7uG8ZAya8ogijLhTtaKNcpzpB4TMoTw2Si+8GYKRwFPMMtUT0263QFWFfqyQ==", "dev": true, "hasInstallScript": true, "funding": { @@ -4124,24 +4525,6 @@ "node": "*" } }, - "node_modules/dag-jose": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/dag-jose/-/dag-jose-1.0.0.tgz", - "integrity": "sha512-U0b/YsIPBp6YZNTFrVjwLZAlY3qGRxZTIEcM/CcQmrVrCWq9MWQq9pheXVSPLIhF4SNwzp2SikPva4/BIrJY+g==", - "dependencies": { - "@ipld/dag-cbor": "^6.0.3", - "multiformats": "^9.0.2" - } - }, - "node_modules/dag-jose/node_modules/@ipld/dag-cbor": { - "version": "6.0.15", - "resolved": "https://registry.npmjs.org/@ipld/dag-cbor/-/dag-cbor-6.0.15.tgz", - "integrity": "sha512-Vm3VTSTwlmGV92a3C5aeY+r2A18zbH2amehNhsX8PBa3muXICaWrN8Uri85A5hLH7D7ElhE8PdjxD6kNqUmTZA==", - "dependencies": { - "cborg": "^1.5.4", - "multiformats": "^9.5.4" - } - }, "node_modules/data-uri-to-buffer": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/data-uri-to-buffer/-/data-uri-to-buffer-4.0.1.tgz", @@ -4532,16 +4915,6 @@ "node": ">=8" } }, - "node_modules/dns-over-http-resolver": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/dns-over-http-resolver/-/dns-over-http-resolver-1.2.3.tgz", - "integrity": "sha512-miDiVSI6KSNbi4SVifzO/reD8rMnxgrlnkrlkugOLQpWQTe2qMdHsZp5DmfKjxNE+/T3VAAYLQUZMv9SMr6+AA==", - "dependencies": { - "debug": "^4.3.1", - "native-fetch": "^3.0.0", - "receptacle": "^1.3.2" - } - }, "node_modules/doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", @@ -4568,21 +4941,10 @@ "node": ">=0.10.0" } }, - "node_modules/electron-fetch": { - "version": "1.9.1", - "resolved": "https://registry.npmjs.org/electron-fetch/-/electron-fetch-1.9.1.tgz", - "integrity": "sha512-M9qw6oUILGVrcENMSRRefE1MbHPIz0h79EKIeJWK9v563aT9Qkh8aEHPO1H5vi970wPirNY+jO9OpFoLiMsMGA==", - "dependencies": { - "encoding": "^0.1.13" - }, - "engines": { - "node": ">=6" - } - }, "node_modules/electron-to-chromium": { - "version": "1.4.457", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.457.tgz", - "integrity": "sha512-/g3UyNDmDd6ebeWapmAoiyy+Sy2HyJ+/X8KyvNeHfKRFfHaA2W8oF5fxD5F3tjBDcjpwo0iek6YNgxNXDBoEtA==" + "version": "1.4.460", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.460.tgz", + "integrity": "sha512-kKiHnbrHME7z8E6AYaw0ehyxY5+hdaRmeUbjBO22LZMdqTYCO29EvF0T1cQ3pJ1RN5fyMcHl1Lmcsdt9WWJpJQ==" }, "node_modules/elliptic": { "version": "6.5.4", @@ -4619,14 +4981,6 @@ "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" }, - "node_modules/encoding": { - "version": "0.1.13", - "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz", - "integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==", - "dependencies": { - "iconv-lite": "^0.6.2" - } - }, "node_modules/enhanced-resolve": { "version": "5.15.0", "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz", @@ -4639,11 +4993,6 @@ "node": ">=10.13.0" } }, - "node_modules/err-code": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", - "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" - }, "node_modules/error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -5184,12 +5533,61 @@ "url": "https://github.com/sponsors/epoberezkin" } }, + "node_modules/eslint/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "peer": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, "node_modules/eslint/node_modules/argparse": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", "peer": true }, + "node_modules/eslint/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "peer": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/eslint/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "peer": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/eslint/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "peer": true + }, "node_modules/eslint/node_modules/eslint-scope": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", @@ -5227,6 +5625,30 @@ "node": ">=10.13.0" } }, + "node_modules/eslint/node_modules/globals": { + "version": "13.20.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", + "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", + "peer": true, + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/eslint/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "peer": true, + "engines": { + "node": ">=8" + } + }, "node_modules/eslint/node_modules/js-yaml": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", @@ -5245,6 +5667,30 @@ "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "peer": true }, + "node_modules/eslint/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "peer": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/eslint/node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "peer": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/espree": { "version": "9.6.0", "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.0.tgz", @@ -5463,11 +5909,6 @@ "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz", "integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==" }, - "node_modules/fast-fifo": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/fast-fifo/-/fast-fifo-1.3.0.tgz", - "integrity": "sha512-IgfweLvEpwyA4WgiQe9Nx6VV2QkML2NkvZnk1oKnIzXgXdWxuhF7zw4DvLTPZJn6PIUneiAXPF24QmoEqHTjyw==" - }, "node_modules/fast-glob": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.0.tgz", @@ -5794,11 +6235,6 @@ "node": "*" } }, - "node_modules/get-iterator": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/get-iterator/-/get-iterator-1.0.2.tgz", - "integrity": "sha512-v+dm9bNVfOYsY1OrhaCrmyOcYoSeVvbt+hHZ0Au+T+p1y+0Uyj9aMaGIeUTT6xdpRbWzDeYKvfOslPhggQMcsg==" - }, "node_modules/get-own-enumerable-property-symbols": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.2.tgz", @@ -5860,18 +6296,11 @@ "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==" }, "node_modules/globals": { - "version": "13.20.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", - "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", - "peer": true, - "dependencies": { - "type-fest": "^0.20.2" - }, + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=4" } }, "node_modules/globby": { @@ -5930,11 +6359,11 @@ } }, "node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", "engines": { - "node": ">=8" + "node": ">=4" } }, "node_modules/hash-base": { @@ -5999,17 +6428,6 @@ "node": ">=10.17.0" } }, - "node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/idb-keyval": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/idb-keyval/-/idb-keyval-6.2.1.tgz", @@ -6119,182 +6537,6 @@ "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", "dev": true }, - "node_modules/interface-datastore": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/interface-datastore/-/interface-datastore-6.1.1.tgz", - "integrity": "sha512-AmCS+9CT34pp2u0QQVXjKztkuq3y5T+BIciuiHDDtDZucZD8VudosnSdUyXJV6IsRkN5jc4RFDhCk1O6Q3Gxjg==", - "dependencies": { - "interface-store": "^2.0.2", - "nanoid": "^3.0.2", - "uint8arrays": "^3.0.0" - } - }, - "node_modules/interface-store": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/interface-store/-/interface-store-2.0.2.tgz", - "integrity": "sha512-rScRlhDcz6k199EkHqT8NpM87ebN89ICOzILoBHgaG36/WX50N32BnU/kpZgCGPLhARRAWUUX5/cyaIjt7Kipg==" - }, - "node_modules/ip-regex": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ip-regex/-/ip-regex-4.3.0.tgz", - "integrity": "sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q==", - "engines": { - "node": ">=8" - } - }, - "node_modules/ipfs-core-types": { - "version": "0.10.3", - "resolved": "https://registry.npmjs.org/ipfs-core-types/-/ipfs-core-types-0.10.3.tgz", - "integrity": "sha512-GNid2lRBjR5qgScCglgk7w9Hk3TZAwPHQXxOLQx72wgyc0jF2U5NXRoKW0GRvX8NPbHmsrFszForIqxd23I1Gw==", - "deprecated": "js-IPFS has been deprecated in favour of Helia - please see https://github.com/ipfs/js-ipfs/issues/4336 for details", - "dependencies": { - "@ipld/dag-pb": "^2.1.3", - "interface-datastore": "^6.0.2", - "ipfs-unixfs": "^6.0.3", - "multiaddr": "^10.0.0", - "multiformats": "^9.5.1" - } - }, - "node_modules/ipfs-core-utils": { - "version": "0.14.3", - "resolved": "https://registry.npmjs.org/ipfs-core-utils/-/ipfs-core-utils-0.14.3.tgz", - "integrity": "sha512-aBkewVhgAj3NWXPwu6imj0wADGiGVZmJzqKzODOJsibDjkx6FGdMv8kvvqtLnK8LS/dvSk9yk32IDtuDyYoV7Q==", - "deprecated": "js-IPFS has been deprecated in favour of Helia - please see https://github.com/ipfs/js-ipfs/issues/4336 for details", - "dependencies": { - "any-signal": "^3.0.0", - "blob-to-it": "^1.0.1", - "browser-readablestream-to-it": "^1.0.1", - "debug": "^4.1.1", - "err-code": "^3.0.1", - "ipfs-core-types": "^0.10.3", - "ipfs-unixfs": "^6.0.3", - "ipfs-utils": "^9.0.6", - "it-all": "^1.0.4", - "it-map": "^1.0.4", - "it-peekable": "^1.0.2", - "it-to-stream": "^1.0.0", - "merge-options": "^3.0.4", - "multiaddr": "^10.0.0", - "multiaddr-to-uri": "^8.0.0", - "multiformats": "^9.5.1", - "nanoid": "^3.1.23", - "parse-duration": "^1.0.0", - "timeout-abort-controller": "^3.0.0", - "uint8arrays": "^3.0.0" - } - }, - "node_modules/ipfs-http-client": { - "version": "56.0.3", - "resolved": "https://registry.npmjs.org/ipfs-http-client/-/ipfs-http-client-56.0.3.tgz", - "integrity": "sha512-E3L5ylVl6BjyRUsNehvfuRBYp1hj8vQ8in4zskVPMNzXs6JiCFUbif5a6BtcAlSK4xPQyJCeLNNAWLUeFQTLNA==", - "deprecated": "js-IPFS has been deprecated in favour of Helia - please see https://github.com/ipfs/js-ipfs/issues/4336 for details", - "dependencies": { - "@ipld/dag-cbor": "^7.0.0", - "@ipld/dag-json": "^8.0.1", - "@ipld/dag-pb": "^2.1.3", - "any-signal": "^3.0.0", - "dag-jose": "^1.0.0", - "debug": "^4.1.1", - "err-code": "^3.0.1", - "ipfs-core-types": "^0.10.3", - "ipfs-core-utils": "^0.14.3", - "ipfs-utils": "^9.0.6", - "it-first": "^1.0.6", - "it-last": "^1.0.4", - "merge-options": "^3.0.4", - "multiaddr": "^10.0.0", - "multiformats": "^9.5.1", - "parse-duration": "^1.0.0", - "stream-to-it": "^0.2.2", - "uint8arrays": "^3.0.0" - }, - "engines": { - "node": ">=15.0.0", - "npm": ">=3.0.0" - } - }, - "node_modules/ipfs-unixfs": { - "version": "6.0.9", - "resolved": "https://registry.npmjs.org/ipfs-unixfs/-/ipfs-unixfs-6.0.9.tgz", - "integrity": "sha512-0DQ7p0/9dRB6XCb0mVCTli33GzIzSVx5udpJuVM47tGcD+W+Bl4LsnoLswd3ggNnNEakMv1FdoFITiEnchXDqQ==", - "dependencies": { - "err-code": "^3.0.1", - "protobufjs": "^6.10.2" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/ipfs-utils": { - "version": "9.0.14", - "resolved": "https://registry.npmjs.org/ipfs-utils/-/ipfs-utils-9.0.14.tgz", - "integrity": "sha512-zIaiEGX18QATxgaS0/EOQNoo33W0islREABAcxXE8n7y2MGAlB+hdsxXn4J0hGZge8IqVQhW8sWIb+oJz2yEvg==", - "dependencies": { - "any-signal": "^3.0.0", - "browser-readablestream-to-it": "^1.0.0", - "buffer": "^6.0.1", - "electron-fetch": "^1.7.2", - "err-code": "^3.0.1", - "is-electron": "^2.2.0", - "iso-url": "^1.1.5", - "it-all": "^1.0.4", - "it-glob": "^1.0.1", - "it-to-stream": "^1.0.0", - "merge-options": "^3.0.4", - "nanoid": "^3.1.20", - "native-fetch": "^3.0.0", - "node-fetch": "^2.6.8", - "react-native-fetch-api": "^3.0.0", - "stream-to-it": "^0.2.2" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/ipfs-utils/node_modules/base64-js": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, - "node_modules/ipfs-utils/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/is-arrayish": { "version": "0.2.1", "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", @@ -6323,11 +6565,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-electron": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/is-electron/-/is-electron-2.2.2.tgz", - "integrity": "sha512-FO/Rhvz5tuw4MCWkpMzHFKWD2LsfHzIb7i6MdPYZ/KW7AlxawyLkqdy+jPZP1WubqEADE3O4FUENlJHDfQASRg==" - }, "node_modules/is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", @@ -6372,17 +6609,6 @@ "node": ">=8" } }, - "node_modules/is-ip": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/is-ip/-/is-ip-3.1.0.tgz", - "integrity": "sha512-35vd5necO7IitFPjd/YBeqwWnyDWbuLH9ZXQdMfDA8TEo7pv5X8yfrvVO3xbJbLUlERCMvf6X0hTUamQxCYJ9Q==", - "dependencies": { - "ip-regex": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -6413,6 +6639,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", + "dev": true, "engines": { "node": ">=8" } @@ -6443,6 +6670,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-subset": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-subset/-/is-subset-0.1.1.tgz", + "integrity": "sha512-6Ybun0IkarhmEqxXCNw/C0bna6Zb/TkfUX9UbwJtK6ObwAVCxmAP308WWTHviM/zAqXk05cdhYsUsZeGQh99iw==", + "dev": true + }, "node_modules/is-unicode-supported": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", @@ -6478,14 +6711,6 @@ "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" }, - "node_modules/iso-url": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/iso-url/-/iso-url-1.2.1.tgz", - "integrity": "sha512-9JPDgCN4B7QPkLtYAAOrEuAWvP9rWvR5offAr0/SeF046wIkglqH3VXgYYP6NcsKslH80UIVgmPqNe3j7tG2ng==", - "engines": { - "node": ">=12" - } - }, "node_modules/istanbul-lib-coverage": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz", @@ -6509,14 +6734,6 @@ "node": ">=8" } }, - "node_modules/istanbul-lib-instrument/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/istanbul-lib-report": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz", @@ -6530,6 +6747,25 @@ "node": ">=8" } }, + "node_modules/istanbul-lib-report/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/istanbul-lib-source-maps": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", @@ -6555,95 +6791,6 @@ "node": ">=8" } }, - "node_modules/it-all": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/it-all/-/it-all-1.0.6.tgz", - "integrity": "sha512-3cmCc6Heqe3uWi3CVM/k51fa/XbMFpQVzFoDsV0IZNHSQDyAXl3c4MjHkFX5kF3922OGj7Myv1nSEUgRtcuM1A==" - }, - "node_modules/it-first": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/it-first/-/it-first-1.0.7.tgz", - "integrity": "sha512-nvJKZoBpZD/6Rtde6FXqwDqDZGF1sCADmr2Zoc0hZsIvnE449gRFnGctxDf09Bzc/FWnHXAdaHVIetY6lrE0/g==" - }, - "node_modules/it-glob": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/it-glob/-/it-glob-1.0.2.tgz", - "integrity": "sha512-Ch2Dzhw4URfB9L/0ZHyY+uqOnKvBNeS/SMcRiPmJfpHiM0TsUZn+GkpcZxAoF3dJVdPm/PuIk3A4wlV7SUo23Q==", - "dependencies": { - "@types/minimatch": "^3.0.4", - "minimatch": "^3.0.4" - } - }, - "node_modules/it-last": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/it-last/-/it-last-1.0.6.tgz", - "integrity": "sha512-aFGeibeiX/lM4bX3JY0OkVCFkAw8+n9lkukkLNivbJRvNz8lI3YXv5xcqhFUV2lDJiraEK3OXRDbGuevnnR67Q==" - }, - "node_modules/it-map": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/it-map/-/it-map-1.0.6.tgz", - "integrity": "sha512-XT4/RM6UHIFG9IobGlQPFQUrlEKkU4eBUFG3qhWhfAdh1JfF2x11ShCrKCdmZ0OiZppPfoLuzcfA4cey6q3UAQ==" - }, - "node_modules/it-peekable": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/it-peekable/-/it-peekable-1.0.3.tgz", - "integrity": "sha512-5+8zemFS+wSfIkSZyf0Zh5kNN+iGyccN02914BY4w/Dj+uoFEoPSvj5vaWn8pNZJNSxzjW0zHRxC3LUb2KWJTQ==" - }, - "node_modules/it-to-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/it-to-stream/-/it-to-stream-1.0.0.tgz", - "integrity": "sha512-pLULMZMAB/+vbdvbZtebC0nWBTbG581lk6w8P7DfIIIKUfa8FbY7Oi0FxZcFPbxvISs7A9E+cMpLDBc1XhpAOA==", - "dependencies": { - "buffer": "^6.0.3", - "fast-fifo": "^1.0.0", - "get-iterator": "^1.0.2", - "p-defer": "^3.0.0", - "p-fifo": "^1.0.0", - "readable-stream": "^3.6.0" - } - }, - "node_modules/it-to-stream/node_modules/base64-js": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, - "node_modules/it-to-stream/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/jake": { "version": "10.8.7", "resolved": "https://registry.npmjs.org/jake/-/jake-10.8.7.tgz", @@ -6661,6 +6808,70 @@ "node": ">=10" } }, + "node_modules/jake/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jake/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jake/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jake/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jake/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jake/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest/-/jest-29.6.1.tgz", @@ -6728,10 +6939,74 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-cli": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.6.1.tgz", - "integrity": "sha512-607dSgTA4ODIN6go9w6xY3EYkyPFGicx51a69H7yfvt7lN53xNswEVLovq+E77VsTRi5fWprLH0yl4DJgE8Ing==", + "node_modules/jest-circus/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-circus/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-circus/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-circus/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-circus/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-circus/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-cli": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.6.1.tgz", + "integrity": "sha512-607dSgTA4ODIN6go9w6xY3EYkyPFGicx51a69H7yfvt7lN53xNswEVLovq+E77VsTRi5fWprLH0yl4DJgE8Ing==", "dependencies": { "@jest/core": "^29.6.1", "@jest/test-result": "^29.6.1", @@ -6761,6 +7036,70 @@ } } }, + "node_modules/jest-cli/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-cli/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-cli/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-cli/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-cli/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-cli/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-config": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.6.1.tgz", @@ -6805,6 +7144,70 @@ } } }, + "node_modules/jest-config/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-config/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-config/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-config/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-config/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-config/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-diff": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.6.1.tgz", @@ -6819,6 +7222,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-diff/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-diff/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-diff/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-diff/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-diff/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-diff/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-docblock": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", @@ -6845,6 +7312,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-each/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-each/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-each/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-each/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-each/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-each/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-environment-node": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-29.6.1.tgz", @@ -6887,55 +7418,183 @@ "walker": "^1.0.8" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "optionalDependencies": { + "fsevents": "^2.3.2" + } + }, + "node_modules/jest-leak-detector": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-29.6.1.tgz", + "integrity": "sha512-OrxMNyZirpOEwkF3UHnIkAiZbtkBWiye+hhBweCHkVbCgyEy71Mwbb5zgeTNYWJBi1qgDVfPC1IwO9dVEeTLwQ==", + "dependencies": { + "jest-get-type": "^29.4.3", + "pretty-format": "^29.6.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-matcher-utils": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.6.1.tgz", + "integrity": "sha512-SLaztw9d2mfQQKHmJXKM0HCbl2PPVld/t9Xa6P9sgiExijviSp7TnZZpw2Fpt+OI3nwUO/slJbOfzfUMKKC5QA==", + "dependencies": { + "chalk": "^4.0.0", + "jest-diff": "^29.6.1", + "jest-get-type": "^29.4.3", + "pretty-format": "^29.6.1" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-matcher-utils/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-matcher-utils/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-matcher-utils/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-matcher-utils/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-matcher-utils/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-matcher-utils/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-message-util": { + "version": "29.6.1", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.6.1.tgz", + "integrity": "sha512-KoAW2zAmNSd3Gk88uJ56qXUWbFk787QKmjjJVOjtGFmmGSZgDBrlIL4AfQw1xyMYPNVD7dNInfIbur9B2rd/wQ==", + "dependencies": { + "@babel/code-frame": "^7.12.13", + "@jest/types": "^29.6.1", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.9", + "micromatch": "^4.0.4", + "pretty-format": "^29.6.1", + "slash": "^3.0.0", + "stack-utils": "^2.0.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-message-util/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-message-util/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" }, - "optionalDependencies": { - "fsevents": "^2.3.2" + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/jest-leak-detector": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-29.6.1.tgz", - "integrity": "sha512-OrxMNyZirpOEwkF3UHnIkAiZbtkBWiye+hhBweCHkVbCgyEy71Mwbb5zgeTNYWJBi1qgDVfPC1IwO9dVEeTLwQ==", + "node_modules/jest-message-util/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dependencies": { - "jest-get-type": "^29.4.3", - "pretty-format": "^29.6.1" + "color-name": "~1.1.4" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=7.0.0" } }, - "node_modules/jest-matcher-utils": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-29.6.1.tgz", - "integrity": "sha512-SLaztw9d2mfQQKHmJXKM0HCbl2PPVld/t9Xa6P9sgiExijviSp7TnZZpw2Fpt+OI3nwUO/slJbOfzfUMKKC5QA==", - "dependencies": { - "chalk": "^4.0.0", - "jest-diff": "^29.6.1", - "jest-get-type": "^29.4.3", - "pretty-format": "^29.6.1" - }, + "node_modules/jest-message-util/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-message-util/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=8" } }, - "node_modules/jest-message-util": { - "version": "29.6.1", - "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.6.1.tgz", - "integrity": "sha512-KoAW2zAmNSd3Gk88uJ56qXUWbFk787QKmjjJVOjtGFmmGSZgDBrlIL4AfQw1xyMYPNVD7dNInfIbur9B2rd/wQ==", + "node_modules/jest-message-util/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dependencies": { - "@babel/code-frame": "^7.12.13", - "@jest/types": "^29.6.1", - "@types/stack-utils": "^2.0.0", - "chalk": "^4.0.0", - "graceful-fs": "^4.2.9", - "micromatch": "^4.0.4", - "pretty-format": "^29.6.1", - "slash": "^3.0.0", - "stack-utils": "^2.0.3" + "has-flag": "^4.0.0" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=8" } }, "node_modules/jest-mock": { @@ -7006,6 +7665,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-resolve/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-resolve/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-resolve/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-resolve/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-resolve/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-resolve/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-runner": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.6.1.tgz", @@ -7037,6 +7760,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-runner/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-runner/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-runner/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-runner/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-runner/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-runner/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-runtime": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.6.1.tgz", @@ -7069,6 +7856,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-runtime/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-runtime/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-runtime/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-runtime/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-runtime/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-runtime/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-snapshot": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.6.1.tgz", @@ -7097,7 +7948,60 @@ "semver": "^7.5.3" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/jest-snapshot/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-snapshot/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-snapshot/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-snapshot/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-snapshot/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" } }, "node_modules/jest-snapshot/node_modules/lru-cache": { @@ -7125,6 +8029,17 @@ "node": ">=10" } }, + "node_modules/jest-snapshot/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-snapshot/node_modules/yallist": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", @@ -7146,6 +8061,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-util/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-util/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-util/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-util/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-util/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-util/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-validate": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.6.1.tgz", @@ -7162,6 +8141,20 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-validate/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, "node_modules/jest-validate/node_modules/camelcase": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", @@ -7173,6 +8166,56 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/jest-validate/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-validate/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-validate/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-validate/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-validate/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-watcher": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.6.1.tgz", @@ -7191,6 +8234,70 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-watcher/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/jest-watcher/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/jest-watcher/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/jest-watcher/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/jest-watcher/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-watcher/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-worker": { "version": "29.6.1", "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.6.1.tgz", @@ -7205,6 +8312,14 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/jest-worker/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, "node_modules/jest-worker/node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -7377,23 +8492,6 @@ } } }, - "node_modules/ky-universal/node_modules/node-fetch": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-3.3.1.tgz", - "integrity": "sha512-cRVc/kyto/7E5shrWca1Wsea4y6tL9iYJE5FBCius3JQfb/4P4I295PfhgbJQBLTx6lATE4z+wK0rPM4VS2uow==", - "dependencies": { - "data-uri-to-buffer": "^4.0.0", - "fetch-blob": "^3.1.4", - "formdata-polyfill": "^4.0.10" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/node-fetch" - } - }, "node_modules/leven": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", @@ -7478,20 +8576,90 @@ "integrity": "sha512-HDWXG8isMntAyRF5vZ7xKuEvOhT4AhlRt/3czTSjvGUxjYCBVRQY48ViDHyfYz9VIoBkW4TMGQNapx+l3RUwdA==", "dev": true }, - "node_modules/log-symbols": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "node_modules/log-symbols": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", + "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "dev": true, + "dependencies": { + "chalk": "^4.1.0", + "is-unicode-supported": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-symbols/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/log-symbols/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/log-symbols/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/log-symbols/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/log-symbols/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/log-symbols/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" } }, "node_modules/logplease": { @@ -7499,11 +8667,6 @@ "resolved": "https://registry.npmjs.org/logplease/-/logplease-1.2.15.tgz", "integrity": "sha512-jLlHnlsPSJjpwUfcNyUxXCl33AYg2cHhIf9QhGL2T4iPT0XPB+xP1LRKFPgIg1M/sg9kAJvy94w9CzBNrfnstA==" }, - "node_modules/long": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/long/-/long-4.0.0.tgz", - "integrity": "sha512-XsP+KhQif4bjX1kbuSiySJFNAehNxgLb6hPRGJ9QsUr8ajHkuXGdrHmFUTUUXhDwVX2R5bY4JNZEwbUiMhV+MA==" - }, "node_modules/loupe": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz", @@ -7569,6 +8732,76 @@ } } }, + "node_modules/madge/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/madge/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/madge/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/madge/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/madge/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/madge/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/magic-string": { "version": "0.25.9", "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.9.tgz", @@ -7591,14 +8824,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/make-dir/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "bin": { - "semver": "bin/semver.js" - } - }, "node_modules/make-error": { "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", @@ -7622,17 +8847,6 @@ "safe-buffer": "^5.1.2" } }, - "node_modules/merge-options": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/merge-options/-/merge-options-3.0.4.tgz", - "integrity": "sha512-2Sug1+knBjkaMsMgf1ctR1Ujx+Ayku4EdJN4Z+C2+JzoeF7A3OZ9KM2GY0CpQS51NR61LTurMJrRKPhSs3ZRTQ==", - "dependencies": { - "is-plain-obj": "^2.1.0" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/merge-stream": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", @@ -7823,6 +9037,15 @@ "node": "*" } }, + "node_modules/mocha/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/mocha/node_modules/js-yaml": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", @@ -7862,18 +9085,6 @@ "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", "dev": true }, - "node_modules/mocha/node_modules/nanoid": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", - "integrity": "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==", - "dev": true, - "bin": { - "nanoid": "bin/nanoid.cjs" - }, - "engines": { - "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" - } - }, "node_modules/mocha/node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -7974,29 +9185,6 @@ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, - "node_modules/multiaddr": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/multiaddr/-/multiaddr-10.0.1.tgz", - "integrity": "sha512-G5upNcGzEGuTHkzxezPrrD6CaIHR9uo+7MwqhNVcXTs33IInon4y7nMiGxl2CY5hG7chvYQUQhz5V52/Qe3cbg==", - "deprecated": "This module is deprecated, please upgrade to @multiformats/multiaddr", - "dependencies": { - "dns-over-http-resolver": "^1.2.3", - "err-code": "^3.0.1", - "is-ip": "^3.1.0", - "multiformats": "^9.4.5", - "uint8arrays": "^3.0.0", - "varint": "^6.0.0" - } - }, - "node_modules/multiaddr-to-uri": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/multiaddr-to-uri/-/multiaddr-to-uri-8.0.0.tgz", - "integrity": "sha512-dq4p/vsOOUdVEd1J1gl+R2GFrXJQH8yjLtz4hodqdVbieg39LvBOdMQRdQnfbg5LSM/q1BYNVf5CBbwZFFqBgA==", - "deprecated": "This module is deprecated, please upgrade to @multiformats/multiaddr-to-uri", - "dependencies": { - "multiaddr": "^10.0.0" - } - }, "node_modules/multiformats": { "version": "9.9.0", "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", @@ -8077,15 +9265,10 @@ "integrity": "sha512-7vO7n28+aYO4J+8w96AzhmU8G+Y/xpPDJz/se19ICsqj/momRbb9mh9ZUtkoJ5X3nTnPdhEJyc0qnM6yAsHBaA==" }, "node_modules/nanoid": { - "version": "3.3.6", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.6.tgz", - "integrity": "sha512-BGcqMMJuToF7i1rt+2PWSNVnWIkGCU78jBG3RxO/bZlnZPK2Cmi2QaffxGO/2RvWi9sL+FAiRiXMgsyxQ1DIDA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", + "integrity": "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==", + "dev": true, "bin": { "nanoid": "bin/nanoid.cjs" }, @@ -8093,14 +9276,6 @@ "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" } }, - "node_modules/native-fetch": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/native-fetch/-/native-fetch-3.0.0.tgz", - "integrity": "sha512-G3Z7vx0IFb/FQ4JxvtqGABsOTIqRWvgQz6e+erkB+JJD6LrszQtMozEHI4EkmgZQvnGHrpLVzUWk7t4sJCIkVw==", - "peerDependencies": { - "node-fetch": "*" - } - }, "node_modules/natural-compare": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", @@ -8141,41 +9316,20 @@ } }, "node_modules/node-fetch": { - "version": "2.6.12", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz", - "integrity": "sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g==", + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-3.3.1.tgz", + "integrity": "sha512-cRVc/kyto/7E5shrWca1Wsea4y6tL9iYJE5FBCius3JQfb/4P4I295PfhgbJQBLTx6lATE4z+wK0rPM4VS2uow==", "dependencies": { - "whatwg-url": "^5.0.0" + "data-uri-to-buffer": "^4.0.0", + "fetch-blob": "^3.1.4", + "formdata-polyfill": "^4.0.10" }, "engines": { - "node": "4.x || >=6.0.0" - }, - "peerDependencies": { - "encoding": "^0.1.0" + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" }, - "peerDependenciesMeta": { - "encoding": { - "optional": true - } - } - }, - "node_modules/node-fetch/node_modules/tr46": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" - }, - "node_modules/node-fetch/node_modules/webidl-conversions": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" - }, - "node_modules/node-fetch/node_modules/whatwg-url": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", - "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", - "dependencies": { - "tr46": "~0.0.3", - "webidl-conversions": "^3.0.0" + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/node-fetch" } }, "node_modules/node-gyp-build": { @@ -8291,23 +9445,76 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/p-defer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-3.0.0.tgz", - "integrity": "sha512-ugZxsxmtTln604yeYd29EGrNhazN2lywetzpKhfmQjW/VJmhpDmWbiX+h0zL8V91R0UXkhb3KtPmyq9PZw3aYw==", + "node_modules/ora/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/ora/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/ora/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/ora/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/ora/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/ora/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, "engines": { "node": ">=8" } }, - "node_modules/p-fifo": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-fifo/-/p-fifo-1.0.0.tgz", - "integrity": "sha512-IjoCxXW48tqdtDFz6fqo5q1UfFVjjVZe8TC1QRflvNUJtNfCUhxOUw6MOVZhDPjqhSzc26xKdugsO17gmzd5+A==", - "dependencies": { - "fast-fifo": "^1.0.0", - "p-defer": "^3.0.0" - } - }, "node_modules/p-limit": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", @@ -8368,11 +9575,6 @@ "safe-buffer": "^5.1.1" } }, - "node_modules/parse-duration": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/parse-duration/-/parse-duration-1.1.0.tgz", - "integrity": "sha512-z6t9dvSJYaPoQq7quMzdEagSFtpGu+utzHqqxmpVWNNZRIXnvqyCvn9XsTdh7c/w0Bqmdz3RB3YnRaKtpRtEXQ==" - }, "node_modules/parse-json": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", @@ -8559,9 +9761,9 @@ } }, "node_modules/postcss": { - "version": "8.4.25", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.25.tgz", - "integrity": "sha512-7taJ/8t2av0Z+sQEvNzCkpDynl0tX3uJMCODi6nT3PfASC7dYCWV9aQ+uiCf+KBD4SEFcu+GvJdGdwzQ6OSjCw==", + "version": "8.4.26", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.26.tgz", + "integrity": "sha512-jrXHFF8iTloAenySjM/ob3gSj7pCu0Ji49hnjqzsgSRa50hkWCKD0HQ+gMNJkW38jBI68MpAAg7ZWwHwX8NMMw==", "dev": true, "funding": [ { @@ -8603,6 +9805,30 @@ "postcss": "^8.2.9" } }, + "node_modules/postcss-values-parser/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/postcss/node_modules/nanoid": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.6.tgz", + "integrity": "sha512-BGcqMMJuToF7i1rt+2PWSNVnWIkGCU78jBG3RxO/bZlnZPK2Cmi2QaffxGO/2RvWi9sL+FAiRiXMgsyxQ1DIDA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, "node_modules/precinct": { "version": "8.3.1", "resolved": "https://registry.npmjs.org/precinct/-/precinct-8.3.1.tgz", @@ -8835,6 +10061,18 @@ "node": ">=6.0" } }, + "node_modules/precinct/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/precinct/node_modules/node-source-walk": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/node-source-walk/-/node-source-walk-4.3.0.tgz", @@ -8861,6 +10099,21 @@ "node": ">=6.14.4" } }, + "node_modules/precinct/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/precinct/node_modules/typescript": { "version": "3.9.10", "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", @@ -8874,6 +10127,12 @@ "node": ">=4.2.0" } }, + "node_modules/precinct/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, "node_modules/prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -8967,31 +10226,6 @@ "node": ">= 6" } }, - "node_modules/protobufjs": { - "version": "6.11.3", - "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-6.11.3.tgz", - "integrity": "sha512-xL96WDdCZYdU7Slin569tFX712BxsxslWwAfAhCYjQKGTq7dAU91Lomy6nLLhh/dyGhk/YH4TwTSRxTzhuHyZg==", - "hasInstallScript": true, - "dependencies": { - "@protobufjs/aspromise": "^1.1.2", - "@protobufjs/base64": "^1.1.2", - "@protobufjs/codegen": "^2.0.4", - "@protobufjs/eventemitter": "^1.1.0", - "@protobufjs/fetch": "^1.1.0", - "@protobufjs/float": "^1.0.2", - "@protobufjs/inquire": "^1.1.0", - "@protobufjs/path": "^1.1.2", - "@protobufjs/pool": "^1.1.0", - "@protobufjs/utf8": "^1.1.0", - "@types/long": "^4.0.1", - "@types/node": ">=13.7.0", - "long": "^4.0.0" - }, - "bin": { - "pbjs": "bin/pbjs", - "pbts": "bin/pbts" - } - }, "node_modules/public-encrypt": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.3.tgz", @@ -9033,6 +10267,16 @@ } ] }, + "node_modules/querystring": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/querystring/-/querystring-0.2.1.tgz", + "integrity": "sha512-wkvS7mL/JMugcup3/rMitHmd9ecIGd2lhFhK9N3UUQ450h66d1r3Y9nvXzQAW1Lq+wyx61k/1pfKS5KuKiyEbg==", + "deprecated": "The querystring API is considered Legacy. new code should use the URLSearchParams API instead.", + "dev": true, + "engines": { + "node": ">=0.4.x" + } + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -9144,14 +10388,6 @@ "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==" }, - "node_modules/react-native-fetch-api": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/react-native-fetch-api/-/react-native-fetch-api-3.0.0.tgz", - "integrity": "sha512-g2rtqPjdroaboDKTsJCTlcmtw54E25OjyaunUP0anOZn4Fuo2IKs8BVfe02zVggA/UysbmfSnRJIqtNkAgggNA==", - "dependencies": { - "p-defer": "^3.0.0" - } - }, "node_modules/readable-stream": { "version": "3.6.2", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", @@ -9177,14 +10413,6 @@ "node": ">=8.10.0" } }, - "node_modules/receptacle": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/receptacle/-/receptacle-1.3.2.tgz", - "integrity": "sha512-HrsFvqZZheusncQRiEE7GatOAETrARKV/lnfYicIm8lbvp/JQOdADOfhjBd2DajvoszEyxSM6RlAAIZgEoeu/A==", - "dependencies": { - "ms": "^2.1.1" - } - }, "node_modules/regenerator-runtime": { "version": "0.13.11", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz", @@ -9307,11 +10535,6 @@ "node": ">=8" } }, - "node_modules/retimer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/retimer/-/retimer-3.0.0.tgz", - "integrity": "sha512-WKE0j11Pa0ZJI5YIk0nflGI7SQsfl2ljihVy7ogh7DeQSeYAUi0ubZ/yEueGtDfUPk6GH5LRw1hBdLq4IwUBWA==" - }, "node_modules/reusify": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", @@ -9496,35 +10719,13 @@ "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" }, "node_modules/semver": { - "version": "7.3.8", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", - "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", - "dependencies": { - "lru-cache": "^6.0.0" - }, + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "bin": { "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/semver/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=10" } }, - "node_modules/semver/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - }, "node_modules/serialize-javascript": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", @@ -9691,14 +10892,6 @@ "any-promise": "^1.1.0" } }, - "node_modules/stream-to-it": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/stream-to-it/-/stream-to-it-0.2.4.tgz", - "integrity": "sha512-4vEbkSs83OahpmBybNJXlJd7d6/RxzkkSdT3I0mnGt79Xd2Kk+e1JqbvAvsQfCeKj3aKb0QIWkyK3/n0j506vQ==", - "dependencies": { - "get-iterator": "^1.0.2" - } - }, "node_modules/streamsearch": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/streamsearch/-/streamsearch-1.1.0.tgz", @@ -9824,14 +11017,14 @@ "dev": true }, "node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dependencies": { - "has-flag": "^4.0.0" + "has-flag": "^3.0.0" }, "engines": { - "node": ">=8" + "node": ">=4" } }, "node_modules/supports-preserve-symlinks-flag": { @@ -9905,6 +11098,15 @@ } } }, + "node_modules/terser-webpack-plugin/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "peer": true, + "engines": { + "node": ">=8" + } + }, "node_modules/terser-webpack-plugin/node_modules/jest-worker": { "version": "27.5.1", "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz", @@ -9978,14 +11180,6 @@ "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", "peer": true }, - "node_modules/timeout-abort-controller": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/timeout-abort-controller/-/timeout-abort-controller-3.0.0.tgz", - "integrity": "sha512-O3e+2B8BKrQxU2YRyEjC/2yFdb33slI22WRdUaDx6rvysfi9anloNZyR2q0l6LnePo5qH7gSM7uZtvvwZbc2yA==", - "dependencies": { - "retimer": "^3.0.0" - } - }, "node_modules/tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -10135,6 +11329,100 @@ "webpack": "^5.0.0" } }, + "node_modules/ts-loader/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/ts-loader/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/ts-loader/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/ts-loader/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/ts-loader/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/ts-loader/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/ts-loader/node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/ts-loader/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/ts-loader/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, "node_modules/ts-node": { "version": "10.9.1", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", @@ -10263,10 +11551,9 @@ } }, "node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "peer": true, + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", "engines": { "node": ">=10" }, @@ -10388,11 +11675,6 @@ "node": ">=10.12.0" } }, - "node_modules/v8-to-istanbul/node_modules/convert-source-map": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.9.0.tgz", - "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" - }, "node_modules/validator": { "version": "13.9.0", "resolved": "https://registry.npmjs.org/validator/-/validator-13.9.0.tgz", @@ -10402,11 +11684,6 @@ "node": ">= 0.10" } }, - "node_modules/varint": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/varint/-/varint-6.0.0.tgz", - "integrity": "sha512-cXEIW6cfr15lFv563k4GuVuW/fiwjknytD37jIOLSdSWuOI6WnO/oKwmP2FQTU2l01LP8/M5TSAJpzUaGe3uWg==" - }, "node_modules/walkdir": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/walkdir/-/walkdir-0.4.1.tgz", @@ -10581,6 +11858,36 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, + "node_modules/wrap-ansi/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/wrap-ansi/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", diff --git a/package.json b/package.json index 66049427..2ed6d119 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "doc:build": "npm run doc:extract && npm run doc:documenter", "doc:watch:website": "ts-node ./scripts/doc-watch.ts", "tsc:declaration:watch": "tsc --watch --module commonjs --emitDeclarationOnly", - "test": "mocha", + "test": "env TS_NODE_COMPILER_OPTIONS='{\"strict\": false}' mocha", "lint": "eslint --fix --ext .js,.ts src/** tests/**", "format": "prettier --write \"src/**/*.ts\" \"tests/**/*.ts\"", "deps:check": "madge --circular --extensions ts ./" @@ -43,16 +43,18 @@ }, "homepage": "https://github.com/0xPolygonID/js-sdk#readme", "devDependencies": { - "@4c/fetch-mock": "^8.0.0", "@esbuild-plugins/node-globals-polyfill": "^0.1.1", "@esbuild-plugins/node-modules-polyfill": "^0.1.4", - "@microsoft/api-documenter": "^7.20.1", - "@microsoft/api-extractor": "^7.34.4", + "@gr2m/fetch-mock": "^9.11.0-pull-request-644.1", + "@microsoft/api-documenter": "^7.8.20", + "@microsoft/api-extractor": "^7.9.0", "@types/chai": "^4.3.4", "@types/chai-as-promised": "^7.1.5", - "@types/jsonld": "^1.4.8", + "@types/elliptic": "^6.4.14", + "@types/jsonld": "^1.5.9", "@types/mocha": "^10.0.1", "@types/node": "^18.16.19", + "@types/uuid": "^9.0.2", "@typescript-eslint/eslint-plugin": "^5.41.0", "chai": "^4.3.7", "chai-as-promised": "^7.1.1", @@ -86,7 +88,6 @@ "ethers": "^5.7.2", "ffjavascript": "^0.2.57", "idb-keyval": "^6.2.0", - "ipfs-http-client": "56.0.3", "jsonld": "^8.1.1", "multiformats": "^9.6.5", "rfc4648": "^1.5.2", @@ -108,5 +109,5 @@ }, "engines": { "node": ">=18.16.0" - } + } } diff --git a/src/circuits/atomic-query-mtp-v2-on-chain.ts b/src/circuits/atomic-query-mtp-v2-on-chain.ts index 2ff19081..e3a1a26e 100644 --- a/src/circuits/atomic-query-mtp-v2-on-chain.ts +++ b/src/circuits/atomic-query-mtp-v2-on-chain.ts @@ -23,28 +23,28 @@ import { byteDecoder, byteEncoder } from '../utils'; */ export class AtomicQueryMTPV2OnChainInputs extends BaseConfig { // auth - id: Id; - profileNonce: bigint; - claimSubjectProfileNonce: bigint; + id!: Id; + profileNonce!: bigint; + claimSubjectProfileNonce!: bigint; // claim issued for user - claim: ClaimWithMTPProof; - skipClaimRevocationCheck: boolean; - requestID: bigint; + claim!: ClaimWithMTPProof; + skipClaimRevocationCheck!: boolean; + requestID!: bigint; - currentTimeStamp: number; + currentTimeStamp!: number; - authClaim: Claim; - authClaimIncMtp: Proof; - authClaimNonRevMtp: Proof; - treeState: TreeState; + authClaim!: Claim; + authClaimIncMtp!: Proof; + authClaimNonRevMtp!: Proof; + treeState!: TreeState; - gistProof: GISTProof; + gistProof!: GISTProof; - signature: Signature; - challenge: bigint; + signature!: Signature; + challenge!: bigint; // query - query: Query; + query!: Query; /** * Validate inputs @@ -60,7 +60,7 @@ export class AtomicQueryMTPV2OnChainInputs extends BaseConfig { if (!this.authClaimNonRevMtp) { throw new Error(CircuitError.EmptyAuthClaimNonRevProof); } - if (!this.gistProof?.proof) { + if (!this.gistProof.proof) { throw new Error(CircuitError.EmptyGISTProof); } if (!this.signature) { @@ -88,29 +88,35 @@ export class AtomicQueryMTPV2OnChainInputs extends BaseConfig { requestID: this.requestID.toString(), userGenesisID: this.id.bigInt().toString(), profileNonce: this.profileNonce.toString(), - claimSubjectProfileNonce: this.claimSubjectProfileNonce.toString(), - issuerID: this.claim.issuerID.bigInt().toString(), - issuerClaim: this.claim.claim.marshalJson(), - issuerClaimMtp: prepareSiblingsStr(this.claim.incProof.proof, this.getMTLevel()), + claimSubjectProfileNonce: this.claimSubjectProfileNonce?.toString(), + issuerID: this.claim.issuerID?.bigInt().toString(), + issuerClaim: this.claim.claim?.marshalJson(), + issuerClaimMtp: + this.claim.incProof?.proof && + prepareSiblingsStr(this.claim.incProof.proof, this.getMTLevel()), issuerClaimClaimsTreeRoot: this.claim.incProof?.treeState?.claimsRoot?.string(), issuerClaimRevTreeRoot: this.claim.incProof?.treeState?.revocationRoot?.string(), issuerClaimRootsTreeRoot: this.claim.incProof?.treeState?.rootOfRoots?.string(), issuerClaimIdenState: this.claim.incProof?.treeState?.state?.string(), - issuerClaimNonRevMtp: prepareSiblingsStr(this.claim.nonRevProof?.proof, this.getMTLevel()), + issuerClaimNonRevMtp: + this.claim.nonRevProof?.proof && + prepareSiblingsStr(this.claim.nonRevProof?.proof, this.getMTLevel()), issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof?.treeState?.claimsRoot?.string(), issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof?.treeState?.revocationRoot?.string(), issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof?.treeState?.rootOfRoots?.string(), issuerClaimNonRevState: this.claim.nonRevProof?.treeState?.state?.string(), - claimSchema: this.claim.claim.getSchemaHash().bigInt().toString(), + claimSchema: this.claim.claim?.getSchemaHash().bigInt().toString(), claimPathMtp: prepareSiblingsStr(valueProof.mtp, this.getMTLevelsClaimMerklization()), claimPathValue: valueProof.value.toString(), operator: this.query.operator, slotIndex: this.query.slotIndex, - timestamp: this.currentTimeStamp, + timestamp: this.currentTimeStamp ?? undefined, isRevocationChecked: 1, - authClaim: this.authClaim?.marshalJson(), - authClaimIncMtp: prepareSiblingsStr(this.authClaimIncMtp, this.getMTLevel()), - authClaimNonRevMtp: prepareSiblingsStr(this.authClaimNonRevMtp, this.getMTLevel()), + authClaim: this.authClaim.marshalJson(), + authClaimIncMtp: + this.authClaimIncMtp && prepareSiblingsStr(this.authClaimIncMtp, this.getMTLevel()), + authClaimNonRevMtp: + this.authClaimNonRevMtp && prepareSiblingsStr(this.authClaimNonRevMtp, this.getMTLevel()), challenge: this.challenge.toString(), challengeSignatureR8x: this.signature.R8[0].toString(), challengeSignatureR8y: this.signature.R8[1].toString(), @@ -120,17 +126,18 @@ export class AtomicQueryMTPV2OnChainInputs extends BaseConfig { userRootsTreeRoot: this.treeState.rootOfRoots?.string(), userState: this.treeState.state?.string(), gistRoot: this.gistProof.root?.string(), - gistMtp: prepareSiblingsStr(this.gistProof.proof, this.getMTLevelOnChain()) + gistMtp: this.gistProof && prepareSiblingsStr(this.gistProof.proof, this.getMTLevelOnChain()) }; if (this.skipClaimRevocationCheck) { s.isRevocationChecked = 0; } - const nodeAuxNonRev = getNodeAuxValue(this.claim.nonRevProof.proof); - s.issuerClaimNonRevMtpAuxHi = nodeAuxNonRev.key.bigInt().toString(); - s.issuerClaimNonRevMtpAuxHv = nodeAuxNonRev.value.bigInt().toString(); - s.issuerClaimNonRevMtpNoAux = nodeAuxNonRev.noAux; + const nodeAuxNonRev = + this.claim.nonRevProof?.proof && getNodeAuxValue(this.claim.nonRevProof.proof); + s.issuerClaimNonRevMtpAuxHi = nodeAuxNonRev?.key.bigInt().toString(); + s.issuerClaimNonRevMtpAuxHv = nodeAuxNonRev?.value.bigInt().toString(); + s.issuerClaimNonRevMtpNoAux = nodeAuxNonRev?.noAux; s.claimPathNotExists = existenceToInt(valueProof.mtp.existence); const nodAuxJSONLD = getNodeAuxValue(valueProof.mtp); @@ -139,15 +146,16 @@ export class AtomicQueryMTPV2OnChainInputs extends BaseConfig { s.claimPathMtpAuxHv = nodAuxJSONLD.value.bigInt().toString(); s.claimPathKey = valueProof.path.toString(); - const values = prepareCircuitArrayValues(this.query.values, this.getValueArrSize()); - s.value = bigIntArrayToStringArray(values); + const values = + this.query.values && prepareCircuitArrayValues(this.query.values, this.getValueArrSize()); + s.value = values && bigIntArrayToStringArray(values); - const nodeAuxAuth = getNodeAuxValue(this.authClaimNonRevMtp); + const nodeAuxAuth = this.authClaimNonRevMtp && getNodeAuxValue(this.authClaimNonRevMtp); s.authClaimNonRevMtpAuxHi = nodeAuxAuth.key.string(); s.authClaimNonRevMtpAuxHv = nodeAuxAuth.value.string(); s.authClaimNonRevMtpNoAux = nodeAuxAuth.noAux; - const globalNodeAux = getNodeAuxValue(this.gistProof.proof); + const globalNodeAux = this.gistProof && getNodeAuxValue(this.gistProof.proof); s.gistMtpAuxHi = globalNodeAux.key.string(); s.gistMtpAuxHv = globalNodeAux.value.string(); s.gistMtpNoAux = globalNodeAux.noAux; @@ -163,7 +171,7 @@ interface atomicQueryMTPV2OnChainCircuitInputs { profileNonce: string; claimSubjectProfileNonce: string; issuerID: string; - issuerClaim?: string[]; + issuerClaim: string[]; issuerClaimMtp: string[]; issuerClaimClaimsTreeRoot: string; @@ -188,8 +196,8 @@ interface atomicQueryMTPV2OnChainCircuitInputs { claimPathMtp: string[]; claimPathMtpNoAux: string; // 1 if aux node is empty, // 0 if non-empty or for inclusion proofs - claimPathMtpAuxHi?: string; // 0 for inclusion proof - claimPathMtpAuxHv?: string; // 0 for inclusion proof + claimPathMtpAuxHi: string; // 0 for inclusion proof + claimPathMtpAuxHv: string; // 0 for inclusion proof claimPathKey: string; // hash of path in merklized json-ld document claimPathValue: string; // value in this path in merklized json-ld document @@ -236,17 +244,17 @@ interface atomicQueryMTPV2OnChainCircuitInputs { * @extends {BaseConfig} */ export class AtomicQueryMTPV2OnChainPubSignals extends BaseConfig { - requestID?: bigint; - userID?: Id; - issuerID?: Id; - issuerClaimIdenState?: Hash; - issuerClaimNonRevState?: Hash; - timestamp: number; - merklized: number; - isRevocationChecked: number; // 0 revocation not check, // 1 for check revocation - circuitQueryHash: bigint; - challenge: bigint; - gistRoot: Hash; + requestID!: bigint; + userID!: Id; + issuerID!: Id; + issuerClaimIdenState!: Hash; + issuerClaimNonRevState!: Hash; + timestamp!: number; + merklized!: number; + isRevocationChecked!: number; // 0 revocation not check, // 1 for check revocation + circuitQueryHash!: bigint; + challenge!: bigint; + gistRoot!: Hash; /** * diff --git a/src/circuits/atomic-query-mtp-v2.ts b/src/circuits/atomic-query-mtp-v2.ts index af1f9dc3..7574c5ef 100644 --- a/src/circuits/atomic-query-mtp-v2.ts +++ b/src/circuits/atomic-query-mtp-v2.ts @@ -22,18 +22,18 @@ import { byteDecoder, byteEncoder } from '../utils'; */ export class AtomicQueryMTPV2Inputs extends BaseConfig { // auth - id: Id; - profileNonce: bigint; - claimSubjectProfileNonce: bigint; + id!: Id; + profileNonce!: bigint; + claimSubjectProfileNonce!: bigint; // claim issued for user - claim: ClaimWithMTPProof; - skipClaimRevocationCheck: boolean; - requestID: bigint; + claim!: ClaimWithMTPProof; + skipClaimRevocationCheck!: boolean; + requestID!: bigint; - currentTimeStamp: number; + currentTimeStamp!: number; // query - query: Query; + query!: Query; /** * Validate AtomicQueryMTPV2 inputs @@ -62,27 +62,31 @@ export class AtomicQueryMTPV2Inputs extends BaseConfig { const s: Partial = { requestID: this.requestID.toString(), userGenesisID: this.id.bigInt().toString(), - profileNonce: this.profileNonce.toString(), - claimSubjectProfileNonce: this.claimSubjectProfileNonce.toString(), + profileNonce: this.profileNonce?.toString(), + claimSubjectProfileNonce: this.claimSubjectProfileNonce?.toString(), issuerID: this.claim.issuerID?.bigInt().toString(), - issuerClaim: this.claim.claim.marshalJson(), - issuerClaimMtp: prepareSiblingsStr(this.claim.incProof.proof, this.getMTLevel()), - issuerClaimClaimsTreeRoot: this.claim.incProof.treeState?.claimsRoot.bigInt().toString(), - issuerClaimRevTreeRoot: this.claim.incProof.treeState?.revocationRoot.bigInt().toString(), - issuerClaimRootsTreeRoot: this.claim.incProof.treeState?.rootOfRoots.bigInt().toString(), - issuerClaimIdenState: this.claim.incProof.treeState?.state.bigInt().toString(), - issuerClaimNonRevMtp: prepareSiblingsStr(this.claim.nonRevProof.proof, this.getMTLevel()), - issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof.treeState?.claimsRoot - .bigInt() + issuerClaim: this.claim.claim?.marshalJson(), + issuerClaimMtp: + this.claim.incProof?.proof && + prepareSiblingsStr(this.claim.incProof.proof, this.getMTLevel()), + issuerClaimClaimsTreeRoot: this.claim.incProof?.treeState?.claimsRoot?.bigInt().toString(), + issuerClaimRevTreeRoot: this.claim.incProof?.treeState?.revocationRoot?.bigInt().toString(), + issuerClaimRootsTreeRoot: this.claim.incProof?.treeState?.rootOfRoots?.bigInt().toString(), + issuerClaimIdenState: this.claim.incProof?.treeState?.state?.bigInt().toString(), + issuerClaimNonRevMtp: + this.claim.nonRevProof?.proof && + prepareSiblingsStr(this.claim.nonRevProof.proof, this.getMTLevel()), + issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof?.treeState?.claimsRoot + ?.bigInt() .toString(), - issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof.treeState?.revocationRoot - .bigInt() + issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof?.treeState?.revocationRoot + ?.bigInt() .toString(), - issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof.treeState?.rootOfRoots - .bigInt() + issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof?.treeState?.rootOfRoots + ?.bigInt() .toString(), - issuerClaimNonRevState: this.claim.nonRevProof.treeState?.state.bigInt().toString(), - claimSchema: this.claim.claim.getSchemaHash().bigInt().toString(), + issuerClaimNonRevState: this.claim.nonRevProof?.treeState?.state?.bigInt().toString(), + claimSchema: this.claim.claim?.getSchemaHash().bigInt().toString(), claimPathMtp: prepareSiblingsStr(valueProof.mtp, this.getMTLevelsClaimMerklization()), claimPathValue: valueProof.value.toString(), operator: this.query.operator, @@ -90,10 +94,10 @@ export class AtomicQueryMTPV2Inputs extends BaseConfig { timestamp: this.currentTimeStamp }; - const nodeAux = getNodeAuxValue(this.claim.nonRevProof.proof); - s.issuerClaimNonRevMtpAuxHi = nodeAux.key.bigInt().toString(); - s.issuerClaimNonRevMtpAuxHv = nodeAux.value.bigInt().toString(); - s.issuerClaimNonRevMtpNoAux = nodeAux.noAux; + const nodeAux = getNodeAuxValue(this.claim.nonRevProof?.proof); + s.issuerClaimNonRevMtpAuxHi = nodeAux?.key.bigInt().toString(); + s.issuerClaimNonRevMtpAuxHv = nodeAux?.value.bigInt().toString(); + s.issuerClaimNonRevMtpNoAux = nodeAux?.noAux; s.claimPathNotExists = existenceToInt(valueProof.mtp.existence); const nodAuxJSONLD = getNodeAuxValue(valueProof.mtp); @@ -109,7 +113,8 @@ export class AtomicQueryMTPV2Inputs extends BaseConfig { s.isRevocationChecked = 1; } - const values = prepareCircuitArrayValues(this.query.values, this.getValueArrSize()); + const values = + this.query.values && prepareCircuitArrayValues(this.query.values, this.getValueArrSize()); s.value = bigIntArrayToStringArray(values); @@ -167,17 +172,17 @@ export class AtomicQueryMTPV2PubSignals extends BaseConfig { issuerID?: Id; issuerClaimIdenState?: Hash; issuerClaimNonRevState?: Hash; - claimSchema: SchemaHash; - slotIndex: number; - operator: number; + claimSchema?: SchemaHash; + slotIndex?: number; + operator?: number; value: bigint[] = []; - timestamp: number; - merklized: number; + timestamp?: number; + merklized?: number; claimPathKey?: bigint; // 0 for inclusion, 1 for non-inclusion - claimPathNotExists: number; + claimPathNotExists?: number; // 0 revocation not check, // 1 for check revocation - isRevocationChecked: number; + isRevocationChecked?: number; /** * PubSignalsUnmarshal unmarshal credentialAtomicQueryMTP.circom public signals array to AtomicQueryMTPPubSignals diff --git a/src/circuits/atomic-query-sig-v2-on-chain.ts b/src/circuits/atomic-query-sig-v2-on-chain.ts index 6566ed7e..4e9111cd 100644 --- a/src/circuits/atomic-query-sig-v2-on-chain.ts +++ b/src/circuits/atomic-query-sig-v2-on-chain.ts @@ -22,31 +22,31 @@ import { byteDecoder, byteEncoder } from '../utils'; * @extends {BaseConfig} */ export class AtomicQuerySigV2OnChainInputs extends BaseConfig { - requestID: bigint; + requestID!: bigint; // auth - id: Id; - profileNonce: bigint; - claimSubjectProfileNonce: bigint; + id!: Id; + profileNonce!: bigint; + claimSubjectProfileNonce!: bigint; // claim issued for user - claim: ClaimWithSigProof; - skipClaimRevocationCheck: boolean; + claim!: ClaimWithSigProof; + skipClaimRevocationCheck!: boolean; - authClaim: Claim; + authClaim!: Claim; - authClaimIncMtp: Proof; - authClaimNonRevMtp: Proof; - treeState: TreeState; + authClaimIncMtp!: Proof; + authClaimNonRevMtp!: Proof; + treeState!: TreeState; - gistProof: GISTProof; + gistProof!: GISTProof; - signature: Signature; - challenge: bigint; + signature!: Signature; + challenge!: bigint; // query - query: Query; + query!: Query; - currentTimeStamp: number; + currentTimeStamp!: number; /** * Validate inputs @@ -57,11 +57,11 @@ export class AtomicQuerySigV2OnChainInputs extends BaseConfig { if (!this.requestID) { throw new Error(CircuitError.EmptyRequestID); } - if (!this.claim.nonRevProof.proof) { + if (!this.claim.nonRevProof?.proof) { throw new Error(CircuitError.EmptyClaimNonRevProof); } - if (!this.claim.signatureProof.issuerAuthIncProof.proof) { + if (!this.claim.signatureProof?.issuerAuthIncProof.proof) { throw new Error(CircuitError.EmptyIssuerAuthClaimProof); } @@ -73,7 +73,7 @@ export class AtomicQuerySigV2OnChainInputs extends BaseConfig { throw new Error(CircuitError.EmptyClaimSignature); } - if (!this.query.values) { + if (!this.query?.values) { throw new Error(CircuitError.EmptyQueryValue); } @@ -106,91 +106,98 @@ export class AtomicQuerySigV2OnChainInputs extends BaseConfig { inputsMarshal(): Uint8Array { this.validate(); - if (this.query.valueProof) { + if (this.query?.valueProof) { this.query.validate(); this.query.valueProof.validate(); } - const valueProof = this.query.valueProof ?? new ValueProof(); + const valueProof = this.query?.valueProof ?? new ValueProof(); const s: Partial = { requestID: this.requestID.toString(), userGenesisID: this.id.bigInt().toString(), profileNonce: this.profileNonce.toString(), - claimSubjectProfileNonce: this.claimSubjectProfileNonce.toString(), - issuerID: this.claim.issuerID.bigInt().toString(), - issuerClaim: this.claim.claim.marshalJson(), - issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof.treeState?.claimsRoot - .bigInt() + claimSubjectProfileNonce: this.claimSubjectProfileNonce?.toString(), + issuerID: this.claim.issuerID?.bigInt().toString(), + issuerClaim: this.claim.claim?.marshalJson(), + issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof?.treeState?.claimsRoot + ?.bigInt() .toString(), - issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof.treeState?.revocationRoot - .bigInt() + issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof?.treeState?.revocationRoot + ?.bigInt() .toString(), - issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof.treeState?.rootOfRoots - .bigInt() + issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof?.treeState?.rootOfRoots + ?.bigInt() .toString(), - issuerClaimNonRevState: this.claim.nonRevProof.treeState?.state.bigInt().toString(), - issuerClaimNonRevMtp: prepareSiblingsStr(this.claim.nonRevProof.proof, this.getMTLevel()), - issuerClaimSignatureR8x: this.claim.signatureProof.signature.R8[0].toString(), - issuerClaimSignatureR8y: this.claim.signatureProof.signature.R8[1].toString(), - issuerClaimSignatureS: this.claim.signatureProof.signature.S.toString(), - issuerAuthClaim: this.claim.signatureProof.issuerAuthClaim?.marshalJson(), - issuerAuthClaimMtp: prepareSiblingsStr( - this.claim.signatureProof.issuerAuthIncProof.proof, - this.getMTLevel() - ), - issuerAuthClaimsTreeRoot: this.claim.signatureProof.issuerAuthIncProof.treeState?.claimsRoot - .bigInt() + issuerClaimNonRevState: this.claim.nonRevProof?.treeState?.state?.bigInt().toString(), + issuerClaimNonRevMtp: + this.claim.nonRevProof?.proof && + prepareSiblingsStr(this.claim.nonRevProof.proof, this.getMTLevel()), + + issuerClaimSignatureR8x: + this.claim.signatureProof && this.claim.signatureProof.signature.R8[0].toString(), + issuerClaimSignatureR8y: this.claim.signatureProof?.signature.R8[1].toString(), + issuerClaimSignatureS: this.claim.signatureProof?.signature.S.toString(), + issuerAuthClaim: this.claim.signatureProof?.issuerAuthClaim?.marshalJson(), + issuerAuthClaimMtp: + this.claim.signatureProof?.issuerAuthIncProof?.proof && + prepareSiblingsStr(this.claim.signatureProof.issuerAuthIncProof.proof, this.getMTLevel()), + issuerAuthClaimsTreeRoot: this.claim.signatureProof?.issuerAuthIncProof?.treeState?.claimsRoot + ?.bigInt() .toString(), - issuerAuthRevTreeRoot: this.claim.signatureProof.issuerAuthIncProof.treeState?.revocationRoot - .bigInt() + issuerAuthRevTreeRoot: + this.claim.signatureProof?.issuerAuthIncProof?.treeState?.revocationRoot + ?.bigInt() + .toString(), + issuerAuthRootsTreeRoot: this.claim.signatureProof?.issuerAuthIncProof?.treeState?.rootOfRoots + ?.bigInt() .toString(), - issuerAuthRootsTreeRoot: this.claim.signatureProof.issuerAuthIncProof.treeState?.rootOfRoots - .bigInt() - .toString(), - - issuerAuthClaimNonRevMtp: prepareSiblingsStr( - this.claim.signatureProof.issuerAuthNonRevProof.proof, - this.getMTLevel() - ), - claimSchema: this.claim.claim.getSchemaHash().bigInt().toString(), + issuerAuthClaimNonRevMtp: + this.claim.signatureProof?.issuerAuthNonRevProof?.proof && + prepareSiblingsStr( + this.claim.signatureProof.issuerAuthNonRevProof.proof, + this.getMTLevel() + ), + claimSchema: this.claim.claim?.getSchemaHash().bigInt().toString(), claimPathMtp: prepareSiblingsStr(valueProof.mtp, this.getMTLevelsClaimMerklization()), claimPathValue: valueProof.value.toString(), - operator: this.query.operator, + operator: this.query?.operator, timestamp: this.currentTimeStamp, // value in this path in merklized json-ld document - slotIndex: this.query.slotIndex, + slotIndex: this.query?.slotIndex, isRevocationChecked: 1, - authClaim: this.authClaim?.marshalJson(), - authClaimIncMtp: prepareSiblingsStr(this.authClaimIncMtp, this.getMTLevel()), - authClaimNonRevMtp: prepareSiblingsStr(this.authClaimNonRevMtp, this.getMTLevel()), - challenge: this.challenge.toString(), + authClaim: this.authClaim.marshalJson(), + authClaimIncMtp: + this.authClaimIncMtp && prepareSiblingsStr(this.authClaimIncMtp, this.getMTLevel()), + authClaimNonRevMtp: + this.authClaimNonRevMtp && prepareSiblingsStr(this.authClaimNonRevMtp, this.getMTLevel()), + challenge: this.challenge?.toString(), challengeSignatureR8x: this.signature.R8[0].toString(), challengeSignatureR8y: this.signature.R8[1].toString(), challengeSignatureS: this.signature.S.toString(), - userClaimsTreeRoot: this.treeState.claimsRoot.string(), - userRevTreeRoot: this.treeState.revocationRoot.string(), - userRootsTreeRoot: this.treeState.rootOfRoots.string(), - userState: this.treeState.state.string(), + userClaimsTreeRoot: this.treeState.claimsRoot?.string(), + userRevTreeRoot: this.treeState.revocationRoot?.string(), + userRootsTreeRoot: this.treeState.rootOfRoots?.string(), + userState: this.treeState.state?.string(), gistRoot: this.gistProof.root.string(), - gistMtp: prepareSiblingsStr(this.gistProof.proof, this.getMTLevelOnChain()) + gistMtp: this.gistProof && prepareSiblingsStr(this.gistProof.proof, this.getMTLevelOnChain()) }; if (this.skipClaimRevocationCheck) { s.isRevocationChecked = 0; } - const nodeAuxNonRev = getNodeAuxValue(this.claim.nonRevProof.proof); - s.issuerClaimNonRevMtpAuxHi = nodeAuxNonRev.key.bigInt().toString(); - s.issuerClaimNonRevMtpAuxHv = nodeAuxNonRev.value.bigInt().toString(); - s.issuerClaimNonRevMtpNoAux = nodeAuxNonRev.noAux; + const nodeAuxNonRev = getNodeAuxValue(this.claim.nonRevProof?.proof); + s.issuerClaimNonRevMtpAuxHi = nodeAuxNonRev?.key.bigInt().toString(); + s.issuerClaimNonRevMtpAuxHv = nodeAuxNonRev?.value.bigInt().toString(); + s.issuerClaimNonRevMtpNoAux = nodeAuxNonRev?.noAux; const nodeAuxIssuerAuthNonRev = getNodeAuxValue( - this.claim.signatureProof.issuerAuthNonRevProof.proof + this.claim.signatureProof?.issuerAuthNonRevProof.proof ); - s.issuerAuthClaimNonRevMtpAuxHi = nodeAuxIssuerAuthNonRev.key.bigInt().toString(); - s.issuerAuthClaimNonRevMtpAuxHv = nodeAuxIssuerAuthNonRev.value.bigInt().toString(); - s.issuerAuthClaimNonRevMtpNoAux = nodeAuxIssuerAuthNonRev.noAux; + s.issuerAuthClaimNonRevMtpAuxHi = nodeAuxIssuerAuthNonRev?.key.bigInt().toString(); + s.issuerAuthClaimNonRevMtpAuxHv = nodeAuxIssuerAuthNonRev?.value.bigInt().toString(); + s.issuerAuthClaimNonRevMtpNoAux = nodeAuxIssuerAuthNonRev?.noAux; s.claimPathNotExists = existenceToInt(valueProof.mtp.existence); const nodAuxJSONLD = getNodeAuxValue(valueProof.mtp); @@ -224,81 +231,81 @@ export class AtomicQuerySigV2OnChainInputs extends BaseConfig { * @class AtomicQuerySigV2OnChainCircuitInputs */ export class AtomicQuerySigV2OnChainCircuitInputs { - requestID: string; + requestID!: string; // user data - userGenesisID: string; - profileNonce: string; - claimSubjectProfileNonce: string; + userGenesisID!: string; + profileNonce!: string; + claimSubjectProfileNonce!: string; - issuerID: string; + issuerID!: string; // Claim - issuerClaim?: string[]; - issuerClaimNonRevClaimsTreeRoot: string; - issuerClaimNonRevRevTreeRoot: string; - issuerClaimNonRevRootsTreeRoot: string; - issuerClaimNonRevState: string; - issuerClaimNonRevMtp: string[]; - issuerClaimNonRevMtpAuxHi?: string; - issuerClaimNonRevMtpAuxHv?: string; - issuerClaimNonRevMtpNoAux: string; - claimSchema: string; - issuerClaimSignatureR8x: string; - issuerClaimSignatureR8y: string; - issuerClaimSignatureS: string; - issuerAuthClaim?: string[]; - issuerAuthClaimMtp: string[]; - issuerAuthClaimNonRevMtp: string[]; - issuerAuthClaimNonRevMtpAuxHi?: string; - issuerAuthClaimNonRevMtpAuxHv?: string; - issuerAuthClaimNonRevMtpNoAux: string; - issuerAuthClaimsTreeRoot: string; - issuerAuthRevTreeRoot: string; - issuerAuthRootsTreeRoot: string; - - isRevocationChecked: number; + issuerClaim!: string[]; + issuerClaimNonRevClaimsTreeRoot!: string; + issuerClaimNonRevRevTreeRoot!: string; + issuerClaimNonRevRootsTreeRoot!: string; + issuerClaimNonRevState!: string; + issuerClaimNonRevMtp!: string[]; + issuerClaimNonRevMtpAuxHi!: string; + issuerClaimNonRevMtpAuxHv!: string; + issuerClaimNonRevMtpNoAux!: string; + claimSchema!: string; + issuerClaimSignatureR8x!: string; + issuerClaimSignatureR8y!: string; + issuerClaimSignatureS!: string; + issuerAuthClaim!: string[]; + issuerAuthClaimMtp!: string[]; + issuerAuthClaimNonRevMtp!: string[]; + issuerAuthClaimNonRevMtpAuxHi!: string; + issuerAuthClaimNonRevMtpAuxHv!: string; + issuerAuthClaimNonRevMtpNoAux!: string; + issuerAuthClaimsTreeRoot!: string; + issuerAuthRevTreeRoot!: string; + issuerAuthRootsTreeRoot!: string; + + isRevocationChecked!: number; // Query // JSON path - claimPathNotExists: number; // 0 for inclusion, 1 for non-inclusion - claimPathMtp: string[]; - claimPathMtpNoAux: string; // 1 if aux node is empty, 0 if non-empty or for inclusion proofs - claimPathMtpAuxHi: string; // 0 for inclusion proof - claimPathMtpAuxHv: string; // 0 for inclusion proof - claimPathKey: string; // hash of path in merklized json-ld document - claimPathValue: string; // value in this path in merklized json-ld document - - operator: number; - slotIndex: number; - timestamp: number; - value: string[]; + claimPathNotExists!: number; // 0 for inclusion, 1 for non-inclusion + claimPathMtp!: string[]; + claimPathMtpNoAux!: string; // 1 if aux node is empty, 0 if non-empty or for inclusion proofs + claimPathMtpAuxHi!: string; // 0 for inclusion proof + claimPathMtpAuxHv!: string; // 0 for inclusion proof + claimPathKey!: string; // hash of path in merklized json-ld document + claimPathValue!: string; // value in this path in merklized json-ld document + + operator!: number; + slotIndex!: number; + timestamp!: number; + value!: string[]; // AuthClaim proof of inclusion - authClaim: string[]; - authClaimIncMtp: string[]; + authClaim!: string[]; + authClaimIncMtp!: string[]; // AuthClaim non revocation proof - authClaimNonRevMtp: string[]; - authClaimNonRevMtpAuxHi: string; - authClaimNonRevMtpAuxHv: string; - authClaimNonRevMtpNoAux: string; + authClaimNonRevMtp!: string[]; + authClaimNonRevMtpAuxHi!: string; + authClaimNonRevMtpAuxHv!: string; + authClaimNonRevMtpNoAux!: string; - challenge: string; - challengeSignatureR8x: string; - challengeSignatureR8y: string; - challengeSignatureS: string; + challenge!: string; + challengeSignatureR8x!: string; + challengeSignatureR8y!: string; + challengeSignatureS!: string; // User State - userClaimsTreeRoot: string; - userRevTreeRoot: string; - userRootsTreeRoot: string; - userState: string; + userClaimsTreeRoot!: string; + userRevTreeRoot!: string; + userRootsTreeRoot!: string; + userState!: string; // Global on-cain state - gistRoot: string; - gistMtp: string[]; - gistMtpAuxHi: string; - gistMtpAuxHv: string; - gistMtpNoAux: string; + gistRoot!: string; + gistMtp!: string[]; + gistMtpAuxHi!: string; + gistMtpAuxHv!: string; + gistMtpNoAux!: string; } /** @@ -310,17 +317,17 @@ export class AtomicQuerySigV2OnChainCircuitInputs { * @extends {BaseConfig} */ export class AtomicQuerySigV2OnChainPubSignals extends BaseConfig { - requestID?: bigint; - userID?: Id; - issuerID?: Id; - issuerAuthState?: Hash; - issuerClaimNonRevState?: Hash; - timestamp: number; - merklized: number; - isRevocationChecked: number; // 0 revocation not check, // 1 for check revocation - circuitQueryHash: bigint; - challenge: bigint; - gistRoot: Hash; + requestID!: bigint; + userID!: Id; + issuerID!: Id; + issuerAuthState!: Hash; + issuerClaimNonRevState!: Hash; + timestamp!: number; + merklized!: number; + isRevocationChecked!: number; // 0 revocation not check, // 1 for check revocation + circuitQueryHash!: bigint; + challenge!: bigint; + gistRoot!: Hash; // /** diff --git a/src/circuits/atomic-query-sig-v2.ts b/src/circuits/atomic-query-sig-v2.ts index c7810040..93c7cc38 100644 --- a/src/circuits/atomic-query-sig-v2.ts +++ b/src/circuits/atomic-query-sig-v2.ts @@ -23,20 +23,20 @@ import { byteDecoder, byteEncoder } from '../utils'; * @extends {BaseConfig} */ export class AtomicQuerySigV2Inputs extends BaseConfig { - requestID: bigint; + requestID!: bigint; // auth - id: Id; - profileNonce: bigint; - claimSubjectProfileNonce: bigint; + id!: Id; + profileNonce!: bigint; + claimSubjectProfileNonce!: bigint; // claim issued for user - claim: ClaimWithSigProof; - skipClaimRevocationCheck: boolean; + claim!: ClaimWithSigProof; + skipClaimRevocationCheck!: boolean; - currentTimeStamp: number; + currentTimeStamp!: number; // query - query: Query; + query!: Query; /** * Validate inputs @@ -46,11 +46,11 @@ export class AtomicQuerySigV2Inputs extends BaseConfig { if (!this.requestID) { throw new Error(CircuitError.EmptyRequestID); } - if (!this.claim.nonRevProof.proof) { + if (!this.claim.nonRevProof?.proof) { throw new Error(CircuitError.EmptyClaimNonRevProof); } - if (!this.claim.signatureProof.issuerAuthIncProof.proof) { + if (!this.claim.signatureProof?.issuerAuthIncProof.proof) { throw new Error(CircuitError.EmptyIssuerAuthClaimProof); } @@ -85,51 +85,54 @@ export class AtomicQuerySigV2Inputs extends BaseConfig { requestID: this.requestID.toString(), userGenesisID: this.id.bigInt().toString(), profileNonce: this.profileNonce.toString(), - claimSubjectProfileNonce: this.claimSubjectProfileNonce.toString(), - issuerID: this.claim.issuerID.bigInt().toString(), - issuerClaim: this.claim.claim.marshalJson(), - issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof.treeState?.claimsRoot - .bigInt() + claimSubjectProfileNonce: this.claimSubjectProfileNonce?.toString(), + issuerID: this.claim.issuerID?.bigInt().toString(), + issuerClaim: this.claim.claim?.marshalJson(), + issuerClaimNonRevClaimsTreeRoot: this.claim.nonRevProof?.treeState?.claimsRoot + ?.bigInt() .toString(), - issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof.treeState?.revocationRoot - .bigInt() + issuerClaimNonRevRevTreeRoot: this.claim.nonRevProof?.treeState?.revocationRoot + ?.bigInt() .toString(), - issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof.treeState?.rootOfRoots - .bigInt() + issuerClaimNonRevRootsTreeRoot: this.claim.nonRevProof?.treeState?.rootOfRoots + ?.bigInt() .toString(), - issuerClaimNonRevState: this.claim.nonRevProof.treeState?.state.bigInt().toString(), - issuerClaimNonRevMtp: prepareSiblingsStr(this.claim.nonRevProof.proof, this.getMTLevel()), - issuerClaimSignatureR8x: this.claim.signatureProof.signature.R8[0].toString(), - issuerClaimSignatureR8y: this.claim.signatureProof.signature.R8[1].toString(), - issuerClaimSignatureS: this.claim.signatureProof.signature.S.toString(), - issuerAuthClaim: this.claim.signatureProof.issuerAuthClaim?.marshalJson(), - issuerAuthClaimMtp: prepareSiblingsStr( - this.claim.signatureProof.issuerAuthIncProof.proof, - this.getMTLevel() - ), - issuerAuthClaimsTreeRoot: this.claim.signatureProof.issuerAuthIncProof.treeState?.claimsRoot - .bigInt() + issuerClaimNonRevState: this.claim.nonRevProof?.treeState?.state?.bigInt().toString(), + issuerClaimNonRevMtp: + this.claim.nonRevProof?.proof && + prepareSiblingsStr(this.claim.nonRevProof.proof, this.getMTLevel()), + issuerClaimSignatureR8x: this.claim.signatureProof?.signature.R8[0].toString(), + issuerClaimSignatureR8y: this.claim.signatureProof?.signature.R8[1].toString(), + issuerClaimSignatureS: this.claim.signatureProof?.signature.S.toString(), + issuerAuthClaim: this.claim.signatureProof?.issuerAuthClaim?.marshalJson(), + issuerAuthClaimMtp: + this.claim.signatureProof?.issuerAuthIncProof?.proof && + prepareSiblingsStr(this.claim.signatureProof.issuerAuthIncProof.proof, this.getMTLevel()), + issuerAuthClaimsTreeRoot: this.claim.signatureProof?.issuerAuthIncProof.treeState?.claimsRoot + ?.bigInt() .toString(), - issuerAuthRevTreeRoot: this.claim.signatureProof.issuerAuthIncProof.treeState?.revocationRoot - .bigInt() - .toString(), - issuerAuthRootsTreeRoot: this.claim.signatureProof.issuerAuthIncProof.treeState?.rootOfRoots - .bigInt() + issuerAuthRevTreeRoot: + this.claim.signatureProof?.issuerAuthIncProof?.treeState?.revocationRoot + ?.bigInt() + .toString(), + issuerAuthRootsTreeRoot: this.claim.signatureProof?.issuerAuthIncProof?.treeState?.rootOfRoots + ?.bigInt() .toString(), - issuerAuthClaimNonRevMtp: prepareSiblingsStr( - this.claim.signatureProof.issuerAuthNonRevProof.proof, - this.getMTLevel() - ), + issuerAuthClaimNonRevMtp: + this.claim.signatureProof?.issuerAuthNonRevProof?.proof && + prepareSiblingsStr( + this.claim.signatureProof.issuerAuthNonRevProof.proof, + this.getMTLevel() + ), - claimSchema: this.claim.claim.getSchemaHash().bigInt().toString(), + claimSchema: this.claim.claim?.getSchemaHash().bigInt().toString(), claimPathMtp: prepareSiblingsStr(valueProof.mtp, this.getMTLevelsClaimMerklization()), claimPathValue: valueProof.value.toString(), operator: this.query.operator, timestamp: this.currentTimeStamp, // value in this path in merklized json-ld document - slotIndex: this.query.slotIndex }; @@ -138,17 +141,17 @@ export class AtomicQuerySigV2Inputs extends BaseConfig { } else { s.isRevocationChecked = 1; } - const nodeAuxNonRev = getNodeAuxValue(this.claim.nonRevProof.proof); - s.issuerClaimNonRevMtpAuxHi = nodeAuxNonRev.key.bigInt().toString(); - s.issuerClaimNonRevMtpAuxHv = nodeAuxNonRev.value.bigInt().toString(); - s.issuerClaimNonRevMtpNoAux = nodeAuxNonRev.noAux; - - const nodeAuxIssuerAuthNonRev = getNodeAuxValue( - this.claim.signatureProof.issuerAuthNonRevProof.proof - ); - s.issuerAuthClaimNonRevMtpAuxHi = nodeAuxIssuerAuthNonRev.key.bigInt().toString(); - s.issuerAuthClaimNonRevMtpAuxHv = nodeAuxIssuerAuthNonRev.value.bigInt().toString(); - s.issuerAuthClaimNonRevMtpNoAux = nodeAuxIssuerAuthNonRev.noAux; + const nodeAuxNonRev = getNodeAuxValue(this.claim.nonRevProof?.proof); + s.issuerClaimNonRevMtpAuxHi = nodeAuxNonRev?.key.bigInt().toString(); + s.issuerClaimNonRevMtpAuxHv = nodeAuxNonRev?.value.bigInt().toString(); + s.issuerClaimNonRevMtpNoAux = nodeAuxNonRev?.noAux; + + const nodeAuxIssuerAuthNonRev = + this.claim.signatureProof && + getNodeAuxValue(this.claim.signatureProof.issuerAuthNonRevProof.proof); + s.issuerAuthClaimNonRevMtpAuxHi = nodeAuxIssuerAuthNonRev?.key.bigInt().toString(); + s.issuerAuthClaimNonRevMtpAuxHv = nodeAuxIssuerAuthNonRev?.value.bigInt().toString(); + s.issuerAuthClaimNonRevMtpNoAux = nodeAuxIssuerAuthNonRev?.noAux; s.claimPathNotExists = existenceToInt(valueProof.mtp.existence); const nodAuxJSONLD = getNodeAuxValue(valueProof.mtp); @@ -222,22 +225,22 @@ interface AtomicQuerySigV2CircuitInputs { * @extends {BaseConfig} */ export class AtomicQuerySigV2PubSignals extends BaseConfig { - requestID?: bigint; - userID?: Id; - issuerID?: Id; - issuerAuthState?: Hash; - issuerClaimNonRevState?: Hash; - claimSchema: SchemaHash; - slotIndex: number; - operator: number; + requestID!: bigint; + userID!: Id; + issuerID!: Id; + issuerAuthState!: Hash; + issuerClaimNonRevState!: Hash; + claimSchema!: SchemaHash; + slotIndex!: number; + operator!: number; value: bigint[] = []; - timestamp: number; - merklized: number; - claimPathKey?: bigint; + timestamp!: number; + merklized!: number; + claimPathKey!: bigint; // 0 for inclusion, 1 for non-inclusion - claimPathNotExists: number; + claimPathNotExists!: number; // 0 revocation not check, // 1 for check revocation - isRevocationChecked: number; + isRevocationChecked!: number; // /** diff --git a/src/circuits/auth-v2.ts b/src/circuits/auth-v2.ts index d9c23a6b..f6c13b86 100644 --- a/src/circuits/auth-v2.ts +++ b/src/circuits/auth-v2.ts @@ -15,15 +15,15 @@ import { byteDecoder, byteEncoder } from '../utils'; * @extends {BaseConfig} */ export class AuthV2Inputs extends BaseConfig { - genesisID?: Id; - profileNonce?: bigint; - authClaim?: Claim; - authClaimIncMtp: Proof; - authClaimNonRevMtp: Proof; - treeState: TreeState; - gistProof: GISTProof; - signature?: Signature; - challenge?: bigint; + genesisID!: Id; + profileNonce!: bigint; + authClaim!: Claim; + authClaimIncMtp!: Proof; + authClaimNonRevMtp!: Proof; + treeState!: TreeState; + gistProof!: GISTProof; + signature!: Signature; + challenge!: bigint; validate(): void { if (!this.genesisID) { @@ -38,7 +38,7 @@ export class AuthV2Inputs extends BaseConfig { throw new Error(CircuitError.EmptyAuthClaimNonRevProof); } - if (!this.gistProof?.proof) { + if (!this.gistProof.proof) { throw new Error(CircuitError.EmptyGISTProof); } @@ -62,15 +62,15 @@ export class AuthV2Inputs extends BaseConfig { authClaimIncMtp: prepareSiblingsStr(this.authClaimIncMtp, this.getMTLevel()), authClaimNonRevMtp: prepareSiblingsStr(this.authClaimNonRevMtp, this.getMTLevel()), challenge: this.challenge?.toString(), - challengeSignatureR8x: this.signature?.R8[0].toString(), - challengeSignatureR8y: this.signature?.R8[1].toString(), - challengeSignatureS: this.signature?.S.toString(), - claimsTreeRoot: this.treeState?.claimsRoot.bigInt().toString(), - revTreeRoot: this.treeState?.revocationRoot.bigInt().toString(), - rootsTreeRoot: this.treeState?.rootOfRoots.bigInt().toString(), - state: this.treeState?.state.bigInt().toString(), + challengeSignatureR8x: this.signature.R8[0].toString(), + challengeSignatureR8y: this.signature.R8[1].toString(), + challengeSignatureS: this.signature.S.toString(), + claimsTreeRoot: this.treeState.claimsRoot?.bigInt().toString(), + revTreeRoot: this.treeState.revocationRoot?.bigInt().toString(), + rootsTreeRoot: this.treeState.rootOfRoots?.bigInt().toString(), + state: this.treeState.state?.bigInt().toString(), gistRoot: this.gistProof.root.bigInt().toString(), - gistMtp: prepareSiblingsStr(this.gistProof.proof, this.getMTLevelOnChain()) + gistMtp: this.gistProof && prepareSiblingsStr(this.gistProof.proof, this.getMTLevelOnChain()) }; const nodeAuxAuth = getNodeAuxValue(this.authClaimNonRevMtp); @@ -120,10 +120,9 @@ interface AuthV2CircuitInputs { * @class AuthV2PubSignals */ export class AuthV2PubSignals { - userID: Id; - challenge: bigint; - GISTRoot: Hash; - // + userID!: Id; + challenge!: bigint; + GISTRoot!: Hash; /** * PubSignalsUnmarshal unmarshal auth.circom public inputs to AuthPubSignals diff --git a/src/circuits/common.ts b/src/circuits/common.ts index a045960c..45d8362d 100644 --- a/src/circuits/common.ts +++ b/src/circuits/common.ts @@ -27,10 +27,10 @@ export const ErrorEmptyIssuerAuthClaimNonRevProof = * @class BaseConfig */ export class BaseConfig { - mtLevel: number; // Max levels of MT - valueArraySize: number; // Size if( value array in identity circuit)s - mtLevelOnChain: number; - mtLevelClaimsMerklization: number; // max levels in the merklization + mtLevel!: number; // Max levels of MT + valueArraySize!: number; // Size if( value array in identity circuit)s + mtLevelOnChain!: number; + mtLevelClaimsMerklization!: number; // max levels in the merklization /** * getMTLevel max circuit MT levels @@ -221,11 +221,12 @@ export const existenceToInt = (b: boolean): number => (b ? 0 : 1); * @returns object */ export function getProperties(obj: object): object { - const result: object = {}; + const result: { [key: string]: unknown } = {}; + for (const property in obj) { // eslint-disable-next-line no-prototype-builtins if (obj.hasOwnProperty(property) && !property.startsWith('_')) { - result[property] = obj[property]; + result[property] = obj[property as keyof typeof obj]; } } return result; diff --git a/src/circuits/models.ts b/src/circuits/models.ts index be50d5fd..ee948d38 100644 --- a/src/circuits/models.ts +++ b/src/circuits/models.ts @@ -37,17 +37,17 @@ export interface ClaimNonRevStatus { * @class Query */ export class Query { - slotIndex: number; - values: bigint[]; - operator: number; - valueProof?: ValueProof; + slotIndex!: number; + values!: bigint[]; + operator!: number; + valueProof!: ValueProof; /** * Validates Query instance * */ validate(): void { - if (this.operator !== QueryOperators.$noop && this.values.some((v) => typeof v !== 'bigint')) + if (this.operator !== QueryOperators.$noop && this.values?.some((v) => typeof v !== 'bigint')) throw new Error(CircuitError.EmptyQueryValue); } } @@ -81,12 +81,12 @@ export enum CircuitId { * @class CircuitClaim */ export class CircuitClaim { - issuerId: Id; - claim: CoreClaim; - treeState: TreeState; - proof: Proof; - nonRevProof: ClaimNonRevStatus; // Claim non revocation proof - signatureProof: BJJSignatureProof; + issuerId!: Id; + claim!: CoreClaim; + treeState!: TreeState; + proof!: Proof; + nonRevProof!: ClaimNonRevStatus; // Claim non revocation proof + signatureProof!: BJJSignatureProof; } /** @@ -97,10 +97,10 @@ export class CircuitClaim { * @interface ClaimWithSigProof */ export interface ClaimWithSigProof { - issuerID: Id; - claim: Claim; - nonRevProof: MTProof; - signatureProof: BJJSignatureProof; + issuerID?: Id; + claim?: Claim; + nonRevProof?: MTProof; + signatureProof?: BJJSignatureProof; } /** @@ -112,9 +112,9 @@ export interface ClaimWithSigProof { */ export interface ClaimWithMTPProof { issuerID?: Id; - claim: Claim; - incProof: MTProof; - nonRevProof: MTProof; + claim?: Claim; + incProof?: MTProof; + nonRevProof?: MTProof; } /** @@ -139,7 +139,7 @@ export interface BJJSignatureProof { * @interface MTProof */ export interface MTProof { - proof: Proof; + proof?: Proof; treeState?: TreeState; } /** diff --git a/src/circuits/state-transition.ts b/src/circuits/state-transition.ts index 6c15faca..4cda3f17 100644 --- a/src/circuits/state-transition.ts +++ b/src/circuits/state-transition.ts @@ -15,16 +15,16 @@ import { byteDecoder, byteEncoder } from '../utils'; * @extends {BaseConfig} */ export class StateTransitionInputs extends BaseConfig { - id: Id; - oldTreeState: TreeState; - newTreeState: TreeState; + id!: Id; + oldTreeState!: TreeState; + newTreeState!: TreeState; - isOldStateGenesis: boolean; - authClaim: ClaimWithMTPProof; + isOldStateGenesis!: boolean; + authClaim!: ClaimWithMTPProof; - authClaimNewStateIncProof: Proof; + authClaimNewStateIncProof!: Proof; - signature: Signature; + signature!: Signature; /** * CircuitInputMarshal returns Circom private inputs for stateTransition.circom @@ -32,7 +32,7 @@ export class StateTransitionInputs extends BaseConfig { * @returns Uint8Array */ inputsMarshal(): Uint8Array { - if (!this.authClaim.incProof.proof) { + if (!this.authClaim?.incProof?.proof) { throw new Error(CircuitError.EmptyAuthClaimProof); } @@ -40,27 +40,27 @@ export class StateTransitionInputs extends BaseConfig { throw new Error(CircuitError.EmptyAuthClaimProofInTheNewState); } - if (!this.authClaim.nonRevProof.proof) { + if (!this.authClaim.nonRevProof?.proof) { throw new Error(CircuitError.EmptyAuthClaimNonRevProof); } const s: Partial = { - authClaim: this.authClaim.claim.marshalJson(), + authClaim: this.authClaim?.claim?.marshalJson(), authClaimMtp: prepareSiblingsStr(this.authClaim.incProof.proof, this.getMTLevel()), authClaimNonRevMtp: prepareSiblingsStr(this.authClaim.nonRevProof.proof, this.getMTLevel()), newAuthClaimMtp: prepareSiblingsStr(this.authClaimNewStateIncProof, this.getMTLevel()), - userID: this.id.bigInt().toString(), - newUserState: this.newTreeState.state.bigInt().toString(), - claimsTreeRoot: this.oldTreeState.claimsRoot.bigInt().toString(), - oldUserState: this.oldTreeState.state.bigInt().toString(), - revTreeRoot: this.oldTreeState.revocationRoot.bigInt().toString(), - rootsTreeRoot: this.oldTreeState.rootOfRoots.bigInt().toString(), + userID: this.id?.bigInt().toString(), + newUserState: this.newTreeState?.state?.bigInt().toString(), + claimsTreeRoot: this.oldTreeState?.claimsRoot?.bigInt().toString(), + oldUserState: this.oldTreeState?.state?.bigInt().toString(), + revTreeRoot: this.oldTreeState?.revocationRoot?.bigInt().toString(), + rootsTreeRoot: this.oldTreeState?.rootOfRoots?.bigInt().toString(), signatureR8x: this.signature.R8[0].toString(), signatureR8y: this.signature.R8[1].toString(), signatureS: this.signature.S.toString(), - newClaimsTreeRoot: this.newTreeState.claimsRoot.bigInt().toString(), - newRootsTreeRoot: this.newTreeState.rootOfRoots.bigInt().toString(), - newRevTreeRoot: this.newTreeState.revocationRoot.bigInt().toString() + newClaimsTreeRoot: this.newTreeState?.claimsRoot?.bigInt().toString(), + newRootsTreeRoot: this.newTreeState?.rootOfRoots?.bigInt().toString(), + newRevTreeRoot: this.newTreeState?.revocationRoot?.bigInt().toString() }; if (this.isOldStateGenesis) { @@ -109,10 +109,10 @@ interface StateTransitionInputsInternal { * @class StateTransitionPubSignals */ export class StateTransitionPubSignals { - userId: Id; - oldUserState: Hash; - newUserState: Hash; - isOldStateGenesis: boolean; + userId!: Id; + oldUserState!: Hash; + newUserState!: Hash; + isOldStateGenesis!: boolean; /** * diff --git a/src/credentials/credential-wallet.ts b/src/credentials/credential-wallet.ts index b7166a56..93781205 100644 --- a/src/credentials/credential-wallet.ts +++ b/src/credentials/credential-wallet.ts @@ -280,7 +280,7 @@ export class CredentialWallet implements ICredentialWallet { issuerDID: DID, issuerData: IssuerData ): Promise { - const statusResolver = this._credentialStatusResolverRegistry.get(credStatus.type); + const statusResolver = this._credentialStatusResolverRegistry?.get(credStatus.type); if (!statusResolver) { throw new Error(`credential status resolver does not exist for ${credStatus.type} type`); } diff --git a/src/credentials/status/on-chain-revocation.ts b/src/credentials/status/on-chain-revocation.ts index b92e3de3..d79de30d 100644 --- a/src/credentials/status/on-chain-revocation.ts +++ b/src/credentials/status/on-chain-revocation.ts @@ -78,9 +78,8 @@ export class OnChainResolver implements CredentialStatusResolver { } // TODO (illia-korotia): after merging core v2 need to parse contract address from did if `contractAddress` is not present in id as param const contractId = url.searchParams.get('contractAddress'); - const revocationNonce = parseInt(url.searchParams.get('revocationNonce'), 10); - - const parts = contractId.split(':'); + const revocationNonce = parseInt(url.searchParams.get('revocationNonce')!, 10); + const parts = contractId!.split(':'); if (parts.length != 2) { throw new Error('invalid contract address'); } diff --git a/src/credentials/status/resolver.ts b/src/credentials/status/resolver.ts index ea88627f..2885e5ff 100644 --- a/src/credentials/status/resolver.ts +++ b/src/credentials/status/resolver.ts @@ -11,7 +11,7 @@ export class CredentialStatusResolverRegistry { this.resolvers.set(type, resolver); } - get(type: CredentialStatusType): CredentialStatusResolver { + get(type: CredentialStatusType): CredentialStatusResolver | undefined { return this.resolvers.get(type); } } diff --git a/src/credentials/status/reverse-sparse-merkle-tree.ts b/src/credentials/status/reverse-sparse-merkle-tree.ts index 115b9500..865826eb 100644 --- a/src/credentials/status/reverse-sparse-merkle-tree.ts +++ b/src/credentials/status/reverse-sparse-merkle-tree.ts @@ -130,8 +130,8 @@ export class RHSResolver implements CredentialStatusResolver { ): Promise { try { return await this.getStatus(credentialStatus, opts); - } catch (e) { - const errMsg = e.reason ?? e.message; + } catch (e: unknown) { + const errMsg = (e as { reason: string })?.reason ?? (e as Error).message ?? (e as string); if ( !!opts.issuerData && errMsg.includes(VerifiableConstants.ERRORS.IDENTITY_DOES_NOT_EXIST) && diff --git a/src/credentials/status/sparse-merkle-tree.ts b/src/credentials/status/sparse-merkle-tree.ts index 530b37c5..8bd8ca62 100644 --- a/src/credentials/status/sparse-merkle-tree.ts +++ b/src/credentials/status/sparse-merkle-tree.ts @@ -1,11 +1,12 @@ import { CredentialStatus, RevocationStatus, Issuer } from '../../verifiable'; import { CredentialStatusResolver } from './resolver'; -import { newHashFromBigInt, Proof, NodeAux, setBitBigEndian } from '@iden3/js-merkletree'; +import { newHashFromBigInt, Proof, setBitBigEndian } from '@iden3/js-merkletree'; export class IssuerResolver implements CredentialStatusResolver { async resolve(credentialStatus: CredentialStatus): Promise { - const revStatusDTO = await (await fetch(credentialStatus.id)).json(); - return Object.assign(new RevocationStatusDTO(), revStatusDTO).toRevocationStatus(); + const revStatusResp = await fetch(credentialStatus.id); + const revStatus = await revStatusResp.json(); + return new RevocationStatusDTO(revStatus).toRevocationStatus(); } } @@ -13,9 +14,9 @@ export class IssuerResolver implements CredentialStatusResolver { * Proof dto as a partial result of fetching credential status with type SparseMerkleTreeProof * * @export - * @class ProofDTO + * @interface ProofDTO */ -export class ProofDTO { +export interface ProofDTO { existence: boolean; siblings: string[]; node_aux: { @@ -32,18 +33,20 @@ export class ProofDTO { * @class RevocationStatusDTO */ export class RevocationStatusDTO { - issuer: Issuer; - mtp: ProofDTO; + issuer!: Issuer; + mtp!: ProofDTO; + + constructor(payload: object) { + Object.assign(this, payload); + } toRevocationStatus(): RevocationStatus { const p = new Proof(); p.existence = this.mtp.existence; - p.nodeAux = this.mtp.node_aux - ? ({ - key: newHashFromBigInt(BigInt(this.mtp.node_aux.key)), - value: newHashFromBigInt(BigInt(this.mtp.node_aux.value)) - } as NodeAux) - : undefined; + p.nodeAux = { + key: newHashFromBigInt(BigInt(this.mtp.node_aux.key)), + value: newHashFromBigInt(BigInt(this.mtp.node_aux.value)) + }; const s = this.mtp.siblings.map((s) => newHashFromBigInt(BigInt(s))); diff --git a/src/iden3comm/constants.ts b/src/iden3comm/constants.ts index 43ee3699..379e1007 100644 --- a/src/iden3comm/constants.ts +++ b/src/iden3comm/constants.ts @@ -41,11 +41,6 @@ export enum MediaType { SignedMessage = 'application/iden3comm-signed-json' } -/** - * Universal resolver url - */ -export const UNIVERSAL_RESOLVER_URL = 'https://dev.uniresolver.io/1.0/identifiers'; - export const SUPPORTED_PUBLIC_KEY_TYPES = { ES256K: [ 'EcdsaSecp256k1VerificationKey2019', diff --git a/src/iden3comm/errors.ts b/src/iden3comm/errors.ts index d3c54e53..074be88a 100644 --- a/src/iden3comm/errors.ts +++ b/src/iden3comm/errors.ts @@ -11,3 +11,4 @@ export const ErrSenderNotUsedTokenCreation = 'sender of message is not used for export const ErrPackedWithUnsupportedCircuit = 'message was packed with unsupported circuit'; export const ErrProofIsInvalid = 'message proof is invalid'; export const ErrStateVerificationFailed = 'message state verification failed'; +export const ErrNoProvingMethodAlg = 'unknown proving method algorithm'; diff --git a/src/iden3comm/handlers/auth.ts b/src/iden3comm/handlers/auth.ts index 541b58bc..dfdf5002 100644 --- a/src/iden3comm/handlers/auth.ts +++ b/src/iden3comm/handlers/auth.ts @@ -246,14 +246,14 @@ export class AuthHandler implements IAuthHandler { type: PROTOCOL_MESSAGE_TYPE.AUTHORIZATION_RESPONSE_MESSAGE_TYPE, thid: authRequest.thid ?? guid, body: { - message: authRequest.body.message, + message: authRequest?.body?.message, scope: [] }, from: userGenesisDID.string(), to: authRequest.from }; - for (const r of zkpRequestsWithCreds) { + for (const r of zkpRequestsWithCreds || []) { const zkpRes: ZeroKnowledgeProofResponse = await this._proofService.generateProof( r.req, userGenesisDID, diff --git a/src/iden3comm/handlers/fetch.ts b/src/iden3comm/handlers/fetch.ts index c2ee471a..a39fb19b 100644 --- a/src/iden3comm/handlers/fetch.ts +++ b/src/iden3comm/handlers/fetch.ts @@ -97,8 +97,8 @@ export class FetchHandler implements IFetchHandler { } const credentials: W3CCredential[] = []; - for (let index = 0; index < offerMessage.body.credentials.length; index++) { - const credentialInfo = offerMessage.body.credentials[index]; + for (let index = 0; index < (offerMessage?.body?.credentials?.length ?? 0); index++) { + const credentialInfo = offerMessage?.body?.credentials[index]; const guid = uuid.v4(); const fetchRequest: MessageFetchRequestMessage = { @@ -107,7 +107,7 @@ export class FetchHandler implements IFetchHandler { type: PROTOCOL_MESSAGE_TYPE.CREDENTIAL_FETCH_REQUEST_MESSAGE_TYPE, thid: offerMessage.thid ?? guid, body: { - id: credentialInfo.id + id: credentialInfo?.id || '' }, from: did.string(), to: offerMessage.from @@ -119,6 +119,9 @@ export class FetchHandler implements IFetchHandler { ); let message: { body: { credential: W3CCredential } }; try { + if (!offerMessage?.body?.url) { + throw new Error(`could not fetch W3C credential, body url is missing`); + } const resp = await fetch(offerMessage.body.url, { method: 'post', headers: { @@ -127,13 +130,15 @@ export class FetchHandler implements IFetchHandler { body: token }); if (resp.status !== 200) { - throw new Error(`could not fetch W3C credential, ${credentialInfo.id}`); + throw new Error(`could not fetch W3C credential, ${credentialInfo?.id}`); } message = await resp.json(); credentials.push(message.body.credential); - } catch (e) { + } catch (e: unknown) { throw new Error( - `could not fetch W3C credential, ${credentialInfo.id}, error: ${e.message ?? e}` + `could not fetch W3C credential, ${credentialInfo?.id}, error: ${ + (e as Error).message ?? e + }` ); } } diff --git a/src/iden3comm/packers/jws.ts b/src/iden3comm/packers/jws.ts index 2835415d..965ee266 100644 --- a/src/iden3comm/packers/jws.ts +++ b/src/iden3comm/packers/jws.ts @@ -1,10 +1,6 @@ import { BasicMessage, IPacker, PackerParams } from '../types'; import { MediaType, SUPPORTED_PUBLIC_KEY_TYPES } from '../constants'; -import { - extractPublicKeyBytes, - resolveVerificationMethods, - resolveDIDDocument -} from '../utils/did'; +import { extractPublicKeyBytes, resolveVerificationMethods } from '../utils/did'; import { keyPath, KMS } from '../../kms/'; import { Signer, verifyJWS } from 'did-jwt'; @@ -31,13 +27,10 @@ export class JWSPacker implements IPacker { * Creates an instance of JWSPacker. * * @param {KMS} _kms - * @param {Resolvable} [_documentResolver={ resolve: resolveDIDDocument }] + * @param {Resolvable} _documentResolver * @memberof JWSPacker */ - constructor( - private readonly _kms: KMS, - private readonly _documentResolver: Resolvable = { resolve: resolveDIDDocument } - ) {} + constructor(private readonly _kms: KMS, private readonly _documentResolver: Resolvable) {} /** * creates JSON Web Signature token * @@ -64,7 +57,8 @@ export class JWSPacker implements IPacker { throw new Error('Missing sender DID'); } - const vmTypes: string[] = SUPPORTED_PUBLIC_KEY_TYPES[params.alg]; + const vmTypes: string[] = + SUPPORTED_PUBLIC_KEY_TYPES[params.alg as keyof typeof SUPPORTED_PUBLIC_KEY_TYPES]; if (!vmTypes?.length) { throw new Error(`No supported verification methods for algorithm ${params.alg}`); } diff --git a/src/iden3comm/packers/zkp.ts b/src/iden3comm/packers/zkp.ts index adf78800..e3cde6cc 100644 --- a/src/iden3comm/packers/zkp.ts +++ b/src/iden3comm/packers/zkp.ts @@ -12,6 +12,7 @@ import { AuthV2PubSignals, CircuitId } from '../../circuits/index'; import { DID, Id } from '@iden3/js-iden3-core'; import { bytesToProtocolMessage } from '../utils/envelope'; import { + ErrNoProvingMethodAlg, ErrPackedWithUnsupportedCircuit, ErrProofIsInvalid, ErrSenderNotUsedTokenCreation, @@ -110,19 +111,26 @@ export class ZKPPacker implements IPacker { */ async pack(payload: Uint8Array, params: ZKPPackerParams): Promise { const provingMethod = await getProvingMethod(params.provingMethodAlg); - const { provingKey, wasm, dataPreparer } = this.provingParamsMap.get( - params.provingMethodAlg.toString() - ); + const provingParams = this.provingParamsMap.get(params.provingMethodAlg.toString()); + + if (!provingParams) { + throw new Error(ErrNoProvingMethodAlg); + } const token = new Token( provingMethod, byteDecoder.decode(payload), - (hash: Uint8Array, circuitID: CircuitId) => { - return dataPreparer.prepare(hash, params.senderDID, params.profileNonce, circuitID); + (hash: Uint8Array, circuitId: string) => { + return provingParams?.dataPreparer?.prepare( + hash, + params.senderDID, + params.profileNonce, + circuitId as CircuitId + ); } ); token.setHeader(Header.Type, MediaType.ZKPMessage); - const tokenStr = await token.prove(provingKey, wasm); + const tokenStr = await token.prove(provingParams.provingKey, provingParams.wasm); return byteEncoder.encode(tokenStr); } @@ -135,18 +143,16 @@ export class ZKPPacker implements IPacker { async unpack(envelope: Uint8Array): Promise { const token = await Token.parse(byteDecoder.decode(envelope)); const provingMethodAlg = new ProvingMethodAlg(token.alg, token.circuitId); - const { key: verificationKey, verificationFn } = this.verificationParamsMap.get( - provingMethodAlg.toString() - ); - if (!verificationKey) { + const verificationParams = this.verificationParamsMap.get(provingMethodAlg.toString()); + if (!verificationParams?.key) { throw new Error(ErrPackedWithUnsupportedCircuit); } - const isValid = await token.verify(verificationKey); + const isValid = await token.verify(verificationParams?.key); if (!isValid) { throw new Error(ErrProofIsInvalid); } - const verificationResult = await verificationFn.verify( + const verificationResult = await verificationParams?.verificationFn?.verify( token.circuitId, token.zkProof.pub_signals ); @@ -170,7 +176,7 @@ export class ZKPPacker implements IPacker { const verifySender = (token: Token, msg: BasicMessage): void => { switch (token.circuitId) { case CircuitId.AuthV2: - if (!verifyAuthV2Sender(msg.from, token.zkProof.pub_signals)) { + if (!msg.from || !verifyAuthV2Sender(msg.from, token.zkProof.pub_signals)) { throw new Error(ErrSenderNotUsedTokenCreation); } break; @@ -183,7 +189,7 @@ const verifyAuthV2Sender = (from: string, pubSignals: Array): boolean => const authSignals = new AuthV2PubSignals(); const pubSig = authSignals.pubSignalsUnmarshal(byteEncoder.encode(JSON.stringify(pubSignals))); - return checkSender(from, pubSig.userID); + return pubSig.userID ? checkSender(from, pubSig.userID) : false; }; const checkSender = (from: string, id: Id): boolean => { diff --git a/src/iden3comm/utils/did.ts b/src/iden3comm/utils/did.ts index 58991286..242b6572 100644 --- a/src/iden3comm/utils/did.ts +++ b/src/iden3comm/utils/did.ts @@ -1,29 +1,10 @@ -import { SUPPORTED_PUBLIC_KEY_TYPES, UNIVERSAL_RESOLVER_URL } from '../constants'; +import { SUPPORTED_PUBLIC_KEY_TYPES } from '../constants'; import elliptic from 'elliptic'; -import { - DIDDocument, - DIDResolutionOptions, - DIDResolutionResult, - VerificationMethod -} from 'did-resolver'; +import { DIDDocument, VerificationMethod } from 'did-resolver'; import { KmsKeyType } from '../../kms'; import { base58ToBytes, base64ToBytes, bytesToHex, hexToBytes } from '../../utils'; -export const resolveDIDDocument = async ( - didUrl: string, - // eslint-disable-next-line @typescript-eslint/no-unused-vars - options?: DIDResolutionOptions -): Promise => { - try { - const response = await fetch(`${UNIVERSAL_RESOLVER_URL}/${didUrl}`); - const data = await response.json(); - return data as DIDResolutionResult; - } catch (error) { - throw new Error(`Can't resolve did document: ${error.message}`); - } -}; - const DIDAuthenticationSection = 'authentication'; export const resolveVerificationMethods = (didDocument: DIDDocument): VerificationMethod[] => { const vms: VerificationMethod[] = didDocument.verificationMethod || []; @@ -52,9 +33,9 @@ const secp256k1 = new elliptic.ec('secp256k1'); export const extractPublicKeyBytes = ( vm: VerificationMethod -): { publicKeyBytes: Uint8Array; kmsKeyType?: KmsKeyType } => { +): { publicKeyBytes: Uint8Array | null; kmsKeyType?: KmsKeyType } => { const isSupportedVmType = Object.keys(SUPPORTED_PUBLIC_KEY_TYPES).some((key) => - SUPPORTED_PUBLIC_KEY_TYPES[key].includes(vm.type) + SUPPORTED_PUBLIC_KEY_TYPES[key as keyof typeof SUPPORTED_PUBLIC_KEY_TYPES].includes(vm.type) ); if (vm.publicKeyBase58 && isSupportedVmType) { return { publicKeyBytes: base58ToBytes(vm.publicKeyBase58), kmsKeyType: KmsKeyType.Secp256k1 }; diff --git a/src/identity/common.ts b/src/identity/common.ts index 5a4ab51b..0cbc9f9b 100644 --- a/src/identity/common.ts +++ b/src/identity/common.ts @@ -30,7 +30,7 @@ export const defineMerklizedRootPosition = ( metadata?: SchemaMetadata, position?: MerklizedRootPosition ): MerklizedRootPosition => { - if (!metadata && !metadata.serialization) { + if (!metadata?.serialization) { return MerklizedRootPosition.None; } diff --git a/src/identity/identity-wallet.ts b/src/identity/identity-wallet.ts index 07418649..fa5cb5ef 100644 --- a/src/identity/identity-wallet.ts +++ b/src/identity/identity-wallet.ts @@ -281,9 +281,11 @@ export class IdentityWallet implements IIdentityWallet { opts.seed = opts.seed ?? getRandomBytes(32); - const keyID = await this._kms.createKeyFromSeed(KmsKeyType.BabyJubJub, opts.seed); + const keyId = await this._kms.createKeyFromSeed(KmsKeyType.BabyJubJub, opts.seed); - const pubKey = (await this._kms.publicKey(keyID)) as PublicKey; + const pubKeyHex = await this._kms.publicKey(keyId); + + const pubKey = PublicKey.newFromHex(pubKeyHex); const schemaHash = SchemaHash.authSchemaHash; @@ -617,9 +619,11 @@ export class IdentityWallet implements IIdentityWallet { if (!issuerAuthBJJCredential.proof) { throw new Error('issuer auth credential must have proof'); } - const mtpAuthBJJProof = issuerAuthBJJCredential.proof[0] as Iden3SparseMerkleTreeProof; + const mtpAuthBJJProof = ( + issuerAuthBJJCredential.proof as unknown[] + )[0] as Iden3SparseMerkleTreeProof; - const sigProof: BJJSignatureProof2021 = { + const sigProof = new BJJSignatureProof2021({ type: ProofType.BJJSignature, issuerData: new IssuerData({ id: issuerDID.string(), @@ -630,7 +634,7 @@ export class IdentityWallet implements IIdentityWallet { }), coreClaim: coreClaim.hex(), signature: Hex.encodeString(signature) - }; + }); credential.proof = [sigProof]; return credential; diff --git a/src/kms/key-providers/bjj-provider.ts b/src/kms/key-providers/bjj-provider.ts index 06c28395..8f6e272d 100644 --- a/src/kms/key-providers/bjj-provider.ts +++ b/src/kms/key-providers/bjj-provider.ts @@ -1,4 +1,4 @@ -import { Hex, PrivateKey, PublicKey } from '@iden3/js-crypto'; +import { Hex, PrivateKey } from '@iden3/js-crypto'; import { BytesHelper, checkBigIntInField } from '@iden3/js-iden3-core'; import { IKeyProvider } from '../kms'; import { AbstractPrivateKeyStore, KmsKeyId, KmsKeyType } from '../store'; @@ -56,9 +56,9 @@ export class BjjProvider implements IKeyProvider { * * @param {KmsKeyId} keyId - key identifier */ - async publicKey(keyId: KmsKeyId): Promise { + async publicKey(keyId: KmsKeyId): Promise { const privateKey: PrivateKey = await this.privateKey(keyId); - return privateKey.public(); + return privateKey.public().hex(); } /** diff --git a/src/kms/key-providers/sec256k1-provider.ts b/src/kms/key-providers/sec256k1-provider.ts index 7a5d4d20..0767b8fc 100644 --- a/src/kms/key-providers/sec256k1-provider.ts +++ b/src/kms/key-providers/sec256k1-provider.ts @@ -2,7 +2,6 @@ import { IKeyProvider } from '../kms'; import { AbstractPrivateKeyStore, KmsKeyId, KmsKeyType } from '../store'; import Elliptic from 'elliptic'; import * as providerHelpers from '../provider-helpers'; -import { PublicKey } from '@iden3/js-crypto'; import { ES256KSigner } from 'did-jwt'; import { base64ToBytes, byteEncoder, bytesToHex, hexToBytes } from '../../utils'; @@ -42,7 +41,7 @@ export class Sec256k1Provider implements IKeyProvider { const keyPair = this._ec.genKeyPair(); const kmsId = { type: this.keyType, - id: providerHelpers.keyPath(this.keyType, keyPair.getPublic().encode('hex')) + id: providerHelpers.keyPath(this.keyType, keyPair.getPublic().encode('hex', false)) }; await this._keyStore.importKey({ alias: kmsId.id, key: keyPair.getPrivate().toString('hex') }); @@ -54,9 +53,9 @@ export class Sec256k1Provider implements IKeyProvider { * * @param {KmsKeyId} keyId - key identifier */ - async publicKey(keyId: KmsKeyId): Promise { + async publicKey(keyId: KmsKeyId): Promise { const privateKeyHex = await this.privateKey(keyId); - return this._ec.keyFromPrivate(privateKeyHex, 'hex').getPublic().encode('hex'); + return this._ec.keyFromPrivate(privateKeyHex, 'hex').getPublic().encode('hex', false); } /** diff --git a/src/kms/kms.ts b/src/kms/kms.ts index dba870d3..2a858152 100644 --- a/src/kms/kms.ts +++ b/src/kms/kms.ts @@ -1,4 +1,3 @@ -import { PublicKey } from '@iden3/js-crypto'; import { KmsKeyId, KmsKeyType } from './store'; /** @@ -21,7 +20,7 @@ export interface IKeyProvider { * @param {KmsKeyId} keyID - kms key identifier * @returns `Promise` */ - publicKey(keyID: KmsKeyId): Promise; + publicKey(keyID: KmsKeyId): Promise; /** * sign data with kms key * @@ -49,12 +48,7 @@ export interface IKeyProvider { * @class KMS - class */ export class KMS { - private registry: { - [keyType in KmsKeyType]: IKeyProvider; - } = { - BJJ: null, - Secp256k1: null - }; + private readonly _registry = new Map(); /** * register key provider in the KMS @@ -63,10 +57,10 @@ export class KMS { * @param {IKeyProvider} keyProvider - key provider implementation */ registerKeyProvider(keyType: KmsKeyType, keyProvider: IKeyProvider): void { - if (this.registry[keyType]) { + if (this._registry.get(keyType)) { throw new Error('present keyType'); } - this.registry[keyType] = keyProvider; + this._registry.set(keyType, keyProvider); } /** @@ -77,7 +71,7 @@ export class KMS { * @returns kms key id */ async createKeyFromSeed(keyType: KmsKeyType, bytes: Uint8Array): Promise { - const keyProvider = this.registry[keyType]; + const keyProvider = this._registry.get(keyType); if (!keyProvider) { throw new Error(`keyProvider not found for: ${keyType}`); } @@ -90,8 +84,8 @@ export class KMS { * @param {KmsKeyId} keyId -- key id * @returns public key */ - async publicKey(keyId: KmsKeyId): Promise { - const keyProvider = this.registry[keyId.type]; + async publicKey(keyId: KmsKeyId): Promise { + const keyProvider = this._registry.get(keyId.type); if (!keyProvider) { throw new Error(`keyProvider not found for: ${keyId.type}`); } @@ -113,7 +107,7 @@ export class KMS { [key: string]: unknown; } ): Promise { - const keyProvider = this.registry[keyId.type]; + const keyProvider = this._registry.get(keyId.type); if (!keyProvider) { throw new Error(`keyProvider not found for: ${keyId.type}`); } diff --git a/src/kms/store/local-storage-key-store.ts b/src/kms/store/local-storage-key-store.ts index 892cde26..a353bb04 100644 --- a/src/kms/store/local-storage-key-store.ts +++ b/src/kms/store/local-storage-key-store.ts @@ -1,4 +1,5 @@ import { AbstractPrivateKeyStore } from './abstract-key-store'; +import { KmsKeyId } from './types'; /** * Allows storing keys in the local storage of the browser @@ -23,7 +24,7 @@ export class LocalStoragePrivateKeyStore implements AbstractPrivateKeyStore { throw new Error('no key under given alias'); } const data = JSON.parse(dataStr); - const privateKey = data.find((d) => d.id === args.alias); + const privateKey = data.find((d: KmsKeyId) => d.id === args.alias); if (!privateKey) { throw new Error('no key under given alias'); } @@ -43,7 +44,7 @@ export class LocalStoragePrivateKeyStore implements AbstractPrivateKeyStore { data = JSON.parse(dataStr); } - const index = data.findIndex((d) => d.id === args.alias); + const index = data.findIndex((d: KmsKeyId) => d.id === args.alias); if (index > -1) { data[index].value = args.key; } else { diff --git a/src/proof/common.ts b/src/proof/common.ts index 22f41a54..f921b7a2 100644 --- a/src/proof/common.ts +++ b/src/proof/common.ts @@ -21,7 +21,7 @@ export const toClaimNonRevStatus = (s: RevocationStatus): ClaimNonRevStatus => { }; }; -const newProofFromData = (existence: boolean, allSiblings: Hash[], nodeAux: NodeAux): Proof => { +const newProofFromData = (existence: boolean, allSiblings: Hash[], nodeAux?: NodeAux): Proof => { const p = new Proof(); p.existence = existence; p.nodeAux = nodeAux; @@ -46,7 +46,7 @@ const newProofFromData = (existence: boolean, allSiblings: Hash[], nodeAux: Node */ export const toGISTProof = (smtProof: StateProof): GISTProof => { let existence = false; - let nodeAux: NodeAux; + let nodeAux: NodeAux | undefined; if (smtProof.existence) { existence = true; diff --git a/src/proof/proof-service.ts b/src/proof/proof-service.ts index 88e067b5..5dcf1a89 100644 --- a/src/proof/proof-service.ts +++ b/src/proof/proof-service.ts @@ -1,4 +1,3 @@ -/* eslint-disable no-console */ import { Hex, Poseidon, Signature } from '@iden3/js-crypto'; import { BytesHelper, @@ -405,24 +404,26 @@ export class ProofService implements IProofService { const gistProof = toGISTProof(stateProof); circuitInputs.gistProof = gistProof; - circuitInputs.treeState = { - state: authClaimData.treeState.state, - claimsRoot: authClaimData.treeState.claimsRoot, - revocationRoot: authClaimData.treeState.revocationRoot, - rootOfRoots: authClaimData.treeState.rootOfRoots - }; + if (authClaimData?.treeState) { + circuitInputs.treeState = { + state: authClaimData?.treeState?.state, + claimsRoot: authClaimData?.treeState?.claimsRoot, + revocationRoot: authClaimData?.treeState?.revocationRoot, + rootOfRoots: authClaimData?.treeState?.rootOfRoots + }; + } circuitInputs.authClaim = authClaimData.claim; circuitInputs.authClaimIncMtp = authClaimData.proof; circuitInputs.authClaimNonRevMtp = authPrepared.nonRevProof.proof; - + const challenge = opts.challenge!; const signature = await this._identityWallet.signChallenge( - opts.challenge ?? BigInt(proofReq.id), + challenge, authPrepared.authCredential ); circuitInputs.signature = signature; - circuitInputs.challenge = opts.challenge; + circuitInputs.challenge = challenge; const { query, vp } = await this.toCircuitsQuery( proofReq.query, @@ -461,7 +462,7 @@ export class ProofService implements IProofService { const circuitInputs = new AtomicQuerySigV2Inputs(); circuitInputs.id = DID.idFromDID(identifier); circuitInputs.claim = { - issuerID: circuitClaimData.issuerId, + issuerID: circuitClaimData?.issuerId, signatureProof: circuitClaimData.signatureProof, claim: circuitClaimData.claim, nonRevProof: circuitClaimData.nonRevProof @@ -522,12 +523,14 @@ export class ProofService implements IProofService { circuitInputs.query = query; circuitInputs.currentTimeStamp = getUnixTimestamp(new Date()); - circuitInputs.treeState = { - state: authClaimData.treeState.state, - claimsRoot: authClaimData.treeState.claimsRoot, - revocationRoot: authClaimData.treeState.revocationRoot, - rootOfRoots: authClaimData.treeState.rootOfRoots - }; + if (authClaimData.treeState) { + circuitInputs.treeState = { + state: authClaimData.treeState?.state, + claimsRoot: authClaimData.treeState?.claimsRoot, + revocationRoot: authClaimData.treeState?.revocationRoot, + rootOfRoots: authClaimData.treeState?.rootOfRoots + }; + } const stateProof = await this._stateStorage.getGISTProof(id.bigInt()); const gistProof = toGISTProof(stateProof); @@ -537,13 +540,14 @@ export class ProofService implements IProofService { circuitInputs.authClaimIncMtp = authClaimData.proof; circuitInputs.authClaimNonRevMtp = authPrepared.nonRevProof.proof; + const challenge = opts.challenge!; const signature = await this._identityWallet.signChallenge( - opts.challenge ?? BigInt(proofReq.id), + challenge, authPrepared.authCredential ); circuitInputs.signature = signature; - circuitInputs.challenge = opts.challenge; + circuitInputs.challenge = challenge; return { inputs: circuitInputs.inputsMarshal(), vp }; } @@ -576,21 +580,25 @@ export class ProofService implements IProofService { const signature = await bJJSignatureFromHexString(sigProof.signature); const issuer = DID.parse(sigProof.issuerData.id); - const rs: RevocationStatus = await this._credentialWallet.getRevocationStatus( - sigProof.issuerData.credentialStatus, - issuer, - sigProof.issuerData - ); + let rs: RevocationStatus | undefined; + + if (sigProof.issuerData.credentialStatus) { + rs = await this._credentialWallet.getRevocationStatus( + sigProof.issuerData.credentialStatus, + issuer, + sigProof.issuerData + ); + } //todo: check if this is correct const issuerAuthNonRevProof: MTProof = { treeState: { - state: strMTHex(rs.issuer.state), - claimsRoot: strMTHex(rs.issuer.claimsTreeRoot), - revocationRoot: strMTHex(rs.issuer.revocationTreeRoot), - rootOfRoots: strMTHex(rs.issuer.rootOfRoots) + state: strMTHex(rs?.issuer.state), + claimsRoot: strMTHex(rs?.issuer.claimsTreeRoot), + revocationRoot: strMTHex(rs?.issuer.revocationTreeRoot), + rootOfRoots: strMTHex(rs?.issuer.rootOfRoots) }, - proof: rs.mtp + proof: rs?.mtp }; if (!sigProof.issuerData.mtp) { throw new Error('issuer auth credential must have a mtp proof'); @@ -667,8 +675,10 @@ export class ProofService implements IProofService { parsedQuery.query.valueProof.mtp = proof; parsedQuery.query.valueProof.path = pathKey; parsedQuery.query.valueProof.mtp = proof; - const mtEntry = await mtValue.mtEntry(); - parsedQuery.query.valueProof.value = mtEntry; + const mtEntry = await mtValue?.mtEntry(); + if (mtEntry) { + parsedQuery.query.valueProof.value = mtEntry; + } if (merklizedPosition == MerklizedRootPosition.Index) { parsedQuery.query.slotIndex = 2; // value data slot a @@ -678,20 +688,20 @@ export class ProofService implements IProofService { if (!parsedQuery.fieldName) { const resultQuery = parsedQuery.query; resultQuery.operator = QueryOperators.$eq; - resultQuery.values = [mtEntry]; + resultQuery.values = [mtEntry!]; return { query: resultQuery }; } if (parsedQuery.isSelectiveDisclosure) { const rawValue = mk.rawValue(path); const vp = createVerifiablePresentation( - query.context, - query.type, + query.context ?? '', + query.type ?? '', parsedQuery.fieldName, rawValue ); const resultQuery = parsedQuery.query; resultQuery.operator = QueryOperators.$eq; - resultQuery.values = [mtEntry]; + resultQuery.values = [mtEntry!]; return { query: resultQuery, vp }; } if (parsedQuery.rawValue === null || parsedQuery.rawValue === undefined) { @@ -768,7 +778,7 @@ export class ProofService implements IProofService { const [fieldName, fieldReq] = entries[0]; - const fieldReqEntries = Object.entries(fieldReq); + const fieldReqEntries = Object.entries(fieldReq as { [key: string]: unknown }); if (fieldReqEntries.length > 1) { throw new Error(`multiple predicates for one field not supported`); @@ -783,10 +793,10 @@ export class ProofService implements IProofService { let operator = 0; const [key, value] = fieldReqEntries[0]; - if (!QueryOperators[key]) { + if (!QueryOperators[key as keyof typeof QueryOperators]) { throw new Error(`operator is not supported by lib`); } - operator = QueryOperators[key]; + operator = QueryOperators[key as keyof typeof QueryOperators]; query.operator = operator; diff --git a/src/proof/prover.ts b/src/proof/prover.ts index f10a408b..90e4181c 100644 --- a/src/proof/prover.ts +++ b/src/proof/prover.ts @@ -1,12 +1,11 @@ +/* eslint-disable @typescript-eslint/no-var-requires */ import { ZKProof } from '@iden3/js-jwz'; -import * as snarkjs from 'snarkjs'; import { CircuitId } from '../circuits'; import { ICircuitStorage } from '../storage/interfaces/circuits'; import { witnessBuilder } from './witness_calculator'; -import { getCurveFromName } from 'ffjavascript'; import { byteDecoder } from '../utils'; - -/* eslint-disable no-console */ +import * as snarkjs from 'snarkjs'; +import { getCurveFromName } from 'ffjavascript'; // NativeProver service responsible for zk generation groth16 algorithm with bn128 curve export class NativeProver { @@ -28,6 +27,7 @@ export class NativeProver { await this.terminateCurve(); return true; } catch (e) { + // eslint-disable-next-line no-console console.log(e); return false; } @@ -35,31 +35,26 @@ export class NativeProver { // Generate calls prover-server for proof generation async generate(inputs: Uint8Array, circuitId: CircuitId): Promise { - try { - const circuitData = await this._circuitStorage.loadCircuitData(circuitId); - const wasm: Uint8Array = circuitData.wasm; + const circuitData = await this._circuitStorage.loadCircuitData(circuitId); + const wasm: Uint8Array = circuitData.wasm; - const witnessCalculator = await witnessBuilder(wasm); + const witnessCalculator = await witnessBuilder(wasm); - const parsedData = JSON.parse(byteDecoder.decode(inputs)); + const parsedData = JSON.parse(byteDecoder.decode(inputs)); - const wtnsBytes: Uint8Array = await witnessCalculator.calculateWTNSBin(parsedData, 0); + const wtnsBytes: Uint8Array = await witnessCalculator.calculateWTNSBin(parsedData, 0); - const provingKey = circuitData.provingKey; + const provingKey = circuitData.provingKey; - const { proof, publicSignals } = await snarkjs.groth16.prove(provingKey, wtnsBytes); + const { proof, publicSignals } = await snarkjs.groth16.prove(provingKey, wtnsBytes); - // we need to terminate curve manually - await this.terminateCurve(); + // we need to terminate curve manually + await this.terminateCurve(); - return { - proof: proof, - pub_signals: publicSignals - }; - } catch (e) { - console.log(e); - throw e; - } + return { + proof, + pub_signals: publicSignals + }; } private async terminateCurve(): Promise { diff --git a/src/proof/witness_calculator.ts b/src/proof/witness_calculator.ts index 99c1ce77..8e7c5c2f 100644 --- a/src/proof/witness_calculator.ts +++ b/src/proof/witness_calculator.ts @@ -1,12 +1,12 @@ /* eslint-disable require-await */ /* eslint-disable @typescript-eslint/no-explicit-any */ -export async function witnessBuilder(code, options?) { +export async function witnessBuilder(code: BufferSource, options?: any) { options = options || {}; let wasmModule; try { wasmModule = await WebAssembly.compile(code); - } catch (err) { + } catch (err: any) { throw new Error(err); } @@ -15,7 +15,7 @@ export async function witnessBuilder(code, options?) { const instance = await WebAssembly.instantiate(wasmModule, { runtime: { - exceptionHandler: function (code) { + exceptionHandler: function (code: number) { let err; if (code == 1) { err = 'Signal not found.\n'; @@ -94,7 +94,7 @@ class WitnessCalculator { prime: any; witnessSize: any; sanityCheck: any; - constructor(private instance, sanityCheck) { + constructor(private instance: any, sanityCheck: any) { this.instance = instance; this.version = (this.instance.exports as any).getVersion(); this.n32 = (this.instance.exports as any).getFieldNumLen32(); @@ -115,7 +115,7 @@ class WitnessCalculator { return (this.instance.exports as any).getVersion(); } - async _doCalculateWitness(input, sanityCheck) { + async _doCalculateWitness(input: any, sanityCheck: any) { //input is assumed to be a map from signals to arrays of bigints (this.instance.exports as any).init(this.sanityCheck || sanityCheck ? 1 : 0); const keys = Object.keys(input); @@ -143,7 +143,7 @@ class WitnessCalculator { try { (this.instance.exports as any).setInputSignal(hMSB, hLSB, i); input_counter++; - } catch (err) { + } catch (err: any) { // console.log(`After adding signal ${i} of ${k}`) throw new Error(err); } @@ -158,7 +158,7 @@ class WitnessCalculator { } } - async calculateWitness(input, sanityCheck) { + async calculateWitness(input: any, sanityCheck: any) { const w = []; await this._doCalculateWitness(input, sanityCheck); @@ -175,7 +175,7 @@ class WitnessCalculator { return w; } - async calculateBinWitness(input, sanityCheck) { + async calculateBinWitness(input: any, sanityCheck: any) { const buff32 = new Uint32Array(this.witnessSize * this.n32); const buff = new Uint8Array(buff32.buffer); await this._doCalculateWitness(input, sanityCheck); @@ -191,7 +191,7 @@ class WitnessCalculator { return buff; } - async calculateWTNSBin(input, sanityCheck) { + async calculateWTNSBin(input: any, sanityCheck: any) { const buff32 = new Uint32Array(this.witnessSize * this.n32 + this.n32 + 11); const buff = new Uint8Array(buff32.buffer); await this._doCalculateWitness(input, sanityCheck); @@ -257,7 +257,7 @@ class WitnessCalculator { } } -function toArray32(rem, size) { +function toArray32(rem: bigint, size: number) { const res = []; //new Uint32Array(size); //has no unshift const radix = BigInt(0x100000000); while (rem) { @@ -274,7 +274,7 @@ function toArray32(rem, size) { return res; } -function fromArray32(arr) { +function fromArray32(arr: Uint32Array) { //returns a BigInt let res = BigInt(0); const radix = BigInt(0x100000000); @@ -284,12 +284,12 @@ function fromArray32(arr) { return res; } -function flatArray(a) { - const res = []; +function flatArray(a: any[]) { + const res: any[] = []; fillArray(res, a); return res; - function fillArray(res, a) { + function fillArray(res: any[], a: any[]) { if (Array.isArray(a)) { for (let i = 0; i < a.length; i++) { fillArray(res, a[i]); @@ -300,7 +300,7 @@ function flatArray(a) { } } -function fnvHash(str) { +function fnvHash(str: any) { const uint64_max = BigInt(2) ** BigInt(64); let hash = BigInt('0xCBF29CE484222325'); for (let i = 0; i < str.length; i++) { diff --git a/src/schema-processor/json/parser.ts b/src/schema-processor/json/parser.ts index e2f95803..a064527d 100644 --- a/src/schema-processor/json/parser.ts +++ b/src/schema-processor/json/parser.ts @@ -71,7 +71,7 @@ export interface CoreClaimOptions { subjectPosition: string; merklizedRootPosition: string; updatable: boolean; - merklizeOpts: Options; + merklizeOpts?: Options; } /** diff --git a/src/schema-processor/json/validator.ts b/src/schema-processor/json/validator.ts index 6d56dccc..27803397 100644 --- a/src/schema-processor/json/validator.ts +++ b/src/schema-processor/json/validator.ts @@ -37,7 +37,8 @@ export class JsonSchemaValidator { if (!draft) { validator = defaultJSONSchemaValidator; } - const ajv = JSON_SCHEMA_VALIDATORS_REGISTRY[draft]; + const ajv = + JSON_SCHEMA_VALIDATORS_REGISTRY[draft as keyof typeof JSON_SCHEMA_VALIDATORS_REGISTRY]; validator = ajv ?? defaultJSONSchemaValidator; const validate = validator.compile(schema); const valid = validate(data); diff --git a/src/schema-processor/jsonld/parser.ts b/src/schema-processor/jsonld/parser.ts index 25f69977..7c62d877 100644 --- a/src/schema-processor/jsonld/parser.ts +++ b/src/schema-processor/jsonld/parser.ts @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/no-var-requires */ import * as jsonld from 'jsonld/lib'; import * as ldcontext from 'jsonld/lib/context'; @@ -25,7 +26,7 @@ export class LDParser { throw new Error(`Failed process LD context. Error ${e}`); } - const terms = res.mappings as Map; + const terms = res.mappings; return terms; } diff --git a/src/schema-processor/utils.ts b/src/schema-processor/utils.ts index 164312b4..6a27f575 100644 --- a/src/schema-processor/utils.ts +++ b/src/schema-processor/utils.ts @@ -75,7 +75,7 @@ export const createSchemaHash = (schemaId: Uint8Array): SchemaHash => { * @param {string} fieldName - field name * @returns Uint8Array - filled slot */ -export const fillSlot = (data, fieldName: string): Uint8Array => { +export const fillSlot = (data: { [key: string]: unknown }, fieldName: string): Uint8Array => { let slot = Uint8Array.from([]); if (!fieldName) { diff --git a/src/storage/blockchain/onchain-revocation.ts b/src/storage/blockchain/onchain-revocation.ts index 243c9beb..a7f80867 100644 --- a/src/storage/blockchain/onchain-revocation.ts +++ b/src/storage/blockchain/onchain-revocation.ts @@ -51,7 +51,7 @@ export class OnChainRevocationStorage { }; } - private static convertIssuerInfo(issuer: unknown): Issuer { + private static convertIssuerInfo(issuer: unknown[]): Issuer { return { state: newHashFromBigInt(BigNumber.from(issuer[0]).toBigInt()).hex(), claimsTreeRoot: newHashFromBigInt(BigNumber.from(issuer[1]).toBigInt()).hex(), @@ -70,10 +70,7 @@ export class OnChainRevocationStorage { const p = new Proof(); p.existence = mtp.existence; if (p.existence) { - p.nodeAux = { - key: undefined, - value: undefined - } as NodeAux; + p.nodeAux = {} as NodeAux; } else { if (mtp.auxExistence) { const auxIndex = BigInt(mtp.auxIndex.toString()); @@ -83,10 +80,7 @@ export class OnChainRevocationStorage { value: newHashFromBigInt(auxValue) } as NodeAux; } else { - p.nodeAux = { - key: undefined, - value: undefined - } as NodeAux; + p.nodeAux = {} as NodeAux; } } diff --git a/src/storage/blockchain/state.ts b/src/storage/blockchain/state.ts index 6792f771..00a2c0ad 100644 --- a/src/storage/blockchain/state.ts +++ b/src/storage/blockchain/state.ts @@ -26,7 +26,7 @@ export interface EthConnectionConfig { rpcResponseTimeout: number; waitReceiptCycleTime: number; waitBlockCycleTime: number; - chainId: number; + chainId: number | null; } export /** @type {EthConnectionConfig} - default configuration for EthConnectionConfig */ @@ -93,9 +93,9 @@ export class EthStateStorage implements IStateStorage { const { userId, oldUserState, newUserState, isOldStateGenesis } = stateTransitionPubSig; const payload = [ - userId.bigInt().toString(), - oldUserState.bigInt().toString(), - newUserState.bigInt().toString(), + userId?.bigInt().toString(), + oldUserState?.bigInt().toString(), + newUserState?.bigInt().toString(), isOldStateGenesis, proof.proof.pi_a.slice(0, 2), [ @@ -127,7 +127,10 @@ export class EthStateStorage implements IStateStorage { return { root: BigInt(data.root.toString()), existence: data.existence, - siblings: data.siblings?.map((sibling) => BigInt(sibling.toString())), + siblings: data.siblings?.map( + (sibling: { toString: () => string | number | bigint | boolean }) => + BigInt(sibling.toString()) + ), index: BigInt(data.index.toString()), value: BigInt(data.value.toString()), auxExistence: data.auxExistence, diff --git a/src/storage/filters/jsonQuery.ts b/src/storage/filters/jsonQuery.ts index 1b8e4fd2..082c8b3e 100644 --- a/src/storage/filters/jsonQuery.ts +++ b/src/storage/filters/jsonQuery.ts @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ import { W3CCredential, ProofQuery } from '../../verifiable'; /** @@ -15,7 +16,7 @@ export enum SearchError { export type FilterOperatorMethod = '$noop' | '$eq' | '$in' | '$nin' | '$gt' | '$lt' | '$ne'; /** filter function type */ -export type FilterOperatorFunction = (a, b) => boolean; +export type FilterOperatorFunction = (a: any, b: any) => boolean; /** * query filter interface that allows to query Verifiable Credential @@ -37,7 +38,7 @@ export interface IFilterQuery { const truthyValues = [true, 1, 'true']; const falsyValues = [false, 0, 'false']; -const equalsComparator = (a, b) => { +const equalsComparator = (a: number | string | boolean, b: number | string | boolean) => { if (truthyValues.includes(a) && truthyValues.includes(b)) { return true; } @@ -73,7 +74,7 @@ export const resolvePath = (object: object, path: string, defaultValue = null) = if (o === null || o === undefined) { return defaultValue; } - o = o[part]; + o = o[part as keyof typeof o]; } return o; }; @@ -98,7 +99,7 @@ export class FilterQuery implements IFilterQuery { constructor( public path: string, public operatorFunc: FilterOperatorFunction, - public value, + public value: any, public isReverseParams = false ) {} /** {@inheritdoc IFilterQuery} */ @@ -124,7 +125,8 @@ export class FilterQuery implements IFilterQuery { */ export const StandardJSONCredentialsQueryFilter = (query: ProofQuery): FilterQuery[] => { return Object.keys(query).reduce((acc: FilterQuery[], queryKey) => { - const queryValue = query[queryKey]; + // eslint-disable-next-line @typescript-eslint/no-explicit-any + const queryValue: any = query[queryKey as keyof typeof query]; switch (queryKey) { case 'claimId': return acc.concat(new FilterQuery('id', comparatorOptions.$eq, queryValue)); @@ -160,7 +162,11 @@ export const StandardJSONCredentialsQueryFilter = (query: ProofQuery): FilterQue const res = Object.keys(fieldParams).map((comparator) => { const value = fieldParams[comparator]; const path = `credentialSubject.${fieldKey}`; - return new FilterQuery(path, comparatorOptions[comparator], value); + return new FilterQuery( + path, + comparatorOptions[comparator as keyof typeof comparatorOptions], + value + ); }); return acc.concat(res); }, []); diff --git a/src/storage/indexed-db/merkletree.ts b/src/storage/indexed-db/merkletree.ts index dd46c7a5..4b0c222d 100644 --- a/src/storage/indexed-db/merkletree.ts +++ b/src/storage/indexed-db/merkletree.ts @@ -97,7 +97,10 @@ export class MerkleTreeIndexedDBStorage implements IMerkleTreeStorage { throw err; } - const resultMeta = meta.find((m) => m.identifier === identifier && m.type === mtType); + const resultMeta = meta.find( + (m: { identifier: string; type: MerkleTreeType }) => + m.identifier === identifier && m.type === mtType + ); if (!resultMeta) { throw err; } @@ -114,7 +117,10 @@ export class MerkleTreeIndexedDBStorage implements IMerkleTreeStorage { if (!meta) { throw new Error(`Merkle tree meta not found for identifier ${identifier}`); } - const resultMeta = meta.find((m) => m.identifier === identifier && m.type === mtType); + const resultMeta = meta.find( + (m: { identifier: string; type: MerkleTreeType }) => + m.identifier === identifier && m.type === mtType + ); if (!resultMeta) { throw new Error(`Merkle tree not found for identifier ${identifier} and type ${mtType}`); } @@ -135,7 +141,10 @@ export class MerkleTreeIndexedDBStorage implements IMerkleTreeStorage { throw new Error(`Merkle tree meta not found for identifier ${oldIdentifier}`); } - const treesMeta = meta.map((m) => ({ ...m, identifier: newIdentifier })); + const treesMeta = meta.map((m: { identifier: string; type: MerkleTreeType }) => ({ + ...m, + identifier: newIdentifier + })); await del(oldIdentifier, this._merkleTreeMetaStore); await set(newIdentifier, treesMeta, this._merkleTreeMetaStore); diff --git a/src/storage/local-storage/data-source.ts b/src/storage/local-storage/data-source.ts index f6babc4e..b754974c 100644 --- a/src/storage/local-storage/data-source.ts +++ b/src/storage/local-storage/data-source.ts @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ import { StorageErrors } from '../errors'; import { IDataSource } from '../interfaces/data-source'; @@ -31,8 +32,11 @@ export class BrowserDataSource implements IDataSource { async save(key: string, value: Type, keyName = 'id'): Promise { if (localStorage) { const data = localStorage.getItem(this._localStorageKey); - const items = JSON.parse(data) as Type[]; - const itemIndex = items.findIndex((i) => i[keyName] === key); + let items: Type[] = []; + if (data) { + items = JSON.parse(data) as Type[]; + } + const itemIndex = items.findIndex((i: any): boolean => i[keyName] === key); if (itemIndex === -1) { items.push(value); } else { @@ -50,8 +54,11 @@ export class BrowserDataSource implements IDataSource { async get(key: string, keyName = 'id'): Promise { const data = localStorage.getItem(this._localStorageKey); - const parsedData = data && (JSON.parse(data) as Type[]); - return parsedData.find((t) => t[keyName] === key); + let parsedData: Type[] = []; + if (data) { + parsedData = JSON.parse(data) as Type[]; + } + return parsedData.find((t: any) => t[keyName] === key); } /** @@ -68,8 +75,11 @@ export class BrowserDataSource implements IDataSource { */ async delete(key: string, keyName = 'id'): Promise { const dataStr = localStorage.getItem(this._localStorageKey); - const data = JSON.parse(dataStr) as Type[]; - const items = data.filter((i) => i[keyName] !== key); + let data: Type[] = []; + if (dataStr) { + data = JSON.parse(dataStr) as Type[]; + } + const items = data.filter((i: any) => i[keyName] !== key); if (data.length === items.length) { throw new Error(`${StorageErrors.ItemNotFound} to delete: ${key}`); } diff --git a/src/storage/memory/data-source.ts b/src/storage/memory/data-source.ts index 553b96d7..9e01d37e 100644 --- a/src/storage/memory/data-source.ts +++ b/src/storage/memory/data-source.ts @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ import { StorageErrors } from '../errors'; import { IDataSource } from '../interfaces/data-source'; @@ -14,7 +15,7 @@ export class InMemoryDataSource implements IDataSource { /** saves in the memory */ async save(key: string, value: Type, keyName = 'id'): Promise { - const itemIndex = this._data.findIndex((i) => i[keyName] === key); + const itemIndex = this._data.findIndex((i: any) => i[keyName] === key); if (itemIndex === -1) { this._data.push(value); } else { @@ -24,7 +25,7 @@ export class InMemoryDataSource implements IDataSource { /** gets value from from the memory */ async get(key: string, keyName = 'id'): Promise { - return this._data.find((t) => t[keyName] === key); + return this._data.find((t: any) => t[keyName] === key); } /** loads from value from the memory */ @@ -34,7 +35,7 @@ export class InMemoryDataSource implements IDataSource { /** deletes from value from the memory */ async delete(key: string, keyName = 'id'): Promise { - const newData = this._data.filter((i) => i[keyName] !== key); + const newData = this._data.filter((i: any) => i[keyName] !== key); if (newData.length === this._data.length) { throw new Error(`${StorageErrors.ItemNotFound} to delete: ${key}`); diff --git a/src/storage/shared/credential-storage.ts b/src/storage/shared/credential-storage.ts index 9e8e608e..8ad45236 100644 --- a/src/storage/shared/credential-storage.ts +++ b/src/storage/shared/credential-storage.ts @@ -26,9 +26,10 @@ export class CredentialStorage implements ICredentialStorage { /** {@inheritdoc ICredentialStorage.listCredentials } */ async listCredentials(): Promise { - let creds = await this._dataSource.load(); - creds = creds.map((cred) => (cred ? Object.assign(new W3CCredential(), cred) : undefined)); - return creds; + const creds = await this._dataSource.load(); + return creds + .filter((i) => i !== undefined) + .map((cred) => cred && Object.assign(new W3CCredential(), cred)); } /** @inheritdoc */ @@ -51,7 +52,7 @@ export class CredentialStorage implements ICredentialStorage { /** {@inheritdoc ICredentialStorage.listCredentials } */ async findCredentialById(id: string): Promise { const cred = await this._dataSource.get(id); - return cred ? Object.assign(new W3CCredential(), cred) : undefined; + return cred && Object.assign(new W3CCredential(), cred); } /** {@inheritdoc ICredentialStorage.listCredentials } @@ -59,11 +60,14 @@ export class CredentialStorage implements ICredentialStorage { */ async findCredentialsByQuery(query: ProofQuery): Promise { const filters = StandardJSONCredentialsQueryFilter(query); - let creds = (await this._dataSource.load()).filter((credential) => + const creds = (await this._dataSource.load()).filter((credential) => filters.every((filter) => filter.execute(credential)) ); - creds = creds.map((cred) => (cred ? Object.assign(new W3CCredential(), cred) : undefined)); - return creds; + const mappedCreds = creds + .filter((i) => i !== undefined) + .map((cred) => Object.assign(new W3CCredential(), cred)); + + return mappedCreds; } } diff --git a/src/storage/shared/identity-storage.ts b/src/storage/shared/identity-storage.ts index 3104c8fc..73645c7f 100644 --- a/src/storage/shared/identity-storage.ts +++ b/src/storage/shared/identity-storage.ts @@ -76,7 +76,7 @@ export class IdentityStorage implements IIdentityStorage { return this._identityDataSource.save(identity.identifier, identity, 'identifier'); } - async getIdentity(identifier: string): Promise { + async getIdentity(identifier: string): Promise { return this._identityDataSource.get(identifier, 'identifier'); } } diff --git a/src/verifiable/credential.ts b/src/verifiable/credential.ts index 682452da..7e46d857 100644 --- a/src/verifiable/credential.ts +++ b/src/verifiable/credential.ts @@ -13,16 +13,16 @@ import { Merklizer, Options } from '@iden3/js-jsonld-merklization'; * @class W3CCredential */ export class W3CCredential { - id: string; - '@context': string[]; - type: string[]; + id = ''; + '@context': string[] = []; + type: string[] = []; expirationDate?: string; issuanceDate?: string; - credentialSubject: { [key: string]: object | string | number | boolean }; - credentialStatus: CredentialStatus; - issuer: string; - credentialSchema: CredentialSchema; - proof?: object; + credentialSubject: { [key: string]: object | string | number | boolean } = {}; + credentialStatus!: CredentialStatus; + issuer = ''; + credentialSchema!: CredentialSchema; + proof?: object | unknown[]; /** * merklization of the verifiable credential @@ -68,13 +68,13 @@ export class W3CCredential { for (const proof of this.proof) { const { proofType: extractedProofType } = extractProof(proof); if (proofType === extractedProofType) { - return proof as BJJSignatureProof2021; + return new BJJSignatureProof2021(proof); } } } else if (typeof this.proof === 'object') { const { proofType: extractedProofType } = extractProof(this.proof); if (extractedProofType == proofType) { - return this.proof as BJJSignatureProof2021; + return new BJJSignatureProof2021(this.proof); } } return undefined; @@ -91,13 +91,13 @@ export class W3CCredential { for (const proof of this.proof) { const { proofType: extractedProofType } = extractProof(proof); if (proofType === extractedProofType) { - return proof as Iden3SparseMerkleTreeProof; + return new Iden3SparseMerkleTreeProof(proof); } } } else if (typeof this.proof === 'object') { const { proofType: extractedProofType } = extractProof(this.proof); if (extractedProofType == proofType) { - return this.proof as Iden3SparseMerkleTreeProof; + return new Iden3SparseMerkleTreeProof(this.proof); } } return undefined; @@ -122,11 +122,12 @@ export function extractProof(proof: object): { claim: Claim; proofType: ProofTyp return { claim: new Claim().fromHex(proof.coreClaim), proofType: ProofType.BJJSignature }; } if (typeof proof === 'object') { - const defaultProofType = proof['type']; + const p = proof as { type: ProofType; coreClaim: string }; + const defaultProofType: ProofType = p.type; if (!defaultProofType) { throw new Error('proof type is not specified'); } - const coreClaimHex = proof['coreClaim']; + const coreClaimHex = p.coreClaim; if (!coreClaimHex) { throw new Error(`coreClaim field is not defined in proof type ${defaultProofType}`); } diff --git a/src/verifiable/presentation.ts b/src/verifiable/presentation.ts index 6d175e33..e20e4106 100644 --- a/src/verifiable/presentation.ts +++ b/src/verifiable/presentation.ts @@ -3,7 +3,7 @@ import { Hasher, MtValue, Options, Path } from '@iden3/js-jsonld-merklization'; import { W3CCredential } from './credential'; import { ProofQuery } from './proof'; -export const stringByPath = (obj: object, path: string): string => { +export const stringByPath = (obj: { [key: string]: unknown }, path: string): string => { const parts = path.split('.'); let value = obj; @@ -12,7 +12,7 @@ export const stringByPath = (obj: object, path: string): string => { if (!key) { throw new Error('path is empty'); } - value = value[key]; + value = value[key] as { [key: string]: unknown }; if (value === undefined) { throw new Error('path not found'); } @@ -29,8 +29,8 @@ export const buildQueryPath = async ( let resp; try { resp = await (await fetch(contextURL)).json(); - } catch (error) { - throw new Error(`context not found: ${error.message}`); + } catch (error: unknown) { + throw new Error(`context not found: ${(error as Error).message}`); } const path = await Path.getContextPathKey(JSON.stringify(resp), contextType, field, opts); @@ -83,11 +83,13 @@ export const verifiablePresentationFromCred = async ( }> => { const mz = await w3cCred.merklize(opts); - const contextType = stringByPath(requestObj, 'type'); + const request = requestObj as { [key: string]: unknown }; + + const contextType = stringByPath(request, 'type'); const hasher = mz.hasher; - const contextURL = stringByPath(requestObj, 'context'); + const contextURL = stringByPath(request, 'context'); const path = await buildQueryPath(contextURL, contextType, field, opts); @@ -99,5 +101,5 @@ export const verifiablePresentationFromCred = async ( const vp = createVerifiablePresentation(contextURL, contextType, field, rawValue); - return { vp, mzValue: value, dataType, hasher }; + return { vp, mzValue: value!, dataType, hasher }; }; diff --git a/src/verifiable/proof.ts b/src/verifiable/proof.ts index 740b8e4b..2035c8fa 100644 --- a/src/verifiable/proof.ts +++ b/src/verifiable/proof.ts @@ -28,8 +28,8 @@ export interface State { * @class IssuerData */ export class IssuerData { - id: string; - state: State; + id = ''; + state!: State; authCoreClaim?: string; mtp?: Proof; credentialStatus?: CredentialStatus; @@ -48,7 +48,11 @@ export class IssuerData { toJSON() { return { ...this, - mtp: { existence: this.mtp.existence, siblings: this.mtp.siblings, nodeAux: this.mtp.nodeAux } + mtp: { + existence: this.mtp?.existence, + siblings: this.mtp?.siblings, + nodeAux: this.mtp?.nodeAux + } }; } } @@ -61,10 +65,10 @@ export class IssuerData { * @class Iden3SparseMerkleTreeProof */ export class Iden3SparseMerkleTreeProof { - type: ProofType; - issuerData: IssuerData; - mtp: Proof; - coreClaim: string; + type!: ProofType; + issuerData!: IssuerData; + mtp!: Proof; + coreClaim = ''; /** * Creates an instance of Iden3SparseMerkleTreeProof. * @param {object} obj @@ -93,10 +97,14 @@ export class Iden3SparseMerkleTreeProof { * @class BJJSignatureProof2021 */ export class BJJSignatureProof2021 { - type: ProofType; - issuerData: IssuerData; - signature: string; - coreClaim: string; + type!: ProofType; + issuerData!: IssuerData; + signature!: string; + coreClaim!: string; + + constructor(obj?: object) { + Object.assign(this, obj ?? {}); + } } /** * Query represents structure for query to atomic circuit diff --git a/tests/circuits/utils.ts b/tests/circuits/utils.ts index 6545cd33..159931a2 100644 --- a/tests/circuits/utils.ts +++ b/tests/circuits/utils.ts @@ -197,12 +197,12 @@ async function calcStateFromRoots(claimsTree: Merkletree, ...args: Merkletree[]) } export class IdentityTest { - id: Id; - clt: Merkletree; - ret: Merkletree; - rot: Merkletree; - authClaim: Claim; - pk: PrivateKey; + id!: Id; + clt!: Merkletree; + ret!: Merkletree; + rot!: Merkletree; + authClaim!: Claim; + pk!: PrivateKey; /** * @@ -343,19 +343,6 @@ export function mtHashFromStr(hashStr: string): Hash { return newHashFromString(hashStr); } -export const JSONSerializer = (key, value) => { - if (typeof value === 'bigint') { - return value.toString(); - } - if (value instanceof Id) { - return value.bigInt().toString(); - } - if (value instanceof SchemaHash) { - return value.bigInt().toString(); - } - return value; -}; - export const globalTree = () => new Merkletree(new InMemoryDB(str2Bytes('')), true, 64); export const coreSchemaFromStr = (schemaIntString: string) => { diff --git a/tests/handlers/auth.test.ts b/tests/handlers/auth.test.ts index 0821a614..61bf5727 100644 --- a/tests/handlers/auth.test.ts +++ b/tests/handlers/auth.test.ts @@ -1,4 +1,3 @@ -/* eslint-disable @typescript-eslint/no-non-null-assertion */ /* eslint-disable no-console */ import { Identity, Profile } from '../../src/storage/entities/identity'; import { IdentityStorage } from '../../src/storage/shared/identity-storage'; diff --git a/tests/handlers/fetch.test.ts b/tests/handlers/fetch.test.ts index 5c34137c..a3727be7 100644 --- a/tests/handlers/fetch.test.ts +++ b/tests/handlers/fetch.test.ts @@ -34,7 +34,7 @@ import * as uuid from 'uuid'; import { byteEncoder } from '../../src/utils'; import { Blockchain, DidMethod, NetworkId } from '@iden3/js-iden3-core'; import { assert, expect } from 'chai'; -import fetchMock from '@4c/fetch-mock'; +import fetchMock from '@gr2m/fetch-mock'; import { after } from 'mocha'; import { proving } from '@iden3/js-jwz'; diff --git a/tsconfig.json b/tsconfig.json index e9ca2cbf..5479c476 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -11,9 +11,10 @@ "allowJs": true, "esModuleInterop": true, "skipLibCheck": true, - + "strict": true }, "include": [ - "src" + "src", + "types" ] } diff --git a/types/ffjavascript.d.ts b/types/ffjavascript.d.ts new file mode 100644 index 00000000..578e45ec --- /dev/null +++ b/types/ffjavascript.d.ts @@ -0,0 +1,3 @@ +declare module 'ffjavascript' { + export function getCurveFromName(name: string): Promise<{ terminate: () => void }>; +} diff --git a/types/jsonld/index.d.ts b/types/jsonld/index.d.ts new file mode 100644 index 00000000..c0fc21c4 --- /dev/null +++ b/types/jsonld/index.d.ts @@ -0,0 +1,11 @@ +declare module 'jsonld/lib' { + function processContext( + activeCtx: unknown, + localCtx: unknown, + opts: unknown + ): Promise<{ mappings: Map }>; +} + +declare module 'jsonld/lib/context' { + function getInitialContext(opts: unknown): Map; +} diff --git a/types/snarkjs.d.ts b/types/snarkjs.d.ts new file mode 100644 index 00000000..e259b222 --- /dev/null +++ b/types/snarkjs.d.ts @@ -0,0 +1,13 @@ +declare module 'snarkjs' { + export namespace groth16 { + export function verify(verKey: object, pubSignals: string[], proof: object): Promise; + + export function prove( + provingKey: object, + wtnsBytes: object + ): Promise<{ + proof: { pi_a: string[]; pi_b: string[][]; pi_c: string[]; protocol: string }; + publicSignals: string[]; + }>; + } +}