diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3b24c603..d044b4df 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -4,18 +4,18 @@ jobs: build: strategy: matrix: - version: [20.11.0] + version: ['lts/*'] timeout-minutes: 10 runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: ${{ matrix.version }} - name: Cache node modules id: cache-npm - uses: actions/cache@v3 + uses: actions/cache@v4 env: cache-name: cache-node-modules with: @@ -35,10 +35,10 @@ jobs: run: npm ci - name: Run Prettier - run: npm run format + run: npm run format:check - name: Run ESLint - run: npm run lint + run: npm run lint:check - name: Run Build run: npm run build diff --git a/README.md b/README.md index 057259f5..9e313439 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,13 @@ Installation: npm install @0xpolygonid/js-sdk ``` -See [tests](/tests) for examples on how to use SDK. +## Circuits + +And place actual circuits to `test/proofs/testdata` + +```bash +curl -LO https://iden3-circuits-bucket.s3.eu-west-1.amazonaws.com/latest.zip +``` ## Tests @@ -35,10 +41,11 @@ export RHS_URL="..reverse hash service url" export IPFS_URL="url for ipfs" export STATE_CONTRACT_ADDRESS="state contract address" export RHS_CONTRACT_ADDRESS="reverse hash service contract address" - ``` -And place actual circuits to `test/proofs/testdata` +## Examples + +Please see [examples](https://github.com/0xPolygonID/js-sdk-examples) for visit examples information. ## Documentation diff --git a/index.html b/index.html index 6f5a738e..e0dcafd5 100644 --- a/index.html +++ b/index.html @@ -117,7 +117,7 @@ const { did, credential } = await wallet.createIdentity({ method: core.DidMethod.Iden3, blockchain: core.Blockchain.Polygon, - networkId: core.NetworkId.Mumbai, + networkId: core.NetworkId.Amoy, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, id: 'https://rhs-staging.polygonid.me' @@ -126,7 +126,7 @@ const { did: issuerDID, credential: issuerAuthCredential } = await wallet.createIdentity({ method: core.DidMethod.Iden3, blockchain: core.Blockchain.Polygon, - networkId: core.NetworkId.Mumbai, + networkId: core.NetworkId.Amoy, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, id: 'https://rhs-staging.polygonid.me' diff --git a/package-lock.json b/package-lock.json index 41c43f61..553235d9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@0xpolygonid/js-sdk", - "version": "1.9.4", + "version": "1.10.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@0xpolygonid/js-sdk", - "version": "1.9.4", + "version": "1.10.0", "license": "AGPL-3.0", "dependencies": { "@noble/curves": "^1.4.0", @@ -61,14 +61,14 @@ "typescript": "^4.8.4" }, "engines": { - "node": ">=18.16.0" + "node": ">=20.11.0" }, "peerDependencies": { - "@iden3/js-crypto": "1.0.3", - "@iden3/js-iden3-core": "1.2.1", - "@iden3/js-jsonld-merklization": "1.1.2", - "@iden3/js-jwz": "1.3.0", - "@iden3/js-merkletree": "1.1.2", + "@iden3/js-crypto": "1.1.0", + "@iden3/js-iden3-core": "1.3.1", + "@iden3/js-jsonld-merklization": "1.2.0", + "@iden3/js-jwz": "1.4.0", + "@iden3/js-merkletree": "1.2.0", "ffjavascript": "0.2.63", "rfc4648": "1.5.3", "snarkjs": "0.7.3" @@ -90,56 +90,56 @@ "integrity": "sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==" }, "node_modules/@ampproject/remapping": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.1.tgz", - "integrity": "sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.3.0.tgz", + "integrity": "sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==", "dev": true, "dependencies": { - "@jridgewell/gen-mapping": "^0.3.0", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { "node": ">=6.0.0" } }, "node_modules/@babel/code-frame": { - "version": "7.23.5", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.23.5.tgz", - "integrity": "sha512-CgH3s1a96LipHCmSUmYFPwY7MNx8C3avkq7i4Wl3cfa662ldtUe4VM1TPXX70pfmrlWTb6jLqTYrZyT2ZTJBgA==", + "version": "7.24.2", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.2.tgz", + "integrity": "sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==", "dev": true, "dependencies": { - "@babel/highlight": "^7.23.4", - "chalk": "^2.4.2" + "@babel/highlight": "^7.24.2", + "picocolors": "^1.0.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/compat-data": { - "version": "7.23.5", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.23.5.tgz", - "integrity": "sha512-uU27kfDRlhfKl+w1U6vp16IuvSLtjAxdArVXPa9BvLkrr7CYIsxH5adpHObeAGY/41+syctUWOZ140a2Rvkgjw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.24.1.tgz", + "integrity": "sha512-Pc65opHDliVpRHuKfzI+gSA4zcgr65O4cl64fFJIWEEh8JoHIHh0Oez1Eo8Arz8zq/JhgKodQaxEwUPRtZylVA==", "dev": true, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/core": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.23.9.tgz", - "integrity": "sha512-5q0175NOjddqpvvzU+kDiSOAk4PfdO6FvwCWoQ6RO7rTzEe8vlo+4HVfcnAREhD4npMs0e9uZypjTwzZPCf/cw==", + "version": "7.24.3", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.24.3.tgz", + "integrity": "sha512-5FcvN1JHw2sHJChotgx8Ek0lyuh4kCKelgMTTqhYJJtloNvUfpAFMeNQUtdlIaktwrSV9LtCdqwk48wL2wBacQ==", "dev": true, "dependencies": { "@ampproject/remapping": "^2.2.0", - "@babel/code-frame": "^7.23.5", - "@babel/generator": "^7.23.6", + "@babel/code-frame": "^7.24.2", + "@babel/generator": "^7.24.1", "@babel/helper-compilation-targets": "^7.23.6", "@babel/helper-module-transforms": "^7.23.3", - "@babel/helpers": "^7.23.9", - "@babel/parser": "^7.23.9", - "@babel/template": "^7.23.9", - "@babel/traverse": "^7.23.9", - "@babel/types": "^7.23.9", + "@babel/helpers": "^7.24.1", + "@babel/parser": "^7.24.1", + "@babel/template": "^7.24.0", + "@babel/traverse": "^7.24.1", + "@babel/types": "^7.24.0", "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", @@ -155,14 +155,14 @@ } }, "node_modules/@babel/generator": { - "version": "7.23.6", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.6.tgz", - "integrity": "sha512-qrSfCYxYQB5owCmGLbl8XRpX1ytXlpueOb0N0UmQwA073KZxejgQTzAmJezxvpwQD9uGtK2shHdi55QT+MbjIw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.24.1.tgz", + "integrity": "sha512-DfCRfZsBcrPEHUfuBMgbJ1Ut01Y/itOs+hY2nFLgqsqXd52/iSiVq5TITtUasIUgm+IIKdY2/1I7auiQOEeC9A==", "dev": true, "dependencies": { - "@babel/types": "^7.23.6", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", + "@babel/types": "^7.24.0", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", "jsesc": "^2.5.1" }, "engines": { @@ -220,12 +220,12 @@ } }, "node_modules/@babel/helper-module-imports": { - "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.22.15.tgz", - "integrity": "sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==", + "version": "7.24.3", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.24.3.tgz", + "integrity": "sha512-viKb0F9f2s0BCS22QSF308z/+1YWKV/76mwt61NBzS5izMzDPwdq1pTrzf+Li3npBWX9KdQbkeCt1jSAM7lZqg==", "dev": true, "dependencies": { - "@babel/types": "^7.22.15" + "@babel/types": "^7.24.0" }, "engines": { "node": ">=6.9.0" @@ -275,9 +275,9 @@ } }, "node_modules/@babel/helper-string-parser": { - "version": "7.23.4", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.23.4.tgz", - "integrity": "sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.1.tgz", + "integrity": "sha512-2ofRCjnnA9y+wk8b9IAREroeUP02KHp431N2mhKniy2yKIDKpbrHv9eXwm8cBeWQYcJmzv5qKCu65P47eCF7CQ==", "dev": true, "engines": { "node": ">=6.9.0" @@ -302,37 +302,38 @@ } }, "node_modules/@babel/helpers": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.23.9.tgz", - "integrity": "sha512-87ICKgU5t5SzOT7sBMfCOZQ2rHjRU+Pcb9BoILMYz600W6DkVRLFBPwQ18gwUVvggqXivaUakpnxWQGbpywbBQ==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.24.1.tgz", + "integrity": "sha512-BpU09QqEe6ZCHuIHFphEFgvNSrubve1FtyMton26ekZ85gRGi6LrTF7zArARp2YvyFxloeiRmtSCq5sjh1WqIg==", "dev": true, "dependencies": { - "@babel/template": "^7.23.9", - "@babel/traverse": "^7.23.9", - "@babel/types": "^7.23.9" + "@babel/template": "^7.24.0", + "@babel/traverse": "^7.24.1", + "@babel/types": "^7.24.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/highlight": { - "version": "7.23.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.23.4.tgz", - "integrity": "sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A==", + "version": "7.24.2", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.2.tgz", + "integrity": "sha512-Yac1ao4flkTxTteCDZLEvdxg2fZfz1v8M4QpaGypq/WPDqg3ijHYbDfs+LG5hvzSoqaSZ9/Z9lKSP3CjZjv+pA==", "dev": true, "dependencies": { "@babel/helper-validator-identifier": "^7.22.20", "chalk": "^2.4.2", - "js-tokens": "^4.0.0" + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/parser": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.9.tgz", - "integrity": "sha512-9tcKgqKbs3xGJ+NtKF2ndOBBLVwPjl1SHxPQkd36r3Dlirw3xWUeGaTbqr7uGZcTaxkVNwc+03SVP7aCdWrTlA==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.24.1.tgz", + "integrity": "sha512-Zo9c7N3xdOIQrNip7Lc9wvRPzlRtovHVE4lkz8WEDr7uYh/GMQhSiIgFxGIArRHYdJE5kxtZjAf8rT0xhdLCzg==", "dev": true, "bin": { "parser": "bin/babel-parser.js" @@ -342,9 +343,9 @@ } }, "node_modules/@babel/runtime": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.23.9.tgz", - "integrity": "sha512-0CX6F+BI2s9dkUqr08KFrAIZgNFj75rdBU/DjCyYLIaV/quFjkk6T+EJ2LkZHyZTbEV4L5p97mNkUsHl2wLFAw==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.24.1.tgz", + "integrity": "sha512-+BIznRzyqBf+2wCTxcKE3wDjfGeCoVE61KSHGpkzqrLi8qxqFwBeUFyId2cxkTmm55fzDGnm0+yCxaxygrLUnQ==", "dev": true, "dependencies": { "regenerator-runtime": "^0.14.0" @@ -354,33 +355,33 @@ } }, "node_modules/@babel/template": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.23.9.tgz", - "integrity": "sha512-+xrD2BWLpvHKNmX2QbpdpsBaWnRxahMwJjO+KZk2JOElj5nSmKezyS1B4u+QbHMTX69t4ukm6hh9lsYQ7GHCKA==", + "version": "7.24.0", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.24.0.tgz", + "integrity": "sha512-Bkf2q8lMB0AFpX0NFEqSbx1OkTHf0f+0j82mkw+ZpzBnkk7e9Ql0891vlfgi+kHwOk8tQjiQHpqh4LaSa0fKEA==", "dev": true, "dependencies": { "@babel/code-frame": "^7.23.5", - "@babel/parser": "^7.23.9", - "@babel/types": "^7.23.9" + "@babel/parser": "^7.24.0", + "@babel/types": "^7.24.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/traverse": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.9.tgz", - "integrity": "sha512-I/4UJ9vs90OkBtY6iiiTORVMyIhJ4kAVmsKo9KFc8UOxMeUfi2hvtIBsET5u9GizXE6/GFSuKCTNfgCswuEjRg==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.24.1.tgz", + "integrity": "sha512-xuU6o9m68KeqZbQuDt2TcKSxUw/mrsvavlEqQ1leZ/B+C9tk6E4sRWy97WaXgvq5E+nU3cXMxv3WKOCanVMCmQ==", "dev": true, "dependencies": { - "@babel/code-frame": "^7.23.5", - "@babel/generator": "^7.23.6", + "@babel/code-frame": "^7.24.1", + "@babel/generator": "^7.24.1", "@babel/helper-environment-visitor": "^7.22.20", "@babel/helper-function-name": "^7.23.0", "@babel/helper-hoist-variables": "^7.22.5", "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.9", - "@babel/types": "^7.23.9", + "@babel/parser": "^7.24.1", + "@babel/types": "^7.24.0", "debug": "^4.3.1", "globals": "^11.1.0" }, @@ -389,9 +390,9 @@ } }, "node_modules/@babel/types": { - "version": "7.23.9", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.9.tgz", - "integrity": "sha512-dQjSq/7HaSjRM43FFGnv5keM2HsxpmyV1PfaSVm0nzzjwwTmjOe6J4bC8e3+pTEIgHaHj+1ZlLThRJ2auc/w1Q==", + "version": "7.24.0", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.24.0.tgz", + "integrity": "sha512-+j7a5c253RfKh8iABBhywc8NSfP5LURe7Uh4qpsh6jc+aLJguvmIUBdjSdEMQv2bENrCR5MfRdjGo7vzS/ob7w==", "dev": true, "dependencies": { "@babel/helper-string-parser": "^7.23.4", @@ -545,10 +546,23 @@ "dev": true, "peer": true }, + "node_modules/@eslint/eslintrc/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/@eslint/js": { - "version": "8.56.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.56.0.tgz", - "integrity": "sha512-gMsVel9D7f2HLkBma9VbtzZRehRogVRfbr++f06nL2vnCGCNlzOD+/MUov/F4p8myyAHspEhVobgjpX64q5m6A==", + "version": "8.57.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.57.0.tgz", + "integrity": "sha512-Ys+3g2TaW7gADOJzPt83SJtCDhMjndcDMFVQ/Tj9iA1BfJzFKD9mAUXT3OenpuPHbI6P/myECxRJrofUsDx/5g==", "dev": true, "peer": true, "engines": { @@ -556,9 +570,9 @@ } }, "node_modules/@fastify/busboy": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.1.0.tgz", - "integrity": "sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA==", + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.1.1.tgz", + "integrity": "sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA==", "engines": { "node": ">=14" } @@ -663,24 +677,24 @@ } }, "node_modules/@iden3/js-crypto": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@iden3/js-crypto/-/js-crypto-1.0.3.tgz", - "integrity": "sha512-IFBLIN1O26mM5MVWO8dlABDC6HKLuhYs+30BT+p6dGWsNXB4Rr5JWuhKBUbKlkW78ly3j3+YSoY+J63q7vPs5Q==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@iden3/js-crypto/-/js-crypto-1.1.0.tgz", + "integrity": "sha512-MbL7OpOxBoCybAPoorxrp+fwjDVESyDe6giIWxErjEIJy0Q2n1DU4VmKh4vDoCyhJx/RdVgT8Dkb59lKwISqsw==", "peer": true }, "node_modules/@iden3/js-iden3-core": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@iden3/js-iden3-core/-/js-iden3-core-1.2.1.tgz", - "integrity": "sha512-XvRYQY1LfAn3sO2xoZfr3aAotr3snLKVlQ9ipfkfKwBpBbDGIMswljANcjWa2HxHwjKK4XLyPHArNORjw/yXMQ==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@iden3/js-iden3-core/-/js-iden3-core-1.3.1.tgz", + "integrity": "sha512-cCPuEdbTtgqtcK57trS23FmRbLqh8maHyAlxapYPDlua5GFOtKcyPJlglDb1tfIRxEipErfY7gdvBh3hm26kMg==", "peer": true, "peerDependencies": { - "@iden3/js-crypto": "1.0.3" + "@iden3/js-crypto": "1.1.0" } }, "node_modules/@iden3/js-jsonld-merklization": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@iden3/js-jsonld-merklization/-/js-jsonld-merklization-1.1.2.tgz", - "integrity": "sha512-R8p8EW35YCZQIAfb1GKUEpSdBayACvKFfwQBShGygTmCvA6TzixFc7POu3jmgGcjyRArZjUV6l17YJ33Pu++QQ==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@iden3/js-jsonld-merklization/-/js-jsonld-merklization-1.2.0.tgz", + "integrity": "sha512-7SplwPwNxdwdG/cx2xReEHskgF1Xs+z292M1OYtSrM1PYNY4TRBI5BVMgDcp7im6ehUnsGNOWvdqt78dYiGRqg==", "peer": true, "dependencies": { "@js-temporal/polyfill": "0.4.4", @@ -688,31 +702,31 @@ "n3": "1.17.1" }, "peerDependencies": { - "@iden3/js-crypto": "1.0.3", - "@iden3/js-merkletree": "1.1.2" + "@iden3/js-crypto": "1.1.0", + "@iden3/js-merkletree": "1.2.0" } }, "node_modules/@iden3/js-jwz": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@iden3/js-jwz/-/js-jwz-1.3.0.tgz", - "integrity": "sha512-rb6qtxDITy6gagxcoJJcTTccM0dDviyOVwDZVSPmmP/YHZ6JAPeZrIeC9hXDiKxmq83Gg9jD2qp9i89tjYBUTQ==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@iden3/js-jwz/-/js-jwz-1.4.0.tgz", + "integrity": "sha512-QaIpgR3Lp/+ZB4ZOgtG3eUsaoeg/CIfAf4NOl64f6kdeH40EdvOxku1Gw6NXUgg1U6Lhl1gU8Y/1RDgs/zzVxA==", "peer": true, "peerDependencies": { - "@iden3/js-crypto": "1.0.3", - "@iden3/js-iden3-core": "1.2.1", - "@iden3/js-merkletree": "1.1.2", + "@iden3/js-crypto": "1.1.0", + "@iden3/js-iden3-core": "1.3.1", + "@iden3/js-merkletree": "1.2.0", "ffjavascript": "0.2.63", "rfc4648": "1.5.3", "snarkjs": "0.7.3" } }, "node_modules/@iden3/js-merkletree": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@iden3/js-merkletree/-/js-merkletree-1.1.2.tgz", - "integrity": "sha512-NT0L+Nk6barcEnSV5q2M6LkZuR889E856e+awnok6iDlmzYMt2l3gulo//zMqGsO6wQvzVECaSn0LJQ7uM5c1A==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@iden3/js-merkletree/-/js-merkletree-1.2.0.tgz", + "integrity": "sha512-tM6jj1v/41qQ6V2K6CTrv0KsNHQ2y/O6Q9RSB1SdN2LTu+cgA9FnD2Qr3whzSvwgUs7X3SjuJgb9OTgs0lDemQ==", "peer": true, "peerDependencies": { - "@iden3/js-crypto": "1.0.3", + "@iden3/js-crypto": "1.1.0", "idb-keyval": "^6.2.0" } }, @@ -813,14 +827,14 @@ } }, "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", - "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==", + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, "dependencies": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { "node": ">=6.0.0" @@ -836,22 +850,22 @@ } }, "node_modules/@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true, "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/source-map": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.5.tgz", - "integrity": "sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ==", + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz", + "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==", "dev": true, "dependencies": { - "@jridgewell/gen-mapping": "^0.3.0", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25" } }, "node_modules/@jridgewell/sourcemap-codec": { @@ -861,9 +875,9 @@ "dev": true }, "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.22", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.22.tgz", - "integrity": "sha512-Wf963MzWtA2sjrNt+g18IAln9lKnlRp+K2eH4jjIoF1wYeq3aMREpG09xhlhdzS0EjwU7qmUJYangWa+151vZw==", + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", @@ -884,16 +898,16 @@ } }, "node_modules/@microsoft/api-documenter": { - "version": "7.23.30", - "resolved": "https://registry.npmjs.org/@microsoft/api-documenter/-/api-documenter-7.23.30.tgz", - "integrity": "sha512-yX8MXnvRmdSE6bVY1Mb24uoM/db+TXO39nCg9II6o6pXdKvopIpN/Y96l8Q6pzbIouDcm4ah6N74H5wSPNF+7g==", + "version": "7.24.1", + "resolved": "https://registry.npmjs.org/@microsoft/api-documenter/-/api-documenter-7.24.1.tgz", + "integrity": "sha512-DX332aznb5SWpOLGuymvzg2OZsQ5+dCbSm8yvVYqTylDgSAiPouvKrdlWPoEeicuLU8wzxSl3xv7DMb6xgYwPw==", "dev": true, "dependencies": { "@microsoft/api-extractor-model": "7.28.13", "@microsoft/tsdoc": "0.14.2", "@rushstack/node-core-library": "4.0.2", - "@rushstack/terminal": "0.9.0", - "@rushstack/ts-command-line": "4.17.3", + "@rushstack/terminal": "0.10.0", + "@rushstack/ts-command-line": "4.19.1", "js-yaml": "~3.13.1", "resolve": "~1.22.1" }, @@ -902,9 +916,9 @@ } }, "node_modules/@microsoft/api-extractor": { - "version": "7.40.6", - "resolved": "https://registry.npmjs.org/@microsoft/api-extractor/-/api-extractor-7.40.6.tgz", - "integrity": "sha512-9N+XCIQB94Di+ETTzNGLqjgQydslynHou7QPgDhl5gZ+B/Q5hTv5jtqBglTUnTrC0trHdG5/YKN07ehGKlSb5g==", + "version": "7.43.0", + "resolved": "https://registry.npmjs.org/@microsoft/api-extractor/-/api-extractor-7.43.0.tgz", + "integrity": "sha512-GFhTcJpB+MI6FhvXEI9b2K0snulNLWHqC/BbcJtyNYcKUiw7l3Lgis5ApsYncJ0leALX7/of4XfmXk+maT111w==", "dev": true, "dependencies": { "@microsoft/api-extractor-model": "7.28.13", @@ -912,13 +926,14 @@ "@microsoft/tsdoc-config": "~0.16.1", "@rushstack/node-core-library": "4.0.2", "@rushstack/rig-package": "0.5.2", - "@rushstack/terminal": "0.9.0", - "@rushstack/ts-command-line": "4.17.3", + "@rushstack/terminal": "0.10.0", + "@rushstack/ts-command-line": "4.19.1", "lodash": "~4.17.15", + "minimatch": "~3.0.3", "resolve": "~1.22.1", "semver": "~7.5.4", "source-map": "~0.6.1", - "typescript": "5.3.3" + "typescript": "5.4.2" }, "bin": { "api-extractor": "bin/api-extractor" @@ -963,9 +978,9 @@ } }, "node_modules/@microsoft/api-extractor/node_modules/typescript": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", + "version": "5.4.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.4.2.tgz", + "integrity": "sha512-+2/g0Fds1ERlP6JsakQQDXjZdZMM+rqpamFZJEKh4kwTIn3iDkgKtby0CeNd5ATNZ4Ry1ax15TMx0W2V+miizQ==", "dev": true, "bin": { "tsc": "bin/tsc", @@ -1045,7 +1060,7 @@ "url": "https://paulmillr.com/funding/" } }, - "node_modules/@noble/curves/node_modules/@noble/hashes": { + "node_modules/@noble/hashes": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.4.0.tgz", "integrity": "sha512-V1JJ1WTRUqHHrOSh597hURcMqVKVGL/ea3kv0gSnEdsEZ0/+VyPghM1lMNGc00z7CIQorSvbKpuJkxvuHbvdbg==", @@ -1056,17 +1071,6 @@ "url": "https://paulmillr.com/funding/" } }, - "node_modules/@noble/hashes": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.2.tgz", - "integrity": "sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==", - "engines": { - "node": ">= 16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", @@ -1291,9 +1295,9 @@ } }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.12.0.tgz", - "integrity": "sha512-+ac02NL/2TCKRrJu2wffk1kZ+RyqxVUlbjSagNgPm94frxtr+XDL12E5Ll1enWskLrtrZ2r8L3wED1orIibV/w==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.13.2.tgz", + "integrity": "sha512-3XFIDKWMFZrMnao1mJhnOT1h2g0169Os848NhhmGweEcfJ4rCi+3yMCOLG4zA61rbJdkcrM/DjVZm9Hg5p5w7g==", "cpu": [ "arm" ], @@ -1304,9 +1308,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.12.0.tgz", - "integrity": "sha512-OBqcX2BMe6nvjQ0Nyp7cC90cnumt8PXmO7Dp3gfAju/6YwG0Tj74z1vKrfRz7qAv23nBcYM8BCbhrsWqO7PzQQ==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.13.2.tgz", + "integrity": "sha512-GdxxXbAuM7Y/YQM9/TwwP+L0omeE/lJAR1J+olu36c3LqqZEBdsIWeQ91KBe6nxwOnb06Xh7JS2U5ooWU5/LgQ==", "cpu": [ "arm64" ], @@ -1317,9 +1321,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.12.0.tgz", - "integrity": "sha512-X64tZd8dRE/QTrBIEs63kaOBG0b5GVEd3ccoLtyf6IdXtHdh8h+I56C2yC3PtC9Ucnv0CpNFJLqKFVgCYe0lOQ==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.13.2.tgz", + "integrity": "sha512-mCMlpzlBgOTdaFs83I4XRr8wNPveJiJX1RLfv4hggyIVhfB5mJfN4P8Z6yKh+oE4Luz+qq1P3kVdWrCKcMYrrA==", "cpu": [ "arm64" ], @@ -1330,9 +1334,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.12.0.tgz", - "integrity": "sha512-cc71KUZoVbUJmGP2cOuiZ9HSOP14AzBAThn3OU+9LcA1+IUqswJyR1cAJj3Mg55HbjZP6OLAIscbQsQLrpgTOg==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.13.2.tgz", + "integrity": "sha512-yUoEvnH0FBef/NbB1u6d3HNGyruAKnN74LrPAfDQL3O32e3k3OSfLrPgSJmgb3PJrBZWfPyt6m4ZhAFa2nZp2A==", "cpu": [ "x64" ], @@ -1343,9 +1347,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.12.0.tgz", - "integrity": "sha512-a6w/Y3hyyO6GlpKL2xJ4IOh/7d+APaqLYdMf86xnczU3nurFTaVN9s9jOXQg97BE4nYm/7Ga51rjec5nfRdrvA==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.13.2.tgz", + "integrity": "sha512-GYbLs5ErswU/Xs7aGXqzc3RrdEjKdmoCrgzhJWyFL0r5fL3qd1NPcDKDowDnmcoSiGJeU68/Vy+OMUluRxPiLQ==", "cpu": [ "arm" ], @@ -1356,9 +1360,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.12.0.tgz", - "integrity": "sha512-0fZBq27b+D7Ar5CQMofVN8sggOVhEtzFUwOwPppQt0k+VR+7UHMZZY4y+64WJ06XOhBTKXtQB/Sv0NwQMXyNAA==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.13.2.tgz", + "integrity": "sha512-L1+D8/wqGnKQIlh4Zre9i4R4b4noxzH5DDciyahX4oOz62CphY7WDWqJoQ66zNR4oScLNOqQJfNSIAe/6TPUmQ==", "cpu": [ "arm64" ], @@ -1369,9 +1373,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.12.0.tgz", - "integrity": "sha512-eTvzUS3hhhlgeAv6bfigekzWZjaEX9xP9HhxB0Dvrdbkk5w/b+1Sxct2ZuDxNJKzsRStSq1EaEkVSEe7A7ipgQ==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.13.2.tgz", + "integrity": "sha512-tK5eoKFkXdz6vjfkSTCupUzCo40xueTOiOO6PeEIadlNBkadH1wNOH8ILCPIl8by/Gmb5AGAeQOFeLev7iZDOA==", "cpu": [ "arm64" ], @@ -1381,10 +1385,23 @@ "linux" ] }, + "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.13.2.tgz", + "integrity": "sha512-zvXvAUGGEYi6tYhcDmb9wlOckVbuD+7z3mzInCSTACJ4DQrdSLPNUeDIcAQW39M3q6PDquqLWu7pnO39uSMRzQ==", + "cpu": [ + "ppc64le" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.12.0.tgz", - "integrity": "sha512-ix+qAB9qmrCRiaO71VFfY8rkiAZJL8zQRXveS27HS+pKdjwUfEhqo2+YF2oI+H/22Xsiski+qqwIBxVewLK7sw==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.13.2.tgz", + "integrity": "sha512-C3GSKvMtdudHCN5HdmAMSRYR2kkhgdOfye4w0xzyii7lebVr4riCgmM6lRiSCnJn2w1Xz7ZZzHKuLrjx5620kw==", "cpu": [ "riscv64" ], @@ -1394,10 +1411,23 @@ "linux" ] }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.13.2.tgz", + "integrity": "sha512-l4U0KDFwzD36j7HdfJ5/TveEQ1fUTjFFQP5qIt9gBqBgu1G8/kCaq5Ok05kd5TG9F8Lltf3MoYsUMw3rNlJ0Yg==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.12.0.tgz", - "integrity": "sha512-TenQhZVOtw/3qKOPa7d+QgkeM6xY0LtwzR8OplmyL5LrgTWIXpTQg2Q2ycBf8jm+SFW2Wt/DTn1gf7nFp3ssVA==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.13.2.tgz", + "integrity": "sha512-xXMLUAMzrtsvh3cZ448vbXqlUa7ZL8z0MwHp63K2IIID2+DeP5iWIT6g1SN7hg1VxPzqx0xZdiDM9l4n9LRU1A==", "cpu": [ "x64" ], @@ -1408,9 +1438,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.12.0.tgz", - "integrity": "sha512-LfFdRhNnW0zdMvdCb5FNuWlls2WbbSridJvxOvYWgSBOYZtgBfW9UGNJG//rwMqTX1xQE9BAodvMH9tAusKDUw==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.13.2.tgz", + "integrity": "sha512-M/JYAWickafUijWPai4ehrjzVPKRCyDb1SLuO+ZyPfoXgeCEAlgPkNXewFZx0zcnoIe3ay4UjXIMdXQXOZXWqA==", "cpu": [ "x64" ], @@ -1421,9 +1451,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.12.0.tgz", - "integrity": "sha512-JPDxovheWNp6d7AHCgsUlkuCKvtu3RB55iNEkaQcf0ttsDU/JZF+iQnYcQJSk/7PtT4mjjVG8N1kpwnI9SLYaw==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.13.2.tgz", + "integrity": "sha512-2YWwoVg9KRkIKaXSh0mz3NmfurpmYoBBTAXA9qt7VXk0Xy12PoOP40EFuau+ajgALbbhi4uTj3tSG3tVseCjuA==", "cpu": [ "arm64" ], @@ -1434,9 +1464,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.12.0.tgz", - "integrity": "sha512-fjtuvMWRGJn1oZacG8IPnzIV6GF2/XG+h71FKn76OYFqySXInJtseAqdprVTDTyqPxQOG9Exak5/E9Z3+EJ8ZA==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.13.2.tgz", + "integrity": "sha512-2FSsE9aQ6OWD20E498NYKEQLneShWes0NGMPQwxWOdws35qQXH+FplabOSP5zEe1pVjurSDOGEVCE2agFwSEsw==", "cpu": [ "ia32" ], @@ -1447,9 +1477,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.12.0.tgz", - "integrity": "sha512-ZYmr5mS2wd4Dew/JjT0Fqi2NPB/ZhZ2VvPp7SmvPZb4Y1CG/LRcS6tcRo2cYU7zLK5A7cdbhWnnWmUjoI4qapg==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.13.2.tgz", + "integrity": "sha512-7h7J2nokcdPePdKykd8wtc8QqqkqxIrUz7MHj6aNr8waBRU//NLDVnNjQnqQO6fqtjrtCdftpbTuOKAyrAQETQ==", "cpu": [ "x64" ], @@ -1525,13 +1555,13 @@ } }, "node_modules/@rushstack/terminal": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/@rushstack/terminal/-/terminal-0.9.0.tgz", - "integrity": "sha512-49RnIDooriXyqcd7mGyjh9CmjOjf/Vn8PkOQXHa1CS0/RrrynCJLFhRDkswf7gGXZW+6UhROOE8wTmbOrfUTSA==", + "version": "0.10.0", + "resolved": "https://registry.npmjs.org/@rushstack/terminal/-/terminal-0.10.0.tgz", + "integrity": "sha512-UbELbXnUdc7EKwfH2sb8ChqNgapUOdqcCIdQP4NGxBpTZV2sQyeekuK3zmfQSa/MN+/7b4kBogl2wq0vpkpYGw==", "dev": true, "dependencies": { "@rushstack/node-core-library": "4.0.2", - "colors": "~1.2.1" + "supports-color": "~8.1.1" }, "peerDependencies": { "@types/node": "*" @@ -1543,12 +1573,12 @@ } }, "node_modules/@rushstack/ts-command-line": { - "version": "4.17.3", - "resolved": "https://registry.npmjs.org/@rushstack/ts-command-line/-/ts-command-line-4.17.3.tgz", - "integrity": "sha512-/PtTYW38A8iUviuCmQSccHfmx3uBh4Jm5YRPU2aTgYEgwT2jtg60vAbwnkMYkyaT1AbWpjZM3xq5uHYPURvStw==", + "version": "4.19.1", + "resolved": "https://registry.npmjs.org/@rushstack/ts-command-line/-/ts-command-line-4.19.1.tgz", + "integrity": "sha512-J7H768dgcpG60d7skZ5uSSwyCZs/S2HrWP1Ds8d1qYAyaaeJmpmmLr9BVw97RjFzmQPOYnoXcKA4GkqDCkduQg==", "dev": true, "dependencies": { - "@rushstack/terminal": "0.9.0", + "@rushstack/terminal": "0.10.0", "@types/argparse": "1.0.38", "argparse": "~1.0.9", "string-argv": "~0.3.1" @@ -1703,9 +1733,9 @@ } }, "node_modules/@tsconfig/node10": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", - "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==", + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.11.tgz", + "integrity": "sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==", "dev": true }, "node_modules/@tsconfig/node12": { @@ -1757,9 +1787,9 @@ } }, "node_modules/@types/chai": { - "version": "4.3.11", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.11.tgz", - "integrity": "sha512-qQR1dr2rGIHYlJulmr8Ioq3De0Le9E4MJ5AiaeAETJJpndT1uUNHsGFK3L/UIu+rbkQSdj8J/w2bCsBZc/Y5fQ==", + "version": "4.3.14", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.14.tgz", + "integrity": "sha512-Wj71sXE4Q4AkGdG9Tvq1u/fquNz9EdG4LIJMwVVII7ashjD/8cf8fyIfJAjRr6YcsXnSE8cOGQPq1gqeR8z+3w==", "dev": true }, "node_modules/@types/chai-as-promised": { @@ -1790,9 +1820,9 @@ } }, "node_modules/@types/eslint": { - "version": "8.56.2", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.56.2.tgz", - "integrity": "sha512-uQDwm1wFHmbBbCZCqAlq6Do9LYwByNZHWzXppSnay9SuwJ+VRbjkbLABer54kcPnMSlG6Fdiy2yaFXm/z9Z5gw==", + "version": "8.56.6", + "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.56.6.tgz", + "integrity": "sha512-ymwc+qb1XkjT/gfoQwxIeHZ6ixH23A+tCT2ADSA/DPVKzAjwYkTXBMCQ/f6fe4wEa85Lhp26VPeUxI7wMhAi7A==", "dev": true, "peer": true, "dependencies": { @@ -1855,9 +1885,9 @@ "dev": true }, "node_modules/@types/node": { - "version": "20.11.19", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.19.tgz", - "integrity": "sha512-7xMnVEcZFu0DikYjWOlRq7NTPETrm7teqUT2WkQjrTIkEgUyyGdWsj/Zg8bEJt5TNklzbPD1X3fqfsHw3SpapQ==", + "version": "20.12.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.2.tgz", + "integrity": "sha512-zQ0NYO87hyN6Xrclcqp7f8ZbXNbRfoGWNcMvHTPQp9UUrwI0mI7XBz+cu7/W6/VClYo2g63B0cjull/srU7LgQ==", "dev": true, "dependencies": { "undici-types": "~5.26.4" @@ -1883,9 +1913,9 @@ "dev": true }, "node_modules/@types/semver": { - "version": "7.5.7", - "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.7.tgz", - "integrity": "sha512-/wdoPq1QqkSj9/QOeKkFquEuPzQbHTWAMPH/PaUMB+JuR31lXhlWXRZ52IpfDYVlDOUBvX09uBrPwxGT1hjNBg==", + "version": "7.5.8", + "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", + "integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", "dev": true }, "node_modules/@types/uuid": { @@ -2190,9 +2220,9 @@ "peer": true }, "node_modules/@webassemblyjs/ast": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz", - "integrity": "sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", "dev": true, "peer": true, "dependencies": { @@ -2215,9 +2245,9 @@ "peer": true }, "node_modules/@webassemblyjs/helper-buffer": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.6.tgz", - "integrity": "sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", "dev": true, "peer": true }, @@ -2241,16 +2271,16 @@ "peer": true }, "node_modules/@webassemblyjs/helper-wasm-section": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.6.tgz", - "integrity": "sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", - "@webassemblyjs/helper-buffer": "1.11.6", + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/wasm-gen": "1.11.6" + "@webassemblyjs/wasm-gen": "1.12.1" } }, "node_modules/@webassemblyjs/ieee754": { @@ -2281,30 +2311,30 @@ "peer": true }, "node_modules/@webassemblyjs/wasm-edit": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.6.tgz", - "integrity": "sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", - "@webassemblyjs/helper-buffer": "1.11.6", + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/helper-wasm-section": "1.11.6", - "@webassemblyjs/wasm-gen": "1.11.6", - "@webassemblyjs/wasm-opt": "1.11.6", - "@webassemblyjs/wasm-parser": "1.11.6", - "@webassemblyjs/wast-printer": "1.11.6" + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-gen": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.6.tgz", - "integrity": "sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", + "@webassemblyjs/ast": "1.12.1", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", "@webassemblyjs/ieee754": "1.11.6", "@webassemblyjs/leb128": "1.11.6", @@ -2312,26 +2342,26 @@ } }, "node_modules/@webassemblyjs/wasm-opt": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.6.tgz", - "integrity": "sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", - "@webassemblyjs/helper-buffer": "1.11.6", - "@webassemblyjs/wasm-gen": "1.11.6", - "@webassemblyjs/wasm-parser": "1.11.6" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-parser": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.6.tgz", - "integrity": "sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", + "@webassemblyjs/ast": "1.12.1", "@webassemblyjs/helper-api-error": "1.11.6", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", "@webassemblyjs/ieee754": "1.11.6", @@ -2340,13 +2370,13 @@ } }, "node_modules/@webassemblyjs/wast-printer": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.6.tgz", - "integrity": "sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", + "@webassemblyjs/ast": "1.12.1", "@xtuc/long": "4.2.2" } }, @@ -2597,12 +2627,15 @@ } }, "node_modules/binary-extensions": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", - "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", + "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", "dev": true, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/blake2b-wasm": { @@ -2690,6 +2723,30 @@ "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" } }, + "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" + } + ], + "peer": true, + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, "node_modules/buffer-from": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", @@ -2731,9 +2788,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001589", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001589.tgz", - "integrity": "sha512-vNQWS6kI+q6sBlHbh71IIeC+sRwK2N3EDySc/updIGhIee2x5z00J4c1242/5/d6EpEMdOnk/m+6tuk4/tcsqg==", + "version": "1.0.30001603", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001603.tgz", + "integrity": "sha512-iL2iSS0eDILMb9n5yKQoTBim9jMZ0Yrk8g0N9K7UzYyWnfIKzXBZD5ngpM37ZcL/cv0Mli8XtVMRYMQAfFpi5Q==", "dev": true, "funding": [ { @@ -2811,6 +2868,27 @@ "node": ">=4" } }, + "node_modules/chalk/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==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/chalk/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==", + "dev": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, "node_modules/check-error": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.3.tgz", @@ -2912,15 +2990,6 @@ "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", "dev": true }, - "node_modules/colors": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.2.5.tgz", - "integrity": "sha512-erNRLao/Y3Fv54qUa0LBB+//Uf3YwMUmdJinN20yMXm9zdKKqH9wt7R9IIVZ+K7ShzfpLV/Zg8+VyrBJYB4lpg==", - "dev": true, - "engines": { - "node": ">=0.1.90" - } - }, "node_modules/command-line-args": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/command-line-args/-/command-line-args-5.2.1.tgz", @@ -2973,6 +3042,12 @@ "node": ">=8" } }, + "node_modules/commander": { + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", + "dev": true + }, "node_modules/commondir": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", @@ -2991,9 +3066,9 @@ "dev": true }, "node_modules/core-js": { - "version": "3.36.0", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.36.0.tgz", - "integrity": "sha512-mt7+TUBbTFg5+GngsAxeKBTl5/VS0guFeJacYge9OmHb+m058UwwIm41SE9T4Den7ClatV57B6TYTuJ0CX1MAw==", + "version": "3.36.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.36.1.tgz", + "integrity": "sha512-BTvUrwxVBezj5SZ3f10ImnX2oRByMxql3EimVqMysepbC9EeMUOpLwdy6Eoili2x6E4kf+ZUB5k/+Jv55alPfA==", "dev": true, "hasInstallScript": true, "funding": { @@ -3180,9 +3255,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.4.679", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.679.tgz", - "integrity": "sha512-NhQMsz5k0d6m9z3qAxnsOR/ebal4NAGsrNVRwcDo4Kc/zQ7KdsTKZUxZoygHcVRb0QDW3waEDIcE3isZ79RP6g==", + "version": "1.4.722", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.722.tgz", + "integrity": "sha512-5nLE0TWFFpZ80Crhtp4pIp8LXCztjYX41yUcV6b+bKR2PqzjskTMOOlBi1VjBHlvHwS+4gar7kNKOrsbsewEZQ==", "dev": true }, "node_modules/elliptic": { @@ -3206,9 +3281,9 @@ "dev": true }, "node_modules/enhanced-resolve": { - "version": "5.15.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz", - "integrity": "sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==", + "version": "5.16.0", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.16.0.tgz", + "integrity": "sha512-O+QWCviPNSSLAD9Ucn8Awv+poAkqn3T1XY5/N7kR7rQO9yfSGWkYZDwpJ+iKF7B8rxaQKWngSqACpgzeapSyoA==", "dev": true, "dependencies": { "graceful-fs": "^4.2.4", @@ -3219,9 +3294,9 @@ } }, "node_modules/es-module-lexer": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.4.1.tgz", - "integrity": "sha512-cXLGjP0c4T3flZJKQSuziYoq7MlT+rnvfZjfp7h+I7K9BNX54kP9nyWvdbwjQ4u1iWbOL4u96fgeZLToQlZC7w==", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.0.tgz", + "integrity": "sha512-pqrTKmwEIgafsYZAGw9kszYzmagcE/n4dbgwGWLEXg7J4QFJVQRBld8j3Q3GNez79jzxZshq0bcT962QHOghjw==", "dev": true, "peer": true }, @@ -3243,18 +3318,91 @@ "node": ">=0.8.0" } }, + "node_modules/escodegen": { + "version": "1.14.3", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.14.3.tgz", + "integrity": "sha512-qFcX0XJkdg+PB3xjZZG/wKSuT1PnQWx57+TVSjIMmILd2yC/6ByYElPwJnslDsuWuSAp4AwJGumarAAmJch5Kw==", + "peer": true, + "dependencies": { + "esprima": "^4.0.1", + "estraverse": "^4.2.0", + "esutils": "^2.0.2", + "optionator": "^0.8.1" + }, + "bin": { + "escodegen": "bin/escodegen.js", + "esgenerate": "bin/esgenerate.js" + }, + "engines": { + "node": ">=4.0" + }, + "optionalDependencies": { + "source-map": "~0.6.1" + } + }, + "node_modules/escodegen/node_modules/levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", + "peer": true, + "dependencies": { + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/escodegen/node_modules/optionator": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", + "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", + "peer": true, + "dependencies": { + "deep-is": "~0.1.3", + "fast-levenshtein": "~2.0.6", + "levn": "~0.3.0", + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2", + "word-wrap": "~1.2.3" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/escodegen/node_modules/prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==", + "peer": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/escodegen/node_modules/type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==", + "peer": true, + "dependencies": { + "prelude-ls": "~1.1.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, "node_modules/eslint": { - "version": "8.56.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.56.0.tgz", - "integrity": "sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ==", + "version": "8.57.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.57.0.tgz", + "integrity": "sha512-dZ6+mexnaTIbSBZWgou51U6OmzIhYM2VcNdtiTtI7qPNZm35Akpr0f6vtw3w1Kmn5PYo+tZVfh13WrhpS6oLqQ==", "dev": true, "peer": true, "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", "@eslint-community/regexpp": "^4.6.1", "@eslint/eslintrc": "^2.1.4", - "@eslint/js": "8.56.0", - "@humanwhocodes/config-array": "^0.11.13", + "@eslint/js": "8.57.0", + "@humanwhocodes/config-array": "^0.11.14", "@humanwhocodes/module-importer": "^1.0.1", "@nodelib/fs.walk": "^1.2.8", "@ungap/structured-clone": "^1.2.0", @@ -3503,16 +3651,6 @@ "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==", - "dev": true, - "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", @@ -3533,6 +3671,19 @@ "dev": true, "peer": true }, + "node_modules/eslint/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/eslint/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -3681,6 +3832,17 @@ "url": "https://paulmillr.com/funding/" } }, + "node_modules/ethers/node_modules/@noble/hashes": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.2.tgz", + "integrity": "sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==", + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, "node_modules/ethers/node_modules/@types/node": { "version": "18.15.13", "resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.13.tgz", @@ -3924,6 +4086,19 @@ "url": "https://github.com/sponsors/isaacs" } }, + "node_modules/flat-cache/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/flat-cache/node_modules/rimraf": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", @@ -3963,18 +4138,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/foreground-child/node_modules/signal-exit": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", - "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", - "dev": true, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/formdata-polyfill": { "version": "4.0.10", "resolved": "https://registry.npmjs.org/formdata-polyfill/-/formdata-polyfill-4.0.10.tgz", @@ -4156,12 +4319,11 @@ "dev": true }, "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==", - "dev": true, + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/hash.js": { @@ -4174,9 +4336,9 @@ } }, "node_modules/hasown": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.1.tgz", - "integrity": "sha512-1/th4MHjnwncwXsIW6QMzlvYL9kG5e/CpVvLRZe4XPa8TOUNbCELqmvhDmnkNsAjwaG4+I8gJJL0JBvTTLO9qA==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", "dev": true, "dependencies": { "function-bind": "^1.1.2" @@ -4522,13 +4684,16 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "peer": true }, - "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==", + "node_modules/jake/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, "engines": { - "node": ">=8" + "node": "*" } }, "node_modules/jake/node_modules/supports-color": { @@ -4558,32 +4723,6 @@ "node": ">= 10.13.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==", - "dev": true, - "peer": true, - "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", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", - "dev": true, - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" - } - }, "node_modules/jju": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/jju/-/jju-1.4.0.tgz", @@ -4925,15 +5064,6 @@ "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", @@ -4971,9 +5101,9 @@ } }, "node_modules/magic-string": { - "version": "0.30.7", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.7.tgz", - "integrity": "sha512-8vBuFF/I/+OSLRmdf2wwFCJCz+nSn0m6DPvGH1fS/KiQoSaR+sETbov0eIk9KhEKy8CYqIkIAnbohxT/4H0kuA==", + "version": "0.30.8", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.8.tgz", + "integrity": "sha512-ISQTe55T2ao7XtlAStud6qwYPZjE4GK1S/BeVPus4jrq6JuOnQ00YKQC581RWhR122W7msZV263KzVeLoqidyQ==", "dev": true, "dependencies": { "@jridgewell/sourcemap-codec": "^1.4.15" @@ -5051,10 +5181,10 @@ "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" }, "node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "peer": true, + "version": "3.0.8", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.8.tgz", + "integrity": "sha512-6FsRAQsxQ61mw+qP1ZzbL9Bc78x2p5OqNgNpnoAFLTrX8n5Kxph0CsnhmKKNXTWjXqU5L0pGPR7hYk+XWZr60Q==", + "dev": true, "dependencies": { "brace-expansion": "^1.1.7" }, @@ -5201,15 +5331,6 @@ "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", @@ -5258,21 +5379,6 @@ "randombytes": "^2.1.0" } }, - "node_modules/mocha/node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" - } - }, "node_modules/ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", @@ -5489,12 +5595,12 @@ "dev": true }, "node_modules/path-scurry": { - "version": "1.10.1", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.10.1.tgz", - "integrity": "sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ==", + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.10.2.tgz", + "integrity": "sha512-7xTavNy5RQXnsjANvVvMkEjvloOinkAjv/Z6Ildz9v2RinZ4SBKTWFOVRbaF8p0vpHnyjV/UwNDdKuUv6M5qcA==", "dev": true, "dependencies": { - "lru-cache": "^9.1.1 || ^10.0.0", + "lru-cache": "^10.2.0", "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" }, "engines": { @@ -5702,30 +5808,6 @@ "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/readable-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" - } - ], - "peer": true, - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/readdirp": { "version": "3.6.0", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", @@ -5842,16 +5924,16 @@ } }, "node_modules/rimraf/node_modules/glob": { - "version": "10.3.10", - "resolved": "https://registry.npmjs.org/glob/-/glob-10.3.10.tgz", - "integrity": "sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g==", + "version": "10.3.12", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.3.12.tgz", + "integrity": "sha512-TCNv8vJ+xz4QiqTpfOJA7HvYv+tNIRHKfUWw/q+v2jdgN4ebz+KY9tGx5J4rHP0o84mNP+ApH66HRX8us3Khqg==", "dev": true, "dependencies": { "foreground-child": "^3.1.0", - "jackspeak": "^2.3.5", + "jackspeak": "^2.3.6", "minimatch": "^9.0.1", - "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0", - "path-scurry": "^1.10.1" + "minipass": "^7.0.4", + "path-scurry": "^1.10.2" }, "bin": { "glob": "dist/esm/bin.mjs" @@ -5864,9 +5946,9 @@ } }, "node_modules/rimraf/node_modules/minimatch": { - "version": "9.0.3", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.3.tgz", - "integrity": "sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==", + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.4.tgz", + "integrity": "sha512-KqWh+VchfxcMNRAJjj2tnsSJdNbHsVgnkBhTNrW7AjVo6OvLtxw8zfT9oLw1JSohlFzJ8jCoTgaoXvJ+kHt6fw==", "dev": true, "dependencies": { "brace-expansion": "^2.0.1" @@ -5879,9 +5961,9 @@ } }, "node_modules/rollup": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.12.0.tgz", - "integrity": "sha512-wz66wn4t1OHIJw3+XU7mJJQV/2NAfw5OAk6G6Hoo3zcvz/XOfQ52Vgi+AN4Uxoxi0KBBwk2g8zPrTDA4btSB/Q==", + "version": "4.13.2", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.13.2.tgz", + "integrity": "sha512-MIlLgsdMprDBXC+4hsPgzWUasLO9CE4zOkj/u6j+Z6j5A4zRY+CtiXAdJyPtgCsc42g658Aeh1DlrdVEJhsL2g==", "dev": true, "dependencies": { "@types/estree": "1.0.5" @@ -5894,19 +5976,21 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.12.0", - "@rollup/rollup-android-arm64": "4.12.0", - "@rollup/rollup-darwin-arm64": "4.12.0", - "@rollup/rollup-darwin-x64": "4.12.0", - "@rollup/rollup-linux-arm-gnueabihf": "4.12.0", - "@rollup/rollup-linux-arm64-gnu": "4.12.0", - "@rollup/rollup-linux-arm64-musl": "4.12.0", - "@rollup/rollup-linux-riscv64-gnu": "4.12.0", - "@rollup/rollup-linux-x64-gnu": "4.12.0", - "@rollup/rollup-linux-x64-musl": "4.12.0", - "@rollup/rollup-win32-arm64-msvc": "4.12.0", - "@rollup/rollup-win32-ia32-msvc": "4.12.0", - "@rollup/rollup-win32-x64-msvc": "4.12.0", + "@rollup/rollup-android-arm-eabi": "4.13.2", + "@rollup/rollup-android-arm64": "4.13.2", + "@rollup/rollup-darwin-arm64": "4.13.2", + "@rollup/rollup-darwin-x64": "4.13.2", + "@rollup/rollup-linux-arm-gnueabihf": "4.13.2", + "@rollup/rollup-linux-arm64-gnu": "4.13.2", + "@rollup/rollup-linux-arm64-musl": "4.13.2", + "@rollup/rollup-linux-powerpc64le-gnu": "4.13.2", + "@rollup/rollup-linux-riscv64-gnu": "4.13.2", + "@rollup/rollup-linux-s390x-gnu": "4.13.2", + "@rollup/rollup-linux-x64-gnu": "4.13.2", + "@rollup/rollup-linux-x64-musl": "4.13.2", + "@rollup/rollup-win32-arm64-msvc": "4.13.2", + "@rollup/rollup-win32-ia32-msvc": "4.13.2", + "@rollup/rollup-win32-x64-msvc": "4.13.2", "fsevents": "~2.3.2" } }, @@ -6054,6 +6138,18 @@ "node": ">=8" } }, + "node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, "node_modules/slash": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", @@ -6064,9 +6160,9 @@ } }, "node_modules/smob": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/smob/-/smob-1.4.1.tgz", - "integrity": "sha512-9LK+E7Hv5R9u4g4C3p+jjLstaLe11MDsL21UpYaCNmapvMkYhqCV4A/f/3gyH8QjMyh6l68q9xC85vihY9ahMQ==", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/smob/-/smob-1.5.0.tgz", + "integrity": "sha512-g6T+p7QO8npa+/hNx9ohv1E5pVCmWrVCUzUXJyLdMmftX6ER0oiWY/w9knEonLpnOp6b6FenKnMfR8gqwWdwig==", "dev": true }, "node_modules/snarkjs": { @@ -6130,79 +6226,6 @@ "escodegen": "^1.8.1" } }, - "node_modules/static-eval/node_modules/escodegen": { - "version": "1.14.3", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.14.3.tgz", - "integrity": "sha512-qFcX0XJkdg+PB3xjZZG/wKSuT1PnQWx57+TVSjIMmILd2yC/6ByYElPwJnslDsuWuSAp4AwJGumarAAmJch5Kw==", - "peer": true, - "dependencies": { - "esprima": "^4.0.1", - "estraverse": "^4.2.0", - "esutils": "^2.0.2", - "optionator": "^0.8.1" - }, - "bin": { - "escodegen": "bin/escodegen.js", - "esgenerate": "bin/esgenerate.js" - }, - "engines": { - "node": ">=4.0" - }, - "optionalDependencies": { - "source-map": "~0.6.1" - } - }, - "node_modules/static-eval/node_modules/levn": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", - "peer": true, - "dependencies": { - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/static-eval/node_modules/optionator": { - "version": "0.8.3", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", - "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", - "peer": true, - "dependencies": { - "deep-is": "~0.1.3", - "fast-levenshtein": "~2.0.6", - "levn": "~0.3.0", - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2", - "word-wrap": "~1.2.3" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/static-eval/node_modules/prelude-ls": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", - "integrity": "sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==", - "peer": true, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/static-eval/node_modules/type-check": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", - "integrity": "sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==", - "peer": true, - "dependencies": { - "prelude-ls": "~1.1.2" - }, - "engines": { - "node": ">= 0.8.0" - } - }, "node_modules/string_decoder": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", @@ -6295,15 +6318,18 @@ } }, "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==", + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, "dependencies": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=4" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" } }, "node_modules/supports-preserve-symlinks-flag": { @@ -6364,9 +6390,9 @@ } }, "node_modules/terser": { - "version": "5.27.2", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.27.2.tgz", - "integrity": "sha512-sHXmLSkImesJ4p5apTeT63DsV4Obe1s37qT8qvwHRmVxKTBH7Rv9Wr26VcAMmLbmk9UliiwK8z+657NyJHHy/w==", + "version": "5.30.0", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.30.0.tgz", + "integrity": "sha512-Y/SblUl5kEyEFzhMAQdsxVHh+utAxd4IuRNJzKywY/4uzSogh3G219jqbDDxYu4MXO9CzY3tSEqmZvW6AoEDJw==", "dev": true, "dependencies": { "@jridgewell/source-map": "^0.3.3", @@ -6416,12 +6442,6 @@ } } }, - "node_modules/terser/node_modules/commander": { - "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true - }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", @@ -6534,16 +6554,6 @@ "dev": true, "peer": true }, - "node_modules/ts-command-line-args/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, - "peer": true, - "engines": { - "node": ">=8" - } - }, "node_modules/ts-command-line-args/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -6635,15 +6645,6 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, - "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==", - "dev": true, - "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", @@ -7009,9 +7010,9 @@ } }, "node_modules/watchpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz", - "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==", + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.1.tgz", + "integrity": "sha512-8wrBCMtVhqcXP2Sup1ctSkga6uc2Bx0IIvKyT7yTFier5AXHooSI+QyQQAtTb7+E0IUCCKyTFmXqdqgum2XWGg==", "dev": true, "peer": true, "dependencies": { @@ -7043,27 +7044,27 @@ "dev": true }, "node_modules/webpack": { - "version": "5.90.3", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.90.3.tgz", - "integrity": "sha512-h6uDYlWCctQRuXBs1oYpVe6sFcWedl0dpcVaTf/YF67J9bKvwJajFulMVSYKHrksMB3I/pIagRzDxwxkebuzKA==", + "version": "5.91.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.91.0.tgz", + "integrity": "sha512-rzVwlLeBWHJbmgTC/8TvAcu5vpJNII+MelQpylD4jNERPwpBJOE2lEcko1zJX3QJeLjTTAnQxn/OJ8bjDzVQaw==", "dev": true, "peer": true, "dependencies": { "@types/eslint-scope": "^3.7.3", "@types/estree": "^1.0.5", - "@webassemblyjs/ast": "^1.11.5", - "@webassemblyjs/wasm-edit": "^1.11.5", - "@webassemblyjs/wasm-parser": "^1.11.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", "acorn-import-assertions": "^1.9.0", "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.15.0", + "enhanced-resolve": "^5.16.0", "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", @@ -7071,7 +7072,7 @@ "schema-utils": "^3.2.0", "tapable": "^2.1.1", "terser-webpack-plugin": "^5.3.10", - "watchpack": "^2.4.0", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "bin": { diff --git a/package.json b/package.json index 3f5f9a6d..f325ccae 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@0xpolygonid/js-sdk", - "version": "1.9.4", + "version": "1.10.0", "description": "SDK to work with Polygon ID", "main": "dist/node/cjs/index.js", "module": "dist/node/esm/index.js", @@ -34,7 +34,9 @@ "tsc:declaration:watch": "tsc --watch --module commonjs --emitDeclarationOnly", "test": "env TS_NODE_COMPILER_OPTIONS='{\"strict\": false, \"module\": \"CommonJS\"}' mocha", "lint": "eslint --fix --ext .ts src/** tests/**", - "format": "prettier --write \"src/**/*.ts\" \"tests/**/*.ts\"" + "lint:check": "eslint --ext .ts src/** tests/**", + "format": "prettier --write \"src/**/*.ts\" \"tests/**/*.ts\"", + "format:check": "prettier \"src/**/*.ts\" \"tests/**/*.ts\" --check" }, "repository": { "type": "git", @@ -85,11 +87,11 @@ "typescript": "^4.8.4" }, "peerDependencies": { - "@iden3/js-crypto": "1.0.3", - "@iden3/js-iden3-core": "1.2.1", - "@iden3/js-jsonld-merklization": "1.1.2", - "@iden3/js-jwz": "1.3.0", - "@iden3/js-merkletree": "1.1.2", + "@iden3/js-crypto": "1.1.0", + "@iden3/js-iden3-core": "1.3.1", + "@iden3/js-jsonld-merklization": "1.2.0", + "@iden3/js-jwz": "1.4.0", + "@iden3/js-merkletree": "1.2.0", "ffjavascript": "0.2.63", "rfc4648": "1.5.3", "snarkjs": "0.7.3" @@ -121,6 +123,6 @@ ] }, "engines": { - "node": ">=18.16.0" + "node": ">=20.11.0" } } diff --git a/src/circuits/atomic-query-sig-v2-on-chain.ts b/src/circuits/atomic-query-sig-v2-on-chain.ts index 71874290..a3d901d6 100644 --- a/src/circuits/atomic-query-sig-v2-on-chain.ts +++ b/src/circuits/atomic-query-sig-v2-on-chain.ts @@ -1,8 +1,7 @@ -import { newHashFromString, Proof } from '@iden3/js-merkletree'; import { Id, Claim } from '@iden3/js-iden3-core'; import { Signature } from '@iden3/js-crypto'; import { Query, ValueProof, CircuitError, ClaimWithSigProof, TreeState, GISTProof } from './models'; -import { Hash } from '@iden3/js-merkletree'; +import { Hash, Proof } from '@iden3/js-merkletree'; import { BaseConfig, bigIntArrayToStringArray, @@ -365,7 +364,7 @@ export class AtomicQuerySigV2OnChainPubSignals extends BaseConfig { fieldIdx++; // - issuerAuthState - this.issuerAuthState = newHashFromString(sVals[fieldIdx]); + this.issuerAuthState = Hash.fromString(sVals[fieldIdx]); fieldIdx++; // - requestID @@ -377,7 +376,7 @@ export class AtomicQuerySigV2OnChainPubSignals extends BaseConfig { fieldIdx++; // - gistRoot - this.gistRoot = newHashFromString(sVals[fieldIdx]); + this.gistRoot = Hash.fromString(sVals[fieldIdx]); fieldIdx++; // - issuerID @@ -389,7 +388,7 @@ export class AtomicQuerySigV2OnChainPubSignals extends BaseConfig { fieldIdx++; // - issuerClaimNonRevState - this.issuerClaimNonRevState = newHashFromString(sVals[fieldIdx]); + this.issuerClaimNonRevState = Hash.fromString(sVals[fieldIdx]); fieldIdx++; // - timestamp diff --git a/src/circuits/state-transition.ts b/src/circuits/state-transition.ts index 5578ce85..9baf6678 100644 --- a/src/circuits/state-transition.ts +++ b/src/circuits/state-transition.ts @@ -1,6 +1,6 @@ import { Signature } from '@iden3/js-crypto'; import { Id } from '@iden3/js-iden3-core'; -import { Hash, newHashFromString, Proof } from '@iden3/js-merkletree'; +import { Hash, Proof } from '@iden3/js-merkletree'; import { BaseConfig, getNodeAuxValue, prepareSiblingsStr } from './common'; import { ClaimWithMTPProof, TreeState, CircuitError } from './models'; import { byteDecoder, byteEncoder } from '../utils'; @@ -130,8 +130,8 @@ export class StateTransitionPubSignals { ); } this.userId = Id.fromBigInt(BigInt(sVals[0])); - this.oldUserState = newHashFromString(sVals[1]); - this.newUserState = newHashFromString(sVals[2]); + this.oldUserState = Hash.fromString(sVals[1]); + this.newUserState = Hash.fromString(sVals[2]); this.isOldStateGenesis = BigInt(sVals[3]) === BigInt(1); return this; diff --git a/src/identity/identity-wallet.ts b/src/identity/identity-wallet.ts index f03d4a23..831b7444 100644 --- a/src/identity/identity-wallet.ts +++ b/src/identity/identity-wallet.ts @@ -438,7 +438,7 @@ export class IdentityWallet implements IIdentityWallet { opts.method = opts.method ?? DidMethod.Iden3; opts.blockchain = opts.blockchain ?? Blockchain.Polygon; - opts.networkId = opts.networkId ?? NetworkId.Mumbai; + opts.networkId = opts.networkId ?? NetworkId.Amoy; await this._storage.mt.createIdentityMerkleTrees(tmpIdentifier); diff --git a/tests/circuits/atomic-query-mtp-v2-on-chain.test.ts b/tests/circuits/atomic-query-mtp-v2-on-chain.test.ts index 83e0ffb9..8290cf29 100644 --- a/tests/circuits/atomic-query-mtp-v2-on-chain.test.ts +++ b/tests/circuits/atomic-query-mtp-v2-on-chain.test.ts @@ -1,5 +1,5 @@ import { Id } from '@iden3/js-iden3-core'; -import { newHashFromString } from '@iden3/js-merkletree'; +import { Hash } from '@iden3/js-merkletree'; import { AtomicQueryMTPV2OnChainInputs, AtomicQueryMTPV2OnChainPubSignals, @@ -153,10 +153,10 @@ describe('atomic-query-mtp-v2-on-chain', () => { exp.issuerID = Id.fromBigInt( BigInt('27918766665310231445021466320959318414450284884582375163563581940319453185') ); - exp.issuerClaimIdenState = newHashFromString( + exp.issuerClaimIdenState = Hash.fromString( '19157496396839393206871475267813888069926627705277243727237933406423274512449' ); - exp.issuerClaimNonRevState = newHashFromString( + exp.issuerClaimNonRevState = Hash.fromString( '19157496396839393206871475267813888069926627705277243727237933406423274512449' ); exp.circuitQueryHash = queryHash; @@ -164,7 +164,7 @@ describe('atomic-query-mtp-v2-on-chain', () => { exp.merklized = 0; exp.isRevocationChecked = 1; (exp.challenge = BigInt(10)), - (exp.gistRoot = newHashFromString( + (exp.gistRoot = Hash.fromString( '11098939821764568131087645431296528907277253709936443029379587475821759259406' )); expect(exp).to.deep.equal(out); diff --git a/tests/circuits/atomic-query-mtp-v2.test.ts b/tests/circuits/atomic-query-mtp-v2.test.ts index 430e7a2c..604dba61 100644 --- a/tests/circuits/atomic-query-mtp-v2.test.ts +++ b/tests/circuits/atomic-query-mtp-v2.test.ts @@ -1,5 +1,5 @@ import { Id, SchemaHash } from '@iden3/js-iden3-core'; -import { newHashFromString } from '@iden3/js-merkletree'; +import { Hash } from '@iden3/js-merkletree'; import { AtomicQueryMTPV2Inputs, AtomicQueryMTPV2PubSignals, @@ -177,10 +177,10 @@ describe('atomic-query-mtp-v2', () => { exp.issuerID = Id.fromBigInt( BigInt('23528770672049181535970744460798517976688641688582489375761566420828291073') ); - exp.issuerClaimIdenState = newHashFromString( + exp.issuerClaimIdenState = Hash.fromString( '5687720250943511874245715094520098014548846873346473635855112185560372332782' ); - exp.issuerClaimNonRevState = newHashFromString( + exp.issuerClaimNonRevState = Hash.fromString( '5687720250943511874245715094520098014548846873346473635855112185560372332782' ); exp.claimSchema = SchemaHash.newSchemaHashFromInt( diff --git a/tests/circuits/atomic-query-sig-v2-on-chain.test.ts b/tests/circuits/atomic-query-sig-v2-on-chain.test.ts index 9a3c48a9..30f1a85f 100644 --- a/tests/circuits/atomic-query-sig-v2-on-chain.test.ts +++ b/tests/circuits/atomic-query-sig-v2-on-chain.test.ts @@ -1,5 +1,5 @@ import { Id } from '@iden3/js-iden3-core'; -import { newHashFromString } from '@iden3/js-merkletree'; +import { Hash } from '@iden3/js-merkletree'; import { AtomicQuerySigV2OnChainInputs, AtomicQuerySigV2OnChainPubSignals, @@ -167,10 +167,10 @@ describe('atomic-query-sig-v2-on-chain', () => { exp.issuerID = Id.fromBigInt( BigInt('27918766665310231445021466320959318414450284884582375163563581940319453185') ); - exp.issuerAuthState = newHashFromString( + exp.issuerAuthState = Hash.fromString( '20177832565449474772630743317224985532862797657496372535616634430055981993180' ); - exp.issuerClaimNonRevState = newHashFromString( + exp.issuerClaimNonRevState = Hash.fromString( '20177832565449474772630743317224985532862797657496372535616634430055981993180' ); exp.circuitQueryHash = queryHash; @@ -178,7 +178,7 @@ describe('atomic-query-sig-v2-on-chain', () => { exp.merklized = 0; exp.isRevocationChecked = 1; (exp.challenge = BigInt(10)), - (exp.gistRoot = newHashFromString( + (exp.gistRoot = Hash.fromString( '11098939821764568131087645431296528907277253709936443029379587475821759259406' )); expect(exp).to.deep.equal(out); diff --git a/tests/circuits/atomic-query-sig-v2.test.ts b/tests/circuits/atomic-query-sig-v2.test.ts index d6b96cb3..ff6bba52 100644 --- a/tests/circuits/atomic-query-sig-v2.test.ts +++ b/tests/circuits/atomic-query-sig-v2.test.ts @@ -1,5 +1,5 @@ import { Id, SchemaHash } from '@iden3/js-iden3-core'; -import { newHashFromString } from '@iden3/js-merkletree'; +import { Hash } from '@iden3/js-merkletree'; import { AtomicQuerySigV2Inputs, AtomicQuerySigV2PubSignals, @@ -191,10 +191,10 @@ describe('atomic-query-sig-v2', () => { exp.issuerID = Id.fromBigInt( BigInt('21933750065545691586450392143787330185992517860945727248803138245838110721') ); - exp.issuerAuthState = newHashFromString( + exp.issuerAuthState = Hash.fromString( '2943483356559152311923412925436024635269538717812859789851139200242297094' ); - exp.issuerClaimNonRevState = newHashFromString( + exp.issuerClaimNonRevState = Hash.fromString( '2943483356559152311923412925436024635269538717812859789851139200242297094' ); exp.claimSchema = SchemaHash.newSchemaHashFromInt( diff --git a/tests/circuits/auth-v2.test.ts b/tests/circuits/auth-v2.test.ts index 85bf4baa..63274c32 100644 --- a/tests/circuits/auth-v2.test.ts +++ b/tests/circuits/auth-v2.test.ts @@ -1,6 +1,6 @@ import { AuthV2PubSignals } from './../../src/circuits/auth-v2'; import { Id } from '@iden3/js-iden3-core'; -import { newHashFromBigInt } from '@iden3/js-merkletree'; +import { Hash } from '@iden3/js-merkletree'; import { AuthV2Inputs } from '../../src/circuits'; import { IdentityTest, userPK, issuerPK, globalTree } from './utils'; import expectedJson from './data/auth-v2-inputs.json'; @@ -63,7 +63,7 @@ describe('auth-v2', () => { const stateInt = BigInt( '18656147546666944484453899241916469544090258810192803949522794490493271005313' ); - const state = newHashFromBigInt(stateInt); + const state = Hash.fromBigInt(stateInt); const out = byteEncoder.encode( JSON.stringify([ diff --git a/tests/circuits/state-transition.test.ts b/tests/circuits/state-transition.test.ts index df04add7..3b705ab9 100644 --- a/tests/circuits/state-transition.test.ts +++ b/tests/circuits/state-transition.test.ts @@ -1,6 +1,6 @@ import { poseidon } from '@iden3/js-crypto'; import { Id } from '@iden3/js-iden3-core'; -import { hashElems, newHashFromBigInt, ZERO_HASH } from '@iden3/js-merkletree'; +import { hashElems, Hash, ZERO_HASH } from '@iden3/js-merkletree'; import { getProperties, TreeState } from '../../src/circuits'; import { @@ -16,8 +16,8 @@ describe('state-transition', () => { const id = Id.fromBigInt(28042998099552461593195291926480304872594404846081442121556507376347845121n); - const newState = newHashFromBigInt(BigInt(1)); - const oldState = newHashFromBigInt(BigInt(2)); + const newState = Hash.fromBigInt(1n); + const oldState = Hash.fromBigInt(2n); const sto = new StateTransitionPubSignals(); sto.newUserState = newState; @@ -60,7 +60,7 @@ describe('state-transition', () => { // update rev tree await revTree.add(BigInt(1), BigInt(0)); - const newState = await hashElems([ + const newState = hashElems([ (await claimsTree.root()).bigInt(), (await revTree.root()).bigInt(), ZERO_HASH.bigInt() @@ -96,7 +96,7 @@ describe('state-transition', () => { const inputBytes = sti.inputsMarshal(); - const expectedJSONInputs = `{"authClaim":["80551937543569765027552589160822318028","0","9582165609074695838007712438814613121302719752874385708394134542816240804696","18271435592817415588213874506882839610978320325722319742324814767882756910515","11203087622270641253","0","0","0"],"authClaimMtp":["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"],"authClaimNonRevMtp":["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"],"newAuthClaimMtp":["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"],"userID":"28042998099552461593195291926480304872594404846081442121556507376347845121","newUserState":"8717994378109424649893756016288492635910918769904280638970270379188098989082","claimsTreeRoot":"10304430946970870697981400054531724100803206948489006715521525892274350097449","oldUserState":"20177832565449474772630743317224985532862797657496372535616634430055981993180","revTreeRoot":"0","rootsTreeRoot":"0","signatureR8x":"586684641065293574681175944568309007486914963323113557570969829920744971136","signatureR8y":"19584916991773525781729014480657258633764115167499561241730396722769308232705","signatureS":"1490756235916606497547608218550374490509259398504600808524183003820201544678","newClaimsTreeRoot":"10304430946970870697981400054531724100803206948489006715521525892274350097449","newRootsTreeRoot":"0","newRevTreeRoot":"19374975721259875597650302716689543547647001662517455822229477759190533109280","isOldStateGenesis":"1","authClaimNonRevMtpAuxHi":"0","authClaimNonRevMtpAuxHv":"0","authClaimNonRevMtpNoAux":"1"}`; + const expectedJSONInputs = `{"authClaim":["80551937543569765027552589160822318028","0","9582165609074695838007712438814613121302719752874385708394134542816240804696","18271435592817415588213874506882839610978320325722319742324814767882756910515","11203087622270641253","0","0","0"],"authClaimMtp":["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"],"authClaimNonRevMtp":["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"],"newAuthClaimMtp":["0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"],"userID":"28049899845899252156982726682342581898046855955053612508111669900571644673","newUserState":"8717994378109424649893756016288492635910918769904280638970270379188098989082","claimsTreeRoot":"10304430946970870697981400054531724100803206948489006715521525892274350097449","oldUserState":"20177832565449474772630743317224985532862797657496372535616634430055981993180","revTreeRoot":"0","rootsTreeRoot":"0","signatureR8x":"586684641065293574681175944568309007486914963323113557570969829920744971136","signatureR8y":"19584916991773525781729014480657258633764115167499561241730396722769308232705","signatureS":"1490756235916606497547608218550374490509259398504600808524183003820201544678","newClaimsTreeRoot":"10304430946970870697981400054531724100803206948489006715521525892274350097449","newRootsTreeRoot":"0","newRevTreeRoot":"19374975721259875597650302716689543547647001662517455822229477759190533109280","isOldStateGenesis":"1","authClaimNonRevMtpAuxHi":"0","authClaimNonRevMtpAuxHv":"0","authClaimNonRevMtpNoAux":"1"}`; expect(JSON.parse(expectedJSONInputs)).to.deep.equal( JSON.parse(byteDecoder.decode(inputBytes)) diff --git a/tests/circuits/utils.ts b/tests/circuits/utils.ts index b680cc79..e3a32bcc 100644 --- a/tests/circuits/utils.ts +++ b/tests/circuits/utils.ts @@ -168,7 +168,7 @@ export async function generate(privKeyHex: string): Promise<{ const state = poseidon.hash([ctr.bigInt(), BigInt(0), BigInt(0)]); // create new identity const identity = Id.idGenesisFromIdenState( - buildDIDType(DidMethod.Iden3, Blockchain.Polygon, NetworkId.Mumbai), + buildDIDType(DidMethod.Iden3, Blockchain.Polygon, NetworkId.Amoy), state ); diff --git a/tests/credentials/credential-statuses/on-chain-revocation.test.ts b/tests/credentials/credential-statuses/on-chain-revocation.test.ts index d90fbafb..b0ffa923 100644 --- a/tests/credentials/credential-statuses/on-chain-revocation.test.ts +++ b/tests/credentials/credential-statuses/on-chain-revocation.test.ts @@ -49,13 +49,13 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'extract information from credentialStatus.id', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?revocationNonce=1234&contractAddress=80001:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?revocationNonce=1234&contractAddress=80002:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: 0 }, output: { contractAddress: '0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', - chainId: 80001, + chainId: 80002, revocationNonce: 1234, stateHex: '' } @@ -63,13 +63,13 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'revocation nonce is 0 on id', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?revocationNonce=0&contractAddress=80001:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?revocationNonce=0&contractAddress=80002:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: undefined }, output: { contractAddress: '0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', - chainId: 80001, + chainId: 80002, revocationNonce: 0, stateHex: '' } @@ -77,13 +77,13 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'revocation nonce is 0 on credentialStatus', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?contractAddress=80001:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?contractAddress=80002:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: 0 }, output: { contractAddress: '0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', - chainId: 80001, + chainId: 80002, revocationNonce: 0, stateHex: '' } @@ -91,13 +91,13 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'Parse stateHex from credentialStatus.id', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?contractAddress=80001:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2&state=a1abdb9f44c7b649eb4d21b59ef34bd38e054aa3e500987575a14fc92c49f42c', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?contractAddress=80002:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2&state=a1abdb9f44c7b649eb4d21b59ef34bd38e054aa3e500987575a14fc92c49f42c', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: 100 }, output: { contractAddress: '0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', - chainId: 80001, + chainId: 80002, revocationNonce: 100, stateHex: 'a1abdb9f44c7b649eb4d21b59ef34bd38e054aa3e500987575a14fc92c49f42c' } @@ -114,7 +114,7 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'invalid contract address format', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?revocationNonce=1234&contractAddress=0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?revocationNonce=1234&contractAddress=0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: 4321 }, @@ -123,7 +123,7 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'revocationNonce is empty', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?contractAddress=80001:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus?contractAddress=80002:0x2fCE183c7Fbc4EbB5DB3B0F5a63e0e02AE9a85d2', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: undefined }, @@ -132,7 +132,7 @@ describe('parse credential status with type Iden3OnchainSparseMerkleTreeProof202 { name: 'contractAddress is required parameter', input: { - id: 'did:polygonid:polygon:mumbai:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus', + id: 'did:polygonid:polygon:amoy:2qCU58EJgrELbXjWbWGC9kPPnczQdp93nUR6LC45F6/credentialStatus', type: CredentialStatusType.Iden3OnchainSparseMerkleTreeProof2023, revocationNonce: 1234 }, @@ -196,7 +196,7 @@ describe('onchain revocation checks', () => { const ethStorage = new EthStateStorage({ ...defaultEthConnectionConfig, contractAddress: STATE_CONTRACT, - chainId: 80001, + chainId: 80002, url: RPC_URL }); @@ -215,7 +215,7 @@ describe('onchain revocation checks', () => { ...defaultEthConnectionConfig, url: RPC_URL, contractAddress: STATE_CONTRACT, - chainId: 80001 + chainId: 80002 } ]); diff --git a/tests/credentials/credential-statuses/rhs.test.ts b/tests/credentials/credential-statuses/rhs.test.ts index 5166751b..1e692aa4 100644 --- a/tests/credentials/credential-statuses/rhs.test.ts +++ b/tests/credentials/credential-statuses/rhs.test.ts @@ -20,13 +20,12 @@ import { Blockchain, DidMethod, NetworkId } from '@iden3/js-iden3-core'; import { expect } from 'chai'; import { RHSResolver } from '../../../src/credentials'; import { CredentialStatusResolverRegistry } from '../../../src/credentials'; +import { RHS_URL, SEED_USER, createIdentity } from '../../helpers'; describe('rhs', () => { let idWallet: IdentityWallet; let credWallet: CredentialWallet; let dataStorage: IDataStorage; - const rhsUrl = process.env.RHS_URL as string; - const infuraUrl = process.env.RPC_URL as string; const mockStateStorageForGenesisState: IStateStorage = { getLatestStateById: async () => { @@ -65,12 +64,12 @@ describe('rhs', () => { const mockStateStorageForDefinedState: IStateStorage = { getLatestStateById: async () => { return { - id: 25191641634853875207018381290409317860151551336133597267061715643603096065n, - state: 16074735548090432706010308621156024769148807454202029933745588915345672503542n, + id: 25198543381200665770805816046271594885604002445105767653616878167826895617n, + state: 20397203454293344824319112126262598089448492524764346423396986451600214023752n, replacedByState: 0n, - createdAtTimestamp: 1672245326n, + createdAtTimestamp: 1712062738n, replacedAtTimestamp: 0n, - createdAtBlock: 30258020n, + createdAtBlock: 5384981n, replacedAtBlock: 0n }; }, @@ -106,12 +105,12 @@ describe('rhs', () => { const mockStateStorageForSecondState: IStateStorage = { getLatestStateById: async () => { return { - id: 25191641634853875207018381290409317860151551336133597267061715643603096065n, - state: 6579597760262775007137624273344484963760596803465690980061360458400178710641n, + id: 25198543381200665770805816046271594885604002445105767653616878167826895617n, + state: 9825378702528281403624130829967493160346534249838500892034361176934961813026n, replacedByState: 0n, - createdAtTimestamp: 1672245326n, + createdAtTimestamp: 1712064534n, replacedAtTimestamp: 0n, - createdAtBlock: 30258020n, + createdAtBlock: 5385826n, replacedAtBlock: 0n }; }, @@ -150,11 +149,7 @@ describe('rhs', () => { const bjjProvider = new BjjProvider(KmsKeyType.BabyJubJub, memoryKeyStore); const kms = new KMS(); kms.registerKeyProvider(KmsKeyType.BabyJubJub, bjjProvider); - - const conf = defaultEthConnectionConfig; - conf.url = infuraUrl; - conf.contractAddress = '0xf6781AD281d9892Df285cf86dF4F6eBec2042d71'; - const ethStorage = new EthStateStorage(conf); + const ethStorage = new EthStateStorage(defaultEthConnectionConfig); ethStorage.publishState = mockStateStorageForGenesisState.publishState; dataStorage = { @@ -192,11 +187,11 @@ describe('rhs', () => { const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhraseIssuer, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl + id: RHS_URL } }); @@ -208,7 +203,7 @@ describe('rhs', () => { type: CredentialStatusType.SparseMerkleTreeProof }; const credRHSStatus: CredentialStatus = { - id: rhsUrl, + id: RHS_URL, type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, revocationNonce: 0, statusIssuer: credBasicStatus @@ -229,32 +224,12 @@ describe('rhs', () => { }); it('mocked issuer state', async () => { - const seedPhrase: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseeduser'); - - const seedPhraseIssuer: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseedseed'); - - const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhraseIssuer, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } - }); + const { did: issuerDID, credential: issuerAuthCredential } = await createIdentity(idWallet, {}); await credWallet.save(issuerAuthCredential); - const { did: userDID } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhrase, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } + const { did: userDID } = await createIdentity(idWallet, { + seed: SEED_USER }); const credBasicStatus: CredentialStatus = { @@ -264,7 +239,7 @@ describe('rhs', () => { }; const credRHSStatus: CredentialStatus = { - id: rhsUrl, + id: RHS_URL, type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, revocationNonce: 0, statusIssuer: credBasicStatus @@ -283,7 +258,7 @@ describe('rhs', () => { revocationOpts: { nonce: 1000, type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl + id: RHS_URL } }; @@ -293,7 +268,7 @@ describe('rhs', () => { const res = await idWallet.addCredentialsToMerkleTree([issuerCred], issuerDID); - await idWallet.publishStateToRHS(issuerDID, rhsUrl); + await idWallet.publishStateToRHS(issuerDID, RHS_URL); const rhsResolver = new RHSResolver(mockStateStorageForDefinedState); const rhsStatus = await rhsResolver.resolve(credRHSStatus, { issuerDID }); @@ -304,32 +279,14 @@ describe('rhs', () => { expect(rhsStatus.issuer.rootOfRoots).to.equal(res.newTreeState.rootOfRoots.hex()); expect(rhsStatus.mtp.existence).to.equal(false); }); - it('two creds. one revoked', async () => { - const seedPhrase: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseeduser'); - const seedPhraseIssuer: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseedseed'); - const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhraseIssuer, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } - }); + it('two creds. one revoked', async () => { + const { did: issuerDID, credential: issuerAuthCredential } = await createIdentity(idWallet); await credWallet.save(issuerAuthCredential); - const { did: userDID, credential } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhrase, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } + const { did: userDID, credential } = await createIdentity(idWallet, { + seed: SEED_USER }); expect(credential).not.to.be.undefined; @@ -340,7 +297,7 @@ describe('rhs', () => { type: CredentialStatusType.SparseMerkleTreeProof }; const credRHSStatus: CredentialStatus = { - id: rhsUrl, + id: RHS_URL, type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, revocationNonce: 1000, statusIssuer: credBasicStatus @@ -359,7 +316,7 @@ describe('rhs', () => { revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, nonce: 1000, - id: rhsUrl + id: RHS_URL } }; @@ -383,7 +340,7 @@ describe('rhs', () => { expiration: 2793526400, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl, + id: RHS_URL, nonce: 1001 } }; @@ -398,7 +355,7 @@ describe('rhs', () => { const latestTree = await idWallet.getDIDTreeModel(issuerDID); - await idWallet.publishStateToRHS(issuerDID, rhsUrl, [nonce]); + await idWallet.publishStateToRHS(issuerDID, RHS_URL, [nonce]); // state is published to blockchain (2) dataStorage.states = mockStateStorageForSecondState; diff --git a/tests/handlers/auth.test.ts b/tests/handlers/auth.test.ts index 4e8eb568..3b8639d7 100644 --- a/tests/handlers/auth.test.ts +++ b/tests/handlers/auth.test.ts @@ -1217,6 +1217,7 @@ describe('auth', () => { await authHandler.handleAuthorizationResponse(authRes.authResponse, authReq, testOpts); }); + it('auth response: TestVerifyV3MessageWithMtpProof_Merklized_noop', async () => { const claimReq: CredentialRequest = { credentialSchema: diff --git a/tests/handlers/contract-request.test.ts b/tests/handlers/contract-request.test.ts index 5e799864..089b0f12 100644 --- a/tests/handlers/contract-request.test.ts +++ b/tests/handlers/contract-request.test.ts @@ -203,7 +203,7 @@ describe('contract-request', () => { const { did: userDID, credential: cred } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhrase, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -216,7 +216,7 @@ describe('contract-request', () => { const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhraseIssuer, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -302,7 +302,8 @@ describe('contract-request', () => { it.skip('contract request flow - integration test', async () => { const stateEthConfig = defaultEthConnectionConfig; stateEthConfig.url = rpcUrl; - stateEthConfig.contractAddress = '0x134b1be34911e39a8397ec6289782989729807a4'; + stateEthConfig.contractAddress = '0x1a4cC30f2aA0377b0c3bc9848766D90cb4404124'; + stateEthConfig.chainId = 80002; const memoryKeyStore = new InMemoryPrivateKeyStore(); const bjjProvider = new BjjProvider(KmsKeyType.BabyJubJub, memoryKeyStore); @@ -341,7 +342,7 @@ describe('contract-request', () => { const { did: userDID, credential: cred } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhrase, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -354,7 +355,7 @@ describe('contract-request', () => { const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhraseIssuer, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -399,11 +400,11 @@ describe('contract-request', () => { } }; - const contractAddress = '0x3a4d4E47bFfF6bD0EF3cd46580D9e36F3367da03'; + const contractAddress = '0x2b23e5cF70D133fFaA7D8ba61E1bAC4637253880'; const conf = defaultEthConnectionConfig; conf.contractAddress = contractAddress; conf.url = rpcUrl; - conf.chainId = 80001; + conf.chainId = 80002; const zkpVerifier = new OnChainZKPVerifier([conf]); contractRequestHandler = new ContractRequestHandler(packageMgr, proofService, zkpVerifier); @@ -453,7 +454,7 @@ describe('contract-request', () => { it.skip('contract request flow V3 - integration test', async () => { const stateEthConfig = defaultEthConnectionConfig; stateEthConfig.url = rpcUrl; - stateEthConfig.contractAddress = '0x134b1be34911e39a8397ec6289782989729807a4'; + stateEthConfig.contractAddress = '0x1a4cC30f2aA0377b0c3bc9848766D90cb4404124'; const memoryKeyStore = new InMemoryPrivateKeyStore(); const bjjProvider = new BjjProvider(KmsKeyType.BabyJubJub, memoryKeyStore); @@ -492,7 +493,7 @@ describe('contract-request', () => { const { did: userDID, credential: cred } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhrase, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -505,7 +506,7 @@ describe('contract-request', () => { const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhraseIssuer, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -571,12 +572,12 @@ describe('contract-request', () => { } ]; - const erc20Verifier = '0x36eB0E70a456c310D8d8d15ae01F6D5A7C15309A'; - const verifierDid = 'did:polygonid:polygon:mumbai:2qCU58EJgrELdThzMyykDwT5kWff6XSbpSWtTQ7oS8'; + const erc20Verifier = '0xc5Cd536cb9Cc3BD24829502A39BE593354986dc4'; + const verifierDid = 'did:polygonid:polygon:amoy:2qQ68JkRcf3ymy9wtzKyY3Dajst9c6cHCDZyx7NrTz'; const conf = defaultEthConnectionConfig; conf.contractAddress = erc20Verifier; conf.url = rpcUrl; - conf.chainId = 80001; + conf.chainId = 80002; const zkpVerifier = new OnChainZKPVerifier([conf]); contractRequestHandler = new ContractRequestHandler(packageMgr, proofService, zkpVerifier); diff --git a/tests/helpers.ts b/tests/helpers.ts index d2bcddc1..21f823d3 100644 --- a/tests/helpers.ts +++ b/tests/helpers.ts @@ -49,7 +49,7 @@ export const createIdentity = async ( return await wallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: SEED_ISSUER, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -69,7 +69,8 @@ export const MOCK_STATE_STORAGE: IStateStorage = { '26675680708205250151451142983868154544835349648265874601395279235340702210', '27752766823371471408248225708681313764866231655187366071881070918984471042', '21803003425107230045260507608510138502859759480520560654156359021447614978', - '25191641634853875207018381290409317860151551336133597267061715643603096065' + '25191641634853875207018381290409317860151551336133597267061715643603096065', + '25198543381200665770805816046271594885604002445105767653616878167826895617' ]; if (validTestIds.includes(id.toString())) { return { id, state }; diff --git a/tests/identity/id.test.ts b/tests/identity/id.test.ts index 535efa3c..2dc9304f 100644 --- a/tests/identity/id.test.ts +++ b/tests/identity/id.test.ts @@ -26,6 +26,8 @@ describe('identity', () => { let idWallet: IdentityWallet; let dataStorage: IDataStorage; + const expectedDID = 'did:iden3:polygon:amoy:xCRp75DgAdS63W65fmXHz6p9DwdonuRU9e46DifhX'; + const createClaimReq = ( credentialSubjectId: string, opts?: Partial @@ -61,9 +63,7 @@ describe('identity', () => { it('createIdentity', async () => { const { did, credential } = await createIdentity(idWallet); - expect(did.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(did.string()).to.equal(expectedDID); const dbCred = await dataStorage.credential.findCredentialById(credential.id); expect(credential).to.deep.equal(dbCred); @@ -78,13 +78,11 @@ describe('identity', () => { it('createProfile', async () => { const { did } = await createIdentity(idWallet); - expect(did.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(did.string()).to.equal(expectedDID); const profileDID = await idWallet.createProfile(did, 10, 'http://polygonissuer.com/'); expect(profileDID.string()).to.equal( - 'did:iden3:polygon:mumbai:x2Ld4XmxEo6oGCSr3MsqBa5PmJie6WJ6pFbetzYuq' + 'did:iden3:polygon:amoy:xHMd1mimHu3Gc1nhe3DXrimqUCNtgYP8gcuGAHgxm' ); const dbProfile = await dataStorage.identity.getProfileByVerifier('http://polygonissuer.com/'); @@ -98,9 +96,7 @@ describe('identity', () => { it('sign', async () => { const { did, credential } = await createIdentity(idWallet); - expect(did.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(did.string()).to.equal(expectedDID); const enc = byteEncoder; // always utf-8 @@ -114,9 +110,7 @@ describe('identity', () => { it('generateMtp', async () => { const { did, credential } = await createIdentity(idWallet); - expect(did.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(did.string()).to.equal(expectedDID); const proof = await idWallet.generateCredentialMtp(did, credential); @@ -125,9 +119,7 @@ describe('identity', () => { it('generateNonRevProof', async () => { const { did, credential } = await createIdentity(idWallet); - expect(did.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(did.string()).to.equal(expectedDID); const proof = await idWallet.generateNonRevocationMtp(did, credential); @@ -136,9 +128,7 @@ describe('identity', () => { it('generateNonRevProof', async () => { const { did, credential } = await createIdentity(idWallet); - expect(did.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(did.string()).to.equal(expectedDID); const proof = await idWallet.generateNonRevocationMtp(did, credential); @@ -148,9 +138,7 @@ describe('identity', () => { it('issueCredential', async () => { const { did: issuerDID, credential: issuerAuthCredential } = await createIdentity(idWallet); - expect(issuerDID.string()).to.equal( - 'did:iden3:polygon:mumbai:wzokvZ6kMoocKJuSbftdZxTD6qvayGpJb3m4FVXth' - ); + expect(issuerDID.string()).to.equal(expectedDID); expect(issuerAuthCredential).not.to.be.undefined; diff --git a/tests/proofs/mtp-onchain.test.ts b/tests/proofs/mtp-onchain.test.ts index b8ceda81..a8310636 100644 --- a/tests/proofs/mtp-onchain.test.ts +++ b/tests/proofs/mtp-onchain.test.ts @@ -133,7 +133,7 @@ describe('mtp onchain proofs', () => { const { did: userDID } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhrase, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -144,7 +144,7 @@ describe('mtp onchain proofs', () => { const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhraseIssuer, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, diff --git a/tests/proofs/mtp.test.ts b/tests/proofs/mtp.test.ts index f40f2b72..23a3a107 100644 --- a/tests/proofs/mtp.test.ts +++ b/tests/proofs/mtp.test.ts @@ -21,10 +21,10 @@ import { RootInfo, StateProof } from '../../src/storage/entities/state'; import path from 'path'; import { CredentialStatusType, VerifiableConstants, W3CCredential } from '../../src/verifiable'; import { ZeroKnowledgeProofRequest } from '../../src/iden3comm'; -import { Blockchain, DidMethod, NetworkId } from '@iden3/js-iden3-core'; import { expect } from 'chai'; import { CredentialStatusResolverRegistry } from '../../src/credentials'; import { RHSResolver } from '../../src/credentials'; +import { SEED_USER, createIdentity } from '../helpers'; describe('mtp proofs', () => { let idWallet: IdentityWallet; @@ -123,30 +123,11 @@ describe('mtp proofs', () => { }); const nonMerklizedTest = async (circuitId: CircuitId) => { - const seedPhraseIssuer: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseedseed'); - const seedPhrase: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseeduser'); - - const { did: userDID } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhrase, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } + const { did: userDID } = await createIdentity(idWallet, { + seed: SEED_USER }); - const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhraseIssuer, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } - }); + const { did: issuerDID, credential: issuerAuthCredential } = await createIdentity(idWallet); await credWallet.save(issuerAuthCredential); const claimReq: CredentialRequest = { @@ -231,28 +212,13 @@ describe('mtp proofs', () => { const merklizedTest = async (circuitId: CircuitId) => { const seedPhraseIssuer: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseedsnew'); - const seedPhrase: Uint8Array = byteEncoder.encode('seedseedseedseedseedseedseeduser'); - const { did: userDID } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhrase, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } + const { did: userDID } = await createIdentity(idWallet, { + seed: SEED_USER }); - const { did: issuerDID, credential: issuerAuthCredential } = await idWallet.createIdentity({ - method: DidMethod.Iden3, - blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, - seed: seedPhraseIssuer, - revocationOpts: { - type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, - id: rhsUrl - } + const { did: issuerDID, credential: issuerAuthCredential } = await createIdentity(idWallet, { + seed: seedPhraseIssuer }); await credWallet.save(issuerAuthCredential); diff --git a/tests/proofs/sig-onchain.test.ts b/tests/proofs/sig-onchain.test.ts index c8e2514c..897463e2 100644 --- a/tests/proofs/sig-onchain.test.ts +++ b/tests/proofs/sig-onchain.test.ts @@ -118,7 +118,7 @@ describe('sig onchain proofs', () => { const { did: userDID } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhrase, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, @@ -129,7 +129,7 @@ describe('sig onchain proofs', () => { const { did: issuerDID } = await idWallet.createIdentity({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed: seedPhraseIssuer, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof, diff --git a/tests/proofs/sig.test.ts b/tests/proofs/sig.test.ts index 4345da73..b5fe7a47 100644 --- a/tests/proofs/sig.test.ts +++ b/tests/proofs/sig.test.ts @@ -107,7 +107,7 @@ describe('sig proofs', () => { const opts = (seed: Uint8Array) => ({ method: DidMethod.Iden3, blockchain: Blockchain.Polygon, - networkId: NetworkId.Mumbai, + networkId: NetworkId.Amoy, seed, revocationOpts: { type: CredentialStatusType.Iden3ReverseSparseMerkleTreeProof,